-
• #2
Great! I think that's fine... By default
setWatch
only calls the function once, but you can have more than one setWatch active on a button at once.Maybe the best option is to put
setWatch(function, button, {repeat:true})
right at the end of your code outside the function, then you have something that is called whenever you press a button, and in the function that's called you work out what to do?I don't think there is a tutorial for settings at the moment - but I'll have a go at getting one done later today. If you want to get started quick I'd look at gadgetbridge as an example: https://github.com/espruino/BangleApps/tÂree/master/apps/gbridge
You just create a
settings
file in that format, and put it on the bangle asmyapp.settings.js
and you're done.
I've tweaked the example first app for something else that I wanted/needed - a 3 minute timer for my rest periods in the gym. Except I did it in binary for nerd cred and a random FB chat I was involved in.
JS file attached, MIT licence as usual.
1 Attachment