
Application Note
AN1060 — Rev. 1.0
MOTOROLA
219
M68HC11 Family members which have 256 bytes of RAM, the download 
length is fixed at exactly 256 bytes plus the leading $FF character. 
The intercharacter delay counter is started [8] by loading the delay 
constant from TOC1 into the X index register. The 19-E-cycle wait loop 
is executed repeatedly until either a character is received [9] or the 
allowed intercharacter delay time expires [10]. For 7812 baud, the delay 
constant is 10,241 E cycles (539 x 19 E cycles per loop). Four character 
times at 7812 baud is 10,240 E cycles (baud prescale of 4 x baud divider 
of 4 x 16 internal SCI clocks/bit time x 10 bit times/character x 4 
character times). The delay from reset to the initial $FF character is not 
critical since the delay counter is not started until after the first character 
($FF) is received. 
To terminate the bootloading sequence and jump to the start of RAM 
without downloading any data to the on-chip RAM, simply send $FF and 
nothing else. This feature is similar to the jump to EEPROM at [4] except 
the $FF causes a jump to the start of RAM. This procedure requires that 
the RAM has been loaded with a valid program since it would make no 
sense to jump to a location in uninitialized memory. 
After receiving a character, the downloaded byte is stored in RAM [11]. 
The data is transmitted back to the host [12] as an indication that the 
download is progressing normally. At [13], the RAM pointer is 
incremented to the next RAM address. If the RAM pointer has not 
passed the end of RAM, the main download loop (from [7] to [14]) is 
repeated. 
When all data has been downloaded, the bootloader goes to [16] 
because of an intercharacter delay timeout [10] or because the entire 
512-byte RAM has been filled [15]. At [16], the X and Y index registers 
are set up for calling the PROGRAM utility routine, which saves the user 
from having to do this in a downloaded program. The PROGRAM utility 
is fully explained in 
EPROM Programming Utility
. The final step of the 
bootloader program is to jump to the start of RAM [17], which starts the 
user’s downloaded program. 
F
Freescale Semiconductor, Inc.
For More Information On This Product,
  Go to: www.freescale.com
n
.