🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: rec.games.programmer
Article #447

Re: Vertical Retrace interrupt?

#447
From: Phat H Tran
Date: Thu, 06 Aug 1992 07:36
35 lines
2378 bytes
In article <1992Aug6.154949.164290@dstos3.dsto.gov.au> egg@dstos3.dsto.gov.au writes:
>
>>No Josh, your wrong.  Some VGA board create a vertical retrace interrupt
>>whenever they enter the retrace period.  A program would merely have to
>>trap the interrupt to know when the retrace period is happening.  The
>>program could carry on doing its own thing until it gets the interrupt,
>>then it can update the screen.  No polling required.
>>I don't think the timer interrupt trick would work, even though the
>>interrupt could be generated 60Hz (or 70Hz), it still would not inform
>>the program that it is a safe time to write to the VGA.
>>
>>I have tried the retrace interrupt a little, without any real success,
>>an I would also like to know how to enable the retrace interrupt, and
>>how to signal to the VGA that the interrupt had been recieved.
>
>I beleive its not a good idea to use the vertical retrace interrupt because
> according to "Programmers Guide to PC and PS2 video systems" hardware
>interrupts on IRQ2 cannot be distinguished from Vertical interrupts. I'm not
>that cluey on the subject but if its in the book ??? Apparently bus versoins
>of the Microsoft mouse cause this problem, and possibly other hardware that
>use IRQ2. If you are still keen on using it, The book shows you how.
>
>Themie

I used to do quite a bit of low-level programming on the C64 and I remember
back then, we had only one IRQ line.  But we used this one interrupt
to do everything from I/O timing to raster synchronization.  Having only
one IRQ line meant that we had to daisy chain all our service routines,
and each would have to check various registers to see if the IRQ was
indeed for it.  If not, it would pass control down to the next interrupt
handler in the line, and so on.  So, I'm wondering (as I haven't been
programming IBM clones for very long) whether the same can't be done for
MS-DOS machines.  It should be a trivial task.

Phat.
Technical Details
Message-ID: <BsJx5H.FKy@watserv1.uwaterloo.ca>
Path: arc1-ca.pugleaf.net!sparky!uunet!usc!cs.utexas.edu!torn!watserv2.uwaterloo.ca!watserv1!ptran
References: <1992Aug6.154949.164290@dstos3.dsto.gov.au>

Show Full Headers
Complete Article Headers
Newsgroups: rec.games.programmer
Path: arc1-ca.pugleaf.net!sparky!uunet!usc!cs.utexas.edu!torn!watserv2.uwaterloo.ca!watserv1!ptran
From: ptran@watserv1.uwaterloo.ca (Phat H Tran)
Subject: Re: Vertical Retrace interrupt?
Message-ID: <BsJx5H.FKy@watserv1.uwaterloo.ca>
Organization: University of Waterloo
References: <1992Aug6.154949.164290@dstos3.dsto.gov.au>
Date: Thu, 6 Aug 1992 07:36:52 GMT
Lines: 36