Page 1 of 3
[SOLVED] Opening serial monitor freezes program
Posted:
Tue Aug 04, 2015 11:32 pm
by Ben Baron
I haven't been working with my ESP modules for a while, and started working on a new project tonight. I started with a simple blink program blinking an LED attached to GPIO pin 13. The light blinks, so the program is running.
I start up a serial connection and print some hello world stuff. As soon as I open the serial monitor, the ESP crashes/freezes and the LED stops blinking. Any idea how to debug this? Has anyone had this issue? I need the serial monitor to debug the code for this project.
Re: Opening serial monitor freezes program
Posted:
Tue Aug 04, 2015 11:43 pm
by Ben Baron
Ok making some progress. Before I could see no messages other than the usual ESP startup stuff. I upgraded to the latest Arduino IDE and installed the ESP support via the board manager. Now I see the first printed messages when I connect, but as soon as I connect it freezes. And this only works if I set the same baud rate in Serial.begin that I flash at. If I try, for example, 9600 when flashing at 230400 or 115200, I see nothing in the serial monitor at all.
Re: Opening serial monitor freezes program
Posted:
Tue Aug 04, 2015 11:52 pm
by Ben Baron
Even more interesting, if I stop pulling GPIO0 low, I can restart the ESP and it blinks the LED. However, if I open the serial monitor, it freezes the program. Closing the serial monitor resumes it. If I start the ESP with the serial monitor already open, the light won't blink, but as soon as I close the serial monitor, it starts blinking.
Something that the serial monitor is doing is actively freezing the ESP program.
Re: Opening serial monitor freezes program
Posted:
Tue Aug 04, 2015 11:57 pm
by Ben Baron
Even stranger, I could cause the program to freeze when using an app called Serial or using the terminal program screen. Except when I used those, the program stayed crashed and even restarting the ESP didn't work. I had to refresh. Now it won't flash at all. I'm starting to think this module just went bad somehow. I'll try with another one tomorrow.
edit: same thing is happening on a different esp module