But it's probably better to set button watchers together with other event listeners inside a Bangle.setUI() call: https://www.espruino.com/ReferenceBANGLEJS2#l_Bangle_setUI
Especially look at the example supplying an object as argument with mode:"custom" specified in the link above.
Off topic: If you're coming from pebble, have you seen this rad agenda that was recently contributed?: Rebble Agenda
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.
Hi!
Regarding point 1, hardware button presses are handled as part of Espruino that's available to a broader (all?) set of devices, I think. It's here: https://www.espruino.com/ReferenceBANGLEJS2#l__global_setWatch
But it's probably better to set button watchers together with other event listeners inside a
Bangle.setUI()
call: https://www.espruino.com/ReferenceBANGLEJS2#l_Bangle_setUIEspecially look at the example supplying an object as argument with
mode:"custom"
specified in the link above.Off topic: If you're coming from pebble, have you seen this rad agenda that was recently contributed?: Rebble Agenda