AN2548 Freescale Semiconductor / Motorola, AN2548 Datasheet - Page 13

no-image

AN2548

Manufacturer Part Number
AN2548
Description
Serial Monitor Program for HCS12 MCUs
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
$E4 — Write_SP
Attempted with an
Invalid SP Value
$E5 — Byte Write
Access to
Nonvolatile Memory
$E6 — FACCERR or
FPVIOL FLASH Error
$E7 and $E8
$E9 — EACCERR or
EPVIOL EEPROM
Error
MOTOROLA
Since the monitor requires certain control register settings and a valid stack to
function correctly, a bad SP error results in the monitor forcing a reset to restore
required settings. After the warm reset, the PLL and control registers are
initialized and the prompt indicates there was a bad SP error message ($E3,
$00, $3E).
This error code indicates that the host attempted a Write_SP command with an
invalid 16-bit SP value. In order for the monitor program to function correctly,
the SP must always point into a valid area of RAM to support monitor functions.
The Write_SP command adjusts the supplied SP value (by subtracting 9) to
compensate for the user register stack frame. In addition, the monitor needs a
certain amount of stack space for stacking return addresses for nested
subroutine calls and for temporary storage of register contents during the
normal course of executing the monitor program. Because of these monitor
requirements, the valid range of values for SP is a little less that the whole
range of RAM addresses. See
This code indicates that a byte write access to a FLASH or EEPROM location
was attempted. Byte writing to the nonvolatile memory of the HCS12 devices
is not permitted.
This code indicates that an access error or protection violation error occurred
during an attempt to write or erase FLASH/EEPROM memory. In cases where
a single word was being programmed or a single page was being erased, the
attempted FLASH/EEPROM operation might not have been performed. In
cases where multiple bytes were being programmed or multiple pages were
being erased, this error indicates that at least one location or page erase
operation was flagged with an error. This monitor does not provide more
detailed information about these errors. The debug tool or programmer running
in the host PC can perform additional memory reads to get more detailed
information about the error. This error code will also be returned if the debug
tool attempts to program over the protected monitor space ($F800–$FFFF).
Error codes not implemented
This code indicates that an access error or protection violation error occurred
during an attempt to write or erase EEPROM memory. In cases where a single
word was being programmed or a single page was being erased, the attempted
EEPROM operation might not have been performed. In cases where multiple
bytes were being programmed or multiple pages were being erased, this error
indicates that at least one location or page erase operation was flagged with an
error. This monitor does not provide more detailed information about these
errors. The debug tool or programmer running in the host PC can perform
additional memory reads to get more detailed information about the error.
Freescale Semiconductor, Inc.
For More Information On This Product,
Serial Monitor Program for HCS12 MCUs
Go to: www.freescale.com
$AA — Write_SP
for details.
Command Error Codes
AN2548/D
13

Related parts for AN2548