AnsweredAssumed Answered

send and receive data via TCP connection using Lwip

Question asked by Gonzalo Sanchez on May 14, 2019
Latest reply on May 16, 2019 by jeremyzhou

I'm new on using LWIP and I'm taking my first steps into it. I'm using a self-designed board based on LPC1788 microcontroller and I've been able to run both the lwip_tcpecho and the lwip_web projects successfully so far (I'm using raw API without RTOS).
Now, I would like to send and receive data via a TCP connection but I'm a bit lost where and how to start doing this. I was thinking, as my first step, that I might modify the lwip_tcpecho example in order to show via the DEBUGOUT UART the received data and to send via the TCP connection the data read from DEBUGIN. (Something like a simple RS-232 to TCP converter).

Has anyone done something like this? If so, could you share some piece of code that helps me?

Am I taking the right path? I'm not using RTOS since in the future I have to add this to my existing code which doesn't run RTOS.


what function should I call to get the data received into my app buffer and what function should I call to send data from my app buffer?