Hi 展辉 刘,
I am not fully sure what exactly is the root cause in your case.
When the Query Command returns DFPART and ERPART as 0xFF, something is wrong. I would like to recommend looking at that data in the debugger (address 0x120000’G, first you have to set MMCCTL1_EEEIFRON bit and check “refresh memory when halting” for global memory map range).
The ranges 0x12_0002 – 0x12_0003 and 0x12_0006 – 0x12_0007 should also contain duplicate values of DFPART and ERPART.
The described behavior (“a few months later, they can't store the data normally”) may fit case when Partition command was not finished successfully and DFlash is partitioned just partially.
For confirmation that, please check D-Flash area allocated for EEE (0x10_0000 – 0x10_7FFF when you use the whole 32kB). Every D-Flash sector (256bytes) should start with sector header (2 words with sector status and sector erase counter). Since these sectors are programmed sequentially, you may directly focus on last sector header at address 0x107F00’G.
Unfortunately, the testing DFPART and ERPART at address 0x120000 and 0x120004 is not enough for check whether partition was executed correctly or not.
About difference between Partition D-Flash and Full Partition D-Flash commands)
The Full Partition D-Flash command may be executed only in the special mode (with the connected debugger). The Partition D-Flash may run also in normal mode.
The Full Partition D-Flash command will fully erase D-Flash and EEE IFR (with DFPART and ERPART information) and program DFPART and ERPART again. After that, it will format (part of) D-Flash for EEE use (program sector headers).
The Partition D-Flash command will do the same what Full Partition D-Flash command except erasing D-Flash and EEE IFR (it will just check whether they are already erased or not).
Since the Full Partition D-Flash command may be used only in the special mode, we use it just for debugging purposes. The Partition D-Flash command typically used for partitioning in production.
Another theoretical potential source of the issue may be for example incorrect flash clock settings during partitioning – the EEE IFR memory cells may be insufficiently programmed. That kind of root cause may be checked by reading with different Margin Level (User/Field). Of course, the system clock and code check should be performed rather first.
I hope it helps you.
Have a great day,
Radek
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------