Freescale Semiconductor, Inc.
*****************************************************************************
*
*
*
*
*
*
*
Equates and RAM Storage
*****************************************************************************
*
CS
equ
equ
equ
equ
0
1
2
3
;bit # for chip select
;bit # for serial clock
;bit # for serial data out
;bit # for serial data in
SER_CLK
SER_OUT
SER_IN
***
RAM storage variables ***
org
rmb
rmb
rmb
rmb
rmb
rmb
rmb
rmb
RAM
1
1
1
1
1
1
1
1
;start of static RAM at $C0
;command byte
;EEPROM address byte
;MSByte of data
;LSByte of data
;test byte #1
;test byte #2
;test byte #3
;test byte #4
OPCODE
ADDR
DATA_H
DATA_L
TEST1
TEST2
TEST3
TEST4
*****************************************************************************
*
*
*
*
*
*
*
*
*
*
*
*
*
*
Program Initialization
* This section sets up the port for bit banging.
*
* To prevent floating inputs and associated high current draw,
* the HC705J1A has pulldown devices on all I/O pins. This
* initialization should enable these pulldowns on unused I/O
* pins. RESET_ enables the pulldowns, so no code is required.
*
*****************************************************************************
*
org
lda
sta
sta
lda
sta
EPROM
#$80
PORTA
COPR
#$87
DDRA
J9356_START
;init portA
;
;kick the wdog
;init i/o of port A
AN1241/D
For More Information On This Product,
Go to: www.freescale.com
11