-->
Page 1 of 2

Programming locked out in deep sleep

PostPosted: Fri May 20, 2022 2:45 pm
by Bilbro3
I'm working out some projects that use deep sleep to save power on a generic 8266 board. One of my early iterations went to sleep quickly. Now I am unable to reprogram the 8266 because it goes to sleep as soon as it wakes up. Is there a way to overcome this? Later I learned to stall for 5 or 10 seconds before sleep to give me time to reprogram with Arduino.

Re: Programming locked out in deep sleep

PostPosted: Tue May 24, 2022 5:34 pm
by davydnorris
You will need to start the programmer and push the reset button repeatedly until it catches

Re: Programming locked out in deep sleep

PostPosted: Wed May 25, 2022 3:31 am
by btidey
If the GPIO mode pins are set to enter programming mode before reset is activated then it should go straight to download mode without executing the user program that can send it to sleep.

Development boards with auto-programming circuitry should do this automatically. For other boards you need to set the GPIO (normally just setting GPIO0 low) before pressing reset.

Re: Programming locked out in deep sleep

PostPosted: Wed May 25, 2022 12:23 pm
by schufti
just make sure that you don't use a direct connection (or low value resistor) between gpio16 and rst, that will make entering programming mode during deepsleep almost impossible. Use a diode instead.