- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi all,
I have Cy8CKIT-042-BLE.
I have been following video 3 on http://www.cypress.com/training/how-make-ios-app-control-robot-using-bluetooth-low-energy-ble
When I configure my BLE GAP settings Peripheral role, advertisement packet, it give me the error, error 1: the advertisement packet length exceeds the max length of 31 bytes.
thanks,
J
Solved! Go to Solution.
- Labels:
-
BLE
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Advertisement packet size is 31 bytes max. Out of which only 22 bytes are in your hand, which includes service UUID and device name.
if 2 byte / 16-bit service UUID then max size of device name is 20 bytes
if 4 bytes / 32-bit service UUID then max size of device name is 18 bytes
if 16 bytes / 128-bit of service UUID then max size of device name is 6 bytes.
If you want to use 128-bit characteristics and also want to advertise with a longer name, use a 16-bit service only for advertisement purpose. By doing so you can use 128-bit Services, characteristics etc and can also advertise with al onger name i.e. 20 Characters.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Solution: Shorten device name.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Advertisement packet size is 31 bytes max. Out of which only 22 bytes are in your hand, which includes service UUID and device name.
if 2 byte / 16-bit service UUID then max size of device name is 20 bytes
if 4 bytes / 32-bit service UUID then max size of device name is 18 bytes
if 16 bytes / 128-bit of service UUID then max size of device name is 6 bytes.
If you want to use 128-bit characteristics and also want to advertise with a longer name, use a 16-bit service only for advertisement purpose. By doing so you can use 128-bit Services, characteristics etc and can also advertise with al onger name i.e. 20 Characters.