You are reading a single comment by @Andrewmk and its replies. Click here to read the full conversation.
  • I've managed to compile the new version (0.40) of Gadgetbridge using the instructions here https://codeberg.org/Freeyourgadget/Gadg­etbridge/wiki/Developer-Documentation#bu­ilding-and-installing-the-gadgetbridge-a­pk then loaded the .apk to my phone. My query is what do I need turned on in the watch settings to make it work? Notifications only seem to come through on the watch if I have both BLE and Programmable set to On and leave the watch in 'Connectable' state. If I turn off Programmable then the notifications don't appear but after sending 5 or 6 of them to the watch I get an error message at the bottom of the screen about a buffer full error. It's like the messages are being sent to the watch but not read by anything. So do I need the watch to be 'Programmable'? That seems rather risky as there doesn't seem to be any security around the pairing process - no PINs displayed or requested. The docs here https://www.espruino.com/Gadgetbridge suggest that Bangle.js should interpret the incoming messages in a special way and it's only on other Espruino REPLs that the commands execute a 'GB(...)' function.

  • The docs here https://www.espruino.com/Gadgetbridge suggest that Bangle.js should interpret the incoming messages in a special way and it's only on other Espruino REPLs that the commands execute a 'GB(...)' function.

    The documentaion does not mention it is in any way special so I am guessing you need it 'programmable' state as it is just a call of GB() method over ordinary javascript console.

    Feels a bit insecure but there can be some whitelist implemented in future, there were some examples here previously - basically you hook few lines of your code into 'on connect' event and disconnect when device is not on allowed list. So you could perhaps have some 'learning mode' when you would allow connections ad learn mac addresses of allowed devices and then switch in menu to restricted mode to allow only previously learned predefined list.

    Of course it could be also done over special service quite easily but that would need changes in gadgetbridge and other software too - the nordic uart service is already supported in some software out of box (like e.g. DroidScript or some Arduino android apps).

About

Avatar for Andrewmk @Andrewmk started