XDK API  3.6.0
Documentation
Typedefs | Functions
SensorServices.h File Reference
#include "XDK_SensorServices.h"
+ Include dependency graph for SensorServices.h:
+ This graph shows which files directly or indirectly include this file:

Typedefs

typedef void(* SensorServices_DataReceivedCallBack )(uint8_t *rxBuffer, uint8_t rxDataLength, SensorServices_Info_T *sensorServicesInfo)
 Typedef to notify the application about any incoming data for any of the registered sensor services. More...
 
typedef void(* SensorServices_SendEventCallback )(Retcode_T sendStatus)
 Typedef to send status notification. More...
 

Functions

Retcode_T SensorServices_Init (SensorServices_DataReceivedCallBack readCallback, SensorServices_SendEventCallback sendCallback)
 Initialize application callback to intimate for events from sensor services. More...
 
Retcode_T SensorServices_Register (void)
 This function registers the Sensor Services at the ATT server. This must be done during the boot phase of the stack. More...
 
Retcode_T SensorServices_SendData (uint8_t *payload, uint8_t payloadLen, SensorServices_Info_T *sensorServiceInfo)
 This function sends data to the client. More...
 
void SensorServices_UpdateConnectionStatus (bool connectionStatus)
 This function notifies the BLE connection status. More...
 

Typedef Documentation

typedef void(* SensorServices_DataReceivedCallBack)(uint8_t *rxBuffer, uint8_t rxDataLength, SensorServices_Info_T *sensorServicesInfo)

Typedef to notify the application about any incoming data for any of the registered sensor services.

Parameters
[in]rxBufferpointer to the received data buffer
[in]rxDataLengthLength of the received data
[in]sensorServicesInfoConsists of the necessary service information of the received characteristic.
typedef void(* SensorServices_SendEventCallback)(Retcode_T sendStatus)

Typedef to send status notification.

Parameters
[in]sendStatusStatus of the send operation
Note
For every single SensorServices_SendData, this must be synchronized before triggering a new send. If the interface user wants to have a queuing mechanism for sending data where the user need not worry about this notification and shall load the send API per need, it is excepted to be implemented as a wrapper at the application end on top of this.

Function Documentation

Retcode_T SensorServices_Init ( SensorServices_DataReceivedCallBack  readCallback,
SensorServices_SendEventCallback  sendCallback 
)

Initialize application callback to intimate for events from sensor services

Parameters
[in]readCallbackApplication Callback that will be called on data reception for any sensor services characteristics
[in]sendCallbackApplication Callback that will be notified about the data send status.
Returns
RETCODE_OK on success, or an error code otherwise. Refer Retcode_General_E and Ble_Retcode_E for other values.
See also
SensorServices_SendData
Retcode_T SensorServices_Register ( void  )

This function registers the Sensor Services at the ATT server. This must be done during the boot phase of the stack.

See also
BlePeripheral_ServiceRegistryCallback
Returns
RETCODE_OK on success, or an error code otherwise. Refer Retcode_General_E and Ble_Retcode_E for other values.
Note
Sensor Services must have been successfully initialized prior.

+ Here is the call graph for this function:

Retcode_T SensorServices_SendData ( uint8_t *  payload,
uint8_t  payloadLen,
SensorServices_Info_T sensorServiceInfo 
)

This function sends data to the client

Parameters
[in]dataToSendThe payload to be sent
[in]dataToSendLenThe length of the payload to be sent
[in]paramProvides the service characteristics information
Returns
RETCODE_OK on success, or an error code otherwise. Refer Retcode_General_E and Ble_Retcode_E for other values.
Note
Sensor Services must have been successfully initialized and registered prior. SensorServices_SendEventCallback will be triggered to provide the status of every individual send's.
See also
SensorServices_SendEventCallback
void SensorServices_UpdateConnectionStatus ( bool  connectionStatus)

This function notifies the BLE connection status

Parameters
[in]connectionStatusBLE connection status

+ Here is the call graph for this function:


All rights reserved. The use is subject to the XDK SDK EULA by Bosch Connected Devices and Solutions GmbH.
This documentation file has been automatically generated on Thu Mar 14 2019 19:12:40 by doxygen 1.8.8