I have a little piezo I am turning on by
analogWrite(A5, 0.5, { freq: f } );
While I am debugging and connected to USB it works fine. When I disconnect USB and leave it to run on battery it sounds but does a funny chirp - I assume the PWM is getting messed up somehow.
I dont have a scope to check what is going on - any ideas ? Anything to do with A5 ?
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.
I have a little piezo I am turning on by
analogWrite(A5, 0.5, { freq: f } );
While I am debugging and connected to USB it works fine. When I disconnect USB and leave it to run on battery it sounds but does a funny chirp - I assume the PWM is getting messed up somehow.
I dont have a scope to check what is going on - any ideas ? Anything to do with A5 ?