esp-nimble-cpp
1.4.1
|
All notable changes to this project will be documented in this file.
NimBLEClient::discoverAttributes
now returns a bool value to indicate success/failure.NimBLEServerCallbacks::onMTUChange
to onMtuChanged
in order to support porting code from original library.NimBLEAttValue
Class added to reduce and control RAM footprint of characteristic/descriptor values and support conversions from Arduino Strings and many other data types.NimBLEClient::getLastError
: Gets the error code of the last function call that produces a return code from the stack.NimBLECharacteristic::notify
: Overload method to send notifications/indications with custom values.onMtuChanged
.NimBLEClient::setDataLen
and NimBLEServer::setDataLen
: Data length extension support (IDF version >= 4.3.2 only)portMUX_TYPE
variable in the class definitions.NimBLEService
and changed the constructor no no longer accept numHandles
and inst_id
parameters.btInUse
.NimBLECharacteristic::removeDescriptor
: Dynamically remove a descriptor from a characterisic. Takes effect after all connections are closed and sends a service changed indication.NimBLEService::removeCharacteristic
: Dynamically remove a characteristic from a service. Takes effect after all connections are closed and sends a service changed indicationNimBLEServerCallbacks::onMTUChange
: This is callback is called when the MTU is updated after connection with a client.NimBLEDevice::whiteListAdd
: Add a device to the whitelist.NimBLEDevice::whiteListRemove
: Remove a device from the whitelist.NimBLEDevice::onWhiteList
: Check if the device is on the whitelist.NimBLEDevice::getWhiteListCount
: Gets the size of the whitelistNimBLEDevice::getWhiteListAddress
: Get the address of a device on the whitelist by index value.NimBLEDevice::getNumBonds
: Gets the number of bonds stored.NimBLEDevice::isBonded
: Checks if the device is bonded.NimBLEDevice::deleteAllBonds
: Deletes all bonds.NimBLEDevice::getBondedAddress
: Gets the address of a bonded device by the index value.NimBLECharacteristic::getCallbacks
to retrieve the current callback handler.NimBLEConnInfo
.NimBLEScan::clearDuplicateCache
: This can be used to reset the cache of advertised devices so they will be immediately discovered again.NimBLECharacteristicCallbacks::onSubscribe
Is now called after the connection is added to the vector.NimBLECharacteristic::getDescriptorByHandle
: Return the BLE Descriptor for the given handle.NimBLEDescriptor::getStringValue
: Get the value of this descriptor as a string.NimBLEServer::getServiceByHandle
: Get a service by its handle.NimBLEService::getCharacteristicByHandle
: Get a pointer to the characteristic object with the specified handle.NimBLEService::getCharacteristics
: Get the vector containing pointers to each characteristic associated with this service. Overloads to get a vector containing pointers to all the characteristics in a service with the UUID. (supports multiple same UUID's in a service)
NimBLEAdvertisementData
New methods:NimBLEAdvertisementData::addTxPower
: Adds transmission power to the advertisement.NimBLEAdvertisementData::setPreferredParams
: Adds connection parameters to the advertisement.NimBLEAdvertisementData::setURI
: Adds URI data to the advertisement.NimBLEAdvertising
New methods:NimBLEAdvertising::setName
: Set the name advertised.NimBLEAdvertising::setManufacturerData
: Adds manufacturer data to the advertisement.NimBLEAdvertising::setURI
: Adds URI data to the advertisement.NimBLEAdvertising::setServiceData
: Adds service data to the advertisement.NimBLEAdvertising::addTxPower
: Adds transmission power to the advertisement.NimBLEAdvertising::reset
: Stops the current advertising and resets the advertising data to the default values.NimBLEDevice::setScanFilterMode
: Set the controller duplicate filter mode for filtering scanned devices.NimBLEDevice::setScanDuplicateCacheSize
: Sets the number of advertisements filtered before the cache is reset.NimBLEScan::setMaxResults
: This allows for setting a maximum number of advertised devices stored in the results vector.NimBLEAdvertisedDevice
New data retrieval methods added:haveAdvInterval/getAdvInterval
: checks if the interval is advertised / gets the advertisement interval value.haveConnParams/getMinInterval/getMaxInterval
: checks if the parameters are advertised / get min value / get max value.haveURI/getURI
: checks if a URI is advertised / gets the URI data.haveTargetAddress/getTargetAddressCount/getTargetAddress(index)
: checks if a target address is present / gets a count of the addresses targeted / gets the address of the target at index.nimconfig.h
(Arduino) is now easier to use.NimBLEServer::getServiceByUUID
Now takes an extra parameter of instanceID to support multiple services with the same UUID.NimBLEService::getCharacteristic
Now takes an extra parameter of instanceID to support multiple characteristics with the same UUID.NimBLEAdvertising
Transmission power is no longer advertised by default and can be added to the advertisement by calling NimBLEAdvertising::addTxPower
NimBLEAdvertising
Custom scan response data can now be used without custom advertisment.NimBLEScan
Now uses the controller duplicate filter.NimBLEAdvertisedDevice
Has been refactored to store the complete advertisement payload and no longer parses the data from each advertisement. Instead the data will be parsed on-demand when the user application asks for specific data.NimBLEHIDDevice
Characteristics now use encryption, this resolves an issue with communicating with devices requiring encryption for HID devices.NimBLEDevice::setOwnAddrType
added to enable the use of random and random-resolvable addresses, by asukiaaaNimBLEAdvertising::SetMinPreferred
and NimBLEAdvertising::SetMinPreferred
re-added.nimconfig.h
to support custom configuration in platformio.NimBLEClient::setValue
Now takes an extra bool parameter response
to enable the use of write with response (default = false).NimBLEClient::getCharacteristic(uint16_t handle)
Enabling the use of the characteristic handle to be used to find the NimBLERemoteCharacteristic object.NimBLEHIDDevice
class added by wakwak-koba.NimBLEServerCallbacks::onDisconnect
overloaded callback added to provide a ble_gap_conn_desc parameter for the application to obtain information about the disconnected client.nimconfig.h
for command line defined macros to support platformio config settings.NimBLEAdvertising::start
now returns a bool value to indicate success/failure.NimBLEAdvertising::start
and replaced with better return code handling and logging.NimBLERemoteCharacteristic::subscribe
and NimBLERemoteCharacteristic::registerForNotify
will now set the callback regardless of the existance of the CCCD and return true unless the descriptor write operation failed.NimBLEScan
When the scan ends the scan stopped flag is now set before calling the scan complete callback (if used) this allows the starting of a new scan from the callback function.NimBLEClient::connect
would hang on the task block if no event arrived to unblock. A time limit has been added to timeout appropriately.FreeRTOS
compile errors resolved in latest Ardruino core and IDF v3.3.time()
called inside critical sections caused sporadic crashes, these have been moved out of critical regions.NimBLEAdvertising::start
Now takes 2 optional parameters, the first is the duration to advertise for (in seconds), the second is a callback that is invoked when advertsing ends and takes a pointer to a NimBLEAdvertising
object (similar to the NimBLEScan::start
API).CONFIG_BT_NIMBLE_MAX_CONNECTIONS
in nimconfig.h
. Any changes to the controller max connection settings in sdkconfig.h
will now have no effect when using this library.NimBLEAddress
constructor: NimBLEAddress()
produces an address of 00:00:00:00:00:00 type 0.First stable release.
All the original library functionality is complete and many extras added with full documentation.