Timers and ExSetTimerResolution
-
From the information that I have gathered it appears that XP has a limit in the resolution of timers (10-15 ms). So even though each timer can take a resoltion of 1 ms this cannot be achived in practice due to the OS limitation. I believe that ExSetTimerResolution can be used to change this. Has anyone tried to achive this in .NET? How did you do it? Did it improve timer resolution? Thanks, Liam
-
From the information that I have gathered it appears that XP has a limit in the resolution of timers (10-15 ms). So even though each timer can take a resoltion of 1 ms this cannot be achived in practice due to the OS limitation. I believe that ExSetTimerResolution can be used to change this. Has anyone tried to achive this in .NET? How did you do it? Did it improve timer resolution? Thanks, Liam
You can't improve the resolution of the timers beyond 10-15ms. It's just plain impossible. If you want sub-10ms resolution, you have to use the high performance counter built into the NT kernel, using QueryPerformanceCounter API function. There are examples of this in the CP articles, like this[^] one. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome