[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Proterm and the //E
- Subject: Re: Proterm and the //E
- From: nparker@cie-2.uoregon.edu (Neil Parker)
- Date: 1996/06/29
- Newsgroups: comp.sys.apple2
- Organization: University of Oregon Campus Information Exchange
- References: <swjackso-2606962103050001@ad11-115.compuserve.com> <4qsv8f$a73@nyx10.cs.du.edu> <4qvndj$38f@news.vanderbilt.edu>
In article <4qvndj$38f@news.vanderbilt.edu> lesherjt@vuse.vanderbilt.edu (John
Lesher) writes:
>[...]
>Would anyone happen to know, then, how to tell an enhanced //e from
>a mere //e with a 65c02, from software?
The enhanced ROM is easy to detect. The (almost) full ROM ID test goes
like this:
Look at location $FBB3.
If the value is $38, it's an original Apple II ROM.
If the value is $EA, it's an Apple II+ ROM (or a III in emulation mode).
If the value is $06, it's a IIe, IIc, or IIGS ROM, in which case...
Look at location $FBC0.
If the value is $EA, it's an unenhanced IIe ROM.
If the value is $E0, it's an enhanced IIe ROM, or a IIGS.
If the value is $00, it's a IIc ROM, in which case...
Look at location $FBBF.
For the first four IIc revisions, the values are $FF, $00,
$03, and $04 respectively. For the IIc+, the value is $05.
(Actually, that's not really the full test...the full test would include
distinguishing between a II+ and a III in emulation mode, and between an
enhanced IIe, an IIGS, and an Apple IIe card in a Mac.)
As far as I know, the Mousetext character generator can't be detected by
software. But it's generally safe to assume that if the machine is an
enhanced IIe, a IIc, or a IIGS, then Mousetext is available. (It is
possible to install a pre-Mousetext character generator in an enhanced IIe,
or a Mousetext character generator in an unenhanced IIe, but not many
people do so.)
In other words,
IF PEEK (64435) = 6 AND PEEK (64448) < > 234 THEN PRINT "Mousetext
is probably available."
The above line is also sufficient to distinguish if the CPU is a 65C02 (or
better), since all ROMs that pass that test make use of 65C02 opcodes. If
you want to check whether or not an unenhanced machine has a 65C02, you can
use a machine-language routine that tries to test for one of the infamous
6502 bugs, like this:
18 CLC
F8 SED
A9 99 LDA #$99
69 01 ADC #1
D8 CLD
D0 xx BNE Not65C02
This takes advantage of the fact that on an original 6502, the sign flag
doesn't work right in decimal mode. This bug was fixed in the 65C02.
Thus the BNE always branches on a 6502, and never branches on a 65C02.
- Neil Parker
--
Neil Parker | No cute quote, no cute ASCII art, no cute
nparker@cie-2.uoregon.edu | disclaimer, no deposit, no return....
nparker@cie.uoregon.edu | (This space intentionally left blank:
http://cie-2.uoregon.edu/~nparker | )