Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!att!tut.cis.ohio-state.edu!uoft02.utoledo.edu!grx0644 From: grx0644@uoft02.utoledo.edu Newsgroups: comp.sys.cbm Subject: Re: More accurate timer? Message-ID: <1990Dec19.231720.2500@uoft02.utoledo.edu> Date: 20 Dec 90 04:17:19 GMT References: <16200014@col.hp.com> Lines: 27 In article <16200014@col.hp.com>, warren@col.hp.com (Warren Tustin) writes: > > Is there a way to do timing on the C128 that is more accurate than the > jiffy clock? I assume it is possible, but has someone done it and could > send or post the routine? I just need to be able to start a timer and then > look at the difference later. Thanks for any info. Warren, The C128 has a hardware clock called THE TIME OF DAY clock. It is extreemly accurate because it is driven by the interupts.......all you need to do is to give it the starting value and it'll keep the time even during I/O procedures. All you need to do is to read in the values and do a few simple conversions and you'll have your time. I wrote a routine, in ml, that will create a 'corner clock' using the TOD clock. I can send it out to anyone who can receive files over the net..... If you want the files, just email me directly. Since Iam not at home (currently in another city accessing my account via the net) I do not remember the locations of the registers of the TOD clock. Accessing them is not straight forward and my programs are documented well enough to explain the workings of the clock. I hope this helps and I have not confused anyone (as it is very late and I am sleepy). :) Tony