Release 0.2.13
============== Enhancements ~~~~~~~~~~~~ * Add support for onDataRead(); which is optionally implemented for stacks where an event is generated in response to a read on a characteristic. This feature is not implemented by any of the presently supported stacks. * Update UUID class to get length and pointer. Added UUID comparison operator. * BLEDevice::readCharacteristic() and BLEDevice::upateCharacteristic() should take GattAttribute::Handle_t instead of uint16_t. * fix documentation for setAdvertisingType() for ADV_SCANNABLE_UNDIRECTED. * Extend GattAttribute to export a pointer to the attribute's length. Bugfixes ~~~~~~~~ * Initialize the min/max length values correctly in the constructor for URIDataChar. Previously, the minLength value was always set to URI_DATA_MAX, whereas maxLen got initialized by the values stored persistently. Except for the case of default initialization, the value of maxLength would be fetched at initialization from persistent storage, and would always be less than the minLength, potentially causing incorrect setup in the underlying stack. Compatibility ~~~~~~~~~~~~~ This release is API compatible with 0.2.4.
This commit is contained in:
parent
2fa352d222
commit
f557237f47
2 changed files with 17 additions and 0 deletions
|
@ -31,6 +31,7 @@ public:
|
|||
virtual ble_error_t shutdown(void) = 0;
|
||||
virtual ble_error_t reset(void) = 0;
|
||||
virtual ble_error_t setTxPower(int8_t txPower) = 0;
|
||||
virtual void getPermittedTxPowerValues(const int8_t **, size_t *) = 0;
|
||||
virtual void waitForEvent(void) = 0;
|
||||
};
|
||||
|
||||
|
|
|
@ -368,6 +368,16 @@ public:
|
|||
*/
|
||||
ble_error_t setTxPower(int8_t txPower);
|
||||
|
||||
/**
|
||||
* Query the underlying stack for permitted arguments for setTxPower().
|
||||
*
|
||||
* @param[out] valueArrayPP
|
||||
* Out parameter to receive the immutable array of Tx values.
|
||||
* @param[out] countP
|
||||
* Out parameter to receive the array's size.
|
||||
*/
|
||||
void getPermittedTxPowerValues(const int8_t **valueArrayPP, size_t *countP);
|
||||
|
||||
public:
|
||||
BLEDevice() : transport(createBLEDeviceInstance()), advParams(), advPayload(), scanResponse(), needToSetAdvPayload(true) {
|
||||
advPayload.clear();
|
||||
|
@ -682,6 +692,12 @@ BLEDevice::setTxPower(int8_t txPower)
|
|||
return transport->setTxPower(txPower);
|
||||
}
|
||||
|
||||
inline void
|
||||
BLEDevice::getPermittedTxPowerValues(const int8_t **valueArrayPP, size_t *countP)
|
||||
{
|
||||
transport->getPermittedTxPowerValues(valueArrayPP, countP);
|
||||
}
|
||||
|
||||
/*
|
||||
* ALL OF THE FOLLOWING METHODS ARE DEPRECATED
|
||||
*/
|
||||
|
|
Loading…
Reference in a new issue