Texas Instruments MSP430x1xx User Manual
Page 417

Flash Memory Data Structure and Operation
C-5
Flash Memory
Figure C–4.
Segments in Flash Memory Module, 4K-Byte Example
FFFFh
Flash Memory
F000h
010FFh
01000h
One Module
Segment0
Segment1
Segment2
Segment3
Segment4
Segment5
Segment6
Segment7
SegmentA
SegmentB
FFFFh
Flash Memory
F000h
010FFh
01000h
4Kbyte + 256Byte
One Module
FE00h
FDFFh
FC00h
Several Segments
256-Byte
Flash
4-kbyte
Flash
Main Memory
Information
Memory
C.1.1 Why Is a Flash Memory Module Divided Into Several Segments?
Once a bit in flash memory has been programmed, it cannot be erased without
erasing a whole segment. For this reason, the MSP430 flash memory modules
have been heavily segmented to allow erasing and reprogramming of smaller
memory segments.
C.2 Flash Memory Data Structure and Operation
The flash memory can be read and written (programmed) in bytes or words.
Bits can be written as 0s once between erase cycles. The read access does
not differ from access to masked ROM or RAM. Flash memory has restrictions
in write operation:
-
The default (erased) level for all bits is 1. Bits that are not programmed to
0s can be programmed to 0s at any time.
-
The smallest memory portion to be erased is a segment. No single byte
or word erase is possible.
-
Access to a flash memory module is only possible when the module is not
in a write or erase operation. For example, program code can not be
executed in a module while it is processing a write or erase operation. The
access limitation has no critical impact on program execution, but an
access violation can be flagged in some situations (see flash memory
register section in this chapter).