Pico RP2040 event driven C example for TCP server

Hi Wiznet team,
I would like to implement an event driven TCP server for your Pico RP2040 board. I have your lwIP loopback example running but its necessary to poll for the connection and data, I am hoping you have an example of an event driver version like the one available for the Pico-W which also uses lwIP.
Thanks

Hello, @Colin_Bate
Thank you for your interest with pico ethernet.
if you look for interrupt handing drive, we currently do not have it.
There is interrupt pin from W5100S and it connected to rp2040. but to be implemented.
Is there reason why you want to use it with Pico-W?

Hi Lawrence, thanks for your reply, I use the Pico as I have purchased 3 x Pico RP2040 boards as I want to use a LAN connection, not Wifi for a few projects I have.
I have solved my initial problem with being interrupt driven, I used a modified example of the lwIP loopback.c, it still polls but this seems very efficient passing 60 Pkts/second.
I’m now struggling to get the time from a NTP server via UDP using lwIP. Any guidance would be much appreciated (i.e. are there equilivant functions for (udp_sendto… etc.)
BTW: is it possible to mix lwIP with standard WIZnet non lwIP code in the same application?
many thanks \Colin

I have been able to successfully implement setting the RTC via a NTP server using:
retVal = udp_sendto(state->ntp_pcb, p, (const ip_addr_t *)&state->ntp_serverIp, NTP_SERVER_PORT);
…and a callback via
udp_recv(state->ntp_pcb, ntp_udp_recv_cb, state);

Thanks

1 Like