GATT Database¶
-
group
gattdb_api_functions
GATT Database Access Functions.
Functions
-
wiced_bt_gatt_status_t
wiced_bt_gatt_db_init
(const uint8_t *p_gatt_db, uint16_t gatt_db_size, wiced_bt_db_hash_t hash)¶ Initialize the GATT database (Please refer Service and Characteristic macros for MACRO’s to create or add entries to GATT database)
- Parameters
p_gatt_db – [in] : First element in new GATT database array
gatt_db_size – [in] : Size (in bytes) of GATT database
hash – [out] : The calculated database hash value. The hash pointer passed to this function can be NULL incase the application does not support dynamic databases and does not support database caching
- Returns
-
wiced_bt_gatt_status_t
wiced_bt_gatt_add_services_to_db
(const uint8_t *p_gatt_db, uint16_t gatt_db_size, wiced_bt_db_hash_t hash)¶ Add a service module to the database.
Service modules define the complete service handles (i.e Service, characteristics, descriptor, included service declaration handles) The handle range in the service modules have to be distinct, i.e, cannot overlap with any of the existing service modules in the database Note: Set the wiced_bt_cfg_gatt_t::max_db_service_modules to the number of additional services to be added
- Parameters
p_gatt_db – [in] : First element in GATT database array
gatt_db_size – [in] : Size (in bytes) of GATT database
hash – [out] : The calculated database hash value. The hash pointer passed to this function can be NULL incase the application does not support dynamic databases and does not support database caching
- Returns
-
wiced_bt_gatt_status_t
wiced_bt_gatt_db_remove_services_from_db
(const uint8_t *p_gatt_db, wiced_bt_db_hash_t hash)¶ Remove the service module from the database.
- Parameters
p_gatt_db – [in] : First element in GATT database array
hash – [out] : The calculated database hash value. The hash pointer passed to this function can be NULL incase the application does not support dynamic databases and does not support database caching
- Returns
-
wiced_bt_gatt_status_t