I try to implement a DIY project with Bluepill(STM32F103) + BLE(HM-11) + 10hz GPS(M8TLF).
Now I successfully bind BLE and GPS module to my mainboard and connect to RaceChrono but it always show "No fix to satellites.".
So I try to send the fake data to app but it is still not work (No fix to satellites.).
I am sure my UUID3 byte, index 4 have put the data (0x4A, GPS, 10 satellies).
Is there any un-document conditions caused this happen? (such as real time, valid altitude, UUID4 cannot read
The packet will be
0x22 0x20 0xBA 0x4A 0x0E 0xC4 0x2D 0xD0 0x48 0x1F 0x31 0x80 0x13 0x88 0x00 0x00 0xFF 0xFF 0x00 0xFF
My fake data is here,
gps.hgps.year = 21;
gps.hgps.month = 2;
gps.hgps.date = 17;
gps.hgps.hours = 14;
gps.hgps.minutes = 4;
gps.hgps.seconds = 20;
gps.milliseconds += 100;
gps.hgps.latitude = 24.77377989286238;
gps.hgps.longitude = 121.00038602734459;
gps.hgps.speed = 0;
gps.hgps.fix_mode = 1;
gps.hgps.sats_in_use = 10;
And I use the BLE test tool to snap my packet.
I rebuilt my device, which I had dismantled by mistake. I will now keep it as permanent test device for this API, so it's now much easier to confirm it is still working.
The API still works so you must have a problem with the implementation.
1st thing I look for is the byte 3, in your case 0x4A. It means your GPS has a fix (anything between 1 and 3) and locked to 10 satellites. So everything is good there.
2nd thing I look, is you got the correct characteristics. The UUID 3 looks good, it has read and notify supported, and the read value seems correct in a quick glance. BUT, I see a problem with UUID4, it is write only. It should be readable, and should output a value according to the spec. No write access needed for UUID4, only read.
Also make sure to look at the device status in RaceChrono, the one from the red/green button on bottom left. From there it's easy to see if there's a problem with only one value in the protocol. Or if it doesn't display anything for it, then you have a bigger problem, for example with the BLE characteristics.
ok.. you mean my raw data looks good, the problem may be caused by the properties of characteristics, right? (So your app will not to check whether the data is correct, such as time, or something else.)
Unfortunately, my BLE module (HM-11) don't let me to change the properties of characteristics, if the problem is caused by a mismatch of properties, then I need to change my BLE module. (Actually, I bought Bluefruit LE Friend today, hope to solve my problem...)
And, my screenshot is below, it doesn't seem like to accept any data...
When I receive the new BLE module, I will update the progress, hope everything goes well.
I got the new BLE module (Adafruit Bluefruit LE UART Friend) and configured GATT perperties as the protocol defined.
But RaceChrono still show "No fix to satellites".
I patty sure I have notify the data via BLE because I try to use another GATT monitor app to check it again.. (I put the screenshot at the bottom)
Would you please help me to check what is the problem?
Or maybe you can provide a valid/verified raw data to help analyze this situation?
2) Yes, notify all your updates on both characteristics. It's up-to the connecting party to decide if to register to notifications or just read by polling.
3) Your screenshots are not showing the current value on UUID 4, I find that disturbing as its value is integral for this protocol working.
Now I can continue to develop my kit, thx man.
BTW, report a document error, I marked on the screenshot below.