Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: Version 1.0 Netnews CMS/BITNET 5/19/85; site PSUVM.BITNET Path: utzoo!linus!philabs!cmcl2!seismo!rochester!cmu-cs-pt!cadre!psuvax1!psuvm!gmw From: GMW@psuvm.BITNET Newsgroups: net.micro.cbm Subject: Flaky TOD Alarm Interrupts Message-ID: <1755GMW@psuvm> Date: Mon, 20-May-85 00:09:37 EDT Article-I.D.: psuvm.1755GMW Posted: Mon May 20 00:09:37 1985 Date-Received: Tue, 21-May-85 04:21:31 EDT Lines: 24 I'm trying to get my 64 to provide tracking control for a telescope. One of the requirements is a sidereal time clock. I figured I could set the Time of Day clock alarm in CIA #1 to wake me up n seconds from now, add the appropriate constant to the current sidereal time (kept as a running sum), and reset the alarm for another n seconds so the process repeats ad. nauseum, where n depends on the time resolution I'll need (as yet to be determined). Having never worked with the TOD clock, I wrote a short assembler routine to test it out. This simply 1) sets the time to 0:00:00.0, 2) establishes a new IRQ vector, and 3) twiddles its thumbs forever. The new interrupt handler reads the current TOD, adds 1/2 sec. to it, and resets the alarm with that value. It works, but only for so long (anywhere from 5 minutes to 2 hours); then it seems to miss an IRQ and hangs. I have placed CHROUT's at strategic locations in the code to see where the trouble occurs, and all indications are that the TOD interrupt is occasionally being ignored. The clock keeps running, and the "thumb twiddling" main loop keeps twiddling, but the alarm isn't being heard. Anyone know if this is a(nother) hardware bug, or am I missing some critical piece of info that would make it work? George Weaver GMW at psuvm.bitnet ...!allegra!psuvax1!gmw@psuvm.bitnet