Bluetooth LE Profile API document
Bluetooth LE Profile API document Rev.1.00 [May 22, 2020]
Scan Parameters Service Server

This service enables a GATT Client to store the LE scan parameters it is using on a GATT Server device so that the GATT Server can utilize the information to adjust behavior to optimize power consumption and/or reconnection latency. More...

Detailed Description

This service enables a GATT Client to store the LE scan parameters it is using on a GATT Server device so that the GATT Server can utilize the information to adjust behavior to optimize power consumption and/or reconnection latency.

Data Structures

struct  st_ble_scps_evt_data_t
 Scan Parameters Service event data. More...
 
struct  st_ble_scps_init_param_t
 Scan Parameters Service initialization parameters. More...
 
struct  st_ble_scps_connect_param_t
 Scan Parameters Service connection parameters. More...
 
struct  st_ble_scps_disconnect_param_t
 Scan Parameters Service disconnection parameters. More...
 
struct  st_ble_scps_scan_interval_window_t
 Scan Interval Window characteristic parameters. More...
 
struct  st_ble_scps_scan_refresh_t
 Scan Refresh characteristic parameters. More...
 
struct  st_ble_scps_scan_refresh_client_characteristic_configuration_t
 Scan Refresh Client Characteristic Configuration descriptor parameters. More...
 

Typedefs

typedef void(* ble_scps_app_cb_t) (uint16_t type, ble_status_t result, st_ble_scps_evt_data_t *data)
 Scan Parameters Service event callback. More...
 

Enumerations

enum  e_ble_scps_event_t {
  BLE_SCPS_EVENT_SCAN_REFRESH_CLI_CNFG_ENABLED,
  BLE_SCPS_EVENT_SCAN_REFRESH_CLI_CNFG_DISABLED,
  BLE_SCPS_EVENT_SCAN_INTERVAL_WINDOW_WRITE_CMD
}
 Scan Parameters Service event type. More...
 
enum  e_ble_scps_scan_refresh_t { BLE_SCPS_SCAN_REFRESH_SCAN_REFRESH_VALUE_SERVER_REQUIRES_REFRESH = 0 }
 Scan Refresh Value enumeration. More...
 

Functions

ble_status_t R_BLE_SCPS_Init (const st_ble_scps_init_param_t *param)
 Initialize Scan Parameters Service. More...
 
ble_status_t R_BLE_SCPS_Connect (uint16_t conn_hdl, const st_ble_scps_connect_param_t *param)
 Perform Scan Parameters Service connection settings. More...
 
ble_status_t R_BLE_SCPS_Disconnect (uint16_t conn_hdl, st_ble_scps_disconnect_param_t *param)
 Retrieve Scan Parameters Service connection specific settings before disconnection. More...
 
ble_status_t R_BLE_SCPS_NotifyScanRefresh (uint16_t conn_hdl)
 Send Scan Refresh notification. More...
 
uint32_t R_BLE_SCPS_GetVersion (void)
 Return version of the SCPC service server. More...
 

Typedef Documentation

◆ ble_scps_app_cb_t

typedef void(* ble_scps_app_cb_t) (uint16_t type, ble_status_t result, st_ble_scps_evt_data_t *data)

Scan Parameters Service event callback.

Enumeration Type Documentation

◆ e_ble_scps_event_t

Scan Parameters Service event type.

Enumerator
BLE_SCPS_EVENT_SCAN_REFRESH_CLI_CNFG_ENABLED 

Scan Refresh characteristic cli cnfg enabled event

BLE_SCPS_EVENT_SCAN_REFRESH_CLI_CNFG_DISABLED 

Scan Refresh characteristic cli cnfg disabled event

BLE_SCPS_EVENT_SCAN_INTERVAL_WINDOW_WRITE_CMD 

Scan Interval Window characteristic write command event

◆ e_ble_scps_scan_refresh_t

Scan Refresh Value enumeration.

Enumerator
BLE_SCPS_SCAN_REFRESH_SCAN_REFRESH_VALUE_SERVER_REQUIRES_REFRESH 

TODO

Function Documentation

◆ R_BLE_SCPS_Init()

ble_status_t R_BLE_SCPS_Init ( const st_ble_scps_init_param_t param)

Initialize Scan Parameters Service.

This function shall be called once at startup.

Parameters
[in]paramScan Parameters Service initialization parameters.
Returns

◆ R_BLE_SCPS_Connect()

ble_status_t R_BLE_SCPS_Connect ( uint16_t  conn_hdl,
const st_ble_scps_connect_param_t param 
)

Perform Scan Parameters Service connection settings.

This function shall be called on each connection establishment.

Parameters
[in]conn_hdlConnection handle.
[in]paramConnection parameters.
Returns
ble_status_t

◆ R_BLE_SCPS_Disconnect()

ble_status_t R_BLE_SCPS_Disconnect ( uint16_t  conn_hdl,
st_ble_scps_disconnect_param_t param 
)

Retrieve Scan Parameters Service connection specific settings before disconnection.

This function shall be called on each disconnection.

Parameters
[in]conn_hdlConnection handle.
[in]paramDisconnection parameters.
Returns
ble_status_t

◆ R_BLE_SCPS_NotifyScanRefresh()

ble_status_t R_BLE_SCPS_NotifyScanRefresh ( uint16_t  conn_hdl)

Send Scan Refresh notification.

Parameters
[in]conn_hdlConnection handle.
[in]app_valueScan Refresh value to send.
Returns
ble_status_t

◆ R_BLE_SCPS_GetVersion()

uint32_t R_BLE_SCPS_GetVersion ( void  )

Return version of the SCPC service server.

Returns
version