This wiki has been migrated to https://gitlab.com/wireshark/wireshark/-/wikis/home and is now deprecated. Please use that site instead.
Differences between revisions 219 and 220
Revision 219 as of 2015-03-14 15:16:35
Size: 2687
Comment:
Revision 220 as of 2015-03-14 17:21:12
Size: 2475
Comment: More testing; plane link to WikiSandbox(here) didn't seem to work. It seems it'! not a bug, it's a feature!
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
Here is what I am practicing:
on ProtocolReferencePage;https://wiki.wireshark.org/ProtocolReference the link to I2C;http://www.nxp.com/news/backgrounders/bg_esc9884/index.html has broken, so a quick search leads to I2CManual;http://www.nxp.com/documents/application_note/AN10216.pdf . I don't see the point of writing anything, although I do use the protocol.
Done with main edit, want to do links within ProtocolReferencePage, so I'll link to the end of [[https://wiki.wireshark.org/WikiSandBox|WikiSandBox]]

Done with main edit, want to do links within ProtocolReferencePage, so I'll link to the end of WikiSandBox

Seems editing this page is not peeing in the pool, so I try to ask here because I did't find the right place to ask questions:

Is there a repository/collection/library of Lua scripts beyond Lua/Examples to learn from ? Specifically, it seems os.clock() has only timer tick resolution (15 ms on windows and 10 ms on linux), but I need sub-millisecond precision.

Background: I'm willing to write a Lua script to accumulate the timestamps of tens of thousands of sniffed packets and to account wall clock time to my client application once a packet is received on the client pc and to account wall clock time to the network or the other end of the socket (the server) once a packet is sent and do it vice versa on the server pc to get an exact measure of client, network and server times for a performance analysis, but don't know where to start from.

Perhaps someone can point me to the right place to search or to the right method to use ? Thanks, Juergen.

It's not peeing in the pool, but it's also not the best place to ask, as not everybody will see it, and, if somebody sees it and replies, you won't necessarily get notified of it.

You could ask that question on, for example, http://ask.wireshark.org/ or on the wireshark-dev mailing list, but as it's really a Lua question, it might be better to ask on the lua-l mailing list or on http://stackoverflow.com (I don't know of any Lua-specific Q&A site).

However, the Lua 5.1 manual item on os.clock() seems to indicate that it's not what you want - it says it "returns an approximation of the amount in seconds of CPU time used by the program", but it sounds as if you want real time, not CPU time. I don't know whether os.time() returns a value with a fractional part, or what the resolution is, but, if the OS call atop which os.time() is implemented - probably gettimeofday() or something such as that on most if not all UN*Xes - returns a higher-precision time value, that might give you what you want.

This is just a simple text edit, as practice. Thanks.

WikiSandBox (last edited 2020-08-14 16:23:22 by 2601:200:c001:d44:81f6:197c:58b:2580)