![]() |
BSB Developer Docs
|
Type definitions for describing services and characteristics Each service must be described using this struct and added to service_config collection under the corresponding index. More...
Go to the source code of this file.
Data Structures | |
| struct | BleCharacteristicConfig |
| Characteristic configuration. More... | |
| struct | BleServiceConfig |
| Service configuration. More... | |
Typedefs | |
| typedef bool(* | BleServiceInit) (void *instance) |
| Type definition for init callback method. | |
| typedef bool(* | BleServiceRun) (void *instance, size_t data_size, const void *data) |
| Type definition for run callback method. | |
Type definitions for describing services and characteristics Each service must be described using this struct and added to service_config collection under the corresponding index.
| typedef bool(* BleServiceInit) (void *instance) |
Type definition for init callback method.
This method is called once during initialization process and can be used in order to create necessary context for service logic
| [in] | instance | pointer to BleServiceObject in a generic form |
| typedef bool(* BleServiceRun) (void *instance, size_t data_size, const void *data) |
Type definition for run callback method.
This method is called every time when BleServiceCommandRun is enqueued for the service. Run can be enqueued as a reaction to some logic event happened inside of a service. For example: Battery service has got an event regarding battery charge level from Power subsystem. Also data can be added to call
| [in] | instance | pointer to BleServiceObject in a generic form |
| [in] | data_size | size of incoming data |
| [in] | data | pointer to incoming data |