AN2400 Freescale Semiconductor / Motorola, AN2400 Datasheet - Page 15

no-image

AN2400

Manufacturer Part Number
AN2400
Description
HCS12 NVM Guidelines
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
MOTOROLA
Furthermore, when programming through the page window, $8000 to $BFFF,
the PPAGE register must be configured to select a page within the selected
flash block.
The general command sequence is described in
Sequence.
following initialisation sequence:
1. If the FDIVLD bit is clear, initialise the FCLKDIV register.
2. Verify that all ACCERR and PVIOL flags in the FSTAT register are clear.
3. If the microcontroller has multiple Flash blocks, write the BKSEL bits in
4. Write the core PPAGE register to select the desired page to be
Freescale Semiconductor, Inc.
1. For microcontrollers that have multiple Flash Blocks, each Flash block has a
For More Information On This Product,
$x10A
$x108
If the microcontroller has multiple Flash blocks, the FSTAT contents
must be checked for all combinations of the BKSEL bits in the FCNFG
register.
the FCNFG register to select the bank of registers corresponding to the
Flash block to be programmed, erased or verified.
programmed if programming in the $8000 to $BFFF range. There is no
need to set PPAGE if programming outwith this range, or if the
microcontroller does not have a page window.
separate Protection register (FPROT), Status register (FSTAT), Command register
(FCMD), Address register (FADDR) and Data register (FDATA). However, these
registers are banked, i.e. the registers for each Flash block share the same
address. The active bank of registers is selected by the BKSEL bits in the
unbanked Flash Configuration register (FCNFG). Thus with the BKSEL bits
cleared, Flash Block 0 is selected, and accesses to address $x105 will access the
Flash Status register of Flash Block 0
Address
$x100
$x101
$x102
$x103
$x104
$x105
$x106
$x107
Flash/EEPROM Command Sequence
$x109
$x10B
Go to: www.freescale.com
HCS12 NVM Guidelines
Flash Clock Divider Register (FCLKDIV)
Flash Security Register (FSEC)
Flash Test Mode Register (FTSTMOD)
Flash Configuration Register (FCNFG)
Flash Protection Register (FPROT)
Flash Status Register (FSTAT)
Flash Command Register (FCMD)
Reserved
16-bit Address Buffer (FADDR)
16-bit Data Buffer (FDATA)
Table 3. Flash Register Summary
Name
1
1
Flash/EEPROM Command
1
must be preceded with the
1
1
Flash Memory
AN2400/D
15

Related parts for AN2400