> -----Original Message----- > From: piclist-bounces@mit.edu On Behalf Of Dennis Crawley > Sent: Wednesday, August 16, 2006 4:41 PM > > Ruben J=F6nsson wrote: > > > >I have used the multimedia timer to get better resolution > >than 55 ms. My case was transmitting on a half duplex RS485 > >line and I did the turnaround with the DTR signal. > >Calculating the time it would take to transmitt and set the > >multimedia timer to this time, when fired switched to > >receiving with the DTR. > > Ok! I remember the use of APIs, for example this: > Public Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long) > Sleep (1) > This will work on XP as well. IIRC, the Sleep API call uses the same low resolution timers as the standard VB timer comtrol. I think you need to use other API calls to get the multimedia timers. I have had good success using the CCRP High Performance Timer Object available at: http://ccrp.mvps.org/index.html?controls/ccrptimer6.htm Hope this helps, Paul -- = http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist