So that only the first character received will call the callback... But if you're not using the button for anything, it's a nice easy way of working. I guess you could make it toggle back and forth? You can check what the current console device is using process.env.CONSOLE
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.
Glad it's sorted!
You could maybe do something like:
So that only the first character received will call the callback... But if you're not using the button for anything, it's a nice easy way of working. I guess you could make it toggle back and forth? You can check what the current console device is using
process.env.CONSOLE