Skip to content

Commit 27901f2

Browse files
committed
BLE/GattCharacteristic: Add explanatory note for a parameter
1 parent 05c3ddf commit 27901f2

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

features/FEATURE_BLE/ble/GattCharacteristic.h

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -315,12 +315,17 @@ class GattCharacteristic {
315315
* @param[in] hasVariableLen
316316
* Whether the attribute's value length changes over time.
317317
*
318-
* @note The UUID value must be unique in the service and is normally >1.
318+
* @note The UUID value must be unique in the service and is normally >1.
319319
*
320320
* @note If valuePtr == NULL, length == 0, and properties == READ
321321
* for the value attribute of a characteristic, then that particular
322322
* characteristic may be considered optional and dropped while
323323
* instantiating the service with the underlying BLE stack.
324+
*
325+
* @note A CCCD should not be allocated if either the notify or indicate
326+
* flag is set, as it is handled by the underlying BLE stack. In such
327+
* a case, the param descriptors could be empty and the param
328+
* numDescriptors equal to zero.
324329
*/
325330
GattCharacteristic(const UUID &uuid,
326331
uint8_t *valuePtr = NULL,
@@ -584,6 +589,8 @@ class GattCharacteristic {
584589
SecurityManager::SecurityMode_t _requiredSecurity;
585590
/**
586591
* The characteristic's descriptor attributes.
592+
* This contains only CCCDs that has neither the notify nor the indicate
593+
* flag set, as thoses are handled by the underlying BLE stack.
587594
*/
588595
GattAttribute **_descriptors;
589596
/**

0 commit comments

Comments
 (0)