#include <tactigon_BLE.h>
T_BLE_Characteristic class. This is the class neede to menage a single characteristic of the BLE interface
◆ T_BLE_Characteristic() [1/2]
T_BLE_Characteristic::T_BLE_Characteristic |
( |
| ) |
|
BLE Characteristic Default Class constructor
◆ T_BLE_Characteristic() [2/2]
T_BLE_Characteristic::T_BLE_Characteristic |
( |
uint16_t |
h_char, |
|
|
uint8_t |
size, |
|
|
uint16_t |
h_service |
|
) |
| |
BLE Characteristic Class constructor. Don't use it, T_BLE::addNewChar() do it for you.
- Parameters
-
h_char | handle to thencharacteristic |
size | size of the characteristic (max 20 byte) |
h_service | handle to the characteristic |
- Returns
- status: 0:ok, !=0: not ok
◆ getHandle()
uint16_t T_BLE_Characteristic::getHandle |
( |
void |
| ) |
|
return the handle to characteristic
- Returns
- characteristic handle
◆ setWcb()
uint8_t T_BLE_Characteristic::setWcb |
( |
wCBType |
pFunc | ) |
|
in PERIPHERAL role set a CallBack on Data write event on characteristic
- Parameters
-
pFunc | user provided callback. It Must be of type: void calBackName(uint8_t *pointer_to_data, uint8_t byte_data_size) |
- Returns
- status: 0:ok, !=0: not ok
◆ update()
uint8_t T_BLE_Characteristic::update |
( |
uint8_t * |
pData | ) |
|
update characteristic with new data
- Parameters
-
pData | pointer to data to write in characteristic (characteristic must have CHAR_PROP_WRITE_WITHOUT_RESP proprty) |
- Returns
- status: 0:ok, !=0: not ok
The documentation for this class was generated from the following files: