Update boot.js
parent
e0657ab2ff
commit
618b2dac26
|
|
@ -8,7 +8,6 @@ require("Storage").writeJSON("setting.json", s);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
let unlockedWithLongPress = false;
|
|
||||||
const longPressTime=400; //(ms)
|
const longPressTime=400; //(ms)
|
||||||
|
|
||||||
Bangle.on('lock', function(isLocked) {
|
Bangle.on('lock', function(isLocked) {
|
||||||
|
|
@ -18,7 +17,6 @@ Bangle.on('lock', function(isLocked) {
|
||||||
// Just unlocked — give a short delay and check if BTN1 is still pressed
|
// Just unlocked — give a short delay and check if BTN1 is still pressed
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if (digitalRead(BTN1)) {
|
if (digitalRead(BTN1)) {
|
||||||
unlockedWithLongPress = true;
|
|
||||||
Bangle.setLCDBrightness(0.1);
|
Bangle.setLCDBrightness(0.1);
|
||||||
setTimeout(()=>{
|
setTimeout(()=>{
|
||||||
Bangle.setLCDBrightness(0);
|
Bangle.setLCDBrightness(0);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue