|
From: | Bill Florac |
Subject: | [lwip-devel] Multicast Addressing |
Date: | Thu, 12 Jul 2007 11:11:31 -0500 |
I'm having a problem with sending a UDP message using the same multicast address/port for receiving and sending.
I set up the connection as:
udp_bind(slp_pcb, &slpmcast, SLP_RESERVED_PORT); // sets up local_ip, local_port
udp_connect(slp_pcb, &slpmcast, SLP_RESERVED_PORT); // sets up remote_ip, remote_port
udp_recv(slp_pcb, slp_recv, 0);
However this does not work as expected.
When receiving, since this is a connected pcb, the function udp_input() check the remote_ip to the packet source and bails if they don't match.
When sending, the function udp_send() checks the local_ip to the interface->ip_addr and bails if they don't match.
I have easy fixes for both cases that I can provide but before I go into details, perhaps I'm just setting this up wrong? I can also work around it by not using udp_connet and sending packets with udp_sendto() but it seems the original should work.
Bill Florac
[Prev in Thread] | Current Thread | [Next in Thread] |