mc68hc908ap8a Freescale Semiconductor, Inc, mc68hc908ap8a Datasheet - Page 126

no-image

mc68hc908ap8a

Manufacturer Part Number
mc68hc908ap8a
Description
M68hc08 Microcontrollers
Manufacturer
Freescale Semiconductor, Inc
Datasheet
Monitor Mode (MON)
8.5 ROM-Resident Routines
Seven routines stored in the monitor ROM area (thus ROM-resident) are provided for FLASH memory
manipulation. Five of the seven routines are intended to simplify FLASH program, erase, and load
operations. The other two routines are intended to simplify the use of the FLASH memory as EEPROM.
Table 8-10
The routines are designed to be called as stand-alone subroutines in the user program or monitor mode.
The parameters that are passed to a routine are in the form of a contiguous data block, stored in RAM.
The index register (H:X) is loaded with the address of the first byte of the data block (acting as a pointer),
and the subroutine is called (JSR). Using the start address as a pointer, multiple data blocks can be used,
any area of RAM be used. A data block has the control and data bytes in a defined order, as shown in
Figure
During the software execution, it does not consume any dedicated RAM location, the run-time heap will
extend the system stack, all other RAM location will not be affected.
The control and data bytes are described below.
126
8-9.
shows a summary of the ROM-resident routines.
MON_PRGRNGE
MON_ERARNGE
Routine Name
PRGRNGE
ERARNGE
LDRNGE
ADDRESS AS POINTER
FILE_PTR
Figure 8-9. Data Block Format for ROM-Resident Routines
Table 8-10. Summary of ROM-Resident Routines
Program a range of locations
Erase a page or the entire array
Loads data from a range of locations
Program a range of locations in monitor
mode
Erase a page or the entire array in
monitor mode
ARRAY
MC68HC908AP A-Family Data Sheet, Rev. 3
DATA
$XXXX
Routine Description
START ADDRESS HIGH (ADDRH)
START ADDRESS LOW (ADDRL)
BUS SPEED (BUS_SPD)
DATA SIZE (DATASIZE)
R
DATA N
DATA 0
DATA 1
A
M
Call Address
$FCE4
$FC34
$FC00
$FF24
$FF28
BLOCK
DATA
Freescale Semiconductor
Stack Used
(bytes)
15
17
11
9
7

Related parts for mc68hc908ap8a