Start Flash Program (Burst mode)
Clear pending PRG, PRG_ERR, AVPST and
AVPRE Interrupt flags
Setup burst program operation in
TYPE = type of memory;
LEN = Length of Burst;
FLCTL_PRGBRST_CTLSTAT register
PRGB = 1 in FLCTL_IE
register?
Enable auto burst program verify option after
burst program operation.
(AUTO_PST = 1 in
FLCTL_PRGBRST_CTLSTAT)
Enable auto burst program verify before and
after burst program operation.
(AUTO_PRE = 1, AUTO_PST = 1 in
FLCTL_PRGBRST_CTLSTAT)
YES
NO/MAYBE
YES
Location /Locations to
be programed is already
erased?
NO
Continue CPU execution of other tasks or put
device in LPM0.
YES
End of burst programming
YES
D
BURST_STATUS in
FLCTL_PRGBRST_CTLSTAT = IDLE?
Clear BURST_STATUS by setting
CLR_STAT = 1 in
FLCTL_PRGBRST_CTLSTAT
NO
Write data to be programmed into the burst
data registers.
(FLCTL_PRGBRST_DATAn_x)
Setup start address of burst operation in
FLCTL_PRGBRST_STARTADDR register.
Start Burst program operation by setting
START bit in FLCTL_PRGBRST_CTLSTAT
register.
PRGB = 1 in FLCTL_IFG
register?
NO
PRE_ERR = 1 or
PST_ERR = 1 in
FLCTL_PRGBRST_CTLSTAT?
PRGB interrupt?
NO
YES
NO
ADDR_ERR =
1 in
FLCTL_PRGBRST_CTLSTAT
register?
NO
Check STARTADDR to STLEN
fall in valid memory map
YES
YES
Keep track of the number of programming
pulses.
num_prg_pls = 0;
Increment programing pulses used.
num_+;
Advanced Operations using the Flash Controller
468
SLAU356I – March 2015 – Revised June 2019
Copyright © 2015–2019, Texas Instruments Incorporated
Flash Controller (FLCTL)
Figure 9-4. Burst Program Flow