Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 8037

General • Re: Need advice on sending image data from a Pi5 to several Picos

$
0
0
The bottom line is adding MQTT into the mix doesn't gain anything. Is additional effort for no return.
I indicated in my message why I thought MQTT would make things easier and add value. I don't agree that your proposed solution (manually parsing the ethernet frames, bypassing the IP stack, as I understand it) would cost less effort or be more reliable than setting up and using MQTT, which is a job that should take ten minutes to half an hour.
That's a lot more effort than doing nothing at all. I am not suggesting bypassing the LwIP network stack here, just using the standard -

Code:

udp = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)udp.bind(("0.0.0.0", UDP_PORT))while True:  payload, client = udp.recvfrom(UDP_SIZE)  Handle(payload)
And letting the network stack filter out everything not sent to the port we are listening on.

Why use MQTT to filter what should be seen when the network stack itself can do that with far less overhead ?

But, OP will have to decide for themselves. :)
True, but I can't see them being any more convinced that using MQTT offers any benefit over not having it for what they are wanting to do than I am.

What I am suggesting works, is proven to work - except there seems to be issues with larger packets where LwIP or the CYW43 driver on the Pico W doesn't work how it would be expected to work. Keep below 1,600 bytes per packets and it's fine. Get whatever those bugs are fixed and it will work as expected.

I don't see any benefit MQTT would bring to the table but I guess we'll have to agree to disagree.

Statistics: Posted by hippy — Mon Jul 22, 2024 4:00 pm



Viewing all articles
Browse latest Browse all 8037

Trending Articles