{"action":"created","issue":{"url":"https://api.github.com/repos/esp8266/Arduino/issues/1054","labels_url":"https://api.github.com/repos/esp8266/Arduino/issues/1054/labels{/name}","comments_url":"https://api.github.com/repos/esp8266/Arduino/issues/1054/comments","events_url":"https://api.github.com/repos/esp8266/Arduino/issues/1054/events","html_url":"https://github.com/esp8266/Arduino/issues/1054","id":117895963,"number":1054,"title":"Wifi functions forcing ESP12E to reset after some time","user":{"login":"rafaelmendes","id":11212985,"avatar_url":"https://avatars.githubusercontent.com/u/11212985?v=3","gravatar_id":"","url":"https://api.github.com/users/rafaelmendes","html_url":"https://github.com/rafaelmendes","followers_url":"https://api.github.com/users/rafaelmendes/followers","following_url":"https://api.github.com/users/rafaelmendes/following{/other_user}","gists_url":"https://api.github.com/users/rafaelmendes/gists{/gist_id}","starred_url":"https://api.github.com/users/rafaelmendes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafaelmendes/subscriptions","organizations_url":"https://api.github.com/users/rafaelmendes/orgs","repos_url":"https://api.github.com/users/rafaelmendes/repos","events_url":"https://api.github.com/users/rafaelmendes/events{/privacy}","received_events_url":"https://api.github.com/users/rafaelmendes/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-11-19T20:01:42Z","updated_at":"2015-11-20T13:13:08Z","closed_at":null,"body":"Hi guys,\r\n\r\nI am using an ESP12E to read a temperature sensor every minute and post the data to a webserver. The module reads the data from the sensor, post it and go into deepsleep for 60 seconds. My code works fine for some time (for some modules days, for other it takes weeks) but then the module starts to reset itself with no apparent reason. The weird part is that the MCU still works fine after that: if I upload a new code with no Wifi function (like blink led) the module works alright. However, if I use ANY Wifi function, the code runs up to the point where the function is called and then the module reboots, printing the following message:\r\n\r\n```\r\nSoft WDT reset\r\n\r\nctx: cont \r\nsp: 3ffef960 end: 3ffefce0 offset: 01b0\r\n\r\n>>>stack>>>\r\n3ffefb10:  00000002 4000410f 3ffefc64 40204555  \r\n3ffefb20:  3fffc718 40004a3c 0000007d 3fff0ef0  \r\n3ffefb30:  3fffc718 401016d0 00000378 40204555  \r\n3ffefb40:  0000007d 4020f223 00000378 0000007f  \r\n3ffefb50:  00001000 4020f2b9 3ffedef4 0000007f  \r\n3ffefb60:  0000007d 0000006c 0007d000 3ffedef4  \r\n3ffefb70:  ffffff00 ffffffff ffffffff ffffffff  \r\n3ffefb80:  ffffffff ffffffff ffffffff 0000007f  \r\n3ffefb90:  4020f6cd 3ffe8a60 00000001 3ffefc00  \r\n3ffefba0:  00000001 3ffefc20 4020f7d3 3ffe8a60  \r\n3ffefbb0:  00000001 3ffefc00 0000006c 3ffedde4  \r\n3ffefbc0:  3ffedfb0 3ffefc61 00000001 4020f80a  \r\n3ffefbd0:  3ffeea4c 3ffe854f 3ffe855c 00000000  \r\n3ffefbe0:  3ffefc20 3ffe84c0 00000000 00000002  \r\n3ffefbf0:  40202dd8 3ffefbfc 3ffeea4c 40202d61  \r\n3ffefc00:  76676f6c 2e776569 2e6d6f63 00007262  \r\n3ffefc10:  00000002 00000000 3ffefc20 402011f1 <\r\n3ffefc20:  6f747461 6f747461 6f747461 3ffe8500  \r\n3ffefc30:  3fff0e80 40106776 3ffefcb0 00000041  \r\n3ffefc40:  3ffeeb34 30333531 3f003533 40204d12  \r\n3ffefc50:  3fff0e20 00000041 3ffefcb0 40204d6a  \r\n3ffefc60:  00000000 3ffe84d0 3ffefcb0 40204d9a  \r\n3ffefc70:  00000004 00000000 00000001 3fffdc20  \r\n3ffefc80:  40202c71 3ffefcb0 3ffee9c8 3ffeecb8  \r\n3ffefc90:  3fffdc20 3ffee9f4 3ffeea4c 402029b3  \r\n3ffefca0:  40203ae4 3ffee9f4 3ffee9f0 4020253d  \r\n3ffefcb0:  00000000 00000000 00000000 402024fd  \r\n3ffefcc0:  00000000 00000000 3ffeecb1 40204329  \r\n3ffefcd0:  00000000 00000000 3ffeecc0 40100114  \r\n<<<stack<<<\r\n\r\n ets Jan  8 2013,rst cause:2, boot mode:(3,6)\r\n\r\nload 0x4010f000, len 1264, room 16\r\ntail 0\r\nchksum 0x42\r\ncsum 0x42\r\n~ld\r\n```\r\n\r\nThe same problem happened to five modules now. I am not sure if it is a hardware problem or a bug in my firmware.\r\n\r\nI've been facing this problem for almost 2 months now. I first thought that there was some sort of memory leak causing it so I started to print the free heap available every time the module woke up from deepsleep. Even after the module was \"bricked\", the heap was still ok.\r\n\r\nI ve got no ideas left to solve it, any help will be appreciated.\r\n\r\nThanks,\r\nRafael  \r\n"},"comment":{"url":"https://api.github.com/repos/esp8266/Arduino/issues/comments/158399541","html_url":"https://github.com/esp8266/Arduino/issues/1054#issuecomment-158399541","issue_url":"https://api.github.com/repos/esp8266/Arduino/issues/1054","id":158399541,"user":{"login":"rafaelmendes","id":11212985,"avatar_url":"https://avatars.githubusercontent.com/u/11212985?v=3","gravatar_id":"","url":"https://api.github.com/users/rafaelmendes","html_url":"https://github.com/rafaelmendes","followers_url":"https://api.github.com/users/rafaelmendes/followers","following_url":"https://api.github.com/users/rafaelmendes/following{/other_user}","gists_url":"https://api.github.com/users/rafaelmendes/gists{/gist_id}","starred_url":"https://api.github.com/users/rafaelmendes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafaelmendes/subscriptions","organizations_url":"https://api.github.com/users/rafaelmendes/orgs","repos_url":"https://api.github.com/users/rafaelmendes/repos","events_url":"https://api.github.com/users/rafaelmendes/events{/privacy}","received_events_url":"https://api.github.com/users/rafaelmendes/received_events","type":"User","site_admin":false},"created_at":"2015-11-20T13:13:08Z","updated_at":"2015-11-20T13:13:08Z","body":"Interesting, I will take a look at these EEPROM scketches.\r\n\r\nAnother useful information: At some point, I was trying to \"unbrick\" the module and decided to upload the nodeMCU firmware (https://github.com/nodemcu/nodemcu-firmware) and give it a try. Interesting fact is that with the LUA-based firmware, the same \"bricked\" module worked fine when I tried to connect to a Wifi AP, with no reboots. When I switched back to this arduino-based firmware, the problem came back.\r\n\r\nI guess that possibly relates to what you are saying about the memory partitions. Perhaps the LUA firmware was not using some corrupted part of memory that was being used by the arduino code.\r\n\r\nfood for thought..."}}