Re: Problems with fast timeouts

2003-01-13 Thread Krzysztof Dubowik
Hi, I wanted my timeout function to be called 200 times per second. Another words, my timeout function to be called every 5 miliseconds. why? what's the actual problem behind it? It's a simulator of a measuring device where the sampling rate is fixed at 200Hz. I want to draw the

Re: Problems with fast timeouts

2003-01-13 Thread Krzysztof Dubowik
Hi, Thanks for all your answers, you've been very helpful. I think I got the basic idea and I'll be able to carry on now. I do not know your background, Krisz, but this is pretty much a homework lesson done on realtime university courses. I wish my university did realtime programming

Re: Problems with fast timeouts

2003-01-08 Thread Krzysztof Dubowik
[ i am assuming that you are working on linux, which might be a big assumption. if not, then ignore all that i write here. ] you're using a multitasking, multiuser operating system with a scheduling granularity of 10ms. the kernel will to honor the 5ms request but will fail to

Problems with fast timeouts

2003-01-04 Thread Krzysztof Dubowik
Hi, I wanted my timeout function to be called 200 times per second. Another words, my timeout function to be called every 5 miliseconds. However, when I mesured the intervals with gettimeofday I found out that the timeout function was called ca every 20ms. My timeout function exectutes within