Retrieve attributes with 16bit uuid if 128bit fails.

When retrieving attribute handles using the 128bit base version of a 16 bit UUID some devices will
report "not found". This will attempt to convert the UUID to the 16bit version and try again.

* Adds `to16()` method to NimBLEUUID.
This commit is contained in:
h2zero
2022-01-18 14:48:07 -07:00
parent 6b858a0efd
commit 2386a8a68a
5 changed files with 56 additions and 5 deletions
+1
View File
@@ -48,6 +48,7 @@ public:
bool equals(const NimBLEUUID &uuid) const;
const ble_uuid_any_t* getNative() const;
const NimBLEUUID & to128();
const NimBLEUUID& to16();
std::string toString() const;
static NimBLEUUID fromString(const std::string &uuid);