You need an onInit() in which you stat the timers... save() is also saving the state of the machine, but only the 'static' (code and settings) part, but not the timer things. in the onInit() you put the init(). I did not fully analyze and understand your code, but with timings/timers that's usually the issue.
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.
You need an onInit() in which you stat the timers... save() is also saving the state of the machine, but only the 'static' (code and settings) part, but not the timer things. in the onInit() you put the init(). I did not fully analyze and understand your code, but with timings/timers that's usually the issue.