Wear leveling method suitable for Nor Flash data storage and storage device

A wear leveling and data storage technology, applied in information storage, static memory, read-only memory, etc., can solve problems affecting performance, bad blocks, and inability to guarantee correctness, and achieve the effect of improving service life and ensuring security.

Pending Publication Date: 2021-12-14
海纳云物联科技有限公司 +1
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] When writing data in Nor Flash, the common practice is to write data at a fixed address. When the data at this location needs to be changed, it needs to be erased first and then written. The data can only be written from 1 to 0, and cannot be written from 0 to 1. After erasing, all Norflash data becomes 0xFF. When faced with data that needs to be changed frequently, the very low writing and erasing speed of Nor Flash greatly affects its performance. The write life is generally about 100,000 times. When the number of times exceeds this limit, there will be a possibility of bad blocks. If you continue to rewrite the stored data at this time, the correctness cannot be guaranteed.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Wear leveling method suitable for Nor Flash data storage and storage device
  • Wear leveling method suitable for Nor Flash data storage and storage device
  • Wear leveling method suitable for Nor Flash data storage and storage device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0065] The specific implementation manners of the present invention will be further described in detail below in conjunction with the accompanying drawings.

[0066] combine Figure 1 to Figure 5 As shown, a wear leveling method suitable for Nor Flash data storage includes a method of allocating storage pages to the Nor Flash memory, an initialization method, and a data writing and reading method.

[0067] The method for allocating storage pages includes: dividing the Nor Flash storage space into at least two storage pages of the same size, and determining the start addresses and sizes of the two storage pages.

[0068] Set three global variables in memory: active page address (g_PgAcitve), active page data offset address (g_PgOffset), and page switching flag (g_PgCycle).

[0069] Specifically, when dividing a storage page, each storage page is set to consist of a page attribute (pageHeader) and a data unit (dataItem).

[0070] The page attribute (pageHeader) occupies the fi...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention relates to a wear leveling method suitable for NorFlash data storage. The wear leveling method comprises a storage page distribution method for a memory, an initialization method and a data writing and reading method. The storage page distribution method comprises the step of dividing a storage space into two storage pages; the initialization method comprises the steps of selecting one storage page as an active page, and selecting the other storage page as a standby page, and updating the value of a global variable in a memory; the data writing method comprises the steps that whether the residual storage space of an active page is not smaller than the space needed by data needing to be written or not is judged, if not, the data needing to be stored are written from a data offset address, and if yes, a standby page is switched into the active page, and the active page is rewritten; the data reading method comprises the steps of obtaining related parameters of data needing to be read, searching data in an active page from back to front, and reading the data which is searched firstly and meets the requirements of the related parameters into a memory. The invention further relates to a storage device used for executing the method.

Description

technical field [0001] The invention relates to a non-volatile flash memory technology, in particular to a wear leveling method and a storage device suitable for Nor Flash data storage. Background technique [0002] Nor Flash is a non-volatile flash memory technology, which is characterized by in-chip execution (XIP, eXecute InPlace), so that applications can run directly in the Flash memory without having to read the code into the system RAM. The transmission efficiency of Flash memory is very high, and it is very cost-effective in the small capacity of 1-4MB, but it is generally used to store programs or data with a small amount of code. [0003] When writing data in Nor Flash, the common practice is to write data at a fixed address. When the data at this location needs to be changed, it needs to be erased first and then written. The data can only be written from 1 to 0, and cannot be written from 0 to 1. After erasing, all Norflash data becomes 0xFF. When faced with data...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G11C29/18G11C29/42G11C16/04
CPCG11C29/18G11C29/42G11C16/0483
Inventor 陈斌陈国虎肖斌张亚伟
Owner 海纳云物联科技有限公司
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products