-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature Request: Polar H10 #62
Comments
Hi @Marcel8584 would you be able to help with finding out if and what kind of data the Polar H10 freely broadcasts, which we might be able to then reverse engineer to include the decoding into the App? For finding these advertising broadcasts you could try Humble Explorer on your PC, or if you already have an MQTT broker running on your set-up Theengs Gateway on your PC or OpenMQTTGateway on an ESP32. Or alternatively you can see the advertising data through the nRFConnect app on your phone. |
Hi @DigiH |
Yes, this is what I meant, great. Now if you could get some more readings like that along with what the Polar app says at the same times about what your heart rate is, so that we can see if there is a relationship between the heart rate and the manufacturerdata - especially what is shown as
above. |
I tried to combine the data als follows with Humble Explorer: Hex 23 14 50 4b --> 67 Heartrate I found also an app called BLE Scanner that is able to read the heartbeat data directly (compare attached picture) Within this app the Hartrate is combined as follows: Ox{length=4,bytes=0x103f4504} —> 63 May be this also helps. |
Yes, this was already visible in the Humble Explorer data, that the H10 has a dedicated Bluetooth Heart Rate service, but this is only accessible when connecting to it, unfortunately out of the scope of Decoder and hence the Theengs App :( The heart rate is encoded there with the second hex ocetet
and I hoped that the same would be accessible in the freely advertised data, without having to connect, but only one of your previous samples seems to correlate Hex 3f 14 3d 40 --> 63 Heartrate with the other two not matching, so this one might have been a fluke. In the BLE Scanner app, if you go back one page you should also see Advertisment Data, and possible see if there might be more information. |
I collected some more data with two apps in parallel, so the data is more synchronouse. On the left side I connected the sensor and on the right side I just traced the advertisement. I collected the following data. In my opinion there is a rough correlation between the heart rate and the last HEX value of the advertised data. Ox{length=4,bytes=0x103fd003} —> HR 63 = 3F Hex Ox{length=4,bytes=0x10401004) —> HR 64 = 40 Hex Ox{length=4,bytes=0x10444103) —> HR 68 = 44 Hex Ox{length=4,bytes=0x10456c03) —> HR 69 = 45 Hex Ox{length=4,bytes=0x10469903) —> HR 70 = 46 Hex Ox{length=4,bytes=0x10474703) —>HR 71 = 47 Hex Ox{length=6,bytes=0x1057aa029d02} —> HR 87 = 57 Hex Ox{length=4,bytes=0x1059a102) —> HR 89 = 59 Hex Ox(length=4,bytes=0x105ade02) —> HR 90 Oxilength=4,bytes=0x105cbc02) —> HR 92 Oxflength=6,bytes=0x10607f028602] —>HR 96 = 60 Hex 0x{length=6,bytes=0x106958025a02} —> HR 105 = 69 Hex |
Great with the additional data. Did you have to jump back and forth with the screens to record the hex data and then the heart rate? Just thinking how to best supply a test decoder for you to try out … @Marcel8584 , you do not have access to an ESP32, do you? Or which desktop PC OS do you use? |
Today I borrowed an ESP32 and already installed the firmware. I am just playing around with the configuration. |
Sure, that would be the easiest way, with an ESP32 :) When you tried OpenMQTTGateway with it, did you have an MQTT broker implemented to connect to and be able to connect to the broker to view its messages? How did you install the OpenMQTTGateway? Through the web install or a binary install? I'm just starting a test build which includes the test H10 decoder … |
Yes I have a MQTT broker to view the messages. For the installation I chose the web installation (esp32dev-ble-openhab) |
It'll run for about an hour, then you can go to the test web install page I'll post here once its ready … |
Great, I will try it this evening. Is there any possibility to access the esp32 via the Mac terminal? Or another question, what is the default user and password of the ESP32 with your firmware? |
Correct, for Bluetooth devices Theengs Decoder allows anyone to submit pull requests for new decoders as explained at with Theengs Decoder library then being used for BLE decoding in OpenMQTTGateway, Theengs Gateway, Theengs Explorer, Theengs App …
Not for accessing the interface settings, depending on where and which MQTT broker you are using, but for viewing and also publishing commands to the ESP32 gateway one of the best applications to use is MQTT Explorer
With the above mentioned MQTT Explorer you can also pubslish different setting commands to the gateway, as explained from
Any new devices which freely broadcast BLE advertisements and don't require connections we'll be interested in including in Decoder :) Any queries with other new devices, feel free to post in the Theengs Decoder discussions. The test build is also ready for downloading. https://docs.openmqttgateway.com/dev/upload/web-install.html If you could then post a few messages here for confirmation, possibly copied and pasted from MQTT Explorer. Additionally it would also be good to confirm that the H10 will also still be picked up with passive scanning, which can be set as follows |
In my opinion it is working well. The bpm topic correlates with the heart rate. Related to the passive scanning, I did not understand how to change the setting. What do I have to do with the command: {"id":"F5:8B:B4:DC:74:6B","mac_type":1,"adv_type":3,"name":"Polar H10 75087320","manufacturerdata":"6b00331d3637","rssi":-71,"brand":"Polar","model":"Heart Rate Sensor","model_id":"H10","bpm":55} {"id":"F5:8B:B4:DC:74:6B","mac_type":1,"adv_type":3,"name":"Polar H10 75087320","manufacturerdata":"6b00271d3e3d","rssi":-60,"brand":"Polar","model":"Heart Rate Sensor","model_id":"H10","bpm":61} |
Great, thanks for the confirmation! This new H10 decoder will be included and appear in a future update of the Theengs App as well.
Since you have downloaded MQTT Explorer these commands can easily be published in the applicaiton. Have a look on the right side under the Publish section - as the topic you enter
and as content to publish in json format
Hit Publish, and under the BTtoMQTT message heading on the left you should see the included changed We then just like to know if the recognition and decoding is still the same as above with passive scanning. |
Ok that works and the messages are still good. May be one final question. I read in a discussion that it is also possible to post all ble data. #Make it possible to get all data? How would I change the setting or option on the esp32? |
Thanks, so passive scanning is also fine for the H10, and it avoids more battery drain on the devices.
With actually using the If no decoder is found for a device this information with just the manufacturerdata, servicedata and uuid can be published anyway for undecoded devices with setting pubadvdata to true If you want a gateway which only transmits undecoded BLE data you can Thanks for your collaboration on getting this new decoder implemented. |
Thank you too for your support and your work. |
@Marcel8584 if you are interested in testing the new version of the app, could you send an email to [email protected] |
I really like the idea of the App and the project.
Unfortunately I understood the concept wrong and thought that all devices are supported. May be it is possible that a Polar Heart Sensor H10 could be supported also. Especially the mobile app is great for all fitness devices.
Thank you for your feedback.
The text was updated successfully, but these errors were encountered: