usleep() for windows kernel
Hail guys
Is there a function like usleep(); for windows. usleep(); handles over the control to the kernel for x ms.
If you don''t understand what I mean look here
http://www.fsmlabs.com/developers/docs/html/susv2/xsh/usleep.html
quote:Original post by Leadorn
Is there a function like usleep(); for windows. usleep(); handles over the control to the kernel for x ms.
The usleep function is for microseconds (μs), not milliseconds (ms).
quote:Original post by Leadorn
You must have much time to spend writing shit on this forum!!
I was doing that to helf inform JonStelly more than I was trying to correct you. He gave you a valid answer based upon what you''d written. You''re very considerate.
By the spec, usleep and sleep are functionally equivalent. usleep doesn't set any hard timing requirements other than "later", which is exactly how Sleep behaves
Sleep(0) or Sleep(1) ought to do it
{timeBeginPeriod(1);Sleep(1);timeEndPeriod(1);}
Oh hey, you might be able to emulate a microsecond sleep using a waitable timer (iffy though).
[edited by - Magmai Kai Holmlor on June 6, 2002 1:23:08 AM]
Sleep(0) or Sleep(1) ought to do it
{timeBeginPeriod(1);Sleep(1);timeEndPeriod(1);}
Oh hey, you might be able to emulate a microsecond sleep using a waitable timer (iffy though).
[edited by - Magmai Kai Holmlor on June 6, 2002 1:23:08 AM]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement