-
• #2
When NRF.on('connect'...) event is raised, I expected to see the BLE logo appear in blue
Yes, I'd hope that'd be the case! I'm pretty sure it happens even when the connection is insecure though. Are you saying you checked and sometimes
NRF.on('connect'...)
gets called butNRF.getSecurityStatus().connected
is false?Does it make sense to show the BLE widget appears active even if the connection is not secured
Yes, I'd say so. I guess maybe a little padlock icon if connected and secured?
-
• #3
Actually after deeper test, I realize that the boolean returned by
NRF.getSecurityStatus().connected
is set totrue
only if the device is a peripheral, right? if used as a central device (my Bangle requests connection to the MDBT42Q module), I suspect this boolean to stay atfalse
-
• #4
if used as a central device (my Bangle requests connection to the MDBT42Q module), I suspect this boolean to stay at false
Ahh, yes - that's the case. You can check also check
getSecurityStatus
on the BluetoothDevice you're using to connect to, but there's no global 'am I connected to anything at all?' function at the moment
I am using the Bluetooth Widget to know the connection status between my Bangle.js and a MDBT42Q module. I built a specific BLE service. When NRF.on('connect'...) event is raised, I expected to see the BLE logo appear in blue. However, it stays greyed.
From what I see in the widget script , the connection status is based on
NRF.getSecurityStatus().connected
boolean.Does it make sense to show the BLE widget appears active even if the connection is not secured, maybe with another color, like orange or red?