-->
Page 1 of 2

Resets

PostPosted: Thu Dec 22, 2016 9:04 am
by stern0m1
Has anyone had succes running the esp8266 for month at a time without it reseting?


In my experience sooner or later they are bound to reset.

I want to have it running a timer without it being connected to the internet for time updates. I want to be able to set the time once and it should stay for awhile.


Thanks

Re: Resets

PostPosted: Thu Dec 22, 2016 9:44 am
by AcmeUK
Have a look at the timer part of what this guy is doing:- http://www.esp8266.com/viewtopic.php?f=32&t=12843

He says it offers :-
Sudo Timer for Timely operations, update Sunrise or Sunset data and preserve it in flash memory

Re: Resets

PostPosted: Thu Dec 22, 2016 8:22 pm
by Barnabybear
Hi, I go the other way and store data in flash and reset twice a day on some of my long term projects to prempt problems. The whole process takes less than 1/2 a second, so a second a day.

Re: Resets

PostPosted: Thu Feb 09, 2017 1:42 pm
by eriksl
I have a whole stack of esp8266's that are running for months without resets. In fact they never reset unless I tell them to.

Issues that come to my mind:

- sloppy programming
* not returing to the SDK in time so the watchdog acts
* memory corruption due to bad pointers or bad programming
* use of malloc() and friends which are known to be buggy
* silent bugs due to insufficient warning level of the compiler
* stack overflow due to too much/large auto variables on the stack (which you can't do on a microcontroller)
* not respecting the 32 bit alignment requirement for flash reads
* too long interrupt service functions
- old SDK version
- problem with the flash memory (replaced it yourself, like I do?)
- problems with the power supply (insufficient regulation or insufficient capacity to satisfy peaks of 500 mA)
- problems with I/O pins, where too much current is drawn, which heats the die (never tie the I/O's to ground or +3.3, always use a resistor)
- RST line insufficiently pulled up (use 10k, don't rely on the internal pullup, it's insufficient)
- Too high or too low voltage.