PSD8XX Family
The
PSD835G2
Functional
Blocks
(cont.)
PSD835G2
9.1.1.7.2 Data Toggle (cont.)
It is suggested (as with all Flash memories) to read the location again after the embedded
programming algorithm has completed to compare the word that was written to Flash with
the word that was intended to be written.
When using the Data Toggle method after an erase instructin, Figure 5 still applies. DQ6
will toggle until the erase operation is complete. A ‘1’ on DQ5 will indicate a timeout failure
of the erase operation, a ‘0’ indicates no error. The MCU can read any even location within
the sector being erased to get DQ6 and DQ5.
PSDsoft generates ANSI C code functions which implement these Data Toggling
algorithms.
Figure 5. Data Toggle Flow Chart
START
READ
DQ5 & DQ6
D=Q6
NO
TOGGLE
YES
NO
DQ5
=1
YES
READ DQ6
D=Q6
NO
TOGGLE
YES
FAIL
Program/Erase
Operation Failed
Issue Reset Instruction
PASS
Program/Erase
Operation is
Completed
24