Flash Memory
MPC5606S Microcontroller Reference Manual, Rev. 7
584
Freescale Semiconductor
17.2.7
Programming considerations
17.2.7.1
Modify operation
All the modify operations of the flash module are managed through the flash user registers interface.
All the sectors of the flash module belong to the same partition (bank), therefore when a Modify operation
is active on some sectors no read access is possible on any other sector (Read-While-Modify is not
supported).
During a flash modify operation, any attempt to read any flash memory location will output invalid data
and bit RWE of MCR will be automatically set. This means that the flash module is not fetchable when a
modify operation is active and these commands must be executed from another memory (internal RAM or
another flash module).
If a reset occurs during a modify operation, the operation is suddenly terminated and the macrocell is reset
to Read mode. The data integrity of the flash memory section where the modify operation has been
terminated is not guaranteed — the interrupted flash memory modify operation must be repeated.
In general, each modify operation is started through a sequence of three steps:
•
The first instruction is used to select the desired operation by setting its corresponding selection bit
in MCR (PGM or ERS) or UT0 (MRE or EIE).
•
The second step is the definition of the operands: the address and the data for programming or the
Sectors for erase or margin read.
•
The third instruction is used to start the modify operation by setting EHV in MCR or AIE in UT0.
Once selected, but not yet started, one operation can be canceled by resetting the operation selection bit.
A summary of the available flash memory modify operations are shown in
Once bit MCR.EHV (or UT0.AIE) is set, all the operands can no more be modified until bit MCR.DONE
(or UT0.AID) is high.
In general , each modify operation is completed through a sequence of four steps:
1. Wait for operation completion: wait for bit MCR.DONE (or UT0.AID) to go high.
2. Check operation result: check bit MCR.PEG (or compare UMISR0-4 with expected value).
3. Switch-Off FPEC by resetting MCR.EHV (or UT0.AIE).
4. Deselect current operation by clearing MCR.PGM/ERS (or UT0.MRE/EIE).
Table 17-36. Flash modify operations
Operation
Select bit
Operands
Start bit
Double Word Program
MCR.PGM
Address and Data by Interlock Writes
MCR.EHV
Sector Erase
MCR.ERS
LMS, HBS
MCR.EHV
Array Integrity Check
None
LMS, HBS
UT0.AIE
Margin Read
UT0.MRE
UT0.MRV + LMS, HBS
UT0.AIE
ECC Logic Check
UT0.EIE
UT0.DSI, UT1, UT2
UT0.AIE
Содержание MPC5602S
Страница 76: ...Overview MPC5606S Microcontroller Reference Manual Rev 7 74 Freescale Semiconductor...
Страница 82: ...Memory Map MPC5606S Microcontroller Reference Manual Rev 7 80 Freescale Semiconductor...
Страница 112: ...Signal Description MPC5606S Microcontroller Reference Manual Rev 7 110 Freescale Semiconductor...
Страница 166: ...Analog to Digital Converter ADC MPC5606S Microcontroller Reference Manual Rev 7 164 Freescale Semiconductor...
Страница 182: ...Boot Assist Module BAM MPC5606S Microcontroller Reference Manual Rev 7 180 Freescale Semiconductor...
Страница 234: ...Clock Description MPC5606S Microcontroller Reference Manual Rev 7 232 Freescale Semiconductor...
Страница 286: ...Crossbar Switch XBAR MPC5606S Microcontroller Reference Manual Rev 7 284 Freescale Semiconductor...
Страница 470: ...e200z0h Core MPC5606S Microcontroller Reference Manual Rev 7 468 Freescale Semiconductor...
Страница 524: ...Enhanced Direct Memory Access eDMA MPC5606S Microcontroller Reference Manual Rev 7 522 Freescale Semiconductor...
Страница 546: ...Error Correction Status Module ECSM MPC5606S Microcontroller Reference Manual Rev 7 544 Freescale Semiconductor...
Страница 669: ...Flash Memory MPC5606S Microcontroller Reference Manual Rev 7 Freescale Semiconductor 667...
Страница 670: ...Flash Memory MPC5606S Microcontroller Reference Manual Rev 7 668 Freescale Semiconductor...
Страница 716: ...FlexCAN MPC5606S Microcontroller Reference Manual Rev 7 714 Freescale Semiconductor...
Страница 882: ...LIN Controller LINFlex MPC5606S Microcontroller Reference Manual Rev 7 880 Freescale Semiconductor...
Страница 901: ...Memory Protection Unit MPU MPC5606S Microcontroller Reference Manual Rev 7 Freescale Semiconductor 899...
Страница 902: ...Memory Protection Unit MPU MPC5606S Microcontroller Reference Manual Rev 7 900 Freescale Semiconductor...
Страница 955: ...Mode Entry Module MC_ME MPC5606S Microcontroller Reference Manual Rev 7 Freescale Semiconductor 953...
Страница 956: ...Mode Entry Module MC_ME MPC5606S Microcontroller Reference Manual Rev 7 954 Freescale Semiconductor...
Страница 1072: ...Quad Serial Peripheral Interface QuadSPI MPC5606S Microcontroller Reference Manual Rev 7 1070 Freescale Semiconductor...
Страница 1096: ...Reset Generation Module MC_RGM MPC5606S Microcontroller Reference Manual Rev 7 1094 Freescale Semiconductor...
Страница 1106: ...Real Time Clock RTC API MPC5606S Microcontroller Reference Manual Rev 7 1104 Freescale Semiconductor...
Страница 1186: ...Stepper Stall Detect SSD MPC5606S Microcontroller Reference Manual Rev 7 1184 Freescale Semiconductor...
Страница 1213: ...System Integration Unit Lite SIUL MPC5606S Microcontroller Reference Manual Rev 7 Freescale Semiconductor 1211...
Страница 1214: ...System Integration Unit Lite SIUL MPC5606S Microcontroller Reference Manual Rev 7 1212 Freescale Semiconductor...
Страница 1238: ...Voltage Regulators and Power Supplies MPC5606S Microcontroller Reference Manual Rev 7 1236 Freescale Semiconductor...
Страница 1252: ...Wakeup Unit WKPU MPC5606S Microcontroller Reference Manual Rev 7 1250 Freescale Semiconductor...
Страница 1258: ...Registers Under Protection MPC5606S Microcontroller Reference Manual Rev 7 1256 Freescale Semiconductor...
Страница 1323: ...Register Map MPC5606S Microcontroller Reference Manual Rev 7 Freescale Semiconductor 1321...
Страница 1324: ...Register Map MPC5606S Microcontroller Reference Manual Rev 7 1322 Freescale Semiconductor...