After clicking on Raw Data in Nrf connect App I am getting this 0x0201041AFF590000150112233445566778899AABBCCDDEEFF0FFFFFFFFC3. what are 0201041AFF these bytes ? can I remove it?
After clicking on Raw Data in Nrf connect App I am getting this 0x0201041AFF590000150112233445566778899AABBCCDDEEFF0FFFFFFFFC3. what are 0201041AFF these bytes ? can I remove it?
is anyone here to respond?
Hello,
The advertising packet and scan response data are built using LTV (Length-Type-Value) format (similar to TLV, but Length comes first).
You may read more in Core Bluetooth specification 5.2, Vol 3, Part C, Chapter 11, Supplement to the Bluetooth Core Specification (the same link), chapter 1. The IDs of available types are listed here: https://www.bluetooth.com/specifications/assigned-numbers/generic-access-profile/
Each entry starts with Length, in bytes, of the following type + data. Length of type is always 1 (can be extended in the future).
The raw data you scanned: 0x0201041AFF590000150112233445566778899AABBCCDDEEFF0FFFFFFFFC3 are split into entries the following way (nRF Connect for Android also displays this in the table below the raw data):
Len Type. Value
0x02 0x01 (Flags) 0x04 - BR/EDR Not Supported
0x1A. 0xFF (Manufacturer Data) 0x59000000150112233445566778899AABBCCDDEEFF0FFFFFFFFC3
The Supplement to Bluetooth Core Specification 4.1+ defines the first 2 bytes of Manufacturer data as Company ID.
The Manufacturer Data are encoded using application format, in this case nRF Beacon format, or something similar.
0x5900 - Nordic Semiconductor ASA Company ID (https://www.bluetooth.com/specifications/assigned-numbers/company-identifiers/), in Little Endian
0x00 - beacon type - this should be 0x02, actually
0x15 - length of the rest of payload
0x0112233445566778899AABBCCDDEEFF0 - the UUID: 01122334-4556-6778-899A-ABBCCDDEEFF0
0xFFFF - major number
0xFFFF - minor number
0xC3 - the calculated RSSI signal at 1m, in dBm = -61 dBm
can I remove 0201041AFF or not ?
If you're advertising from a device where you can control the advertising packet, like a nRF5 device, you may remove flags, so you will remove 0x020104. But 0x1AFF must be there in order the Manufacturer Data be decoded correctly. If you are using some other device, like a mobile phone, you cannot remove flags, as they are managed by the system. Also, I don't know if you should remove flags. Each flag has its meaning and they aren't there just to take 3 bytes.
I have to implement the custom characteristics which have a different 31 byte packet format.These five bytes are taking the space which I want to replace by some other data.Is that possble. I am advertising the data on android phone and my device is Nrf52. Tell me at least how to change the value of those bytes.