NOR(或非)和NAND(与非)是市场上两种主要的Flash闪存,sNORFLASH 和CPU之间不需要其他电路控制,NOR flash可以芯片内执行程序,而NAND FLASH 和CPU 的接口必须由相应的控制电路进行转换, NAND FLASH 以块的方式进行访问,不支持芯片内执行。
NAND FLASH 比NOR FLASH 容量大,价格低, NAND flash中每个块的最大擦写次数为100万次,而NOR 10W次, FLASH 编程原理都是只能把1变成0,而不能把0写为1, 所以在FLASH 编程之前,都要把对应的块擦除,擦除的过程就是把所有位都写为1,块内所有字节都变为0xFF。
NAND Flash芯片的种种不足,则需要靠控制芯片或操作系统软件来补足,动态平均抹写(Dynamic Wear
Leveling)就是NAND Flash控制芯片技术上的一项重要设计,可以将写入的资料平均在每一个NAND
Flash芯片的区块上,而非重复写入同一个区块,造成NAND Flash芯片的损害,可以顺利延长NAND
Flash芯片使用寿命,因此Wear-Leveling技术几乎是NAND Flash控制芯片设计上的必备。
Static Wear
Leveler
Let the Static Wear Leveler (SW Leveler) be associated with a Block
Erasing Table (BET) to remember which block has been erased in a
selected period of time. The SW Leveler is activated by some system
parameters for the needs of static wear levelling. When the SW Leveler
is running, it either resets the BET or picks up a block that has not
been erased so far (based on the BET information) and triggers the
Cleaner to do garbage collection on the block. The selection procedure
of a block mu