Changing the set interval from 1000 to 2000 helps.
Is it substantially better? What about going slower still like 3000ms? As @Frida says, if the sensor can only provide a signal every 2 sec then I don't see what we can do if you request something every second?
Possibly the module could be updated to warn the user if they call it too often?
My guess is that sending the pulse twice as you were doing might reset the sensor somehow - but that's probably not going to give you very good readings.
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.
Is it substantially better? What about going slower still like 3000ms? As @Frida says, if the sensor can only provide a signal every 2 sec then I don't see what we can do if you request something every second?
Possibly the module could be updated to warn the user if they call it too often?
My guess is that sending the pulse twice as you were doing might reset the sensor somehow - but that's probably not going to give you very good readings.