[fpc-pascal]High resolution timers on linux ?

Matti Hamalainen mhamalai at ratol.fi
Tue Aug 28 07:07:28 CEST 2001


On Mon, 27 Aug 2001, Kenneth Due wrote:

> Hello list
> 
> I need some way to determine when 1/10000 sec has passed
> 
> I suppose it can be done with the timerchip in the PC - but how ?
> 
> anyone ......
> 

man usleep

usleep(X) suspends the execution of calling process for X microseconds
(10^-6 sec). The accuracy may not be (== is not) 100% due to the
multitasking nature of UNIX-type operating systems.

There are also setitimer() and getitimer()-functions that can be used
to get a callback-type timed action.


=- ccr/TNSP^pWp
] ccr at tnsp.org | http://www.tnsp.org/
] Show me your "realtime raytracer in Java"
] and I'll show you my CBM 8032, 2 MHz!





More information about the fpc-pascal mailing list