ESP-01S (ESP8266) connectivy issue with arduino

Hello,

i bought a ESP-01S and i plan to program it using only arduino (Mega 2560)

wiring :

  • *ESP-01S:____________ Arduino:
  • GND -------------------------- GND
  • GP2 -------------------------- Not connected
  • GP0 -------------------------- GND
  • RX-------------------------- TX (pin 18)
  • TX -------------------------- RX (pin 19)
  • EN (CHPD) ------------------------ 3.3V
  • RST -------------------------- Not connected
  • VCC -------------------------- 3.3V
    after downloading the package from :
    http://arduino.esp8266.com/stable/package_esp8266com_index.json
    and installing it, i choose the "Generic ESP8266 Module" board from the Tools -> Board menu.

then i upload this sketch to program it :

#include <ESP8266WiFi.h>

const char* ssid = "That's crazyyyy";
const char* password = "redacted";

void setup() {
  Serial.begin(115200);
  WiFi.begin(ssid, password);

  while (WiFi.status() != WL_CONNECTED) {
    delay(1000);
    Serial.println("Connecting to WiFi...");
  }

  Serial.println("Connected to WiFi");
  Serial.print("IP address: ");
  Serial.println(WiFi.localIP());
}

void loop() {
  // Add your code here
}

but i get this error :
Connecting......................................____
_
A fatal esptool.py error occurred: Failed to connect to ESP8266: Timed out waiting for packet header.

can anyone help? thank you

put the SerialPassthrough sketch with 115200 baud into the ATmega to bridge the USB to Serial1

i tried this but i get unreadable response in the serial everytime i connect the module

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.