Hi Aparna, You have to be careful when mixing raw and sequential APIs: raw API functions really only may be called from the main tcpip_thread. Also, registering the callbacks (or initializing a UDP pcb in your case) must be done in that context (e.g. at startup time in tcpip_init_callback or at runtime using tcpip_callback). I explicitly say this because many users have mixed up the APIs in the past, and you really get confusing results that way!
Instead of using the raw API for UDP, you could just adjust the size of the mboxes... Simon ________________________________ Hi Simon, I think this is what is happening. Now we have developed a work-around by using the raw-APIs for UDP instead of the socket-APIs, and it seems to be working fine. Thanks, Aparna ________________________________ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Simon Goldschmidt Sent: Saturday, December 01, 2007 6:40 PM To: Mailing list for lwIP users Subject: Re: [lwip-users] UDP sendto() blocking I really don't know the VSDP++ port of lwIP or which version of lwIP they are using, but it sounds like a threading issue: your application thread talks to the lwIP core using mailboxes. If one of that mailboxes is full (which it never should), your application thread might be waiting forever (lockup). You could try to increase the size of the mailboxes (might be created in sys_arch.c of the VDSP++ port)... Simon Am 01.12.2007 um 07:44 schrieb aparna.dutta: We are using Lwip ported onto the Analog Devices VDSP++ 4.5 (Blackfin family , Feb 2007 update) to implement an RTSP/RTP streaming server. To send RTP packets using UDP, we are creating a socket of type SOCK_DGRAM, and then using sendto() to transmit the RTP packets. After sending some packets, the sendto() function blocks, and the RTP thread hangs pending for a semaphore. We tried to change the socket to non-blocking mode, but it does not seem to have any effect. Unlike a TCP connection, UDP does not have flow/congestion control and does not need to wait for ACKs from the receiver. Then what does the UDP sendto() function wait for? Thanks and regards, Aparna _______________________________________________ lwip-users mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/lwip-users _______________________________________________ lwip-users mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/lwip-users
