NodeMCU reading with RX TX from a router

Hello, so I have a NodeMCU and I would like to read TTL serial from a router. The router has 4 pins - RX, TX, GND, 3.3V, I am able to read output from router with TTL->UART adapter, but cant figure out how to read it with NodeMCU.

This is how I have it connected:

This is the sketch im using:

// WiFi includes
 #include <ESP8266WiFi.h>

#include "SSD1306Wire.h"
#include "SoftwareSerial.h"


SSD1306Wire  display(0x3c, D2, D1);
SoftwareSerial s(3,1);



void setup() {
  s.begin(9600);
   Serial.begin(115200);
  while (!Serial) {
    ; // wait for serial port to connect. Needed for native USB port only
  }
  
  display.init();
  display.setContrast(255);

         display.clear();
      display.drawString(1, display.getHeight()/2, "Waiting");
      display.display();
}

void loop() {
  if (s.available()) {
      auto data = s.readString(); //Read the serial data and store it
      delay(10);

      display.clear();
      display.drawString(1, display.getHeight()/2, data);
      display.display();
  }

  if (Serial.available()) {
      auto data = Serial.readString(); //Read the serial data and store it
      delay(10);

      display.clear();
      display.drawString(1, display.getHeight()/2, data);
      display.display();
  }
}

"I am able to read output from router with TTL->UART adapter, but cant figure out how to read it with NodeMCU."

Is the router tx/rx also TTL? What is the resting voltage on the router tx/rx lines? How are you reading the router output using the UART adapter. Being able to get something is a good start.

zoomkat:
“I am able to read output from router with TTL->UART adapter, but cant figure out how to read it with NodeMCU.”

Is the router tx/rx also TTL? What is the resting voltage on the router tx/rx lines? How are you reading the router output using the UART adapter. Being able to get something is a good start.

“Is the router tx/rx also TTL?” Well im not sure how I can test this, there are 4 pins with labels RX TX GND 3.3V

“What is the resting voltage on the router tx/rx lines?”
RX → GND = 0V
TX → GND = 0V
RX → 3.3 = 2.85V
TX → 3.3 = 0.48V

Well, im connecting router like this yt link with a device like this CH340G USB to TTL

I plug the adapter in PC and im using GtkTerm in ubuntu to read the data and it works.

"RX --> GND = 0V
TX --> GND = 0V
RX --> 3.3 = 2.85V
TX --> 3.3 = 0.48V"

That seems to indicate that the router may be using RS232 line voltages instead of TTL line voltages. You may need a voltage inverter setup for the the two devices to communicate. Resting TTL line voltages are typically a positive voltage value relative to ground.