Here is a script I wrote to watch analog input at http://github.com/anars/Espruino/tree/master/analog_read_watch
Usage // constructor parameters (watchPin, eventFunction, timeout, difference, repeat) var obj = new AnalogReadWatch(C4, function(data) { print(data); }, 1000, 0.01, true );
@Kay 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.
Here is a script I wrote to watch analog input at http://github.com/anars/Espruino/tree/master/analog_read_watch
Usage
// constructor parameters (watchPin, eventFunction, timeout, difference, repeat)
var obj = new AnalogReadWatch(C4, function(data) { print(data); }, 1000, 0.01, true );