Updating a Characteristic Value for gatts
Updating a Characteristic Value for gatts
What function call do I use to send the value of the characteristic and the updates to the value? I think its esp_ble_gatts_add_char but I am not sure...the APIs are tough for me to understand. Thanks in advance!
-
- Posts: 79
- Joined: Tue Apr 26, 2016 5:10 am
Re: Updating a Characteristic Value for gatts
I would also very much like to know how to do this.
Re: Updating a Characteristic Value for gatts
Walking through the code I found this structure that appears to be related to passing the value back to the requesting client.
Its located neat the bottom of the esp_gatt_defs.h file
/// Gatt attribute value
typedef struct {
uint8_t value[ESP_GATT_MAX_ATTR_LEN]; /*!< Gatt attribute value */
uint16_t handle; /*!< Gatt attribute handle */
uint16_t offset; /*!< Gatt attribute value offset */
uint16_t len; /*!< Gatt attribute value length */
uint8_t auth_req; /*!< Gatt authentication request */
} esp_gatt_value_t;
/// GATT remote read request response type
typedef union {
esp_gatt_value_t attr_value; /*!< Gatt attribute structure */
uint16_t handle; /*!< Gatt attribute handle */
} esp_gatt_rsp_t;
Its located neat the bottom of the esp_gatt_defs.h file
/// Gatt attribute value
typedef struct {
uint8_t value[ESP_GATT_MAX_ATTR_LEN]; /*!< Gatt attribute value */
uint16_t handle; /*!< Gatt attribute handle */
uint16_t offset; /*!< Gatt attribute value offset */
uint16_t len; /*!< Gatt attribute value length */
uint8_t auth_req; /*!< Gatt authentication request */
} esp_gatt_value_t;
/// GATT remote read request response type
typedef union {
esp_gatt_value_t attr_value; /*!< Gatt attribute structure */
uint16_t handle; /*!< Gatt attribute handle */
} esp_gatt_rsp_t;
Who is online
Users browsing this forum: No registered users and 96 guests