UDP only working one way

  • Hello,

    My Windows PC, Ubuntu VM, and Raspberry Pi are all on a LAN, and I have built the Qt UDP client and server examples on all three. It works when the VM or Pi are sending, but not when my Windows PC is sending. I havent changed any code, the ports are all the same as the default example's. Does anyone know why this might happen? Thank you.

  • Qt Champions 2018

    Firewall on your Windows PC?

  • I dont think that is it. I have tried disabling it all together and I get the same results. On top of that, even when it is ok, the outbound connection setting is set to Allowed (default).

  • @Hyprodimus-Prime

    Just to clarify:

    On what platform is the server running?
    Are all incomming connections allowed on each device?

  • @the_

    Server is Windows, Virtual machine is Ubuntu, Raspberry Pi is running Raspbian.
    Only the Windows machine has a firewall, and communication doesnt work even when it is off.

    Pi->Windows : OK
    Pi->Ubuntu: OK
    Pi->Pi local: OK
    Ubuntu->Windows: OK
    Ubuntu->Pi: OK
    Ubuntu->Ubuntu local: OK
    Windows->Windows local: OK
    Windows->Ubuntu: Not OK
    Windows->Pi: Not OK

  • Solved:
    I was using QHostAddress::Broadcast which is
    I needed to have the local IP subnet 192.168.137 and then .255 for multicast.

    I am assuming that it is not a windows thing, it is just an feature of being the LAN host?

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.