I tweaked a few settings for my Bangle using Bangle.setOptions, but they don't seem to survive a reboot.
For example I changed wakeOnBTN2 and wakeOnBTN3 to false. After E.reboot() they seem to be set to true again. How can I save these settings?
You can use a special filename starting with .bootN (N can be 0 1 2 3) to store additional code you want to load/execute at boot time.
Bangle.js is using .boot0, so use .boot3 for your settings.
// place your settings here
As @MaBe said...
There's an issue open for adding some extra settings for this kind of thing (https://github.com/espruino/BangleApps/issues/134) - it'd be interesting to see what you find useful to change, so they can be added as user-configurable options without needing the code above
Regarding .bootN, wouldn't it be better if the apps could register a js file to be called from one of these files, otherwise the 0-3 would quickly be filled up, as eg the DST change might eg also need to called on startup, see other thread for this issue.
Yes, it's a good point. Can't find this anywhere now but I think it was discussed before - I just filed an issue for it: https://github.com/espruino/BangleApps/issues/163
Ok, thanks all :)
If you update JS firmware now, you can do this instead:
Don't worry about formatting, just type in the text and we'll take care of making sense of it. We will auto-convert links, and if you put asterisks around words we will make them bold.
For a full reference visit the Markdown syntax.
© Espruino, powered by microcosm.
Report a problem