-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Random Exception (9) from Web Server #869
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi @igrr have you had a chance to have a look at this one? I am still getting this quite often |
I did take a look, but I wasn't able to reproduce as I don't have two ESPs with me currently. |
ah I see. thanks @igrr! I'll alter the code not to close the connection each time and see if that fixes the crashing. |
In the case where you have ESP8266 on both sides (client and server), there isn't much you can do — one side will still have to do active close. Yet another option is to abort the connection by sending RST segment. There is |
Thanks for the heads up :) Diverting a little away from ESP8266 questions and more towards HTTP in general I guess but is it possible to perform client.connect() once and then do client.print() each loop? Or do I need to perform a client.close() after each print? I am wanting to control a robot in realtime so the stream of data needs to be continuous and as fast as possible. Is this the best way to do it? cheers |
I got Similar Problem... I am making a program that can control LED through WIFI by combining Relay Control example from aRest.h I frequently got This ERROR... Can anybody tell me Whats going on HERE ???? WiFi connected Exception (9): ctx: sys
ets Jan 8 2013,rst cause:2, boot mode:(3,6) load 0x4010f000, len 1264, room 16 |
Same issue here. Does anyone got a solution? |
with out a objdump or at least a call stack analyses its hart to say where the error is coming from.
|
can you try the same with latest git? |
I can try, but I'm very beginner with Linux and I'm very happy that Arduino with ESP8266 run, so it will take some time ;-) |
Ok, so I installed actual git version. I'm doing heavy testing right now (last error took me about 1/2 hour to generate...). |
so here is the result: |
Hi @jeferrb, what makes you think the exception is related to WebServer? I don't see a single stack frame from ESP8266WebServer library in the screenshot you've posted. |
Hi @igrr, thanks for reply. It is really not a WebServer question. Since it stops on the same line I thought it's related. I'm trying to port a project that works on Arduino Mega and I need some hint to understand where these error come from. |
The final line in stack trace is actually the first function executed. Stack traces are normally read from bottom to top. I.e. the last function is actually |
Hum, I get it now. So many thanks igrr, you help a lot. And, you are doing a grate job. |
Hi everyone, sort of late, but I found myself in a problem related to this one (I think). I started with arduino UNO since I found the loading much faster that ESP, so it was ok untill I started to migrate, my sistem is a LCD & rtc1307 (I2c) and a rotary encoder (with push bottom). My 1st step was to make the 3 periphericals work ok on the ESP, and it did work, just a few modification needed, the point was to make the whole code work ok, I got the EXEPTION (9) (Load or store to an unaligned address) when the interrupt take place. First thing I did was to remove the "lcd.createChar(address, character); " believing that the "address" was causing problems, but the problem remains, also tried a small script to check it out, and this character appeared on the screen, so it doesnt seems to be that. later on, tried the "TIME" pin in the 3 possible states, when low and high, the LCD stays frozen in the main manue, leaving the time pin floating, at least it interrupts, goes to the main manu (showing the current time from rtc) and then fades away as it should. Unfortunally, with my knowledge I can not go further than what I tried, any suggestion? I pasted the code but the " |
as a newbie I've the same problem and no idea how to proceed :-(( Exception (9): ctx: cont
ets Jan 8 2013,rst cause:2, boot mode:(3,6) load 0x4010f000, len 1384, room 16 after one or two successfull requests. It woud be fine if someone could make a little test on his system in his envireoment to see it something is wrong in my setup. const char WIFI_SSID[] = "..."; // WiFi information const char http_site[] = "api.usno.navy.mil"; // Remote site information const int LED_PIN = 16; // global variables & definitions // JSON stuff void setup() { void loop() { connectWiFi(); // Connect to WiFi if ( !getPage() ) { // Attempt to connect to website
// process server data here } //_connect WiFi_***** //**********get page** Thank you for any help or hint |
I had the same problem: Exception (9). My issue was that the page would render for the client, but you couldn't submit the tiny form that was on that page. It threw the error every time. A 'tremor in the force' felt like it was memory related - I thought maybe the array capturing the clients HTTP response was too big and popping the RAM so I kept trimming the array variable allocation down with no love... On a whim, I made the array size bigger and the error vanished. The 8266 web server runs smooth 99.9% (because nothing is ever 100% in IOT, right?) It turned out that the array that was capturing the HTTP_RESPONSE with was not big enough (by a hair). I originally allocated an array size of 500, which was enough to allow the web client to load or refresh the page successfully, but if there was any other data added from the client and sent to the 8266 (i.e. Arguments sent from the tiny web form on the page), it would throw the error after submitting the form.
After changing the array size to 700, the error was gone, and the 8266 takes the form submission and processes it just fine.
Long story short, my problem was in the handling of the arrays and HTTP responses from the client. Hope this helps someone out there! |
Please tell me how did you fixed it? |
Hi, had similar problem with exception 9. Finally in BoardsManager in esp8266 I installed older version 2.3.0 - additionally I had to choose Board Wemos D1 retired - and problem with exception 9 disappeared completely. |
Exception (9): after add firebase database library and arduinojson version 5 latest |
I understand that firebase uses WiFiClientSecure, research that and you'll know what's wrong. |
Thank you Sir. thanks a lot. |
I frequently get this exception and subsequent reset of the ESP8266: http://i.imgur.com/gCp89u2.png
My code (http://pastebin.com/g4T2Bi8u) is essentially just receiving HTTP requests and outputting the value to serial. The client (same .ino file, flashed to another ESP8266, just change SERVER to false) is another ESP8266 spamming HTTP requests at the server. The client is stable.
It can run for 5 minutes or only a few seconds before throwing the exception, it isn't consistent.
I am not running the latest staging however @luc-github is and can replicate the issue as per his comment on issue #428. I'll update to the latest staging and report any changes here
It may be worth mentioning on a couple of occasions I've seen different exceptions but as I'm not running the latest staging they may already be fixed (and I haven't been able to get them to occur again)
Cheers
The text was updated successfully, but these errors were encountered: