[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Apple emulators that support "floating bus" video sensing?
- Subject: Re: Apple emulators that support "floating bus" video sensing?
- From: mdj <mdj.mdj@gmail.com>
- Date: Wed, 19 Mar 2008 03:17:29 -0700 (PDT)
- Complaints-to: groups-abuse@google.com
- Injection-info: d62g2000hsf.googlegroups.com; posting-host=203.214.107.122; posting-account=gKwMEAoAAACgdZoRArZlfcCSOA8KWMxg
- Newsgroups: comp.sys.apple2
- Organization: http://groups.google.com
- References: <YpWdnY2Kaauk8ELanZ2dnUVZ_rOqnZ2d@comcast.com>
- User-agent: G2/1.0
- Xref: g2news1.google.com comp.sys.apple2:33306
On Mar 18, 5:20 pm, "Michael J. Mahon" <mjma...@aol.com> wrote:
> The objective is not to do something sophisticated, like avoid tearing
> of the animation (though that would be nice), but simply to cause it to
> run at its intended speed, regardless of the speed of the processor
> (emulated or real).
>
> Polling VBL works on an Apple //e, but *only* on a //e, since later
> machines de-implemented VBL polling in favor of VBL interrupts.
Actually, this isn't strictly true. On a IIe, the $C019 softswitch
will read with the high order bit set during (and only during) the
vertical blanking interval. On a IIc, the same softswitch will read
with the high order bit set if a VBL interrupt has occurred since the
last time it was read.
For practical purposes, being either waiting for VBL to draw, or using
it as a real time event source, software that polls the softswitch
will behave identically on both machines, assuming you read the
softswitch at least every 1/60th of a second.
The catch is, $C019 is also used to indicate mouse button and movement
activity whilst the mouse firmware is active, so you cannot reliably
poll it on a IIc if your program is also using the mouse.
I'm not 100% sure since I don't have a IIc handy that I can test with,
but I also have an inkling that VBL interrupts must be active for this
to work on a IIc ($C05A disable, $C05B enable), and I'm relatively
sure they're disabled by default. Of course, you also have to ensure
(processor) interrupts are disabled or the firmware is going to handle
them for you...
I guess Apple decided that the relatively short amount of time the IIe
spent in the wild before the IIc appeared meant it was OK to change
the behaviour? Most software would have used the floating bus method
to remain II/II+ compatible so the impact on developers was minor.
And for the IIgs? I have no idea... Can someone shed some light?
I must admit I am *very* curious about what it is you're trying to
achieve that requires both the possibility of an accelerator being
operational *and* a real time clock source .... ;-)
Matt