Communication between Arduino UNO and ESP8266 via TXS0108E

27 views Asked by At

I have an Arduino UNO board and an ESP8266 D1 Mini V2 micro USB (CH340 module based on NodeMcu Lua ESP-12), and I'm trying to set up communication between them using the TXS0108E logic level converter. But nothing works. Neither sees any transmitted information. I'm attaching the code and the connection method. Please help me solve the problem.

enter image description here

Arduino UNO:

    void setup() {
        Serial.begin(9600);
    }

    void loop() {
        Serial.println("Hi, ESP8266!");
        delay(2000);
    }

ESP8266:

    void setup() {
        Serial.begin(9600);
    }

    void loop() {
        if (Serial.available()) {
             String data = Serial.readString();
             Serial.print("Message: ");
             Serial.println(data);
        }
    }

I tried switching pins on the TXS0108E, tried connecting OE to VA with a wire and a 10K resistor, tried directly connecting Arduino RX - ESP8266 TX and Arduino TX - ESP8266 RX. Nothing happens.

enter image description here

enter image description here

enter image description here

enter image description here

enter image description here

Arduino UNO:

    #include <SoftwareSerial.h>

    SoftwareSerial mySerial(10, 11); // TX, RX

    void setup() {
        mySerial.begin(9600);
        Serial.begin(9600);
    }

    void loop() {
        if (mySerial.available()) {
            Serial.write(mySerial.read());
        }
        if (Serial.available()) {
            mySerial.write(Serial.read());
        }
    }

ESP8266:

    void setup() {
        Serial.begin(9600);
    }

    void loop() {
        if (Serial.available()) {
            String data = Serial.readString();
            Serial.println(data); 
        }
    }
0

There are 0 answers