Environment Sensing - Sound Level GATT Service#
Provides microphone sound level data in GATT characteristics. Designed for the Thunderboard smartphone app.
Functions#
void
sl_gatt_service_sound_on_event(sl_bt_msg_t *evt)
sl_status_t
sl_gatt_service_sound_get(float *sound_level)
Macros#
#define
SL_GATT_SERVICE_SOUND_INVALID 0x7FFF
Function Documentation#
sl_gatt_service_sound_on_event#
void sl_gatt_service_sound_on_event (sl_bt_msg_t * evt)
Parameters
Type | Direction | Argument Name | Description |
---|---|---|---|
sl_bt_msg_t * | [in] | evt | Event coming from the Bluetooth stack. |
Bluetooth stack event handler.
sl_gatt_service_sound_get#
sl_status_t sl_gatt_service_sound_get (float * sound_level)
Parameters
Type | Direction | Argument Name | Description |
---|---|---|---|
float * | [out] | sound_level | Sound pressure level (in dB). |
Getter for Sound Level characteristic value. Returns
Status of the operation.
Note
To be implemented in user code.