Can a LM Add-on be used to receive proprietary sensor data ?

Started by barbudor, August 20, 2024, 19:33:31

0 Members and 1 Guest are viewing this topic.

hoschilo

  •  

Andrew Heard

Wow - excellent research & development. Bravo. But needing 2 phones is a show stopper.
4.34.1.1 GOLD user ID:c7d47597a
  •  

Menion

Uff, this was harder than I expected.

@hoschilo

Here are the docs for a new Locsu API 0.10.0
https://github.com/asamm/locus-api/blob/master/docs/android/guides/adapter-apps/README.md

You'll of course need a new Locus Map Beta version > tomorrow.

This one is a big. Locus Map now handle all BT/USB connection logic. Add-ons only deal with the basic definition of parameters and the parsing of received data, nothing more. I'm sure, AI, thanks to the docs do a valid migration to the new system. Check also new sample app > there is clearly visible how easy is it and how it works.
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 Release download
  •  

hoschilo

@Menion:

I wanted to reach out and say thank you for your hard work — genuinely. Your quick response today and the announcement of the Sensor Adapter API 0.10.0 completely changed the trajectory of what I'm building, and in the best possible way.                                                                                                                                                                                     
                                                                                                                                                                                                         
                                                                                                                                                                                                         
With Locus now owning the BLE connection, the "middleman-phone" disappears entirely. Locus on a single device connects directly to the universal display, and our adapter just parses the raw frames. We already have the Brose protocol partially reverse-engineered:                                                                                                                                               
                                                                                                                                                                                                         
  - TEL frame (7×/sec): speed, cadence, battery, assist mode, odometer                                                                                                                                   
  - SEC frame (protobuf, triggered every 2s): motor power, rider power, estimated range                                                                                                                   
                                                                                                                                                                                                         
We've already prepared the adapter — BroseAdapterService, locus_adapter.xml, BroseProtocol.kt — and it's waiting for your Beta to go live tomorrow.                                                     
                                                                                                                                                                                                         
The plan / outlook                                                                                                                                                                                               
                                                                                                                                                                                                         
We intend (after testing) to publish this as an open-source Locus addon on GitHub (locus-brose-adapter) and on Google Play, so the broader Brose motor community can benefit. Is there anything I must consider by publishing an addon from your viewepoint. Brose powers bikes from Scott, Raleigh, Pinarello, Moustache, and others. If you'd like to feature it in the Locus Store or link to it from documentation, we'd be honoured.                                             
                                                                                                                                                                                                         
One open question                                                                                                                                                                                       
                                                                                                                                                                                                         
The HRM sample works without a scanFilter because Locus recognises the standard BT SIG Heart Rate Service UUID. Our Brose motor uses a custom service UUID (31be2300-d927-11e9-8a34-2a2ae2dbcce4). Is there an attribute in <deviceType> or <characteristic> to declare the service UUID for scanning — so Locus can find Brose motors by service UUID rather than by device name prefix?                     
                                                                                                                                                                                                         
Thank you again for this API — it's exactly the right architecture.
  •