Home » Community » Newbie corner » running program at different speeds
Re: running program at different speeds [message #37016 is a reply to message #37015] |
Thu, 09 August 2012 07:13   |
|
There are two factors in this: One is that when you call sleep function, the kernel switches context and lets another process to run. That might make the sleep longer, as mentioned in my previous post. The second factor you have to take in account is the precision of the mechanism you use to measure the time elapsed. If you search the forum, you will find couple threads about precise time measurements and what to be aware of.
Is there any particular reason why you need every interval to be *exactly* the same?
Honza
|
|
|
Goto Forum:
Current Time: Sat Jun 07 22:52:19 CEST 2025
Total time taken to generate the page: 0.04037 seconds
|