NimBLE-Arduino icon indicating copy to clipboard operation
NimBLE-Arduino copied to clipboard

Notification 8 byte data size

Open harunsengul opened this issue 1 year ago • 0 comments

Hi,

void notifyCB(NimBLERemoteCharacteristic* pRemoteCharacteristic, uint8_t* pData, size_t length, bool isNotify) { std::string str = (isNotify == true) ? "" : ""; //str += " from "; ///** NimBLEAddress and NimBLEUUID have std::string operators */ //str += std::string(pRemoteCharacteristic->getRemoteService()->getClient()->getPeerAddress()); //str += ": Service = " + std::string(pRemoteCharacteristic->getRemoteService()->getUUID()); //str += ", Characteristic = " + std::string(pRemoteCharacteristic->getUUID()); str += std::string((char*)pData, length); Serial.print(str.c_str()); }

This code only returns 8 bytes of the data package but my data package is lenght is 25 bytes.

So how can I read all data package instead of 8 bytes. Could you please help me?

I've used nrfConnect to see notification data and it showed me whole data package.

harunsengul avatar Mar 25 '24 12:03 harunsengul