The ESP8266 has a few common issues, specially when you are trying to flash a new firmware or uploading scripts. Here’s a compilation with some of the most common problems with the ESP8266 and how to fix them.
This is a companion guide to the Home Automation using ESP8266 eBook.
ESP8266 Troubleshooting – Arduino IDE
1) Follow this procedure if you can’t upload scripts to your ESP-01 using the Arduino IDE.
How to make your ESP8266 go into upload mode when using the Arduino IDE:
- Remove power from your ESP8266
- Having your ESP connected like this (double check that GPIO 0 is connected to GND)
- Apply power to your ESP8266 and open the Arduino IDE
- Press the “Upload” button
2) If you try to upload a new sketch to your ESP32 and you get this error message “A fatal error occurred: Failed to connect to ESP32: Timed out… Connecting…“. It means that your ESP32 is not in flashing/uploading mode.
Having the right board name and COM por selected, follow these steps:
- Hold-down the BOOT button in your ESP32 board
- Press the Upload button in the Arduino IDE to upload your sketch
- After you see the “Connecting….” message in your Arduino IDE, release the finger from the BOOT button
- After that, you should see the “Done uploading” message
You’ll also have to repeat that button sequence every time you want to upload a new sketch. But if you want to solve this issue once for all without the need to press the BOOT button, follow the suggestions in the next guide:
3) If you get the error “COM Port not found/not available”, you might need to install the CP210x Drivers:
- Install USB Drivers – CP210x USB to UART Bridge (Windows PC)
- Install USB Drivers – CP210x USB to UART Bridge (Mac OS X)
If you experience any problems or issues with your ESP32, take a look at our in-depth ESP32 Troubleshooting Guide.
ESP8266 Troubleshooting – NodeMCU Flasher
Where do I download the NodeMCU flasher?
Go to the NodeMCU flasher GitHub repository and download the flasher for your Windows PC bit version by clicking the button that says “Raw”:
Which settings should I use with the NodeMCU flasher?
The NodeMCU flasher already comes with the right settings by default.
If you have changed some of the settings, I highly recommend that you re-download the NodeMCU flasher.
Here’s my current settings:
After I press the “Flash” button nothing happens, the NodeMCU flasher doesn’t start the flashing process
If you pressed the “Flash” button and nothing happens… It means one of these two things:
- Problem 1 – Your ESP isn’t in flash mode (double-check if GPIO 0 is connected to GND on power up)
- Problem 2 – Your FTDI Programmer can’t supply enough current to your ESP
Problem 1 – How to make your ESP go into flash mode:
- Close the NodeMCU flasher window
- Remove power from your ESP8266
- Having your ESP connected like this (double check that GPIO 0 is connected to GND)
- Apply power to your ESP8266 and open the NodeMCU flasher
- Press the “Flash” button
If it’s still saying “Waiting MAC”, then try the following:
- Having the NodeMCU flasher still open
- Connect a wire from your ESP8266 reset pin to GND
- Remove that wire from GND and connect to VCC
Repeat steps 2 and 3 a few times until your ESP reboots and hopefully the NodeMCU flasher can detect your ESP and start the flashing process.
Problem 2 – If your FTDI can’t supply enough current, you might need to buy a new FTDI programmer or power your ESP8266 with an external power supply.
NodeMCU flasher gets stuck at a certain percentage
- Remove power from your ESP+FTDI:
- Close the NodeMCU flasher window
- Plug your ESP+FTDI to your computer again
- Open NodeMCU flasher and try the 19200 baud rate
If this process fails, please repeat the same procedure for the next baud rates (38400, 57600, 74880 and 115200).
I don’t know why, but at least 5 people faced the same problem and this trick solved it. So at a baud rate of 57600 or 115200 I think it will flash 100%. I don’t have any logical explanation, since this is not very common.
How does the NodeMCU flasher should look after a successful flash?
It should have a green arrow in the bottom left.
Unbricking the FTDI Programmer on Windows PC
If you have a brand new FTDI Programmer and you need to install your FTDI drivers on Windows, visit this website for the official drivers: http://www.ftdichip.com/Drivers/VCP.htm.
In alternative, you can contact the seller that sold you the FTDI Programmer.
If you’re having trouble installing the FTDI drivers on Windows 7/8/8.1/10 it’s very likely that FTDI is bricked.
Follow this tutorial to fix that: http://youtu.be/SPdSKT6KdF8.
In the video I mentioned earlier, the guy tells you to download the drivers from the FTDI website, read carefully the YouTube description of his video to find all the links. Here’s the drivers you need: http://www.ftdichip.com/Drivers/CDM/CDM%20v2.12.00%20WHQL%20Certified.zip
ESP8266 Troubleshooting – ESPlorer IDE
ESPlorer IDE Error: only one tcp server allowed
This means that you tried to upload multiple scripts and you ESP is still running the old script with a web server. To fix it, you simply need to send these commands to delete all the files and restart your ESP:
- file.format()
- node.restart()
Upload the script again and name it ‘init.lua’ and you shouldn’t see that error again.
ESPlorer IDE Error: can’t autodetect firmware
and
ESPlorer IDE Error: Waiting answer from ESP – Timeout reached. Command aborted.Waiting answer from ESP – Timeout reached. Command aborted.
This sounds like your ESP it’s still in flash mode. How to make your ESP go into user mode:
- Close the ESPlorer IDE connection
- Remove power from your ESP8266
- Having your ESP with GPIO 0 connected to VCC
- Apply power to your ESP8266 and re-establish the connection with ESPlorer IDE
If it’s still saying “can’t autodetect firmware”, then try the following:
- Having the ESPlorer IDE connection still printing “…..”
- Connect a wire from your ESP8266 reset pin to GND
- Remove that wire from GND and connect to VCC
Repeat steps 2 and 3 a few times until your ESP reboots and hopefully the ESPlorer IDE can detect your ESP.
My code disappears when I restart the ESP8266
If you upload a script to your ESP and when you restart it your ESP doesn’t do anything. It means that your ESP couldn’t find the script or it occurred a memory issue.
This can be solved like this:
- You didn’t save your script with this exact name ‘init.lua’. Re-uploading the same script, but with the ‘init.lua’ name should solve your problem
- It can be a memory issue. Re-flashing the ESP with NodeMCU flasher usually solves that problem
Finding the ESP8266 IP Address
Before you start make sure you check these two items:
- Verify that the script uploaded to your ESP has the right network credentials
- Make sure your ESP is near your router
Here’s what you can do to find the IP address:
Solution 1 – Sending a command with the ESPlorer IDE
- Send the command “print(wifi.sta.getip())” with the ESPlorer IDE and it should print your IP Address
Solution 2 – Install an IP Scanner Software
- An IP Scanner software searches for all the devices in your network
- Download this free software:
- Windows PC: www.advanced-ip-scanner.com
- MAC OS X, Windows or Linux: http://angryip.org
- Install one of these softwares (while having your ESP running with that web server script)
- Open the IP Scanner software and click “Scan”
- Let that process finish (it can take a couple of minutes)
In my case, it found my ESP. Now if I type 192.168.1.95 in my browser I can see the ESP web server.
Did you experience other problems?
Please leave a comment below, so I can update the troubleshooting guide with more problems and solutions.
Thanks for reading,
Rui Santos
I observed irratic behavior as few mentioned by u, and the solution I observed with NodeMcu dev board was insufficient current capacity of 3.3volt from Dev board. On using 3.3 volt supply from external sourcesolved all such problems. Making system reliable.
Expecting more work from u for NodeMcu with Lua.
Thnx
You are right Sanjay, most of the ESP8266 unexpected behavior is due to power supply issues that causes the ESP to crash.
Thanks,
Rui
Hi Rui. I got that : ¤üFatal exception (0):
epc1=0x40220142, epc2=0x00000000, epc3=0x00000000, excvaddr=0x00000000, depc=0x00000000
Fatal exception (0):
when i tried to use esplorer… any idea?
Thank YOu!
Marc.
Hi Marc!
Do you have Java installed on your computer? Make sure you install Java first, then re-download the ESPlorer IDE and try to run it again.
I hope this solves your issue,
Rui
When I uploaded code
Serial monitor regularly show
Connecting to esp8266
……..!………………….
Please help
Give solution
Hi.
Double-check your network credentials.
Regards,
Sara
I already check many times and change said or password, nothing happened
When I had my esp8266 programmed in wifi.SOFTAP mode, I connected to it with four cell phones at once (to show my friends how it worked). a few minutes later it was smoking and burned out. I’m not sure if this was because of the multiple connections to it via wifi causing the chip to overload or if this was simply because the chip wasn’t built well.
Hi Sam,
How were you powering your ESP8266? Trough the FTDI programmer?
Great comilation Rui!
You may or not remember trying to assist me with these very issues; ufortunately to no avail in my case. You might remember that I had several different types of modules (ESP-07, ESP-12, ESP-03).My plan was to wait for reciept of several more ESP-12 modules to arrive in an effort to prove or disprove the failure of the one module. Those have still not arrived after 2 months. In the mean time several thoughts come to mind and I’m wondering if something in the internal memory could have been overwritten in one of the failed attempts to “brick” the module. (perhaps something like a bootstrap loader?) Not understanding some of the terms used such as “room” etc. I don’t fully understand the make up of the memory map. Keeping in mind that the module failed not only in flashing nodeMCU, but also would not flash the original AT command firmware using the Electrodragon flash tool (with similar results), I am wondering if that indeed could be an issue.
Hi John,
Thank you. Yes, I do remember your problem and I don’t a good explanation why that happen and how to fix it.
Sometimes my flashing process has failed, but if I try a next time I can immediately flash the ESP8266 again. I’ve never experience the problem o bricking the ESP8266…
What happens when you try to flash the NodeMCU firmware again? Does it never start or stop in the middle?
I personally think that the problem that you are facing is with your FTDI programmer and not with the ESPs.
But I’m not sure
I have searched through several available projects but unfortunately I can’t make it work: Controlling some GPIO’s of an Arduino UNO connected with an ESP8266!
How hard can it be…?
Continuously no RX-TX communication between the Arduino and the ESP and similar difficulties. ( yes, I know well about the 3.3V complication)
I’ve found “100’s” different schematics. Everybody does it differently.
Can somone offer me a real simple basic working example ( + Arduino code) please?
This tutorial shows exactly how to establish a serial communication between an ESP8266 and an Arduino: https://randomnerdtutorials.com/sending-data-from-an-arduino-to-the-esp8266-via-serial/
With code and schematics that you can follow
Great, thanks! But I am looking more specifically concerning controlling an Arduino GPIO from an ESP. ( in detail like this tutorial)
So I mean an “IOT ” wifi home control.
I would add a few things i have seen here and there:
GPIO0, GPIO2 should be high at startup for running code.
GPIO0 should be low, GPIO2 should be high at at startup for flashing firmware.
GPIO15 should be low all the time.
Also these pins are not ideal for switching things.
CHPD, RST also should be high, There should be a 100nF cap right next to the ESP’s pins connecting VCC and ground.
What i am not sure about is that how to pull high the pins. I’ve seen a lot of posts/articles etc. stating that pins should be pulled high with resistors, not just a simple wire/pcb track and i’ve seen all kinds of values ranging from 3k to 15k. I am confused about that one.
As noted FTDI boards can become “Bricked” due to FTDI efforts to stop counterfeits. For great explanation see
youtube.com/watch?v=eU66as4Bbds
Also as don’t seem to be very robust. I’ve had two boards burn up a couple of months usage. I’ve much better results with:
CP2102 $1.27
CH340G $0.57
From Aliexpress
Hope others find this useful
Thank you for sharing your results. Yes, those boards are great alternatives.
Rui
PORT OPEN 115200
Communication with MCU…
……….
……….
……….
…
this is what I get when trying to connect with FTDI and windows 7.
Will not connect to the ESP8266-01
Have you tried the reset method? With the wire?
Can you show me the way to use DTS and RTS of the Ft232 adapter to auto programming for esp8266 without reset button and proggraming switch?
I recommend you use the reset method with your ESP8266.
Using ESP8266 V2 Development board, Due to (LuaLoader) coding error hanged the board and no reponse, unable to communicate even. Need to find the right firmware from which can be program use of LuaLoader and flash it. Seek directions sir!
You need to install the NodeMCU flasher as I show at the beginning of this guide.
A quick comment to let you know that your post has been featured in the last embedded systems weekly newsletter embedsysweekly.com/embedded-systems-issue38
I hope you like it, cheers
Thank you for sharing!
Hello Mr. Santos,
I have bought your Book and two NODEMCU-V09 Devkits. Power supply: 5Vdc/2A.
I have succeeded to flash them (nodemcu_integer_0.9.6-dev_20150704.bin)
But to load some Scripts with the Esplorer is not possible. I am receiving only these answers:
*************************++++
PORT OPEN 9600
Communication with MCU…
……….
……….
……….
……….
………Got answer! AutoDetect firmware…
Can’t autodetect firmware, because proper answer not received.
“I˜;\ŸUploading to ESP file init.lua…Waiting answer from ESP – Timeout reached. Command aborted.Waiting answer from ESP – Timeout reached. Command aborted.
***************************+++
I have tried to repeat et least 5-7 times the connection Reset-> Gnd->Vcc. It does not help at all. I have tried to re-flash these two DevKits. It doesn’t help at all.
I am trying to get these modules to work, since 2 days. No chance. I haven’t found for these DevKits any description (only pinouts and 2-3 Youtube -clips, but wit no practical use at all)
Have you ever tried to use these DevKits? If yes, could you please help me?
Best Regards from Germany,
Alex
Hi Alex,
I’ve just sent you a private message with a couple of questions.
This sounds like a power issue though…
Thanks for your patience,
Rui
Thanks a lot for the fast answer, but I haven’t received anything yet.
I am waiting to receive your Email.
I have checked all the voltages.
The 3,3V is: 3.333V
TxD=3.334V
RxD=3.629V
EN=3.330V
RST=3.333V
The 5V=5.02V.
Until then!
Good evening,
your message is still not arrived. Maybe tomorrow.
I wish you a nice evening.
Best Regards,
Alex
I’ve seen you received the message. We can keep the conversation there.
Thanks Alexander.
Rui
Any solution on this ? As even i got such kind of message from esplorer with Java 1.8 version installed in my win7.
PORT OPEN 115200
Communication with MCU…
……….
……….
Got answer! AutoDetect firmware…
Communication with MCU established.
Can’t autodetect firmware, because proper answer not received (may be unknown firmware).
Please, reset module or continue.
You must use 9600 baud rate in order to work…
I have tried every baud rate 9600, 115200 , 74880 etc.
I have been using nodemcu_integer_0.9.5_20150318.bin flashed at 0x000.
But i’m stuck at same place.
PORT OPEN 9600
Communication with MCU…
……….
Got answer! AutoDetect firmware…
Communication with MCU established.
Can’t autodetect firmware, because proper answer not received (may be unknown firmware).
Please, reset module or continue.
�‡‚‚þ‡‚Žþ‡þw{cw{cw{cw{cw{cw{cw{c
I tried your troubleshooting step of Esplorer, closed esplorer, discnnected the ESP power and than reconnected it. But nothing is working.
I’m able to flash and program properly with AT binaries but not with NodeMCU.
I’ve tried using nodemcu_integer_0.9.5_20150318.bin and nodemcu_integer_0.9.6-dev_20150331.bin
There’s not need to try different baud rates. It will only work with 9600 baud rate in the ESPlorer IDE.
Do you have GPIO 0 disconnected from GND on boot?
During flashing GPIO0 was connected to GND, and it flashed properly. Now for programming (user mode) GPIO0 is connected to Vcc (3.3V).
I have a situation when the esp8266 is power on the relay wil automatically on at the same time.as per my program it’s faulty.but the indicator led’s are working properly as per my program but th relay fails how
Pls help
Hi.
Which pin are you using to control the relay?
I recommend taking a look at the ESP8266 GPIO guide: https://randomnerdtutorials.com/esp8266-pinout-reference-gpios/
You might be using a pin that is not appropriate to connect relays.
Regards,
Sara
I purchased your book and was able to get my esp8266 up and running. I had the 2 leds controlled by the web working for about 30 minutes then it stopped working and the blue light has come on and stayed on. I have ben able to flash it but when i try to connect to it all i get is garbage characters back. This has happened on 2 esp8266. They work then after 30 minutes or so they seem to freeze up. Any help would be great.
Thanks
Hi Brad,
Thank you for supporting my work! How are you powering your ESP8266?
Do you have a stable power connection? That might be a power spike that makes your ESP disconnect and needing a reset.
Thanks,
Rui
I ran it off the usb power originally and everything worked for 30 minutes or so. I ran it off a power supply and it is doing the same thing. I’m able to flash it but I can’t get it to connect to the ESPlorer. The red and blue light are on all the time after resetting after a new flash.
I found this on the net and wandering if this could be the problem.
“Looks like you do not use a controller to send your data to. ESP tries to upload data but cannot connect to a controller this results in the ConnectionFailures counter to be added by 1. Every minute ESP gets a new ConnectFailure resulting in the counter reaching 30 after about half an hour.
Then the program reboots itself.
If you uncheck the ‘Send Data’ box in all your device tabs (Edit and under Task Settings) then ESP will stop trying to send data to a controller and no ConnectionFailures are counted.
edit: If you do use a controller then double check if you have given the right Controller IP and Controller Port in the Main Settings tab.”
Any help would be great,
Thanks
Hello Rui!
I’m facing the same problem where my nodemcu firmware update stops midway (right under the P of COM port where the progress is shown) I’ve tried at he method you have mentioned there to tackle it, but with no progress at all. Previously I’ve used the same ESP8266 and the FTDI232 to implement communication between ESP and a browser using the STAIP successfully. I think this means my FTDI and the ESP are working well (right?!). I’m stuck at this point now(firmware update). Any help would be appreciated!
This can be a power issue and your ESP is crashing, because it’s not receiving enough amperage
I am using a power supply capable of providing 1A.
Hi Can you please post the log message from the NodeMCU flasher (in the log tab).
Probably it might be write or address timeout.
Address timeout is generally because of the wrong configurations.
You can try with these advanced configuration in NodeMCU.
flash size : 8Mbyte
flash speed : 40MHz
SPI Mode : DIO
i followed your tutorial to the letter, but i get this error when i try to compile your program:
exit status 1
‘D1’ was not declared in this scope
You probably had the Board Generic ESP board, I’ve fixed the code and it should regardless of the board.
Hi,what are the other buttons for on ESPlorer IDE some buttons are save to and some buttons are save to ans some buttons are the same? i dont get why?there are two save and compile and there are two view buttons on esp,( save to) (upload to) and (send to) whats the differance,realy ime confused and they never work half the time,i cant find a manual for the ide eather that explains “everything”
I had the issue you discribed at “NodeMCU flasher gets stuck at a certain percentage”. Changing the baud rate did not work for me. BUT, fortunantly, my notebook has an USB 2.0 port (beside all the USB 3.0 ports). I plugged the FTDI to the USB 2.0 port and it worked perfectly!
Have fun!
Thanks for letting me know!
Hi Rui,
Any experience with this board:
smartarduino.com/esp8266-wifi-web-sever-shield-for-arduino_p94660.html
Biggest question…how to turn this into a webserver..using the IDE ?????
Wim
I never used one…
Thanks for asking,
Rui
Does anyone know why this sketch does not comile because of the <meta ………. line.
I just want the temp to be send every 2 seconds to my browser and a line feed betwenn the temperature Digits.
PLEASE HELP I am nearly there I think.
// Connect to WiFi network
WiFi.begin(ssid);
Serial.print("\n\r \n\rWorking to connect");
// Wait for connection
while (WiFi.status() != WL_CONNECTED) {
delay(500);
Serial.print(".");
}
Serial.println("");
Serial.println("DHT Weather Reading Server");
Serial.print("Connected to ");
Serial.println(ssid);
Serial.print("IP address: ");
Serial.println(WiFi.localIP());
;
// server.on(“/”, handle_root);
server.on(“/temp”, [](){ // if you add this subdirectory to your webserver call, you get text below 🙂
gettemperature(); // read sensor
webString=”Temperature: “+String((int)temp_t)+” C”; // Arduino has a hard time with float to string
server.send(200, “text/plain”, webString); // send to someones browser when asked
});
/* server.on(“/humidity”, [](){ // if you add this subdirectory to your webserver call, you get text below 🙂
gettemperature(); // read sensor
webString=”Humidity: “+String((int)humidity)+”%”;
server.send(200, “text/plain”, webString); // send to someones browser when asked
});
*/
server.begin();
Serial.println(“HTTP server started”);
Serial.println();//Wiederholung http
// Serial.println(());
}
void loop(void)
{
server.handleClient();
}
void gettemperature() {
// Wait at least 2 seconds seconds between measurements.
// if the difference between the current time and last time you read
// the sensor is bigger than the interval you set, read the sensor
// Works better than delay for things happening elsewhere also
unsigned long currentMillis = millis();
if(currentMillis – previousMillis >= interval) {
// save the last time you read the sensor
previousMillis = currentMillis;
// Reading temperature for humidity takes about 250 milliseconds!
// Sensor readings may also be up to 2 seconds ‘old’ (it’s a very slow sensor)
humidity = dht.readHumidity(); // Read humidity (percent)
temp_t = dht.readTemperature(); // Read temperature as Fahrenheit
// Check if any reads failed and exit early (to try again).
if (isnan(humidity) || isnan(temp_t)) {
Serial.println(“Failed to read from DHT sensor!”);
return;
}
}
}
Sorry got the copy wrong. This is now correct.
#include
#include
#include
#include
#define DHTTYPE DHT22
#define DHTPIN 2
const char* ssid = “ESP8266”;
const char* password = “”;
ESP8266WebServer server(80);
// Initialize DHT sensor
// NOTE: For working with a faster than ATmega328p 16 MHz Arduino chip, like an ESP8266,
// you need to increase the threshold for cycle counts considered a 1 or 0.
// You can do this by passing a 3rd parameter for this threshold. It’s a bit
// of fiddling to find the right value, but in general the faster the CPU the
// higher the value. The default for a 16mhz AVR is a value of 6. For an
// Arduino Due that runs at 84mhz a value of 30 works.
// This is for the ESP8266 processor on ESP-01
DHT dht(DHTPIN, DHTTYPE, 11); // 11 works fine for ESP8266
float humidity, temp_t; // Values read from sensor
String webString=””; // String to display
// Generally, you should use “unsigned long” for variables that hold time
unsigned long previousMillis = 0; // will store last temp was read
const long interval = 2000; // interval at which to read sensor
void handle_root() {
server.send(200, “text/plain”, “Hello from the weather esp8266, read from /temp or /humidity”);
delay(100);
}
void setup(void)
{
// You can open the Arduino IDE Serial Monitor window to see what the code is doing
Serial.begin(115200); // Serial connection from ESP-01 via 3.3v console cable
dht.begin(); // initialize temperature sensor
// Connect to WiFi network
WiFi.begin(ssid);
Serial.print(“\n\r \n\rWorking to connect”);
// Wait for connection
while (WiFi.status() != WL_CONNECTED) {
delay(500);
Serial.print(“.”);
}
Serial.println(“”);
Serial.println(“DHT Weather Reading Server”);
Serial.print(“Connected to “);
Serial.println(ssid);
Serial.print(“IP address: “);
Serial.println(WiFi.localIP());
;
// server.on(“/”, handle_root);
server.on(“/temp”, [](){ // if you add this subdirectory to your webserver call, you get text below 🙂
gettemperature(); // read sensor
webString=”Temperature: “+String((int)temp_t)+” C”; // Arduino has a hard time with float to string
server.send(200, “text/plain”, webString); // send to someones browser when asked
});
/* server.on(“/humidity”, [](){ // if you add this subdirectory to your webserver call, you get text below 🙂
gettemperature(); // read sensor
webString=”Humidity: “+String((int)humidity)+”%”;
server.send(200, “text/plain”, webString); // send to someones browser when asked
});
*/
server.begin();
Serial.println(“HTTP server started”);
Serial.println();//Wiederholung http
// Serial.println(());
}
void loop(void)
{
server.handleClient();
}
void gettemperature() {
// Wait at least 2 seconds seconds between measurements.
// if the difference between the current time and last time you read
// the sensor is bigger than the interval you set, read the sensor
// Works better than delay for things happening elsewhere also
unsigned long currentMillis = millis();
if(currentMillis – previousMillis >= interval) {
// save the last time you read the sensor
previousMillis = currentMillis;
// Reading temperature for humidity takes about 250 milliseconds!
// Sensor readings may also be up to 2 seconds ‘old’ (it’s a very slow sensor)
humidity = dht.readHumidity(); // Read humidity (percent)
temp_t = dht.readTemperature(); // Read temperature as Fahrenheit
// Check if any reads failed and exit early (to try again).
if (isnan(humidity) || isnan(temp_t)) {
Serial.println(“Failed to read from DHT sensor!”);
return;
}
}
}
Where do I place the ( 😉
For some reason I cannot write the repeat line of code. I will try again. sorry for the mess.
.
Sorry I give up!
If anyone understands what I would like please reply with thcode via my email. [email protected]
Hi Rui,
I am new to the ESP8266 and using Wifi related applications. Is it possible to use the esp8266 and an dht22 to send temperature data continiously to a Tablet (without a browser refresh) (android) and to see the data in real temp and as a graph? Must I have a router or the Internet involved? I thought this sketch might work but I think I Need the SSID of my Internet modem and router for it to work..
The easiest way is to add an html tag to your code that makes your browser constantly refresh. Just search for “refresh web page html tag”
Hi Rui,
Thanks for the quick answer. I don’t think I ask the qestion correctly. If I want to send a stream of temperature readings from the esp8266 to my tablet do I HAVE to have connection to the Internet? If not could you direct me to some code that does this, I could then add to it to make a graph etc. as I have written. My knowledge is not enough to start such a Project from scratch.Hope you can help me.
Hi Paul,
Is it an option to use an Arduino and a shield?
for example an Arduino Uno and this shield: smartarduino.com/esp8266-wifi-web-sever-shield-for-arduino_p94660.html
It is very easy to setup. You can connect the Temperature Sensor to the Arduino via the webshield interfaces and the Arduino can send via de Serial port the data to the Shield. The shield can then send via wifi the data as udp package to any IP address. no programming required for the esp8266. Example code is available.
Regards, Wim
Hi Wim,
I think there must be an easier way. I Need to Keep the DHT22 and ESP8266 small. I have now found code which sends the Temperature and Humidity (which I don’t Need) to my tablet via a Hot Spot which I Setup on my Tablet. I still have to write the IP address in the browser and /temp and the Temperature is sent to the Tablet. Now I just Need this to happen as a stream without have to call the Temperature everytime. I will try the code that Rui sent me for a constant feed to the browser. I was looking for a solution which does not need the hotspot. Thank you for your Suggestion, I will be looking at this product a bit nearer.
A few weeks ago I bought the Home automation using ESP8266 ebook.
I tried it out now.
I successfully flash NodeMCU. When opening ESplorer and pressing open, the terminal only shows following output:
PORT OPEN 9600
Communication with MCU..
no additional
Hi Nico.
Did you try to follow the “ESPlorer IDE Error: Waiting answer from ESP – Timeout reached. Command aborted.Waiting answer from ESP – Timeout reached. Command aborted.” section in this blog post?
It sounds like your ESP is not going into upload mode…
Hi Rui,
Just a request.
I have seen that even CSS and javascript can be included in Lua script.
Can you please post a tutorial for the same as i couldn’t find a good tuts on it, how to incorporate it and make my server more user-friendly.
You can add any HTML or even css to your web page take a look at this example: https://randomnerdtutorials.com/esp8266-web-server-with-arduino-ide/
Hi Rui,
nodemcu_integer_0.9.5_20150318.bin : 0x000
esp_init_data_default.bin : 0xfc000
blank.bin : 0xfe000
Java version : build 1.8.0_51-b16
Getting error :
PORT OPEN 115200
Communication with MCU…
……….
……….
Got answer! AutoDetect firmware…
Communication with MCU established.
Can’t autodetect firmware, because proper answer not received (may be unknown firmware).
Please, reset module or continue.
Please help
Thanks
If you flashed your ESP8266 with the NodeMCU version I’ve recommended, you must set the baud rate to 9600.
Otherwise you’ll not be able to establish a serial communication with your ESP8266.
Thanks,
Rui
Hi Rui,
Thanks for replying.
Actually i’ve tried every baud rate.
I keep on getting this :
PORT OPEN 9600
Communication with MCU…
……….
……….
……….
Than at this point i need to bring CH_PD HIGH -> LOW -> HIGH after which communication seems established but than i get (even @9600baud)
Got answer! AutoDetect firmware…
Communication with MCU established.
Can’t autodetect firmware, because proper answer not received (may be unknown firmware).
Please, reset module or continue.
�‡‚‚þ‡‚Žþ‡þw{cw{cw{cw{cw{cw{cw{c
Please check whether does this answer helps…
stackoverflow.com/questions/39142861/esp8266-cannot-read-flash-after-programming
I have the issue “NodeMCU flasher gets stuck at a certain percentage”. I have tried all the bauds rates with the configuration suggested. No results. Is there an other trick to succeed to solve this problem ?
You might either need to power your ESP8266 with an external power supply or you might have to use another FTDI programmer…
how to do the above process for esp8266 es-12e
If your ESP has built-in programmer, you don’t need to worry about any connections…
If your ESP-12 has not programmer, you can follow the same connection diagram shown in this blog post
I am using esp8266-1 modules and the ESP8266Flasher that has 0.9.5 bundled with it. I am able to flash the built in 0.9.5 with no problems. I found there are some issues with the timer code in 0.9.5, and told it was resolved in 0.9.6, so I got the last revision of that NodeMCU 0.9.6 build 20150704, and that will flash just fine. However any of the custom builds that I have tried fail, They seem to flash OK, you can see the bargraph tick along. You get the checkmark at the end like all is well, but when you power them back up in user mode, you get nothing but endless lines of goop out the serial port.
I have tried every memory size. I have seen references to having to set up to blank some areas in the memory map and upload some other file (no idea where that comes from..) to another area. Does anybody have the definitive fix for this?
I use ESP to control some lamps in my home. ESP uses a webserver that provide a page with two buttons – ON and OFF.
In LAN network, everything is fine. I can turn the lamp on and off a thousand times and the ESP works 100%, but when I’m accessing ESP from outside my LAN network, using a DDNS server and port forward in modem, ESP crashes, and does not respond to commands anymore until I reboot it.
Any Idea?
Thanks!
I really don’t know… It might be that the connection is not closed and causes the ESP8266 to crash
Hi,
I have an ESP8266 with usb connection (CP2102 USB interface).
When I connect to my machine (a linux) I get the lines bellow in dmesg (I attempted to make connection on Raspberry as well as my laptop without success). Hence there is no way to get the console connected to the device via USB.
I seems to me the USB died. In the mean time other 2 ESPs are working.
QUESTION: Any idea how to delete everything from the chip inorder to go back to the seller for an exchange? Or do you have any idea how to fix it? I was thinking on RX/TX line + USB to serial converter, but not sure if I can do anything via those lines.
The chip itself seems to work so it is running the scripts inside (I see the LED changing when go into deep sleep).
[69348.252458] usb 1-1.3: new full-speed USB device number 6 using dwc_otg
[69348.332457] usb 1-1.3: device descriptor read/64, error -32
[69348.522449] usb 1-1.3: device descriptor read/64, error -32
[69348.712468] usb 1-1.3: new full-speed USB device number 7 using dwc_otg
[69348.792469] usb 1-1.3: device descriptor read/64, error -32
[69348.982464] usb 1-1.3: device descriptor read/64, error -32
[69349.172446] usb 1-1.3: new full-speed USB device number 8 using dwc_otg
[69349.592464] usb 1-1.3: device not accepting address 8, error -32
[69349.672455] usb 1-1.3: new full-speed USB device number 9 using dwc_otg
[69350.092483] usb 1-1.3: device not accepting address 9, error -32
[69350.092666] usb 1-1-port3: unable to enumerate USB device
Zoli
I’ve never seen that error before. Are you able to detect your device? Or a driver is missing??
Reflashing the ESP8266 with a new firmware should make it work again… You’ll need to use an external programmer instead…
I had the same. Changed the cable … and bingo … these errors gone.
After successfully getting 3 ESP8266’s to take some LUA code and execute, they then stop being able to be connected to by ESPlorer. I get the message “Communication with MCU..Waiting answer from ESP – Timeout reached” The code does execute on the ESPs either. I reflash successfully, but it still appears bricked. I tried moving GPIO back and forth from Ground to VCC, but it still doesn’t work. Any thoughts?
Are you able to flash the ESP with NodeMCU?
That will unbrick your ESP8266. Then, open the ESPlorer with the ESP having GPIO 0 disconnected from GND on boot up and try to upload code.
This is regrading the mangoose OS installation .
If any mismatch please let me know .
I am following same procedure shown below .
Procedure :
1. Connect CP2101 to USB port ( it detect as COM3)
2. Download mangoose software from (https://mongoose-iot.com)
3. Press GPIO0 button , then press Rest button release reset button then release GPIO0button
4. Open cmd prompt change directory to where I have kept mos exe
5. Set MOS_PORT=COM3
6. Type oms ( same folder where I have down load )
Mangoose OS installer :
1. Connect device , select COM3
2. https://mongoose-iot.com/downloads/fw-esp8266.zip
3. setup wifi
Setup wifi am getting error :
Error error connecting to the device via serial://COM3: Access is denied
First, Rui, I thank you for the huge amount of work you have done to simplify the tool chain for this very frustrating chip. I am so close to having a working board now. Please consider the following situation and tell me what you think:
1) I get a success message after flashing NodeMCU with your tool. My chip is 16M; it is on the Espressif ESP Launcher board, which I think is a newer dev kit. From all appearances, everything goes perfectly.
2) I put the chip back into run mode via a switch they provide for GP0, and open the port with ESPlorer at 9600 baud. I receive a message that communication with the MCU is successful.
3) A second message tells me “can’t autodetect firmware”…followed by a few nonsense characters. I have seen this before, though, when running the AT firmware, which otherwise runs without issue. However, in this case, I cannot seem to upload the init.lua script. It acts like it takes, but then when I reboot the chip, I get the message “Waiting answer from ESP – Timeout reached”
**
I do not think there is a problem with your tools. I just do not know what to check, and would appreciate any insight you may offer. I will gladly send you a screenshot if you think that might help; just provide an address. Thanks
Thanks for reading.
While having the ESP connected to your computer and the ESPlorer IDE open. Try to press the ESP reset button, restarting the ESP should make it go into upload mode and remove that error.
GPIO 0 must be disconnected or connected to VCC on boot, so that your ESP goes into upload mode with the ESPlorer IDE
I am using node mcu v3 lua based esp8266.It is flashing successfully,but while opening in esplorer it is unable to communicate with mcu.
Please give me solution
You need to tell me what error is happening
I live of the grid and the ISP dictates that I use a static IP and port forwarding to access cameras and other devices with in my LAN. I must assign a static IP for each device. Can I implement this with the ESP to use a web server?
John
I was never able to use custom node MCU lua firmware. I use window 64 bit programmer , which shows completed (green check mark + ready) but my webserver which runs perfectly on the previous firmware (supplied by the website where I got webserver example from) does not run on the firmware with additional modules. It happened to me twice, I tried two different examples which run ok , but not with my custom builds of firmwares
You’ll have to set the right paths in the NodeMCU Flasher config tab or use the ESPtool script
I was used my esp as AP mode and controlled home lamps… Its working well few hours after that its not working… And i did reset my esp but its not worked but mobile was connected. And i redumped the same code still not work… Finally 1st i am dump different code that code working after i came back redump old code(without any changes) this time its work.. I was faced 3 times this problem… Plz help me
It might be a power issue that causes your ESP to crash…
Make sure you check that you are supplying enough current to your ESP
I had the same exact problem with a lamp controller that I wrote. I used a -01 module with 8Mb or 1MB flash. I used one GPIO to run a relay board and the other for a local on/off toggle as it would be a pain in the ass to have to use a computer every time I want to turn a light on or off. The web interface has on/off buttons and the lamp itself has a push button that toggles it’s current state.
Anyway, after a while the thing would just stop working and need to be rebooted, just like you are seeing. I had already went from flash 0.95 to 0.96 because the timer is broken in 0.95, and I moved from 0.96 to 1.54 (after a lot of fighting to get it to flash) and that solved the not working after a while problem for me.
Lemme know if it helps ya!
Hy
I am new comer in arduino,
But I am not able to flash my esp8266 01 wifi module through the ttl converter… Any one suggest me with pin diagram how to flash esp the esp module through node mcu flasher software
Hi.
You can use this tutorial: https://randomnerdtutorials.com/flashing-nodemcu-firmware-on-the-esp8266-using-windows/
Regards,
Sara
My USB chip is PL2303HX. will your FTDI program work.? I am using win 10 and its hell to see the port . It comes up with a yellow triange and a message saying it does not work.
Thanks for your response.
I searched a bit more and got a driver that worked. It seem to be an old version. I tried your fdti but it did not work. Sorry I did not find a solution earlier.
Hi Rui
This is shishir.I saw your post you did Great job for us. I have problem with node mcu esp 8266 wifi. For relay on off and it working fine with local ip but after few time I lost my ip and its not working until that reset again. Why its happens I could not find.please help me.
Shishir
I’m not sure which code are you running and that’s very general problem. Make sure you are powering the ESP8266 with a stable power supply that can provide enough current to power your project…
thanks this worked for me. 😀
Great!
Hi Rui Santos,
thank you very much for your tutorial, its very useful, but i have problem when upload your program in arduino IDE to NodeMCU. I can’t compile your sketch. This error message like that:
wifi:144:1: error: stray ‘\302’ in program
can you help me to fix it?
thank you Rui Santos
Hi.
I’ve never faced that error, but after a quick search, it seems you have a weird character hidden in your code.
I think the answer is on the following link:
arduino.stackexchange.com/questions/30581/stray-302-in-program-error-when-compiling
Let us know if that solved your problem.
Regards,
Sara 🙂
Hi Rui. i had problems with the uploading but is now fixed. my problem now is another one. i get stuck on the “newclient” and i can´t access the web server…. any ideas??? thanks.
Hi José.
I think this should solve your problem: https://rntlab.com/question/solved-esp32-web-server-drops-connection-crashes/
Let me know if it worked.
Regards,
Sara 🙂
I am using Node MCU board. facing issues for uploading code. Its coming error as follows:
Please provide me solution
warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed
error: espcomm_upload_mem failed
Hi.
It can be one of the following problems:
– The ESP8266 is not in flashing mode.To enable ESP8266 firmware flashing GPIO0 pin must be pulled low before the device is reset. For a normal boot, GPIO0 must be pulled high or floating.
– It is not properly connected to the serial adapter (if you’re using an ESP8266). Double check the connections and the pinout.
– You’re not providing enough power. For example if you’re using an ESP-01, using 3.3V from an Arduino might not provide enough current. Use an external power supply.
– You’re not using a USB cable with data wires (many usb cables from chargers don’t have data wires).
I hope this helps.
Regards,
Sara
I purchased two identical ESP8266MOD based dev boards. I couldn’t do much with them so I flashed them with the default firmware in NodeMCU Flasher. They both worked fine. Then I UpLoaded an Arduino program to one of them. That worked fine. Then I flashed both of them with a custom built firmware from GitHub. The one that had the Arduino program just loops the intro screen when I reset it. The other one still works fine, and has had two other custom firmwares flashed into it since then. The only way to make the ‘bad’ one work is to re-flash it with the default NodeMCU FW that doesn’t have floating point math, and several other useful modules.
Here are the boot screens I get:
====================================================
-=-=-= Output from NodeMCU _default_ FirmWare =-=-=-
PORT OPEN 74880
ets Jan 8 2013,rst cause:2, boot mode:(3,6)
load 0x40100000, len 28740, room 16
tail 4
chksum 0xcd
load 0x3ffe8000, len 2888, room 4
tail 4
chksum 0xbc
load 0x3ffe8b50, len 15252, room 4
tail 0
chksum 0x4f
csum 0x4f
====================================================
Output from NodeMCU _custom_ FirmWare that does NOT work.
PORT OPEN 74880
ets Jan 8 2013,rst cause:2, boot mode:(3,7)
load 0x40100000, len 28652, room 16
tail 12
chksum 0x03
ho 0 tail 12 room 4
load 0x3ffe8000, len 2364, room 12
tail 0
chksum 0x66
load 0x3ffe893c, len 136, room 8
tail 0
chksum 0xfb
csum 0xfb
rf_cal[0] !=0x05,is 0x00
ets Jan 8 2013,rst cause:2, boot mode:(3,7)
load 0x40100000, len 28652, room 16
tail 12
chksum 0x03
ho 0 tail 12 room 4
load 0x3ffe8000, len 2364, room 12
tail 0
chksum 0x66
load 0x3ffe893c, len 136, room 8
tail 0
chksum 0xfb
csum 0xfb
rf_cal[0] !=0x05,is 0x00
ets Jan 8 2013,rst cause:2, boot mode:(3,7)
…
It just repeats over and over.
===================================================
Output from NodeMCU _custom_ FirmWare that does work on other ESP8266MOD.
PORT OPEN 74880
ets Jan 8 2013,rst cause:2, boot mode:(3,7)
load 0x40100000, len 28652, room 16
tail 12
chksum 0x03
ho 0 tail 12 room 4
load 0x3ffe8000, len 2364, room 12
tail 0
chksum 0x66
load 0x3ffe893c, len 136, room 8
tail 0
chksum 0xfb
csum 0xfb
rf cal sector: 1019
freq trace enable 0
rf[112] : 00
rf[113] : 00
rf[114] : 01
SDK ver: 2.2.1(6ab97e9) compiled @ Jun 7 2018 13:59:14
phy ver: 1136_0, pp ver: 10.2
===================================================
It looks like the rf_calibration is the problem, But I don’t know how to fix it.
T.I.A.
Stephen
Hi Stephen.
What code are you running on your “bad” ESP8266? It may be a code that crashes the ESP8266 and it keeps resetting.
You can also have some sort of hardware problem. It’s often related to one of the following issues:
Poor quality USB cable;
USB cable is too long;
Board with some defect (bad solder joints);
Bad computer USB port;
Or not enough power provided by the computer USB port.
If it is an hardware problem, I advise you to try a different shorter USB cable (with data wires), try a different computer USB port or use a USB hub with an external power supply.
I hope this helps.
Regards,
Sara
i followed instructions for the webserver and sensor(one im using is am2301) and the flashed sonoff th16 (esp8266) device . it is saying sensor reading failed, any thoughts?
Hi.
It can be:
– not enough power
– you’re not giving enough time for the sensor to take readings (make sure you have a delay between sensor readings)
– wires not properly connected
Hey there Rui!
I have a LoLin v3 Node MCU Dev Board.
The blue light doesn’t flash/blink anymore on connection to power source or during flashing.
So I have no indication whether the board is working or not.
I tried connecting the D4 pin (built-in blue LED) to GND and it glows constantly.
Other than that, nothing seems to work.
I can’t flash the board, the process doesn’t start, always waiting for MAC; I’ve tried connecting the pins to GND as well.
Please help me out.
This is the error I get on the Arduino IDE when I try to upload any code. I can’t seem to upload any code.
Arduino: 1.8.5 (Windows 10), Board: “NodeMCU 1.0 (ESP-12E Module), 80 MHz, Flash, Disabled, All SSL ciphers (most compatible), 4M (no SPIFFS), v2 Lower Memory, Disabled, None, Only Sketch, 115200”
Build options changed, rebuilding all
Archiving built core (caching) in: C:\Users\MUKUL\AppData\Local\Temp\arduino_cache_549157\core\core_esp8266_esp8266_nodemcuv2_xtal_80,vt_flash,exception_disabled,ssl_all,eesz_4M,ip_lm2f,dbg_Disabled,lvl_None__,wipe_none,baud_115200_65e50a5fad0627179c7c4d2e008fc25d.a
Sketch uses 257716 bytes (24%) of program storage space. Maximum is 1044464 bytes.
Global variables use 26576 bytes (32%) of dynamic memory, leaving 55344 bytes for local variables. Maximum is 81920 bytes.
esptool.py v2.6
2.6
esptool.py v2.6
Serial port COM10
Connecting……..__….._….._….._….._….._…..___Traceback (most recent call last):
File “C:\Users\MUKUL\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.1/tools/upload.py”, line 25, in
esptool.main(fakeargs)
File “C:/Users/MUKUL/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/2.5.1/tools/esptool\esptool.py”, line 2653, in main
esp.connect(args.before)
File “C:/Users/MUKUL/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/2.5.1/tools/esptool\esptool.py”, line 468, in connect
raise FatalError(‘Failed to connect to %s: %s’ % (self.CHIP_NAME, last_error))
esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header
_
the selected serial port _
does not exist or your board is not connected
Hi.
Make sure that you have selected the right COM port. Also, make sure that you’re using a USB cable with data wires. Some USB cables from mobile chargers don’t have data wires.
Also, it seems that you’re having this error: https://randomnerdtutorials.com/solved-failed-to-connect-to-esp32-timed-out-waiting-for-packet-header/
Follow the instructions on that tutorial and it should be fixed.
Regards,
Sara
Arduino: 1.8.9 (Windows 7), Board: “NodeMCU 1.0 (ESP-12E Module), 80 MHz, Flash, Disabled, All SSL ciphers (most compatible), 4M (no SPIFFS), v2 Lower Memory, Disabled, None, Only Sketch, 115200”
Build options changed, rebuilding all
Sketch uses 276204 bytes (26%) of program storage space. Maximum is 1044464 bytes.
Global variables use 27924 bytes (34%) of dynamic memory, leaving 53996 bytes for local variables. Maximum is 81920 bytes.
esptool.py v2.6
2.6
esptool.py v2.6
Serial port COM1
Connecting…….._____….._____….._____….._____….._____….._____….._____
Traceback (most recent call last):
File “C:\Users\use\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.5.2/tools/upload.py”, line 25, in
esptool.main(fakeargs)
File “C:/Users/use/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/2.5.2/tools/esptool\esptool.py”, line 2653, in main
esp.connect(args.before)
File “C:/Users/use/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/2.5.2/tools/esptool\esptool.py”, line 468, in connect
raise FatalError(‘Failed to connect to %s: %s’ % (self.CHIP_NAME, last_error))
esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header
esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header
This report would have more information with
“Show verbose output during compilation”
option enabled in File -> Preferences.
Hi.
I’ve faced a similar issue a few days ago.
I haven’t found a solution. I needed to uninstall Arduino IDE and install everything again (Arduino IDE and the ESP8266 add-on).
Regards,
Sara
Successfully flashed the ESP8266_Deauther_v2.0.0_1MB binary last night. However, today it stopped being able to produce any wifi communication. Trying to reflash right now, but am getting “Note:Serial port disconnected.” right as the flash reaches 100%. All other logs say successful.
So I have been trying everything for 2 days to get my NodeMCU’s to flash. Would you believe it was a bad USB cable. The Node’s would start to flash and aways fail. It was driving me nuts. Now I can flash at full baud rate. Lesson learned, sometimes it’s a bad damn USB cable.
Hi Brian.
That’s true. Always use a food USB cable.
Also, we need to update this troubleshooting guide.
Regards,
Sara
Hello.. the code to connect to wifi gets uploaded to the esp with no errors popping but is still not getting connected to the wifi. I mean no action.. nothing can be seen on serial monitor.
Hi.
After uploading the code, press the on-board RESET button and it should print something on the Serial Monitor.
Regards,
Sara
Hi.
Im having a problem when using lolin esp32 nodemcu
If i upload with dth22 connected i have error , if i disconnect the sensor the Sketch uploads and when i put it to work its allways whit the sensor out and then when pluged it , i have to Connect the sensor afete, if power goes down i have to take the sensor out and do all the process, can you help please? Thanks a lot.
Hi.
Which GPIO are you connecting your sensor?
Try with another pin.
Regards,
Sara
Hi Sara, Portuguese? I am
Thanks i changed and uploads ok and reading ok. Is to much ask you for help? I need to put it reading several dht22 i have parrot and need to monitorize them, already have cameras 1 wire temperature sensors and later relay to feed and watering them, but for Now i need several DHT22 and im not a programer im curious and testing, testing, testing, thanks a lot
Hi.
Yes, I’m portugues.
You can take a look at some of our tutorials with the DHT sensor:
https://randomnerdtutorials.com/esp8266-dht11dht22-temperature-and-humidity-web-server-with-arduino-ide/
https://randomnerdtutorials.com/esp8266-publishing-dht22-readings-with-mqtt-to-raspberry-pi/
Regards,
Sara
Thanks Sara, i`l have a look.
Keep going, all the best for you.
My NodeMCU is neither blinking nor connecting to my computer when I am connecting it to my computer, previously it was working properly but now nothing happens to it after plugging it into the computer…
Please help me
(My NODE MCU has been burnet or What If it is burnet then how to check and verify that its burnt )
Rui, I don’t know if you’re still monitoring this thread, but I’ll give it a try. I’ve been trying to find an answer to a problem that many seem to have, but I’ve seen no actual resolution. Perhaps you’ve seen it or heard of it. The situation is such:
If I set up an ESP8266 with a basic webserver, or asynchronis webserver, and put the ESP into AP mode, I can log onto the access point created using the network selection process on my android devices. IE: my phone, wife’s phone, tablet, and access a webpage served from it’s internal network.
What doesn’t work is that I can’t log on to it using my laptop running Windows 10. The laptop will attempt, and sometimes connect, but almost immeadiately it drops the connection with a message that the network uses an older security protocal and will not connect. I have an older laptop running Ubuntu 20.04, and have similar results. All the while the android devices work fine. Any thoughts on that?
Hey ,thanks for this tutorial
this is my problem :
when i disconnect (or pull up the IO0 ) the esp for running the normal(boot from flash) Esp ,it drew about 100 mA … ( i think there is sth wrong but changing esp (new one ) didn’t work…) and doesn’t show sth readable in the serial port …
but when i put it in the upload mode and programed it , it seems Ok…(2mA draw)
info :
IO15——->pulldown 1k res
IO0——–>pullup/down 1k res
VCC——-> VCC power supply|tested with cap / whitout
GND——>GND power supply|with cap / whitout
ch_en——->pullup 1K res
RX——->TX
Tx——–>RX
and Common gnd for FTDI
using pl2303(as a FTDI) and esp 07-s and windows10 , (pl2303 do work in windows 10 but in the mac has some problem )
I tried it first time and it worked … but now it doesn’t work properly
also people says you should pullup the IO2 , (it’s tested before but in the first time i didn’t do that and it worked !!!)
I ‘m going thru MicroPython_Programming_with_ESP32_and_ESP8266_V1_2, with uPyCraft and currently on PWM.
Installing, flashing ESP with microPython, editing and uploading works good but when I try outside power source
it doesn’t work. When connecting back to computer doesn’t work either and I have to upload script again to get board to work. Is it there something that needs to be set somewhere to make board to remember program. Resetting it didn’t help.
Hi.
You’re probably facing this issue: https://rntlab.com/question/codigo-so-roda-quando-conectado-ao-ide/
You’re running the code, but you’re not uploading it to the board.
Because you’ve purchased one of our courses, you can submit your questions and issues in our forum: https://rntlab.com/forum/
I recommend you to use the forum instead.
Sometimes, it is very difficult to track all comments here.
Regards,
Sara
Hi! I am having trouble with the final steps of getting my ESP32-CAM woking. I used a Mini FT232RL FTDI 3.3 5V USB to TTL Serial Converter Adapter Module for Arduino to upload the CameraWebServer to the ESP32. All good so far (after 3 days of frustration). I open the serial monitor and gt the usual readout.
However, when it come to WiFi starting up all I get is
……………………………………………………………………………………………………
It appears I cannot get past the last lin of is piece of code:
WiFi.begin(ssid, password);
while (WiFi.status() != WL_CONNECTED) {
delay(500);
Serial.print(“.”);
Does anyone have any ideas what I need to do. BTW, I do not have an external antenna fitted. Thanks
Hi.
That usually means that your ESP32-CAM is not able to connect to your network.~
Double-check that you have inserted the right network credentials.
Additionally, because you don’t have an external antenna, make sure that you are close to your router, so that the board can pick up wi-fi signal.
Regards,
Sara
Hi. Thanks for the quick reply.I am working with these electronics < 1m from my router.
I am an absolute (64 y.o.) novice with this stuff. Are you able to give me the ‘credentials’ I need to insert. Thanks
My esp8266 freezes and the web access gets unavailable from time to time…
Hello,
I am a rank beginner trying to follow some examples of ESP NOW.
When I substitute the MAC address derived from the receiver into the sketch for the Sender, I get an error:
No1_Sender:16:33: error: expected ‘}’ before ‘:’ token
uint8_t broadcastAddress[] = {84:CC:A8:83:10:A2};
^
No1_Sender:16:33: error: expected ‘,’ or ‘;’ before ‘:’ token
No1_Sender:16:48: error: expected declaration before ‘}’ token
uint8_t broadcastAddress[] = {84:CC:A8:83:10:A2};
^
exit status 1
expected ‘}’ before ‘:’ token
All the example MAC addresses seem to be in a different format to the derived address.
Could you please help me with what I am sure must be an obvious answer.
This report would have more information with
“Show verbose output during compilation”
option enabled in File -> Preferences.
Hi.
Write your MAC address like this:
uint8_t broadcastAddress[] = {0x84:0xCC:0xA8:0x83:0x10:0xA2};
Regards,
Sara
Hi Rui
I have tried to include my sketch bin file in NODE MCU FIRMWARE PROGRAMMER
config. The first row INTERNAL://NODEMCU as default. I put my .bin file in the
second row. After I push Flash(F) it was working well.
The problem is after normal boot of nodeMcu the sketch is not work as intended.
What should I do Rui.
Thank you
RGDS
Raija
Arduino IDE would not upload to ESP8266, tried reset and flash buttons as some times that works.
Then realised I was using a TEMT6000 wired to the reset pin.
Disconnected the reset wire and arduino ide uploaded as expected,
Thought This might some one else if they have the same problem.
Thanks for the great website
Thanks for sharing.
Regards,
Sara
The Espressif flasher will not work but with yours I manage to flash, however not with the proper result. I have a Robotdyn Mega+Wifi with an ESP8266. You can se the problem I get below. I have set the addresses as per the Espressif readme file but still I fail. Where do i go wrong?
ESP8266 boot output:
ets Jan 8 2013,rst cause:2, boot mode:(3,6)
load 0x40100000, len 2592, room 16
tail 0
chksum 0xf3
load 0x3ffe8000, len 764, room 8
tail 4
chksum 0x92
load 0x3ffe82fc, len 676, room 4
tail 0
chksum 0x22
csum 0x22
2nd boot version : 1.7(5d6f877)
SPI Speed : 20MHz
SPI Mode : QIO
SPI Flash Size & Map: 32Mbit(512KB+512KB)
jump to run user2 @ 81000
error magic!
backup boot failed.
user code done
And the addresses set as per Espressif instructions:
Flash size 8Mbit: 512KB+512KB
boot_v1.2+.bin 0x00000
user1.1024.new.2.bin 0x01000
esp_init_data_default.bin 0xfc000
blank.bin 0x7e000 & 0xfe000
Hi.
I’m not familiar with that board and I’ve never faced that error.
I’m sorry that I can’t help.
Regards,
Sara
Hi Rui and Sara, I have 2 Wemos D1 mini ESP8266 and with Arduino IDE i can not upload sketch anymore. They have a both a CH340G on board. The fault that i get is: (esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header)
On Nano with same CH340 chip no problem to upload sketch.
I use Ubuntu with kernel 5.4.0.89
What can i do ?
esptool.FatalError: MD5 of file does not match data in flash! i have got this error, i could not find any solution from anywhere. could you please help me
this is an esp8266 wemos d1 r1 & mini compatible board, with which i was able to load a couple of time programs. But now I can’t as it tries:
esptool.py v3.0
Serial port COM9
Connecting…….._____….._____….._____….._____….._____….._____….._____
but then:
raise FatalError(‘Failed to connect to %s: %s’ % (self.CHIP_NAME, last_error))
esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header
I tried to connect gpio0 to gnd but nothing changed.
When i press reset i get :
ets Jan 8 2013,rst cause:2, boot mode:(5,6)
waiting for host
in the serial port at 74880baud.
Any suggestions? Thank you
Tengo el siguiente problema
esptool.FatalError: MD5 of file does not match data in flash!
Alguien lo pudo solucionar?
write_flash succeeds but program doesn’t run in esp8266-12F . upolad BIN file but not working
ESP8266 hangs freezes stops responding when sent commands from different devices.
I’m checking ESP.getFreeHeap() and have over 30000 free.
I’m checking ESP.getHeapFragmentation() and goes between 1 to 4.
So heap and fragmentation is not the problem in my situation.
Also, I’ve noticed that HTTP GET requests from Safari and cURL work okay, while the ones from Chrome & Firefox cause the device to freeze.
It is still pingable in that frozen state.
I also installed, EspSaveCrash , GitHub – krzychb/EspSaveCrash: Save exception details and stack trace anytime and anywhere the ESP8266 crashes, https://github.com/krzychb/EspSaveCrash
But no crashes are being recorded.
To get my ESP8266 working after it freezes, I have to unplug the power cord and plug it back in again.
I’ve searched many other forums where users of ESP8266 are experiencing similar problems with little or no solution to this.
Any ideas, on how to have the ESP8266 webserver handle client requests from Chrome and Firefox without freezing up the board?
Thanks, Martin
My ESP8266 was working fine yesterday, but when i started integrating it with lcd, some errors started occurring. My code is getting uploaded fully, but nothing is being displayed on my serial monitor, even though the coding is correct. Then i tried uploading the example code of inbuilt led blinking led, the code got uploaded successfully. But no blinking was observed after this. But my led was working when the code was getting transferred. I don’t know why is it happening. Could you guys please help me?
Hi.
Did you press the board RST button after uplaoding the code?
Sometimes, we need to reset the board so that it starts running the code.
Regards,
Sara
Hi.
Did you press the board RST button after uplaoding the code?
Sometimes, we need to reset the board so that it starts running the code.
Regards,
Sara
Hi, I am bhore
My esp 8266 is uploading code successfuly but not connecting and finding wifi network after everything is ok
Hi.
Double-check your network credentials. Uppercase/smallcase and spaces matter.
Also make sure the board is close enough to the router to be able to pick up the wi-fi signal.
Regards,
Sara
Rui: I consistently get the following error messages on upload. My ESP8266 cannot be having that bad of a day. Any suggestions?
esptool.py v3.0
Serial port COM5
Traceback (most recent call last):
File “C:\Users\Jerry Renken\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\3.0.2/tools/upload.py”, line 66, in
esptool.main(cmdline)
File “C:/Users/Jerry Renken/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/3.0.2/tools/esptool\esptool.py”, line 3551, in main
esp = chip_class(each_port, initial_baud, args.trace)
File “C:/Users/Jerry Renken/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/3.0.2/tools/esptool\esptool.py”, line 283, in init
self._port.write_timeout = DEFAULT_SERIAL_WRITE_TIMEOUT
File “C:/Users/Jerry Renken/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/3.0.2/tools/pyserial\serial\serialutil.py”, line 392, in write_timeout
self._reconfigure_port()
File “C:/Users/Jerry Renken/AppData/Local/Arduino15/packages/esp8266/hardware/esp8266/3.0.2/tools/pyserial\serial\serialwin32.py”, line 224, in _reconfigure_port
‘Original message: {!r}’.format(ctypes.WinError()))
serial.serialutil.SerialException: Cannot configure port, something went wrong. Original message: PermissionError(13, ‘A device attached to the system is not functioning.’, None, 31)
serial.serialutil.SerialException: Cannot configure port, something went wrong. Original message: PermissionError(13, ‘A device attached to the system is not functioning.’, None, 31)
I have some ESP8266 D1 Mini modules. In some units it works without any problem, but in others when turned on the blue LED blinks and “dies”, it only comes into operation after I press the reset button a few times, then the blue LED starts blinking weakly, the network WiFi becomes available and I can access it at 192.168.4.1. On both modules I can record the firmware without any problems. I’ve already redone the firmware recording at low speed 9600 and it still didn’t solve the problem, what could be happening?