Chat freely about anything...

User avatar
By martinayotte
#49608 You're right ! I've answered too quickly thinking about ESP in general.
Then, it could be a power supply issue, because tying RST to GPIO16 should not be the cause.
(BTW, tying them with direct wire will prevent you from doing external reset or uploads during deepSleep(), it is better having a 470R between them or a schottky diode)
User avatar
By charlie
#49617
martinayotte wrote:You still need a PullUp to VCC on RES pin.


Even with a pull up resistor on RST, I still get constant resets the moment I connect D0 to RST.

I think the problem is that D0 is low? I don't know how the sleep code makes D0 high or low. Is it automatic? How does the sleep call specify the use of D0?
User avatar
By charlie
#49618
martinayotte wrote:You're right ! I've answered too quickly thinking about ESP in general.
Then, it could be a power supply issue, because tying RST to GPIO16 should not be the cause.
(BTW, tying them with direct wire will prevent you from doing external reset or uploads during deepSleep(), it is better having a 470R between them or a schottky diode)



I've found that if I made D0 an output pin in setup(), and then digitalWrite(16,HIGH), it wont' reset constantly. But then the moment it goes to sleep and then waits the 10 seconds for the ESP.deepSleep call, it wakes up, and that pin must go to LOW out of sleep and it just keeps resetting again.

So a bit of progress. I know that the D0 pin goes LOW when it comes out of sleep. It never gets to execute setup(), so it stays low and constantly resets. I've also tried putting a capacitor over the GND and 3.3V line, and I still get the constant resets when D0 is connected to RST.
User avatar
By martinayotte
#49622 This is a bit strange !
You should not need to do any thing with GPIO16, you should simply leave the deepSleep() manage it.
I've done such deepSleep() with Wemos-D1-Mini, and I never got issues, and setup() is executed and I can then use ESP.getResetReason() to figure out if it was reset from deepSleep() or real Reset or powerup.