Bluetooth Framework C++ Edition

◆ WriteClientConfiguration()

int WriteClientConfiguration ( const wclGattCharacteristic Characteristic,
const bool  Subscribe,
const wclGattOperationFlag  Flag,
const wclGattProtectionLevel  Protection = plNone,
const wclGattSubscribeKind  SubscribeKind = skManual 
)

Writes the client configuration descriptor to the device.

Parameters
CharacteristicA characteristic object in that changes an application is interested.
SubscribeThe value indicates should we subscribe or unsubscribe from the characteristic value changes.
FlagOperation behavior flag.
ProtectionDescribes the required protection level.
SubscribeKindIndicates a characteristic value change notification method that should be used. If a characteristic has both IsIndicatable and IsNotifiable properties set then this parameter allows to control which notification method should be used.
Returns
If the function succeed the return value is WCL_E_SUCCESS. Otherwise the method returns one of the WCL error codes.

In order to receive notifications about characteristic value changes the client must set the Client Configuration Descriptor. An application can use this method to do it in easy way.

See also
wclGattCharacteristic, wclGattOperationFlag, wclGattProtectionLevel, wclGattSubscribeKind