Hi,
I am trying to write/read long byte stream from Andorid/iOS device to CC2540. I defined characteristic value length as 255 byte. When I connect to CC2540 with BTool, I can read/write 255 Byte with blob readings/writings. I also sniff the packets in the air by using SmartRF Packet Sniffer at the same time. It looks good.
However, when I try to write 255 bytes on Android, Android gives me Error Status 9. I tried to investigate the Error Status Code 9, however, even in Bluedroid stack of Android, I haven't found any clue about that. Then, I tried to reduce number of bytes I am writing, if I write 90 bytes or less then 90 bytes, I can successfully write byte stream to fob's characteristic. Else if I try to write more than 90 bytes, I always have Error Code 9 and can not write byte stream to characteristic.
According to Bluetooth Low Energy Specs, I am able to write/read up to 512 bytes with blob operations. So here are my questions:
1) Is this limit (90 bytes) up to stack implementer?
2) Is there a way to learn from device max blob write/read size?
3) Can I write 255 byte from Android and iOS to fob with Blob Operations?
4) What I want to do design something that works with Android and iOS devices. So if iOS and Android have different max limits for data read/write, what is your suggestion to exchange long characteristics?
Thank you for your help and time,