[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [lwip-users] How do I check if a packet is sent out?

From: Bill Auerbach
Subject: RE: [lwip-users] How do I check if a packet is sent out?
Date: Tue, 19 Jan 2010 14:08:46 -0500

I would use udp_sendto since this does send immediately if lwIP has an ARP entry to know the MAC destination address and your Ethernet driver (low_level_output) sends immediately without some delay or wait for interrupt.  You might make your call, delay a few mS for it to process and then disable system interrupts.


How to prove this?  Start WireShark capturing on the PC (assuming the PC will get/see the UDP packet).  Step in the debugger over lwip_sendto stopping after this line.  Does WireShark contain the UDP packet(s)?  If you can’t stop in a debugger, simply test adding for(;;); after lwip_sendto.  If you don’t see anything, add a software delay after lwip_sendto.


From: address@hidden [mailto:address@hidden On Behalf Of Chen
Sent: Tuesday, January 19, 2010 11:14 AM
To: address@hidden
Subject: [lwip-users] How do I check if a packet is sent out?


Hi, all,

In my project, I need to send out an UDP packet then stop the system interrupts for a few ms, but I need to confirm the UDP packet is sent out first (I don't need to confirm if it will reach the destination)

I send out the UDP packet using

lwip_sendto(lSocketUDP, myudpout.buffer, sizeof(myudpout), 0, (struct sockaddr *)&sSyncDestAddrUDP, sizeof(sSyncDestAddrUDP));

How can I confirm *THIS* packet is sent out?

Can anyone be so kind to give me a pointer?



BTW, I also have an active TCP connection at the same time

reply via email to

[Prev in Thread] Current Thread [Next in Thread]