1
0
Fork 0

bootgatthrm: allow option to remain connected

master
Rob Pilling 2024-04-20 17:41:12 +01:00
parent 0a097dd031
commit da7f03b21f
1 changed files with 5 additions and 1 deletions

View File

@ -30,6 +30,9 @@
});
}
const keepConnected = (require("Storage").readJSON("gatthrm.settings.json", 1) || {}).keepConnected;
function updateBLEHeartRate(hrm) {
/*
* Send updated heart rate measurement via BLE
@ -52,7 +55,8 @@
/*
* BLE has to restart after service setup.
*/
NRF.disconnect();
if(!settings.keepConnected)
NRF.disconnect();
}
else if (error.message.includes("UUID 0x2a37")) {
/*