Suspending a process with something finer than "sleep"

Suspending a process with something finer than "sleep"

Post by john m skinn » Tue, 10 Aug 1993 23:07:22



On a Unix system, I would like to suspend a process for times specified
in tenths of a second. Is this possible with reasonable accuracy?


 
 
 

Suspending a process with something finer than "sleep"

Post by Dan Po » Wed, 11 Aug 1993 04:06:25



Quote:>On a Unix system, I would like to suspend a process for times specified
>in tenths of a second. Is this possible with reasonable accuracy?

Yes, it is possible, but it depends on what you mean by "reasonable accuracy",
Unix not being a real time OS.

Try usleep() or nap(). If neither can be found on your system, read the man
page for setitimer() or select() to find out how to implement yourself one
if you have elementary notions about Unix system programming.

Dan
--
Dan Pop
Tel:   +41.22.767.2335

Mail:  CERN - PPE, Bat. 21 1-023, CH-1211 Geneve 23, Switzerland