Conversation
|
The BLE characteristic UUID for step count is identical to the one used to get responses from call notifications. One of them needs to be changed. |
|
@Arsen6331 Good catch! I totally forgot about that custom "service"! And it's unfortunately not mentioned in the doc page... |
… change the UUID of the new Motion service from 00020000-* to 00030000-*.
|
How much is the battery affected by this service? Can it be switched off? |
|
@ajack2001my This is BLE service, meaning that it exposes some values to the companion app, but it won't consume any power/cpu time unless the companion app actually read those values (or subscribe to notification). |
|
I've implemented this in itd. The issue description should be edited in case someone tries to look for the UUIDs and gets confused by there being two differing sources. |
Awesome!
Indeed, I've just edited, thanks! |
|
Notify on the step count characteristic seems to only populate one byte of data. Once the step count goes above 255, it resets to 0. Reading from the characteristic instead of using notify yields the full, 4-byte value. |
Woops ! You are right : https://github.com/InfiniTimeOrg/InfiniTime/blob/develop/src/components/ble/MotionService.cpp#L83 |
|
Fixed in 71ce13d In this screenshot, the number of steps is 0x12345678 : |
|
Step count implemented in InfiniLink on iOS. This was one of my most frequently requested features, thanks for adding it @JF002! |
Just tried it, it now works. Thank you. |
Thanks for integrating it! |

This PR adds a new Motion service, which exposes the "live" step count and raw motion values (X/Y/Z).
API definition:
00020001-78fc-48fe-8e23-433b3a1942d000030001-78fc-48fe-8e23-433b3a1942d0 (READ/NOTIFY)00020002-78fc-48fe-8e23-433b3a1942d000030002-78fc-48fe-8e23-433b3a1942d0 (READ/NOTIFY)I also improved notifications so that they are processed and send only if the companion app registered to them (and applied to change to the heart rate service).