You'd definitely have to disconnect and reconnect for it to take effect (since Espruino would think the services have changed and the only way to change the services on nRF52 is for Espruino to totally reset the Bluetooth stack, which it can only do when nothing is connected).
It might be that the automatic BLE reset means that the data set in setAdvertising gets lost.
Can you try sticking NRF.setAdvertising inside update() for now? If so I can see if I can change the software a bit so it remembers.
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
You'd definitely have to disconnect and reconnect for it to take effect (since Espruino would think the services have changed and the only way to change the services on nRF52 is for Espruino to totally reset the Bluetooth stack, which it can only do when nothing is connected).
It might be that the automatic BLE reset means that the data set in
setAdvertising
gets lost.Can you try sticking
NRF.setAdvertising
insideupdate()
for now? If so I can see if I can change the software a bit so it remembers.