QNX. do some research on that OS. Long time ago I heard that it was a real time OS and that programming and running programs on it was VERY much more accurate than the standard INTEL. I don't really know what you want... if you wan precission then this might be your solution... if you dont... then try the bes aproximation possible and use it...
El jue, 12-06-2003 a las 03:38, Ray Olszewski escribió: > At 08:17 PM 6/11/2003 -0400, Mark Hahn wrote: > > > An i386 has a hardware timer that beats about 72 times per second, leaving > > > >well, it has several hardware counter/timers, but that setting > >is not special (and isn't it only used by DOS?) > > Actually, I wrote that from memory (of timer limitations I encountered when > programming in VB on Windows 2000), and I think I got the actual numbers wrong. > > > > me uncertain as to how accurate timings below 14 msec can be on this > > > hardware using the kernel's internal timer. > > > >timers can be set MUCH faster than that. > > In principle, yes. usleep() timers can be *set* to 1 usec. That's not the > question. The question is how *accurate* timers based on usleep() can be at > low settings. > > This experiment says they are not very accurate. I changed Lee's loop to be: > > for(i = 0; i < 500; i++) > { > usleep(10); > } > > Now 500 x 10 = 5000 usec, or 1/200 seconds. But the loop actually takes 10 > seconds to iterate. This implies that usleep() has a minimum delay of > 10/500 seconds, or 20 msec, built into it (at least on my test system). > > My best guess is that this limitation derives either from the timer code in > the Linux kernel or from the system hardware that code relies on. > > > > - > To unsubscribe from this list: send the line "unsubscribe linux-newbie" in > the body of a message to [EMAIL PROTECTED] > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.linux-learn.org/faqs -- Alan Bort Linux Registered User 298277 -Country Manager- [http://counter.li.org] [ http://www.linuxquestions.org ] Username: Ciccio [ http://es.tldp.org ] Ciccio.- - To unsubscribe from this list: send the line "unsubscribe linux-newbie" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.linux-learn.org/faqs