Application Note
AN1060
—
Rev. 1.0
MOTOROLA
303
a more detailed discussion of the program as it pertains to
communicating with and programming the target MC68HC711E9. Lines
25
–
45 initialize and define the variables and array used in the program.
Changes to this section would allow for other programs to be
downloaded.
Figure 8. PC-to-MCU Programming Circuit
Lines 50
–
95 read in the small bootloader from DATA statements at the
end of the listing. The source code for this bootloader is presented in the
DATA statements. The bootloaded code makes port C bit 0 low,
initializes the X and Y registers for use by the EPROM programming
utility routine contained in the boot ROM, and then jumps to that routine.
The hexadecimal values read in from the DATA statements are
converted to binary values by a subroutine. The binary values are then
saved as one string (BOOTCODE$).
The next long section of code (lines 97
–
1250) reads in the S records
from an external disk file (in this case, BUF34.S19), converts them to
integer, and saves them in an array. The techniques used in this section
show how to convert ASCII S records to binary form that can be sent
(bootloaded) to an M68HC11.
100
NORMAL EVBU
OPERATION
JUMPER
+
20 μF
+12.25 V
COMMON
PROGRAMMING
POWER
47K
VDD
PROGRAM
EPROM
1K
PC0
P5-9
LED
TO P5-18
(XIRQ/VPPE