[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Information on the //e VBL
- Subject: Information on the //e VBL
- From: "Ole Voss" <ole.voss@netrogue.de>
- Date: Tue, 18 Mar 2003 22:37:40 +0100
- Newsgroups: comp.sys.apple2
- Xref: archiver1.google.com comp.sys.apple2:28817
I just thought this subject should get a thread on its own, seeing that the
Contiki thread is getting difficult to read ;-)
Well, back in the old days I used the VBL quite extensively to get my
scrolling routines smooth. This did, ofcourse, make them extremely slow -
but they were elegant all the same. The programming is quite easy:
$C019 holds the VBL bit (bit 7) When this is low (<128) the Vertical Blank
is active (beam blacker than black returning to home position top-left). As
soon as the VBL goes high, the screen is being drawn. The problem with using
this as a technique for timing is obvious. First, you never know where the
actual VBL is taking place. That is, it could be anywhere within its blank
period (I don't recall how long that is - but maybe somebody would like to
look that up) or anywhere within its normal 'drawing' period. Back then I
used to poll the VBL and wait for a definite change between high and low.
Only after the change had occurred, would I actually change screen data.
Ofcourse this meant that I would often skip an entire cycle.
Will this help anybody?
Cheers,
Ole.