Wiznet has a board that adds ethernet capability to a Raspberry Pi Pico - the W5500-EVB-Pico. I'd like to use this to implement network connected instruments in my home lab.
There are plenty of examples on the documentation site, but the TCP examples all seem to use low-level socket programming. The latest Micropython implementations all have asyncio available so why not use the facilities available there?
For example Bytepawn's simple message queue server
Nope. Doesn't work. The problem seems to be that even though the Micropython documentation says that the asyncio.start_server function works in the same way as the standard library - it doesn't. After some digging on the net, I came up with the following.
This code uses start_server but then runs the resulting generator using an explicitly constructed asyncio event_loop. There is an advantage to this, though, in that this also allows us to start multiple tasks, o