warning: espcomm_sync failed error: espcomm_open failed esp6286-01 wifi module

I am using 1.8.10 Arduino IDE with the esp8266-01 wifi module and Arduino Uno. I just want to upload simple program but I always get the error:

warning: espcomm_sync failed
error: espcomm_open failed
error: espcomm_upload_mem failed
error: espcomm_upload_mem failed

Connection:
Arduino Uno ----- esp
Tx --- Rx
Rx --- Tx
5v --- ch_pd
5v --- VCC
GND --- GPIO 0
GND --- GND

I have tried some changes in connection but that didn't work for me:

  • 3.3v for VCC and ch_pd.
  • reset pin of Arduino to reset pin of esp and also to GND pin of esp.
  • Rx to Rx and Tx to Tx.

Note: I don't have any external power supply or resistor.
Please help me to get rid of this error. Correct me if my connections are wrong.

Please tell us exactly what you are attempting to accomplish.

There are two ways to use an ESP8266 with Arduino:

  • As a WiFi adapter module controlled by a standard Arduino board such as your Uno. In this usage, you will upload your Arduino sketch to the Uno. Typically, you will just leave the stock AT firmware that comes pre-installed on your ESP-01 so there is no need to upload anything to the ESP-01. This is the most common usage of the ESP-01.
  • As a standalone Arduino board. In this usage, you will program the ESP8266 directly from the Arduino IDE. There are ESP8266 boards specifically designed to make this usage easy. For example, the WeMos D1 Mini, the NodeMCU, the Adafruit Feather Huzzah.

Which one do you want to do?

Thank you for your attention. Actually I am using it to send the data to firebase. Data comes from one sensor(mq2).

That doesn't answer my question.

Sorry for misconception. I want to use it for 2nd way that you said.

Change your connections to RX-RX, TX-TX. That will allow the USB to serial adapter chip on your Uno communicate directly with the ESP8266.

As i have mentioned, i have tried it already but that also didn't work.

jaysuthar:
5v --- VCC

The ESP-01 is a 3.3 V device. You likely destroyed it by powering it at 5 V. I recommend replacing it with one of the ESP8266 boards which are specifically designed to make this usage easy, such as the ones I listed above.

I think is not destroyed because when I am uploading the sketch without any code, it uploads successfully and also AT command works fine.

Anyone here can help me?