Is PWM possible during sleep?
Posted: 20 Sep 2019 10:27
Hi,
A question regarding output pins while sleeping.
According to this example, the Z-uno maintains the output level on digital pins even when sleeping: https://z-uno.z-wave.me/Reference/zunoS ... ceToSleep/
Does it work also for analog pins? Let's say I want to use the z-uno as a dimmer and want to output a PWM signal using analogWrite, would that work across sleep cycles?
What I don't quite understand in the example above is how the getter() function will be able to return a value. Are not all variables cleared during sleep? Don't I need to store the value in NZRAM in the getter() function to maintain it across sleeps?
Something like in this example : https://z-uno.z-wave.me/Reference/NZRAM/
Cheers,
Per
A question regarding output pins while sleeping.
According to this example, the Z-uno maintains the output level on digital pins even when sleeping: https://z-uno.z-wave.me/Reference/zunoS ... ceToSleep/
Does it work also for analog pins? Let's say I want to use the z-uno as a dimmer and want to output a PWM signal using analogWrite, would that work across sleep cycles?
What I don't quite understand in the example above is how the getter() function will be able to return a value. Are not all variables cleared during sleep? Don't I need to store the value in NZRAM in the getter() function to maintain it across sleeps?
Something like in this example : https://z-uno.z-wave.me/Reference/NZRAM/
Cheers,
Per