Page 1 of 1

Simple UDP Example

Posted: Mon May 07, 2018 4:09 pm
by TheSub6
Hi,

I have been looking for a simple example using ESP32 to receive UDP packets, but couldnt find any good commented examples. From my understanding the underlying library is lwip, can anyone maybe clarify how to close the gap for using lwip with ESP32?

Maybe someone is willing to help out with a little example. Hopefully others can profit too. ;)

Thanks in regards.

PS: I tried working through the "udp_multicast_example_main.c" example, but it is not very good documented from my point of view and also produces errors.

The most bugging from my POV.
Compiler Warning:
main.c:380:16: error: implicit declaration of function 'create_multicast_ipv6_socket' [-Werror=implicit-function-declaration]
sock = create_multicast_ipv6_socket();

Eclipse Warning:
TCPIP_ADAPTER_IF_STA --- could not be resolved

Re: Simple UDP Example

Posted: Mon May 07, 2018 5:33 pm
by fly135
Just use the Posix socket API and there are tons of examples.

John A