NRF Disconnect reason help #3367
Replies: 4 comments
-
|
Posted at 2020-05-18 by @gfwilliams What you're doing there looks ok, but BLE_HCI_REMOTE_USER_TERMINATED_CONNECTION isn't defined, so you'd have to define it as a number somewhere. To make debugging this easier, I'd suggest adding a USB-TTL converter if you have one handy: http://www.espruino.com/MDBT42Q#serial-console (and then do You can then interact with the REPL at the same time as trying out Bluetooth stuff, which should help no end! |
Beta Was this translation helpful? Give feedback.
-
|
Posted at 2020-05-18 by Gustav Thanks, that's great ! What do you mean by defining it as a number ? the reason has to not match that specific number right. |
Beta Was this translation helpful? Give feedback.
-
|
Posted at 2020-05-18 by @gfwilliams I'm afraid those constants aren't defined in JS - they just come from the Nordic Softdevice. Doing Of course I guess you could also do: And then check out what was in |
Beta Was this translation helpful? Give feedback.
-
|
Posted at 2020-05-18 by Gustav Alright, then i misunderstood. Ah yeah that's great, thanks Gordon. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2020-05-17 by Gustav
Hey i'm trying to to do different things depending on what reason the ble disconnect says. Hard to view this live and debug.
Got a MDBT42Q module hooked up the bangle. I wish to differentiate the gatt.device.disconnect() (user terminated disconnection) event and the event when range is reason to disconnect. Is this possible ? and what events might those be ? and how do i check them.
Currently i do this with no luck, it seems that the same event is fired for both types of disconnection.
Standard buzz never happends.
Beta Was this translation helpful? Give feedback.
All reactions