w65c265s Western Design Center, Inc., w65c265s Datasheet - Page 56
![no-image](/images/no-image-200.jpg)
w65c265s
Manufacturer Part Number
w65c265s
Description
W65c265s 16?bit Microcontroller
Manufacturer
Western Design Center, Inc.
Datasheet
1.W65C265S.pdf
(60 pages)
4.3
Future versions of the W65C265S mask ROM may vary, but each version should contain standard machine
code that allows startup to an external memory. Standard versions of the W65C265S will always contain
such a startup option. Anyone writing a custom mask ROM for the 265 is encouraged to follow this
standard.
The startup standard allows a program in an external memory to be executed after RESET if the startup
code WDC (in ASCII, $57, $44, $43) is present at addresses $8000-$8002 or $0800-$0802. If the startup
code is found at either set of addresses, the mask ROM does a JMP instruction to $8004 or $0804
respectively. W65C265S chip selects CS6 and CS7 can be used to address the memories.
The startup standard was set (and will be followed) with the original mask ROM in the early W65C265S
prototypes. A sample startup program appears below. The W65C02S emulation RESET vector ($FFFD)
should be set to STARTUP.
STARTUP
TSB
LDA
STA
;
TRY80
CMP
BNE
LDA
CMP
BNE
LDA
CMP
BNE
JMP
;
TRY02
CMP
BNE
LDA
CMP
BNE
LDA
CMP
BNE
JMP
;
NOEXT
External ROM Startup with W65C265S Mask ROMs
LDA
BCR
#$C0
PCS3 ;ON P36, P37 (PCS3=$0007)
LDA
#'W'
TRY02
$8001
#'D'
TRY02
$8002
#'C'
TRY02
$8004 ;EXECUTE EXTERNAL ROM PROGRAM
LDA
#'W'
NOEXT
$0801
#'D'
NOEXT
$0802
#'C'
NOEXT
$0804 ;EXECUTE EXTERNAL ROM PROGRAM
JMP
;ENABLE CHIP SELECTS CS6-, CS7-
#$01
;(BCR=$001B)
$8000 ;CHECK $8000 FOR 'WDC'
$0800 ;CHECK $0800 FOR 'WDC'
MASK_ROM_PROGRAM
CS1B:
CS3B:
CS2B:
;ENABLE EXTERNAL MEMORY BUS
8000-FFFF ⇒
0100-7FFF ⇒
0030-003F ⇒
Memory map:
;EXECUTE PROGRAM IN MASK ROM
EPROM (27C256)
SRAM (62C256)
VIA (W65C22S)
56