-->
Page 1 of 1

wdt reset

PostPosted: Thu Nov 13, 2014 4:05 am
by johns
I've been hacking around with the source code a bit but I have a problem:

Every time I try to do something that takes a bit of time the module resets with message "wdt reset".

I know this is by design (and it's a good thing!) but how do I "pat the dog" to keep it alive? Does anybody know?

Re: wdt reset

PostPosted: Thu Nov 13, 2014 5:13 pm
by johns
I found the answer in this post:

viewtopic.php?f=5&t=9&start=40#p878

Re: wdt reset

PostPosted: Mon Nov 17, 2014 4:56 am
by OussemaH
It seems there is a function called ets_wdt_disable in https://github.com/scottjgibson/esp8266 ... addr.v6.ld

May be you can try calling that (just add a line ets_wdt_disable(); to your code)

Re: wdt reset

PostPosted: Thu Dec 18, 2014 11:34 pm
by chandan2002x
ets_wdt_disable is good, but why do we need it as the "OS" is handling it ? [The term "OS" was used with proper realization]

As per my experience, if the code is resetting, "there must be something wrong in the code". A small example may complement the previous statement:
I made a custom user file with proper header and definition. The functions were being called from existing functions and otherwise. Everything was running fine, suddenly [when custom library size was increasing] it started restarting when any functions of the "custom" library was called !!!

The restarting was indicating wdt_reset, I tried almost everything including ets_wdt_disable() and wdt_feed()..............no use.

I found the problem after a day long. It was in a variable declaration. A variable was declared as "BOOL INITSERVER". The variable was called in various other files as "extern BOOL INITSERVER". In one file, I missed and declared as "extern INITSERVER". It never thrown the error/warning in compilation. Just restarting when "INITSERVER" was called. Its funny, but the fact.

However, there may be hundreds reason, I have shared mine !