New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
analogRead and ESP.getVcc don't work when WiFi radio disabled #1961
Comments
I thought the ESP rebooted when coming out of deep sleep - in which case,
it would never get to the loop would it?
|
@duncan-a you are right and wrong. ESP does reboot but if rtc_mem == 125 then it will reach loop(). |
Yep, I wasn't thinking straight... I have a sketch that reads the Vcc prior to sleeping (in loop) and that's On 22 April 2016 at 14:55, pieman64 notifications@github.com wrote:
|
I have same issue ... ESP.getVcc() always return 4094 with same version of Arduino IDE (1.6.8) and ESP core (2.2.0) for this sketch: https://github.com/tzapu/DeepSleepDHT22 |
FYI - asked about this on the Espressif SDK forum and they say it might be fixed in 1.5.3 http://bbs.espressif.com/viewtopic.php?f=7&t=2093&sid=8410c002f432033e2d464fe66934bb41 |
Git version has been updated to 1.5.3. Please give it a go. |
Smashing, that does indeed appear to fix it - both analogRead and ESP.getVcc(). |
The ESP.getVcc() always just returns 4094 and analogRead(A0) returns 1024 when the WiFi radio has been disabled (eg following ESP.deepSleep(1, RF_DISABLED).
This is with Arduine IDE 1.6.8 and ESP core 2.2.0.
This code demonstrates the problem (you can just touch the A0 pin with a finger to test the values change):
The text was updated successfully, but these errors were encountered: