ESP8266 Arduino error with Hardware Serial

Hi guys, I’m using an Arduino Nano connected to the ESP-01. In the Nano I’m receiving data from NRF24L01 and sending to the Blynk app, but I’m having troubles and I need your help.

First, when uploading the code, using SOFTWARE SERIAL, it appear the following error:

[19] Blynk v0.3.3-beta
[520] Connecting to iPhone de Renato
[5761] IP: +CIFSR:STAIP,“172.20.10.2”
+CIFSR:STAMAC,“5c:cf:7f:11:d2:f2”

OK
[5808] Connected to WiFi
[14876] Ready (ping: 38ms).
[32240] Ready (ping: 38ms).
[45142] Login timeout
[52182] Ready (ping: 37ms).
[63019] Login timeout
[69467] Ready (ping: 24ms).
[80476] Login timeout
[86436] Ready (ping: 24ms).

And then, when I turn to the HARDWARE SERIAL, disconnecting the pins 2,3 RX/TX, it shows the following, error:

[19] Blynk v0.3.3-beta
[520] Connecting to iPhone de Renato
ATE0
[1531] Failed to disable Echo
AT+CIPCLOSE
AT+CIPSTART=“TCP”,“cloud.blynk.cc”,8442
AT+CIPCLOSE
AT+CIPSTART=“TCP”,“cloud.blynk.cc”,8442
AT+CIPCLOSE
AT+CIPSTART=“TCP”,“cloud.blynk.cc”,8442
AT+CIPCLOSE
AT+CIPSTART=“TCP”,“cloud.blynk.cc”,8442

Could anyone help me please, I have no idea what’s happening, because I was testing the Serial without the RF24 library and it wasn’t showing error, and I’ve already connect with Blynk, so I don’t think it’s a wiring error, but I never could to use the HARDWARE SERIAL, because it appear the error.

thank you guys.

@RenatoLacerda,

The “Failed to disable ECHO” message generally means that your Arduino is not communicating with the ESP. The first AT command Blynk issues is an ATE0, which turns echo off. If your ESP and Arduino are not communicating then you’ll get this error.

SoftwareSerial for the ESP is really flaky. Blynk advises against using it and I have not gotten it to work at all. (I have gotten the USB PC connection to work which is sort of SoftwareSerial, but not directly.)

Things to check/try:

If you’re using the UART lines (Nano 31, 30), you have to be sure to disconnect the ESP01 before downloading the sketch. Otherwise, you send garbage to the ESP and you’ll at least need to reset it (AT+RESTORE command) if not re-flash it. (see reflashing an ESP8266) for a good tutorial on reflashing your device.

You also need to be running ESP firmware v1.0.0 AT 0.22 which you can download here. (The Blynk library is sensitive to the AT code since it is looking for specific character patters which change from release to release.)

Make sure you have anything that prints to the serial lines turned off. BLYNK_DEBUG, BLYNK_PRINT, anything like Serial.print().

Finally, make sure you did not switch RX & TX. You should have:
Nano ESP01
31 (TX) 7 (RX)
30 (RX) 2 (TX)

Good luck.

Regards,
RD7

All new modules ESP-01 I have had the same problem. To communicate with ESP I used hard serial of UNO and libraries ESP8266_HardSer.h BlynkSimpleShieldEsp8266_HardSer.h
I the problem solved by setting the pre-configuration of the ESP by program “ESP8266 Config.exe.”
I set operating mode = STA and put a name and password for the network to which to connect has ESP.
From that moment all ESP works properly in projects