Advice on deriving accurate time values from the kernel?

1999-07-15 Thread Jennifer Clark
Hi, I am in the process of developing a device driver for the purpose of stepper motor control. The timing of each pulse is determined by external timing hardware on an I/O board, which will fire an interrupt after the time requested. Using this method, I am able to generate streams of pulses at

Re: Advice on deriving accurate time values from the kernel?

1999-07-15 Thread Matthew Dillon
:Hi, : :I am in the process of developing a device driver for the purpose of :stepper motor control. The timing of each pulse is determined by :external timing hardware on an I/O board, which will fire an interrupt :after the time requested. Using this method, I am able to generate :streams of

Re: Advice on deriving accurate time values from the kernel?

1999-07-15 Thread Louis A. Mamakos
I've done some work on measuring things like interrupt response times and the interval between two interesting events or steps in processing. A cheap way to do this is to use the TSC register in the CPU, though you then need to calibrate the frequency that the CPU really runs at. If you're

Re: Advice on deriving accurate time values from the kernel?

1999-07-15 Thread Matthew Dillon
:Hi, : :I am in the process of developing a device driver for the purpose of :stepper motor control. The timing of each pulse is determined by :external timing hardware on an I/O board, which will fire an interrupt :after the time requested. Using this method, I am able to generate :streams of

Re: Advice on deriving accurate time values from the kernel?

1999-07-15 Thread John Hay
If you only want to timestamp events and not generate the event, you can use microtime() or nanotime(). On a 400MHz PII non-SMP you should get 2.5 ns resolution with nanotime(). On a normal kernel with kern.timecounter.method at the default of 0, the get... versions give you time at the last tick

Re: Advice on deriving accurate time values from the kernel?

1999-07-15 Thread Louis A. Mamakos
I've done some work on measuring things like interrupt response times and the interval between two interesting events or steps in processing. A cheap way to do this is to use the TSC register in the CPU, though you then need to calibrate the frequency that the CPU really runs at. If you're