From: David Empson on
Linards Ticmanis <ticmanis(a)gmx.de> wrote:

> David Empson wrote:
>
> > Yes, according to information in the data sheets (which I don't have
> > handy and can't verify).
>
> BTW the 65C02 data sheet is available from WDC as I just found out:

I thought as much. I couldn't be bothered looking, and all my Apple II
books are packed away in the basement now (and unlikely to be accessed
again for a while).

> > http://www.westerndesigncenter.com/wdc/datasheets/w65c02s.pdf
>
> Though AFAIK the old 65C02 in the Apple lacked the WAI, STP, BBSx and
> BBRx instructions, right? Since they're not emulated by the old Applewin
> code.

Not sure about WAI or STP (I seem to recall them being new opcodes on
the 65802/65816). The main ones I recall being added were TSB, TRB, STZ
and BRA plus a few more addressing modes on existing instructions, such
as LDA (etc.) indirect and JSR pre-indexed absolute indirect.

The BBSx, BBRx, SMBx and RMBx instructions are not standard 65C02
opcodes. They were added by Rockwell in their R65C02 and apparently were
also included in some of their earlier R6500 series as well.

A standard 65C02 based on the original specification from WDC does not
have any of these instructions: all of the x3, x7, xB and xF opcodes are
NOPs. These opcodes are used on the 65802/65816 for new addressing modes
and other miscellaneous instructions.

Apple only used the WDC 65C02 or second sources with identical
instruction sets: GTE was most common in my observations; apparently
they also used a Rockwell 65C02 without the extra R65C02 instructions. I
have seen an R65C02 in some IIe clones.

--
David Empson
dempson(a)actrix.gen.nz
From: heuser.marcus on
> BTW the 65C02 data sheet is available from WDC as I just found out:
>
> > http://www.westerndesigncenter.com/wdc/datasheets/w65c02s.pdf

Here is the one for the Rockwell R65C02 for comparison:

http://www.6502.org/documents/datasheets/rockwell/rockwell_r65c00_microprocessors.pdf

bye
Marcus

From: mdj on
tjentzsch(a)yahoo.de wrote:

> Just stay away from those which are marked as unreliable (e.g. see
> http://oxyron.de/html/opcodes02.html)

Which is all of them; the 65C02 and 65816 treat all unused opcodes as
NOP. If you're writing code for the Apple II it's not even worth
considering. Even older Apple II's often have 65C02's fitted nowadays,
either as a replacement or via an accelerator card.

Matt

From: John Selck on
mdj wrote:
> tjentzsch(a)yahoo.de wrote:
>
>> Just stay away from those which are marked as unreliable (e.g. see
>> http://oxyron.de/html/opcodes02.html)
>
> Which is all of them;

No? Only two are completely unstable and 6 are "unstable in certain
aspects" but you can use them if you avoid the unstable conditions.

> the 65C02 and 65816 treat all unused opcodes as
> NOP. If you're writing code for the Apple II it's not even worth
> considering.

Some illegals are quite useful, like SHX/SHY which in some cases can be
used as STX absolute,Y / STY absolute,X if you use the right. Also you
can do a CPU test and use different code on different CPUs. The demo
"Oneder/Oxyron" does this. It works on 6502 with illegal opcodes, and on
65816 it uses a slower but illegal-free code.
From: mdj on
John Selck wrote:

> Some illegals are quite useful, like SHX/SHY which in some cases can be
> used as STX absolute,Y / STY absolute,X if you use the right. Also you
> can do a CPU test and use different code on different CPUs. The demo
> "Oneder/Oxyron" does this. It works on 6502 with illegal opcodes, and on
> 65816 it uses a slower but illegal-free code.

This is reasonable on the C64 where all machines were fitted with
6502's, and in the case of a 65816 it's accelerated, so a slower code
section is acceptable.

The Apple II series is essentially 3 platforms, and 3 CPU generations,
all backwards compatible.

I'll concede there is a potential fringe case where a piece of code was
so tight that downconverting from 65C02 to 6502 broke it, and it was
fixable using an undocumented instruction. Damned if I can think of an
example though; there's almost always another way to find a cycle or
two.

Matt

First  |  Prev  |  Next  |  Last
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Prev: what happened CBM=VGA
Next: 1581 Drive Kits on eBay