wemos / Arduino_XI

Arduino core for WEMOS XI Boards
41 stars 14 forks source link

Power management unit (PMU) can't handle analogRead #7

Open rix133 opened 5 years ago

rix133 commented 5 years ago

inside the main loop: if I do: digitalRead(A3); PMU.sleep(PM_POFFS0, SLEEP_4S); it goes to sleep for 4 seconds

if I do: analogRead(A3); PMU.sleep(PM_POFFS0, SLEEP_4S); no sleep will happen and it will continuously run the loop.

njbinbin commented 4 years ago

Same problem...

njbinbin commented 4 years ago

I found that if you call PMU.sleep twice after analogRead, the second will work...