[Winpcap-users] Getting timestamp while waiting for packets

Merello Andrea andrea.merello at iit.it
Tue Dec 16 08:55:28 GMT 2008


Thank you for your reply!

So I realize that quite a lot of times I call pcap_next_ex I get nothing. No pakets, and also no timestamp.
This arise a new question: Is there any way to block the caller until a new packet arrives?

I am now in nonblocking mode, because it's critical for me to get a packet immediately when it arrives, avoiding to wait for other packets and for the timeout, but in this way the reader thread wastes system CPU..

What I'm trying to do is to create graphs in real time from information acquired at the same time from a serial bus, a CAN bus, and an ethernet card.. Just to give an idea of because we would like this behavior from winpcap :-)

Thanks
Andrea


-----Original Message-----
From: winpcap-users-bounces at winpcap.org on behalf of Merello Andrea
Sent: Fri 12/12/2008 9:20 AM
To: winpcap-users at winpcap.org
Subject: [Winpcap-users] Getting timestamp while waiting for packets
 

Hi,
We are developing an application (win32) that needs getting raw packets from ethernet NICs, and we thought immediately to winpcap, however reading the API documentation I couldn't solve a couple of doubt about winpcap...

We would like to have an accurate timestamp on each received packet, and we see winpcap tag effectively each packet with the timestamp, but we need also to know the value of the timestamp clock even when no packet is arriving (to keep in sync, and detect drift and latency, with other sources of packets on different medias, like CAN-BUS).

Is there any way to do this? 

Also how the timestamping is done? Is it simply a software tagging from the system clock?


Thank you
Andrea

_______________________________________________
Winpcap-users mailing list
Winpcap-users at winpcap.org
https://www.winpcap.org/mailman/listinfo/winpcap-users

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/ms-tnef
Size: 3752 bytes
Desc: not available
Url : http://www.winpcap.org/pipermail/winpcap-users/attachments/20081216/8511afe1/attachment.bin


More information about the Winpcap-users mailing list