A lot has happened in the 6 years since this post!
This should work on any device:
var value = require("Storage").readJSON("myinfo",1); if (value===undefined) value=21; buttonPlus.on('click', function() { maxTemp++; require("Storage").writeJSON("myinfo",maxTemp); }); buttonMinus.on('click', function() { maxTemp--; require("Storage").writeJSON("myinfo",maxTemp); });
@Gordon started
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.
A lot has happened in the 6 years since this post!
This should work on any device: