Hi,
I am working on a hardware device which sends a continuous stream of data over BLE to an Android App. The android app receives this data as GATT notifications, then processes this data and saves it to a database.
The configuration details of the project are as follows:
1. Phone - Moto E 1st Generation
2. Android Version - Android 5.1 - Lollipop
3. iOS - iPhone 4 & 5, tested on iOS 7 & 8
3. Hardware - CC2541
4. Connection_Interval : 40 ms (Set in the firmware of the hardware).
5. Packets Sent Per Connection Interval : 4 (Set in the firmware of the hardware).
THE PROBLEM
When data is transmitted from the hardware device to the BLE data capture app running on Android phone, all the data packets are not received. It receives only about 35-45 packets, whereas the expected number of packets is 50.
What is more surprising is that when we used the BLE packet sniffer, there was a perfect match between the data sniffed and displayed by the Android phone (which is incomplete / incorrect data). This leads me to believe that the hardware is behaving differently when connecting to the Android phone and not sending all of the data.
When we use the same hardware with an iOS BLE data capture app, the data is received correctly.
I am puzzled and clueless about this behaviour of BLE data capture in Android. How the app on iOS device is able to capture all the data correctly whereas app on android phone is not able to capture data properly at all?
Has anyone experienced such a problem of packet loss / incorrect data when using BLE app on Android? Any inputs are welcome. Thank you so much for your help in advance.
The android App is using the standard BLE code (as given on Android Developer website) to connect to the device over BLE.