Page 1 of 1

ESP 12F won't connect once DeepSleep is enabled (Solved)

Posted: 07 Jul 2018, 14:49
by Vic20
Running (or at least trying to) Release mega-20180625 Build.

I set the unit up with a BME280 and a DSB18B20, along with the Analogue input monitoring the battery voltage from a resistor divider network.

The unit is powered from a solar board charged Li-Ion 18650 battery with an LDO regulator and ample smoothing capacitor (Though the same happens when I power the unit from a regulated PSU)
The controller is set as Thingspeak

All works well untill I enable deep sleep to wake up every 12 minutes at which point it will never reconnect to WiFi...

Code: Select all

INIT : Booting version: mega-20180625 (ESP82xx Core 2_4_1, NONOS SDK 2.2.1(cfd48f3), LWIP: 2.0.3)
236 : INIT : Rebooted from deepsleep #2 - Restart Reason: Deep-Sleep Wake
241 : FS   : Mounting...
267 : FS   : Mount successful, used 75802 bytes of 957314
577 : CRC  : program checksum       ...OK
609 : CRC  : SecuritySettings CRC   ...OK 
712 : INIT : Free RAM:24184
713 : INIT : I2C
713 : INIT : SPI not enabled
1542 : INFO : Plugins: 48 [Normal] (ESP82xx Core 2_4_1, NONOS SDK 2.2.1(cfd48f3), LWIP: 2.0.3)
1542 : WIFI : Set WiFi to STA
1574 : WIFI : Connecting MyWifi_Main attempt #0
1595 : WD   : Uptime 0 ConnectFailures 0 FreeMem 23456
1600 : ADC  : Analog value: 1009 = 4.082
15032 : HTTP : connection failed
15061 : DS   : Temperature: 28.12 (28-ff-89-3f-20-18-1-f2)
30067 : HTTP : connection failed
30073 : SYS  : -51.00
45100 : HTTP : connection failed
45137 : EVENT: System#Sleep
45163 : SLEEP: Powering down to deepsleep...
Pressing reset has the same result so the unit becomes stuck never able to connect.

Whilst it is awake, I enter 'settings' from a serial terminal.. (Ive edited the AP names and passwords but they are reported as correct)

Code: Select all

>settings
6098 : Command: settings

System Info
  IP Address    : 192.168.1.105
  Build         : 20102
  Name          : ESP_Easy_MegaL_180625
  Unit          : 1
  WifiSSID      : MyWifi_Main
  WifiKey       : Main_Password
  WifiSSID2     : MyWifiGuest
  WifiKey2      : Guest_Password
  Free mem      : 22280
The only way to get back to the unit is to enter 'Reset' from the serial terminal and re set up the unit once again.


I've had this hardware perviously running fine on much earlier versions but it's driving me nuts trying to get it to connect on wakeup from the versions released more recently.

Re: ESP 12F won't connect once DeepSleep is enabled

Posted: 08 Jul 2018, 10:32
by Vic20
Update:

If I disable all devices, it wakes up and connects every time... Doesn't do a lot though!

.. Enable just one device and it won't connect on wakeup.

Re: ESP 12F won't connect once DeepSleep is enabled

Posted: 08 Jul 2018, 12:03
by barthm
Same problem - march releases do not have this Problem

Re: ESP 12F won't connect once DeepSleep is enabled

Posted: 09 Jul 2018, 01:06
by Vic20
barthm wrote: 08 Jul 2018, 12:03 Same problem - march releases do not have this Problem



Confirmed. Regressed back to v2.0-20180322 and no problems.

Re: ESP 12F won't connect once DeepSleep is enabled

Posted: 14 Jul 2018, 12:04
by TD-er
And a link to the related issue on Github: https://github.com/letscontrolit/ESPEasy/issues/1572

Re: ESP 12F won't connect once DeepSleep is enabled

Posted: 16 Jul 2018, 13:28
by Vic20
MANY thanks for raising that. I wouldn't have had a clue! :?

Re: ESP 12F won't connect once DeepSleep is enabled

Posted: 10 Sep 2018, 13:50
by Vic20
Mega-20180908 with its new controller settings seem to have sorted this beautifully. Thanks folks. Nice consistent connections and data uploads now!

Can you clarify the other settings now available too?

Re: ESP 12F won't connect once DeepSleep is enabled

Posted: 10 Sep 2018, 21:19
by TD-er
Vic20 wrote: 10 Sep 2018, 13:50 Mega-20180908 with its new controller settings seem to have sorted this beautifully. Thanks folks. Nice consistent connections and data uploads now!

Can you clarify the other settings now available too?
There were more requests for explanation on these, so I will add it to the wiki.