[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Proterm and the //E
- Subject: Re: Proterm and the //E
- From: dempson@atlantis.actrix.gen.nz (David Empson)
- Date: 1996/07/02
- Newsgroups: comp.sys.apple2
- Organization: Actrix - Internet Services
- References: <swjackso-2606962103050001@ad11-115.compuserve.com> <4qvndj$38f@news.vanderbilt.edu> <4r2fm4$gr1@pith.uoregon.edu> <4r49mf$l3j@news.vanderbilt.edu>
In article <4r49mf$l3j@news.vanderbilt.edu>,
John Lesher <lesherjt@vuse.vanderbilt.edu> wrote:
>
> I thought of another possible trick, while puzzling over this in my spare
> time. I remember some old programs which would "mirror" the text screen
> to the graphic screen. All I'd have to do is check a certain bit on the
> hires screen, and I'd be able to tell between pre-Mousetext and Mousetext
> ROMs. I'd also be able to tell between the old Mousetext ROMs (running
> man) and the new ROMs (inverse CR & horizontal lines).
>
> Can anyone tell me if this is possible, or did the "mirror" trick not
> really use the ROMs?
As I said in another message on this thread, it is not possible to
read the IIe video ROM in software, so this trick would have worked by
having a copy of the character set on disk.
> I thought of another to detect the difference between the two processors.
>
> lda #$ff
> inc ;to accumulator ($1A or $3A opcode)
> cmp #$00
> beq _65C02_Present
>
> Instead of trying to use an error in the 6502, I just use an opcode
> not available to the 6502, which would be ignored on the 6502.
This is not a good idea. On the 65C02, unimplemented opcodes are
guaranteed to be "no operation". On the 6502, some unimplemented
opcodes are "no operation", but most of them have peculiar side
effects, including hanging the processor in some cases.
The "decimal mode add" trick is the safest method of detecting a 6502,
because the 6502 doesn't implement the negative flag for a decimal mode
add, whereas the 65C02 and later processors do.
For detecting processors newer than the 65C02, you first eliminate the
6502 (using the decimal mode add trick) then use 65802/65816
instructions to identify whether you have one of them installed.
These opcodes are NOPs as far as the 65C02 is concerned (as long as
you only use instructions which are not implemented on the Rockwell
version as well as the standard version).
--
David Empson
dempson@actrix.gen.nz
Snail mail: P.O. Box 27-103, Wellington, New Zealand