-->
Page 2 of 4

Re: Sending and Receiving tcp/ip packets from ESP8266 "direc

PostPosted: Tue Jun 08, 2021 12:33 am
by JurajA

Re: Sending and Receiving tcp/ip packets from ESP8266 "direc

PostPosted: Fri Jun 11, 2021 1:31 pm
by pconst167
What I am looking for is a way for me to know from my CPU end, who the packets came from and all information about the packets. I want to be able to receive the packets and parse them myself. I want to write a TCP/IP Stack and parse the packets myself. Or something similar.

Is this possible with ESP8266 ?

Re: Sending and Receiving tcp/ip packets from ESP8266 "direc

PostPosted: Fri Jun 11, 2021 2:13 pm
by pconst167
JurajA wrote:https://arduino.stackexchange.com/questions/66898/how-to-acheive-fast-and-reliable-communication-between-nodemcus/66899#66899


Nope....... :/

I can already do this.

When I receive data on the ESP, all I receive is the actual data string. How is my CPU going to know who sent me that data? What IP did it come from? The ESP may know that deep down, but my CPU doesn't.

I need to receive that information. And I need to be able to tell the ESP to open and close connections such as telnet.

I need to be able to type a command such as "telnet x.x.x.x port" and have the ESP connect and open the socket.

The question is: can the ESP8266 do this without me having to write some kind of command interpreter for it?

Re: Sending and Receiving tcp/ip packets from ESP8266 "direc

PostPosted: Sat Jun 12, 2021 3:59 am
by eriksl
The absolutely best way is to write your own ESP8266 firmware using the SDK. Then you could transfer data from the ESP8266 to your CPU in any way you like (UART, SPI, I2C...) and include whatever metadata you need (remote host, port, etc.)