![]() |
Bluetooth LE Profile API document
Bluetooth LE Profile API document Rev.1.00 [May 22, 2020]
|
This is the client for the Continuous Glucose Monitoring Service. More...
This is the client for the Continuous Glucose Monitoring Service.
Data Structures | |
struct | st_ble_cgmc_meas_flags_t |
CGM Measurement Flags value structure. More... | |
struct | st_ble_cgmc_meas_sensor_status_annunciation_t |
CGM Measurement Sensor Status Annunciation value structure. More... | |
struct | st_ble_cgmc_meas_t |
CGM Measurement value structure. More... | |
struct | st_ble_cgmc_meas_attr_hdl_t |
CGM Measurement attribute handle value. More... | |
struct | st_ble_cgmc_feat_cgm_feature_t |
CGM Feature CGM Feature value structure. More... | |
struct | st_ble_cgmc_feat_t |
CGM Feature value structure. More... | |
struct | st_ble_cgmc_feat_attr_hdl_t |
CGM Feature attribute handle value. More... | |
struct | st_ble_cgmc_status_t |
CGM Status value structure. More... | |
struct | st_ble_cgmc_status_attr_hdl_t |
CGM Status attribute handle value. More... | |
struct | st_ble_cgmc_session_start_time_t |
CGM Session Start Time value structure. More... | |
struct | st_ble_cgmc_session_start_time_attr_hdl_t |
CGM Session Start Time attribute handle value. More... | |
struct | st_ble_cgmc_session_run_time_t |
CGM Session Run Time value structure. More... | |
struct | st_ble_cgmc_session_run_time_attr_hdl_t |
CGM Session Run Time attribute handle value. More... | |
struct | st_ble_cgmc_record_access_cp_t |
Record Access Control Point value structure. More... | |
struct | st_ble_cgmc_record_access_cp_attr_hdl_t |
Record Access Control Point attribute handle value. More... | |
struct | st_ble_cgmc_specific_ops_cp_calibration_value_calibration_status_t |
CGM Specific Ops Control Point Calibration Value - Calibration Status value structure. More... | |
struct | st_ble_cgmc_specific_ops_cp_t |
CGM Specific Ops Control Point value structure. More... | |
struct | st_ble_cgmc_specific_ops_cp_attr_hdl_t |
CGM Specific Ops Control Point attribute handle value. More... | |
struct | st_ble_cgmc_evt_data_t |
Continuous Glucose Monitoring client event data. More... | |
Macros | |
#define | BLE_CGMC_MEAS_UUID (0x2AA7) |
#define | BLE_CGMC_MEAS_LEN (15) |
#define | BLE_CGMC_MEAS_CLI_CNFG_UUID (0x2902) |
#define | BLE_CGMC_MEAS_CLI_CNFG_LEN (2) |
#define | BLE_CGMC_FEAT_UUID (0x2AA8) |
#define | BLE_CGMC_FEAT_LEN (6) |
#define | BLE_CGMC_STATUS_UUID (0x2AA9) |
#define | BLE_CGMC_STATUS_LEN (7) |
#define | BLE_CGMC_SESSION_START_TIME_UUID (0x2AAA) |
#define | BLE_CGMC_SESSION_START_TIME_LEN (11) |
#define | BLE_CGMC_SESSION_RUN_TIME_UUID (0x2AAB) |
#define | BLE_CGMC_SESSION_RUN_TIME_LEN (4) |
#define | BLE_CGMC_RECORD_ACCESS_CP_UUID (0x2A52) |
#define | BLE_CGMC_RECORD_ACCESS_CP_LEN (10) |
#define | BLE_CGMC_RECORD_ACCESS_CP_CLI_CNFG_UUID (0x2902) |
#define | BLE_CGMC_RECORD_ACCESS_CP_CLI_CNFG_LEN (2) |
#define | BLE_CGMC_SPECIFIC_OPS_CP_UUID (0x2AAC) |
#define | BLE_CGMC_SPECIFIC_OPS_CP_LEN (16) |
#define | BLE_CGMC_SPECIFIC_OPS_CP_CLI_CNFG_UUID (0x2902) |
#define | BLE_CGMC_SPECIFIC_OPS_CP_CLI_CNFG_LEN (2) |
#define | BLE_CGMC_MISSING_CRC_ERROR (BLE_ERR_GROUP_GATT | 0x80) |
If E2E-CRC is supported and a Write procedure is processed without CRC attached. More... | |
#define | BLE_CGMC_INVALID_CRC_ERROR (BLE_ERR_GROUP_GATT | 0x81) |
If E2E-CRC is supported and a Write procedure is processed with incorrect or invalid CRC value attached. More... | |
Functions | |
ble_status_t | R_BLE_CGMC_ReadMeasCliCnfg (uint16_t conn_hdl) |
Read CGM Measurement characteristic Client Characteristic Configuration descriptor value from the remote GATT database. More... | |
ble_status_t | R_BLE_CGMC_WriteMeasCliCnfg (uint16_t conn_hdl, const uint16_t *p_value) |
Write CGM Measurement characteristic Client Characteristic Configuration descriptor value to remote GATT database. More... | |
void | R_BLE_CGMC_GetMeasAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_cgmc_meas_attr_hdl_t *p_hdl) |
Get CGM Measurement attribute handles. More... | |
ble_status_t | R_BLE_CGMC_ReadFeat (uint16_t conn_hdl) |
Read CGM Feature characteristic value from the remote GATT database. More... | |
void | R_BLE_CGMC_GetFeatAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_cgmc_feat_attr_hdl_t *p_hdl) |
Get CGM Feature attribute handles. More... | |
ble_status_t | R_BLE_CGMC_ReadStatus (uint16_t conn_hdl) |
Read CGM Status characteristic value from the remote GATT database. More... | |
void | R_BLE_CGMC_GetStatusAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_cgmc_status_attr_hdl_t *p_hdl) |
Get CGM Status attribute handles. More... | |
ble_status_t | R_BLE_CGMC_ReadSessionStartTime (uint16_t conn_hdl) |
Read CGM Session Start Time characteristic value from the remote GATT database. More... | |
ble_status_t | R_BLE_CGMC_WriteSessionStartTime (uint16_t conn_hdl, const st_ble_cgmc_session_start_time_t *p_value) |
Write CGM Session Start Time characteristic value to remote GATT database. More... | |
void | R_BLE_CGMC_GetSessionStartTimeAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_cgmc_session_start_time_attr_hdl_t *p_hdl) |
Get CGM Session Start Time attribute handles. More... | |
ble_status_t | R_BLE_CGMC_ReadSessionRunTime (uint16_t conn_hdl) |
Read CGM Session Run Time characteristic value from the remote GATT database. More... | |
void | R_BLE_CGMC_GetSessionRunTimeAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_cgmc_session_run_time_attr_hdl_t *p_hdl) |
Get CGM Session Run Time attribute handles. More... | |
ble_status_t | R_BLE_CGMC_ReadRecordAccessCpCliCnfg (uint16_t conn_hdl) |
Read Record Access Control Point characteristic Client Characteristic Configuration descriptor value from the remote GATT database. More... | |
ble_status_t | R_BLE_CGMC_WriteRecordAccessCpCliCnfg (uint16_t conn_hdl, const uint16_t *p_value) |
Write Record Access Control Point characteristic Client Characteristic Configuration descriptor value to remote GATT database. More... | |
ble_status_t | R_BLE_CGMC_WriteRecordAccessCp (uint16_t conn_hdl, const st_ble_cgmc_record_access_cp_t *p_value) |
Write Record Access Control Point characteristic value to remote GATT database. More... | |
void | R_BLE_CGMC_GetRecordAccessCpAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_cgmc_record_access_cp_attr_hdl_t *p_hdl) |
Get Record Access Control Point attribute handles. More... | |
ble_status_t | R_BLE_CGMC_ReadSpecificOpsCpCliCnfg (uint16_t conn_hdl) |
Read CGM Specific Ops Control Point characteristic Client Characteristic Configuration descriptor value from the remote GATT database. More... | |
ble_status_t | R_BLE_CGMC_WriteSpecificOpsCpCliCnfg (uint16_t conn_hdl, const uint16_t *p_value) |
Write CGM Specific Ops Control Point characteristic Client Characteristic Configuration descriptor value to remote GATT database. More... | |
ble_status_t | R_BLE_CGMC_WriteSpecificOpsCp (uint16_t conn_hdl, const st_ble_cgmc_specific_ops_cp_t *p_value) |
Write CGM Specific Ops Control Point characteristic value to remote GATT database. More... | |
void | R_BLE_CGMC_GetSpecificOpsCpAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_cgmc_specific_ops_cp_attr_hdl_t *p_hdl) |
Get CGM Specific Ops Control Point attribute handles. More... | |
ble_status_t | R_BLE_CGMC_Init (ble_servc_app_cb_t cb) |
Initialize Continuous Glucose Monitoring client. More... | |
void | R_BLE_CGMC_ServDiscCb (uint16_t conn_hdl, uint8_t serv_idx, uint16_t type, void *p_param) |
Continuous Glucose Monitoring client discovery callback. More... | |
void | R_BLE_CGMC_GetServAttrHdl (const st_ble_dev_addr_t *p_addr, st_ble_gatt_hdl_range_t *p_hdl) |
Get Continuous Glucose Monitoring client attribute handle. More... | |
#define BLE_CGMC_MISSING_CRC_ERROR (BLE_ERR_GROUP_GATT | 0x80) |
If E2E-CRC is supported and a Write procedure is processed without CRC attached.
#define BLE_CGMC_INVALID_CRC_ERROR (BLE_ERR_GROUP_GATT | 0x81) |
If E2E-CRC is supported and a Write procedure is processed with incorrect or invalid CRC value attached.
CGM Feature CGM Type enumeration.
CGM Feature CGM Sample Location enumeration.
CGM Session Start Time DST-Offset enumeration.
Record Access Control Point Op Code enumeration.
Record Access Control Point Operator enumeration.
Record Access Control Point Operand enumeration.
Record Access Control Point Response Code enumeration.
CGM Specific Ops Control Point Op Code enumeration.
CGM Specific Ops Control Point Op Code - Response Codes enumeration.
CGM Specific Ops Control Point Operand enumeration.
Continuous Glucose Monitoring characteristic ID.
enum e_ble_cgmc_event_t |
Continuous Glucose Monitoring client event type.
ble_status_t R_BLE_CGMC_ReadMeasCliCnfg | ( | uint16_t | conn_hdl | ) |
Read CGM Measurement characteristic Client Characteristic Configuration descriptor value from the remote GATT database.
[in] | conn_hdl | Connection handle. |
ble_status_t R_BLE_CGMC_WriteMeasCliCnfg | ( | uint16_t | conn_hdl, |
const uint16_t * | p_value | ||
) |
Write CGM Measurement characteristic Client Characteristic Configuration descriptor value to remote GATT database.
[in] | conn_hdl | Connection handle. |
[in] | p_value | CGM Measurement characteristic Client Characteristic Configuration descriptor value to write. |
void R_BLE_CGMC_GetMeasAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_cgmc_meas_attr_hdl_t * | p_hdl | ||
) |
Get CGM Measurement attribute handles.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |
ble_status_t R_BLE_CGMC_ReadFeat | ( | uint16_t | conn_hdl | ) |
Read CGM Feature characteristic value from the remote GATT database.
[in] | conn_hdl | Connection handle. |
void R_BLE_CGMC_GetFeatAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_cgmc_feat_attr_hdl_t * | p_hdl | ||
) |
Get CGM Feature attribute handles.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |
ble_status_t R_BLE_CGMC_ReadStatus | ( | uint16_t | conn_hdl | ) |
Read CGM Status characteristic value from the remote GATT database.
[in] | conn_hdl | Connection handle. |
void R_BLE_CGMC_GetStatusAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_cgmc_status_attr_hdl_t * | p_hdl | ||
) |
Get CGM Status attribute handles.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |
ble_status_t R_BLE_CGMC_ReadSessionStartTime | ( | uint16_t | conn_hdl | ) |
Read CGM Session Start Time characteristic value from the remote GATT database.
[in] | conn_hdl | Connection handle. |
ble_status_t R_BLE_CGMC_WriteSessionStartTime | ( | uint16_t | conn_hdl, |
const st_ble_cgmc_session_start_time_t * | p_value | ||
) |
Write CGM Session Start Time characteristic value to remote GATT database.
[in] | conn_hdl | Connection handle. |
[in] | p_value | CGM Session Start Time characteristic value to write. |
void R_BLE_CGMC_GetSessionStartTimeAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_cgmc_session_start_time_attr_hdl_t * | p_hdl | ||
) |
Get CGM Session Start Time attribute handles.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |
ble_status_t R_BLE_CGMC_ReadSessionRunTime | ( | uint16_t | conn_hdl | ) |
Read CGM Session Run Time characteristic value from the remote GATT database.
[in] | conn_hdl | Connection handle. |
void R_BLE_CGMC_GetSessionRunTimeAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_cgmc_session_run_time_attr_hdl_t * | p_hdl | ||
) |
Get CGM Session Run Time attribute handles.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |
ble_status_t R_BLE_CGMC_ReadRecordAccessCpCliCnfg | ( | uint16_t | conn_hdl | ) |
Read Record Access Control Point characteristic Client Characteristic Configuration descriptor value from the remote GATT database.
[in] | conn_hdl | Connection handle. |
ble_status_t R_BLE_CGMC_WriteRecordAccessCpCliCnfg | ( | uint16_t | conn_hdl, |
const uint16_t * | p_value | ||
) |
Write Record Access Control Point characteristic Client Characteristic Configuration descriptor value to remote GATT database.
[in] | conn_hdl | Connection handle. |
[in] | p_value | Record Access Control Point characteristic Client Characteristic Configuration descriptor value to write. |
ble_status_t R_BLE_CGMC_WriteRecordAccessCp | ( | uint16_t | conn_hdl, |
const st_ble_cgmc_record_access_cp_t * | p_value | ||
) |
Write Record Access Control Point characteristic value to remote GATT database.
[in] | conn_hdl | Connection handle. |
[in] | p_value | Record Access Control Point characteristic value to write. |
void R_BLE_CGMC_GetRecordAccessCpAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_cgmc_record_access_cp_attr_hdl_t * | p_hdl | ||
) |
Get Record Access Control Point attribute handles.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |
ble_status_t R_BLE_CGMC_ReadSpecificOpsCpCliCnfg | ( | uint16_t | conn_hdl | ) |
Read CGM Specific Ops Control Point characteristic Client Characteristic Configuration descriptor value from the remote GATT database.
[in] | conn_hdl | Connection handle. |
ble_status_t R_BLE_CGMC_WriteSpecificOpsCpCliCnfg | ( | uint16_t | conn_hdl, |
const uint16_t * | p_value | ||
) |
Write CGM Specific Ops Control Point characteristic Client Characteristic Configuration descriptor value to remote GATT database.
[in] | conn_hdl | Connection handle. |
[in] | p_value | CGM Specific Ops Control Point characteristic Client Characteristic Configuration descriptor value to write. |
ble_status_t R_BLE_CGMC_WriteSpecificOpsCp | ( | uint16_t | conn_hdl, |
const st_ble_cgmc_specific_ops_cp_t * | p_value | ||
) |
Write CGM Specific Ops Control Point characteristic value to remote GATT database.
[in] | conn_hdl | Connection handle. |
[in] | p_value | CGM Specific Ops Control Point characteristic value to write. |
void R_BLE_CGMC_GetSpecificOpsCpAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_cgmc_specific_ops_cp_attr_hdl_t * | p_hdl | ||
) |
Get CGM Specific Ops Control Point attribute handles.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |
ble_status_t R_BLE_CGMC_Init | ( | ble_servc_app_cb_t | cb | ) |
Initialize Continuous Glucose Monitoring client.
[in] | cb | Client callback. |
Function Name: R_BLE_CGMC_Init Description : This function initializes the GATTS Server and CGM Service, registers the callback function for GATTS. Arguments : cb - cal back to the initialization parameters data Return Value : BLE_SUCCESS - Success BLE_ERR_INVALID_PTR - The p_ntf_data parameter or the value field in the value field in the p_ntf_data parameter is NULL. BLE_ERR_INVALID_ARG - The value_len field in the value field in the p_ntf_data parameter is 0 or the attr_hdl field in the p_ntf_data parameters is 0.
void R_BLE_CGMC_ServDiscCb | ( | uint16_t | conn_hdl, |
uint8_t | serv_idx, | ||
uint16_t | type, | ||
void * | p_param | ||
) |
Continuous Glucose Monitoring client discovery callback.
[in] | conn_hdl | Connection handle |
[in] | serv_idx | Service instance index. |
[in] | type | Service discovery event type. |
[in] | p_param | Service discovery event parameter. |
Function Name: R_BLE_CGMC_ServDiscCb Description : Callback function for the Continuous Glucose Monitoring Service Discovery events. Arguments : conn_hdl - handle to the connection type - discovery event id : p_param - pointer to GATTC event data : serv_idx - Service index used to distinguish the multiple same UUID service. Return Value : none
void R_BLE_CGMC_GetServAttrHdl | ( | const st_ble_dev_addr_t * | p_addr, |
st_ble_gatt_hdl_range_t * | p_hdl | ||
) |
Get Continuous Glucose Monitoring client attribute handle.
[in] | p_addr | Bluetooth device address for the attribute handles. |
[out] | p_hdl | The pointer to store the retrieved attribute handles. |