added BLECharacteristic notify32/indicate32(float)
This commit is contained in:
1 parent
2a34e2afd5
commit
3cb7236c6a
4 files changed
+25
-10
No files matched your search
@@ -751,6 +751,11 @@ bool BLECharacteristic::notify32(uint16_t conn_hdl, int num)
|
||||
return notify(conn_hdl, (uint8_t*) &num, sizeof(num));
|
||||
}
|
||||
|
||||
bool BLECharacteristic::notify32(uint16_t conn_hdl, float num)
|
||||
{
|
||||
return notify(conn_hdl, (uint8_t*) &num, sizeof(num));
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// Notify with single connection
|
||||
//--------------------------------------------------------------------+
|
||||
@@ -784,6 +789,10 @@ bool BLECharacteristic::notify32(int num)
|
||||
return notify32(BLE_CONN_HANDLE_INVALID, num);
|
||||
}
|
||||
|
||||
bool BLECharacteristic::notify32(float num)
|
||||
{
|
||||
return notify32(BLE_CONN_HANDLE_INVALID, num);
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------*/
|
||||
/* INDICATE multiple connections
|
||||
@@ -874,6 +883,11 @@ bool BLECharacteristic::indicate32(uint16_t conn_hdl, int num)
|
||||
return indicate32(conn_hdl, (uint32_t) num);
|
||||
}
|
||||
|
||||
bool BLECharacteristic::indicate32(uint16_t conn_hdl, float num)
|
||||
{
|
||||
return indicate(conn_hdl, (uint8_t*) &num, sizeof(num));
|
||||
}
|
||||
|
||||
/*------------------------------------------------------------------*/
|
||||
/* INDICATE single connections
|
||||
*------------------------------------------------------------------*/
|
||||
@@ -906,3 +920,8 @@ bool BLECharacteristic::indicate32(int num)
|
||||
{
|
||||
return indicate32(BLE_CONN_HANDLE_INVALID, num);
|
||||
}
|
||||
|
||||
bool BLECharacteristic::indicate32(float num)
|
||||
{
|
||||
return indicate32(BLE_CONN_HANDLE_INVALID, num);
|
||||
}
|
||||
Reference in new issue
Block a user