[net.micro.cbm] Question about C-128 and 8502 chip.

sinclair@aero.ARPA (William S. Sinclair) (01/03/86)

The C-128 uses the 8502 chip, which is an enhanced version of the 6502.
If I use a 6502 assembler to generate 8502 code, can I still run in the
c128 mode? What are the advantages of using the enhanced set? Can I kluge
the source code to generate instructions in the enhanced set from a regular
assembler, such as the PAL, or MERLIN?

Bill S.
Go ahead and flame! I brought marshmallows!!
213/647-1753

kev@voder.UUCP (Kevin Hoskins) (01/06/86)

In article <183@aero.ARPA>, sinclair@aero.ARPA (William S. Sinclair) writes:
> 
> The C-128 uses the 8502 chip, which is an enhanced version of the 6502.
     
     I believe that it is the 8510, not the 8502 that runs the C-128.
     From what I have been able to discern from Compute! publications
     and from The Transactor, the "enhancement" of the 8510 is its ability
     to run at 2 MHz vs 1 MHz for the 6502 (or 6510). Also, the pin-out 
     has also been modified. (Even the I/O port at H0000 and H0001
     is still there.)

> If I use a 6502 assembler to generate 8502 code, can I still run in the
> c128 mode? 

     The 8510 uses the same op-code set as the 6510. Therefore code 
     generated with an assembler for the 6502/10 will run on the C-128.
     (See below.)

> What are the advantages of using the enhanced set? Can I kluge
> the source code to generate instructions in the enhanced set from a regular
> assembler, such as the PAL, or MERLIN?

     No the source code will not have to be kluged, but obviously code 
     generated for the C-64 will be machine specific. What you will have 
     to do is obtain a detailed memory map of the C-128 and make necessary
     changes so that your code will run on the C-128.
     to obtain a C-128 memory map
--