Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!apple!agate!e260-1d.berkeley.edu!c60b-1eq From: c60b-1eq@e260-1d.berkeley.edu (Noam Mendelson) Newsgroups: comp.sys.ibm.pc.misc Subject: Re: QUESTION ABOUT INTERRUPTS AND TIMERS Message-ID: <1991Apr6.055003.19402@agate.berkeley.edu> Date: 6 Apr 91 05:50:03 GMT References: Sender: usenet@agate.berkeley.edu (USENET Administrator) Distribution: comp.sys.ibm Organization: University of California, Berkeley Lines: 36 In article trux@atop.atop.cs.caltech.edu (Flem Snopes) writes: >Can anyone out there in netland help me? >I am using a 12Mhz IBM AT clone. >Here is my obstacle: > I wish to program an interrupt associated with a timer that calls the > interrupt 8000 times per second. >Here is what I have done already: > I have used interrupt 1CH and changed the 8253 timer from the standard > 18.2 hz to 8Khz but this has an adverse side affect, it calls interrupt > 08H 8000 times per second which make my system crawl. I dont know what > interrupt 08H does, but if you disable it, the system locks. Also, if > I hook 08H instead of 1CH, I could theoretically call the original 08H > at 18.2 hz, but the system locks all the same. So it appears that 08H > MUST be called every timer pulse. >Here are my questions: > why must 08H be called every timer pulse? what does 08H do that takes > so long. Can I use another timer? INT 08H does the following things: 1) Increment a running count of clock ticks at 0040:006C 2) Decrements the byte at 0040:0040, which controls the timing of the diskette motor 3) Calls interrupt 1CH INT 08H is not very CPU-intensive but at 8,000 calls/sec, it's likely to slow your system down considerably. Another point: if you change the rate of the timer you _must_ create a new INT 08H which calls the original INT 08H at the standard interval. Your system should not lock when you do this. I am surprised that your system did not lock when you changed the rate without modifying INT 08H. Perhaps you are not doing this correctly. +==========================================================================+ | Noam Mendelson ..!agate!ucbvax!web!c60b-1eq | "I haven't lost my mind, | | c60b-1eq@web.Berkeley.EDU | it's backed up on tape | | University of California at Berkeley | somewhere." |