WO2023179243A1 - 数据读写方法、系统及介质、设备 - Google Patents

数据读写方法、系统及介质、设备 Download PDF

Info

Publication number
WO2023179243A1
WO2023179243A1 PCT/CN2023/075837 CN2023075837W WO2023179243A1 WO 2023179243 A1 WO2023179243 A1 WO 2023179243A1 CN 2023075837 W CN2023075837 W CN 2023075837W WO 2023179243 A1 WO2023179243 A1 WO 2023179243A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
writing
current
area
flash memory
Prior art date
Application number
PCT/CN2023/075837
Other languages
English (en)
French (fr)
Inventor
樊海军
Original Assignee
上海美仁半导体有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 上海美仁半导体有限公司 filed Critical 上海美仁半导体有限公司
Publication of WO2023179243A1 publication Critical patent/WO2023179243A1/zh

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0616Improving the reliability of storage systems in relation to life time, e.g. increasing Mean Time Between Failures [MTBF]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/08Error detection or correction by redundancy in data representation, e.g. by using checking codes
    • G06F11/10Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's
    • G06F11/1004Adding special bits or symbols to the coded information, e.g. parity check, casting out 9's or 11's to protect a block of data words, e.g. CRC or checksum
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0877Cache access modes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/0644Management of space entities, e.g. partitions, extents, pools
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/0652Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket

Definitions

  • the present disclosure relates to the field of memory technology, and in particular, to a data reading and writing method, system, medium, and equipment for Flash memory.
  • Flash memory is a new type of semiconductor memory launched by Intel in 1988. It has non-volatile storage characteristics, referred to as flash memory. This type of read-only memory has significant advantages such as high integration, fast reading speed, single power supply, and multiple reprogramming times. , Flash memory, as a non-volatile data storage device, is widely used in embedded systems. The Flash memory inside the microcontroller can be programmed online and can also store data when the program is running.
  • Flash memory The storage cells of Flash memory are organized into slice arrays.
  • a slice is the smallest unit for an erasure operation.
  • the erase operation sets all positions in the slice to "1".
  • Pages are the basic units for read and write operations.
  • Flash memory Before writing operations (also called programming operations) on a page, it is necessary to determine whether all the bits in the page are "1". If all are "1", the write operation can be performed; otherwise, the entire area needs to be erased first. Therefore, Flash memory needs to be erased multiple times when used.
  • the life of Flash memory is limited, and its number of erases is also limited. Now most Flash memories can withstand 100,000 erasing times. Then, When the number of erasing and writing is too many, the entire Flash memory will be damaged, thereby reducing the service life of the Flash memory.
  • the present disclosure aims to solve one of the technical problems in the related art, at least to a certain extent.
  • the purpose of this disclosure is to propose a data reading and writing method, system, medium, and equipment for a Flash memory, so as to reduce the number of erasures of the Flash memory and extend the service life of the Flash memory.
  • an embodiment of the present disclosure proposes a data reading and writing method for a Flash memory.
  • the Flash memory includes a plurality of slices.
  • the method includes: determining to write data to the Flash memory and obtaining the currently written slice; It is detected that the storage space of the current writing area does not meet the storage requirements of the data to be written, determines the target writing area according to the current writing area, and adjusts the status value of the current writing area from in use to is full; write the data to be written into the target writing area; detect that the area whose status value is full needs to be erased, and erase the data in the area whose status value is full.
  • the data reading and writing method of the Flash memory before erasing the data in the area with the status value being full, the method further includes: detecting the area in the area with the status value being full. If there is data to be transferred that needs to be transferred to the target writing area, the data to be transferred is transferred to the target writing area.
  • the judgment determines that it is necessary to erase the data in the slices with a status value that is full, including: counting the number of slices with a status value that is full; It is detected that the number reaches the preset threshold, and it is determined that the data in the sector with a full status value needs to be erased.
  • the plurality of slices include static slices and dynamic slices
  • the method further includes: detecting that the currently written slice is a dynamic slice, and executing The step of detecting the storage space of the currently written area; detecting that the currently written area is a static area, erasing the data in the currently written area, and after erasing, the to-be-written area Data is written into the currently written slice.
  • the data reading and writing method of the Flash memory further includes: determining to read the data in the Flash memory and obtaining the current reading area; The data is verified; when it is detected that the verification is passed, the data in the currently read area is stored in the buffer.
  • the verification of the data in the currently read section includes: detecting that the current read section is a static section, and verifying the current read section. Verify the check code of the data in the current reading area; detect that the current reading area is a dynamic area, check the ID length, reading address of the currently reading area, and the data in the currently reading area check code for verification.
  • the data reading and writing method of the Flash memory further includes: determining the initialization of the system where the Flash memory is located, and obtaining the mark value and status value of each of the slices; The tag value and status value of the slice area are used to determine the current write address and the current read address and store them.
  • the method for reading and writing data in Flash memory which determines the current write address and the current read address according to the mark value and status value of each of the slices, includes: Determine the first use of the Flash memory according to the mark value, and obtain the current write address as the preset write address and the current read address as the preset read address; determine the Flash memory according to the mark value It is not the first time to use, and the status of each slice is determined to be normal according to the status value, the current writing slice is indexed according to the status value, and the current writing address and the current writing address are determined according to the current writing slice. Read the address; determine that the Flash memory is not used for the first time according to the mark value, and determine that there is an abnormal state area according to the status value, and obtain that the current writing address is the preset writing address, and the current reading The address is the default reading address.
  • the obtaining the current writing area includes: obtaining the current writing area according to the current writing address; and obtaining the current reading area.
  • the slice area includes: obtaining the current read slice area according to the current read address.
  • the data reading and writing method of Flash memory after writing the data to be written into the target writing area, the method further includes: updating the current writing address and the current read address.
  • embodiments of the present disclosure provide a computer-readable storage medium on which a computer program is stored.
  • the computer program is executed by a processor, the above-mentioned data reading and writing method of the Flash memory is implemented.
  • a third embodiment of the present disclosure provides an electronic device, including a memory, a processor, and a computer program stored on the memory.
  • the computer program is executed by the processor, the above-mentioned Flash memory data reading and writing methods.
  • an embodiment of the present disclosure provides a data reading and writing system for a Flash memory, including a Flash memory and the electronic device.
  • the data reading and writing method, system, media, and equipment of the Flash memory in the embodiment of the present disclosure obtain the current writing area by determining to write data to the Flash memory, and detect that the storage space of the current writing area does not satisfy the data to be written. Storage requirements, determine the target writing area based on the current writing area, adjust the status value of the current writing area from in use to full, write the data to be written into the target writing area, and detect the need to erase the status value It is a method of erasing the data in the sector whose status value is full. As a result, the number of erase times of the Flash memory can be reduced and the service life of the Flash memory can be extended.
  • Figure 1 is a flow chart of a method for reading and writing Flash memory data according to an embodiment of the present disclosure
  • Figure 2 is a flow chart of an example of the present disclosure in which the erase status value is a full area
  • Figure 3 is a flow chart for determining whether to erase a full area according to an example of the present disclosure
  • Figure 4 is a flowchart of determining the currently written slice area according to an example of the present disclosure
  • Figure 5 is a flow chart of flash memory data writing according to an embodiment of the present disclosure
  • Figure 6 is a flow chart of Flash memory data reading according to an embodiment of the present disclosure
  • Figure 7 is a flow chart for determining the first use of Flash memory according to an embodiment of the present disclosure
  • Figure 8 is a flow chart of Flash initialization according to an embodiment of the present disclosure
  • Figure 9 is a structural block diagram of a Flash memory data reading and writing method system according to an embodiment of the present disclosure.
  • the N bytes are usually saved directly from the first address of the Flash memory, and this part of the content is directly modified every time it is rewritten, so this The number of parameter refreshes is the same as the flash memory erase life.
  • the present disclosure adopts a cyclic writing method to reduce the number of erasures.
  • each frame of data that needs to be written, including: DataID, DataLen, Data1,..., DataN, Checksum and EOP.
  • DataID is the data ID, used to distinguish different parameters
  • DataLen is the data length
  • DataN is the data
  • Checksum is the checksum
  • EOP is the end character.
  • the data structure of each slice in the Flash memory includes: SectorLabel, SectorStatus and each frame data that needs to be written (including ID, Len, Data*Len, Checksum and EOP).
  • SectorLabel indicates whether the sector uses a mark, and is also used to distinguish whether it is the first time to operate the Flash memory
  • SectorStatus indicates the current status of the sector, which can include three states: full, in use and empty
  • Data*Len which is the above DataData1-N.
  • Figure 1 is a flow chart of a method for reading and writing data in a Flash memory according to an embodiment of the present disclosure.
  • Flash memory contains multiple areas.
  • the data reading and writing methods of Flash memory include: S101, confirm writing data to the Flash memory and obtain the current writing area.
  • the status of each area is different.
  • the area status is divided into three states: full, in use, and empty.
  • the currently written area obtained may satisfy the requirements of the area to be written.
  • the storage requirements of the incoming data may not meet the storage requirements of the data to be written. Therefore, after obtaining the current writing area, the storage space of the current writing area needs to be detected.
  • the current write-in area does not meet the storage requirements of the data to be written, and the data to be written cannot be written; if the status of the current write-in area is in use, and If the remaining space is not enough to store the data to be written, the current writing area does not meet the storage requirements of the data to be written, and the data to be written cannot be written.
  • the data to be written is divided into dynamic data and static data, which can be distinguished by data ID; correspondingly, multiple slices can also be divided into dynamic slices and static slices.
  • data ID can be distinguished by data ID
  • multiple slices can also be divided into dynamic slices and static slices.
  • the available types of currently written sectors are also different, and different types of sectors have different ways of erasing and writing data to them.
  • the type of data to be written is determined based on the ID of the data to be written, that is, whether the data is dynamic data or static data.
  • the currently written slice is a dynamic slice according to the data type
  • the storage space of the currently written slice meets the storage requirements of the data to be written.
  • the currently written slice is erased. Enter the data in the sector, and write the data to be written into the currently written sector after erasing.
  • the current writing sector can be determined by the current writing address. If the current writing sector pointed to by the current writing address has no space to write data, the current writing address (CurWrAddress) can be pointed to the next sector Sector (i.e. the target Write to the sector), and adjust the status value (SectorStatus) of the current writing sector from in use to full (that is, from ACTIVE to FULLED). You can also adjust the status value of the target writing sector to in use. At this time The CurWrAddress already points to the target write slice. If the target writing area has space to write the data to be written, the data is written to the target writing area.
  • the writing address CurWrAddress is changed again to the next writing area, and the status value of the previous area is marked as full, until the data to be written is found.
  • the required write-in area is used as the target write-in area, and the data to be written is written into the target write-in area. It should be noted that if the storage space of each slice is the same, the target writing slice can be obtained by searching only once.
  • the Flash memory has 5 slices. When the number of slices with a full status value reaches 3, the slices with a full status value need to be erased. It should be noted that when data is written, the slices are written cyclically. For example, the five slices are recorded as slice 1, slice 2, slice 3, slice 4, and slice 5. When slice 1 is full, write slices 2; when area 2 is full, write area 3; and so on, when area 5 is full, write area 1.
  • FIG. 2 is a flow chart in which the erase status value is a full area according to an example of the present disclosure.
  • step S1043 to erase the data in the slice whose status value is full.
  • step S1042 it is necessary to carry out step S1042 to transport the data to be transported to the target writing area.
  • FIG. 5 is a flow chart of flash memory data writing according to an embodiment of the present disclosure.
  • the data format is data ID, data length Len, data Data, checksum CheckSum, and end character EOP
  • the current write address CurWrAddress will be recorded and used as the next read address and write address. If the current write address is unsuccessful, the write address CurWrAddress will be updated to point to the next write address as The current write address for the next write, and Fail will be returned.
  • the target writing area When the target writing area is successfully written, it is necessary to determine whether there is data in the full area that needs to be transferred to the target writing area. If there is data, the data needs to be transferred before the full area can be erased. After transferring the data to the target sector, update the write address and read address, and adjust the status value of the sector to empty (EMPTY) after erasing. If there is no data to be transferred, directly erase the area whose status value is full, and adjust the status value of the area to empty (EMPTY) after erasing), and finally return Success to write successfully.
  • EPTY status value of the sector to empty
  • the data reading and writing method of the Flash memory when writing data to the Flash memory, can eliminate the need to erase the Flash memory before each write through cyclic writing of the area, thereby reducing the need for erasing the Flash memory.
  • the number of erasures is increased to increase the service life of the Flash memory.
  • the data reading and writing method of the Flash memory also includes: confirming to read the data in the Flash memory, obtaining the current reading area, verifying the data in the currently reading area; detecting the verification Pass, the data in the currently read sector is stored in the buffer.
  • obtaining the current reading area is obtained from the current reading address.
  • Verifying the data in the currently reading area may include: detecting that the current reading area is a static area, and verifying the data in the current reading area. Verify the check code; detect that the currently read section is a dynamic section, and verify the ID length, read address, and the check code of the data in the currently read section.
  • the check code (such as the above-mentioned checksum) of the data in the currently read slice is verified; when the current read slice is a dynamic slice, the check code of the currently read slice is verified.
  • the ID length, read address, and the check code (such as the above-mentioned checksum) of the data in the current read area are verified. Specifically, they can be verified in sequence. If any verification fails, the reading process can be ended.
  • Figure 6 is a flow chart of flash memory data reading according to an embodiment of the present disclosure.
  • execute the start command Start and enter the data ID and Buff, where Buff is the data buffer. Determine the attributes of the data ID. If the input data ID represents static data, obtain the data ID from the current reading area pointed to by the fixed address, and then determine whether the data is valid. The method to determine whether the current data is valid is to verify the data in the currently read section, that is, to determine the checksum CheckSum of the currently read section. When the verification passes, the data in the current reading area is stored in the buffer Buff, and then a read success is returned. If the verification fails, a read failure is returned.
  • the input data ID represents dynamic data
  • the data reading and writing method of the Flash memory also includes: determining the initialization of the system where the Flash memory is located, and obtaining the tag value and status value of each area; and determining the current write based on the tag value and status value of each area. address and the current read address and stored.
  • the tag value and status value of each area are obtained, and the current writing address and current reading address are determined based on the tag value and status value of each area, where, The mark value includes used and unused, and the status value includes full, in use and empty.
  • the tags ie, tag values
  • the Flash memory already has data stored, it needs to index to the current writing area, as well as the current writing address CurWrAddress and the latest ID data. offset address (that is, the current read address), and store these data in SRAM (Static Random-Access Memory, static random access memory), where the current read address is stored in IdOffsetAddr[].
  • the current write address is the preset write address
  • the current read address is the preset read address. If the Flash memory is not used for the first time, the status value needs to be determined based on the status value. Is it normal? If the status of each slice is determined to be normal according to the status value, the current writing slice will be indexed according to the status value, and the current writing address and the current reading address will be determined based on the current writing slice. If the status value is abnormal, it means there is For abnormal slices, return to the steps where the current write address is the preset write address and the current read address is the preset read address.
  • the current writing address may be updated so that the current writing area can be obtained during the next writing.
  • Figure 8 is a flow chart of Flash memory initialization according to an embodiment of the present disclosure.
  • the Flash operation clock after starting the command, first configure the Flash operation clock and then check the tag value SectorLabel currently written to the slice area.
  • tag values There are two types of tag values: used and unused. If the current write-in area has a label, it means that data is written to the current write-in area, that is, the mark value is used. If there is no label in the current write-in area, it means that the current write-in area is not in use. When there is no label in the currently written area, the label of each area will be initialized. If the operation is successful, the status value of each area will continue to be initialized. If the operation fails, an initialization failure Fail will be returned, and the status value of each area will be initialized. If it fails, an initialization failure Fail will be returned. If the initialization operation on the status value of each sector is successful, initialize the current write address (Sector0+4) and initialize the ID data offset address (set the offset address to 0, which is the current read address).
  • the current write-in area When the current write-in area has a label, it means that the current write-in area has been used, that is, data has been stored.
  • the status that is, the status value SectorStatus is used when searching for the current section. If the status is abnormal, the status value of each section is initialized. Perform the same operation as initializing the status of each slice without tags, and will not go into details here. If the status is normal, index the current write address and store the write address in SRAM and index the current latest ID data to store the offset address (i.e. the current read address) and store it in SRAM. Finally, return the initialization success Success. Perform the above operations in Complete Flash initialization before use to facilitate subsequent data writing and reading operations.
  • the data reading and writing method of the Flash memory proposed by the present disclosure makes up for the defect of erasing the Flash memory every time data is written through cyclic writing, thereby greatly reducing the number of erasures of the Flash memory and improving the efficiency of the Flash memory.
  • the service life of Flash memory is greatly reducing the number of erasures of the Flash memory and improving the efficiency of the Flash memory.
  • the present disclosure proposes a computer-readable storage medium.
  • the present disclosure proposes an electronic device.
  • the electronic device includes a memory, a processor, and a computer program stored in the memory.
  • the computer program is executed by the processor, the data reading and writing method of the Flash memory as in the above embodiment is implemented.
  • the present disclosure also proposes a data reading and writing system for Flash memory.
  • a flash memory data reading and writing system 100 includes an electronic device 10 and a flash memory 20 .
  • the flash memory data reading and writing system, computer-readable storage medium, and electronic device can reduce the number of erase times of the flash memory and increase the service life of the flash memory through the above-mentioned data reading and writing method of the flash memory.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Computer Security & Cryptography (AREA)
  • Quality & Reliability (AREA)
  • Read Only Memory (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

一种Flash存储器的数据读写方法、系统以及介质、设备,涉及到存储器技术领域,方法包括:确定向Flash存储器写入数据,获取当前写入片区;检测到当前写入片区的存储空间不满足待写入数据的存储需求,根据当前写入片区确定目标写入片区,并将当前写入片区的状态值从使用中调整为已满;将待写入数据写入目标写入片区;检测到需要擦除状态值为已满的片区,擦除状态值为已满的片区中的数据。

Description

数据读写方法、系统及介质、设备
相关申请的交叉引用
本公开基于申请号为:202210283860.5,申请日为2022年03月21日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本公开作为参考。
技术领域
本公开涉及到存储器技术领域,尤其涉及到一种Flash存储器的数据读写方法、系统以及介质、设备。
背景技术
Flash存储器是Intel公司于1988年推出的一种新型半导体存储器,具有非挥发存储特性,简称闪存,该类只读存储器具有集成度高、读取速度快、单一供电、再编程次数多等显著优点,Flash存储器作为非易失数据存储设备,被广泛地应用于嵌入式系统中。单片机片内的Flash存储器可以在线编程,也可以存储程序运行时的数据。
Flash存储器的存储单元组织为片区阵列,片区是擦除操作的最小单位,擦除操作将片区内所有的位置为“1”。每个片区可包含多个页,页是读、写操作的基本单位,在对页进行写操作(也叫编程操作)之前需要判断该页内所有的位是否为“1”。如果全部为“1”,则可以进行写操作;否则,需要先对整个片区进行擦除操作。因此,Flash存储器在使用时,需要进行多次擦除,但是,Flash存储器的寿命是有限的,其擦除次数也有限制,现在大多数Flash存储器可承受的擦除次数为10万次,那么,当擦写次数过多时,会导致整个Flash存储器损坏掉,进而降低Flash存储器的使用寿命。
发明内容
本公开旨在至少在一定程度上解决相关技术中的技术问题之一。为此,本公开的目的在于提出一种Flash存储器的数据读写方法、系统以及介质、设备,以减少Flash存储器的擦除次数,延长Flash存储器的使用寿命。
第一方面,本公开实施例提出了一种Flash存储器的数据读写方法,所述Flash存储器包括多个片区,所述方法包括:确定向所述Flash存储器写入数据,获取当前写入片区;检测到所述当前写入片区的存储空间不满足待写入数据的存储需求,根据所述当前写入片区确定目标写入片区,并将所述当前写入片区的状态值从使用中调整为已满;将所述待写入数据写入所述目标写入片区;检测到需要擦除状态值为已满的片区,擦除状态值为已满的片区中的数据。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,在擦除状态值为已满的片区中的数据之前,所述方法还包括:检测到状态值为已满的片区中存在需要搬运至所述目标写入片区的待搬运数据,将所述待搬运数据搬运至所述目标写入片区。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述判断确定需要擦除状态值为已满的片区中的数据,包括:统计状态值为已满的片区的数量;检测到所述数量达到预设阈值,确定需要擦除状态值为已满的片区中的数据。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述多个片区包括静态片区和动态片区,所述方法还包括:检测到所述当前写入片区为动态片区,执行对所述当前写入片区的存储空间进行检测的步骤;检测到所述当前写入片区为静态片区,擦除所述当前写入片区中的数据,并在擦除后将所述待写入数据写入所述当前写入片区。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述方法还包括:确定读取所述Flash存储器中的数据,获取当前读取片区;对所述当前读取片区中的数据进行校验;检测到校验通过,将所述当前读取片区中的数据存入缓存器。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述对当前读取片区中的数据进行校验,包括:检测到所述当前读取片区为静态片区,对所述当前读取片区中数据的校验码进行校验;检测到所述当前读取片区为动态片区,对所述当前读取片区的ID长度、读取地址,以及所述当前读取片区中数据的校验码进行校验。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述方法还包括:确定所述Flash存储器所在系统初始化,获取到各所述片区的标记值和状态值;根据各所述片区的标记值和状态值,确定所述当前写入地址和所述当前读取地址并存储。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述根据各所述片区的标记值和状态值,确定所述当前写入地址和所述当前读取地址,包括:根据所述标记值确定所述Flash存储器首次使用,得到所述当前写入地址为预设写入地址、所述当前读取地址为预设读取地址;根据所述标记值确定所述Flash存储器非首次使用,且根据所述状态值确定各所述片区的状态均正常,根据所述状态值索引当前写入片区,并根据所述当前写入片区确定所述当前写入地址和所述当前读取地址;根据所述标记值确定所述Flash存储器非首次使用,且根据所述状态值确定存在状态异常的片区,得到所述当前写入地址为预设写入地址、所述当前读取地址为预设读取地址。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述获取当前写入片区,包括:根据所述当前写入地址得到所述当前写入片区;所述获取当前读取片区,包括:根据所述当前读取地址得到所述当前读取片区。
根据本公开的一个实施例,所述的Flash存储器的数据读写方法,所述将所述待写入数据写入所述目标写入片区之后,所述方法还包括:更新所述当前写入地址和所述当前读取地址。
第二方面,本公开实施例提出了一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时,实现如上述的Flash存储器的数据读写方法。
为达到上述目的,本公开第三实施例提出了一种电子设备,包括存储器、处理器和存储在所述存储器上的计算机程序,所述计算机程序被所述处理器执行时,实现如上述的Flash存储器的数据读写方法。
第三方面,本公开实施例提出了一种Flash存储器的数据读写系统,包括:Flash存储器和所述的电子设备。
本公开实施例的Flash存储器的数据读写方法、系统以及介质、设备,通过确定向Flash存储器写入数据,获取当前写入片区,检测到当前写入片区的存储空间不满足待写入数据的存储需求,根据当前写入片区确定目标写入片区,并将当前写入片区的状态值从使用中调整为已满,将待写入数据写入目标写入片区,检测到需要擦除状态值为已满的片区,擦除状态值为已满的片区中的数据的方法。由此,可减少Flash存储器的擦除次数,延长Flash存储器的使用寿命。
本公开附加的方面和优点将在下面的描述中部分给出,部分将从下面的描述中变得明显,或通过本公开的实践了解到。
附图说明
图1是本公开实施例的Flash存储器数据读写方法的流程图;
图2是本公开的一个示例的擦除状态值为已满片区的流程图;
图3是本公开的一个示例的判断是否擦除已满片区的流程图;
图4是本公开的一个示例的判断当前写入片区的流程图;
图5是本公开的一个实施例的Flash存储器数据写入的流程图;
图6是本公开的一个实施例的Flash存储器数据读取的流程图;
图7是本公开的一个实施例的判断Flash存储器首次使用的流程图;
图8是本公开的一个实施例的Flash初始化的流程图;
图9是本公开的实施例的Flash存储器数据读写方法系统的结构框图。
具体实施方式
下面详细描述本公开的实施例,所述实施例的示例在附图中示出,其中自始至终相同或类似的标号表示相同或类似的元件或具有相同或类似功能的元件。下面通过参考附图描述的实施例是示例性的,旨在用于解释本公开,而不能理解为对本公开的限制。
为了更好地理解上述技术方案,下面将结合说明书附图以及具体的实施方式对上述技术方案进行详细的说明。
在实际应用中,用Flash存储器保存一些参数(N个字节)时,一般都是直接将这N个字节从Flash存储器的首地址开始保存,每次改写也是直接修改这部分内容,那这样参数刷新的次数和Flash存储器擦除的寿命一样。为提高数据刷新次数,本公开采用循环写入的方式以降低擦除的次数。
为方便以下详细阐述,首先对需要写入的每帧数据进行定义,包括:DataID、DataLen、Data1,…,DataN、Checksum和EOP。其中,DataID是数据ID,用来区分不同的参数;DataLen是数据长度,DataN是数据,Checksum是校验和,EOP是结束符。
Flash存储器中每个片区的数据结构包括:SectorLabel、SectorStatus和需要写入的每帧数据(包括ID、Len、Data*Len、Checksum和EOP)。其中,SectorLabel表示片区是否使用标记,也用来区分是否为首次操作Flash存储器;SectorStatus表示片区当前的状态,片区当前状态可包括已满、使用中和空三个状态;Data*Len,即上述的数据Data1-N。
图1是本公开实施例的Flash存储器数据读写方法的流程图。
如图1所示,Flash存储器包含多个片区,Flash存储器的数据读写方法包括:
S101,确定向Flash存储器写入数据,获取当前写入片区。
向Flash存储器写入数据时,因Flash存储器包含多个片区,每一个片区的状态都不同,片区状态分为已满、使用中以及空三个状态,获取的当前写入片区有可能满足待写入数据的存储要求,也有可能不满足待写入数据的存储要求,所以获取到当前写入片区之后需对当前写入片区的存储空间进行检测。若当前写入片区的状态为已满状态,则该当前写入片区不满足待写入数据的存储需求,也就无法写入待写入数据;若当前写入片区的状态为使用中,且剩余空间不足以存储待写入数据,则该当前写入片区也不满足待写入数据的存储需求,也就无法写入待写入数据。
具体地,待写入数据有动态数据和静态数据之分,其可通过数据ID区分;对应地,多个片区也可分为动态片区和静态片区。根据数据的不同类型,可得到的当前写入片区的类型也不相同,不同类型的片区对其进行擦除和写入数据的方式也不同。
作为一个可行的实施方式,如图4所示,获取当前写入片区之后,需要判断待写入数据的类型,从而判断当前写入片区的类型从而执行不同的命令。开始命令后,根据待写入数据的ID判断待写入数据的类型,即判断数据是动态数据还是静态数据。当根据数据类型判断当前写入片区为动态片区时,判断当前写入片区的存储空间是否满足待写入数据的存储需求,当根据数据类型判定当前写入片区为静态片区时,擦除当前写入片区中的数据,并在擦除后将待写入数据写入当前写入片区中。
S102,检测到当前写入片区的存储空间不满足待写入数据的存储要求,根据当前写入片区确定目标写入片区,并将当前写入片区的状态值从使用中调整为已满。
具体地,可通过当前写入地址确定当前写入片区,若当前写入地址指向的当前写入片区没有空间写入数据时,可将当前写入地址(CurWrAddress)指向下一个片区Sector(即目标写入片区),并将当前写入片区的状态值(SectorStatus)从使用中调整为已满(即从ACTIVE调整为FULLED),还可将目标写入片区的状态值调整为使用中,此时的CurWrAddress已经指向了目标写入片区。若目标写入片区有空间写入待写入数据,则将数据写入到目标写入片区。若目标写入片区的空间不足以写入待写入数据,则再次更换写入地址CurWrAddress到下一个写入片区,并标记上一个片区状态值为已满,直至找到满足待写入数据写入需求的写入片区,将该写入片区作为目标写入片区,并将待写入数据写入到目标写入片区。需要说明的是,若每个片区的存储空间相同,则可仅查找一次得到目标写入片区。
S103,将待写入数据写入目标写入片区。
将待写入数据写入到目标写入片区时,检索到的状态值为已满的片区的数量可能较多,若要满足之后的数据写入需求,则需擦除已满的片区,所以将待写入数据写入目标片区后还需检测是否需要擦除状态值为已满的片区。例如,Flash存储器有5个片区,当状态值为已满的片区数量达到3个时,需擦除状态值为已满的片区。需要说明的是,在数据写入时,片区是循环写入的,例如,5个片区分别记为片区1、片区2、片区3、片区4、片区5,当片区1写满时,写片区2;当片区2写满时,写片区3;依此类推,当片区5写满时,写片区1。
具体地,如图3所示,判断是否需要擦除状态值为已满的片区中的数据时,首先统计状态值为已满的片区的数量,判断状态值为已满的片区数量是否达到了预设阈值,若达到了预设阈值则判定需要擦除状态值为已满的片区中的数据,此时可设置拷贝标识CopyFlag为1;若没有达到预设阈值则判定为不需要擦除状态值为已满的片区中的数据,此时拷贝标识CopyFlag可为0。其中,预设阈值小于片区的总数量。随着数据的写入,状态值为已满的片区越来越少,若不及时擦除,再有数据写入时,可能会影响运行效率,所以设定预设阈值,当前数据写入完成,且已满片区的数量达到预设阈值时,擦除已满片区中的数据,这样能够及时擦除片区,提高之后数据的写入效率,且无需每次写入数据时,均进行数据擦除,减少了擦除次数。
S104,检测到需要擦除状态值为已满的片区,擦除状态值为已满的片区中的数据。
当已满片区的数量达到预设阈值时,此时就需要擦除状态值标记为已满的片区,在擦除状态值为已满的片区的数据前,为避免一些重要数据被擦除,还需要判断即将被擦除的片区数据中是否存在需要搬运至目标写入片区的待搬运数据;同时,还可将即将被擦除的片区数据拷贝至其他存储器。
具体地,如图2所示,图2是本公开的一个示例的擦除状态值为已满片区的流程图。
S1041,检测到状态值为已满的片区中存在需要搬运至目标片区的待搬运数据。
若检测到需要擦除状态值为已满的片区中的数据,则再次判断已满的片区中是否存在需要搬运至目标写入片区的待搬运数据,若不存在需要搬运至目标片区中的数据,则执行步骤S1043中擦除状态值为已满的片区数据即可,但若检测到存在需要搬运至目标片区中的数据,则不能简单执行擦除状态值为已满的片区,这样会损失和破坏数据,需执行步骤S1042中将待搬运数据搬运至目标写入片区。
S1042,将待搬运数据搬运至目标写入片区。
将待搬运数据搬运至目标写入片区后,即将被擦除的片区中的数据均为无用数据,这样操作既保护了有用数据,也扩大了存储空间。
S1043,擦除状态值为已满的片区中的数据。
需要说明的是,在擦除状态值为已满的片区后,需将状态值调整为空,以便之后的数据写入。
图5是本公开的一个实施例的Flash存储器数据写入的流程图。
如图5所示,对当前片区写入数据时,首先输入待写入数据的ID、数据长度Len以及缓存器Buff,根据ID属性判断当前写入片区的类型,若为静态片区,则擦除当前固定地址指向的当前写入片区中的数据,并且将数据填充进去(数据格式为数据ID、数据长度Len、数据Data、校验和CheckSum、结束符EOP)。数据填充成功则返回写入成功Success,填充失败则返回写入失败Fail。
若为动态片区,则判断ID是否有效,在ID有效的情况下,从CurWrAddress获得数据的当前写入地址,其次判断当前地址指向的当前写入片区是否有空间写入,若当前写入片区没有空间写入时,将写入地址(CurWrAddress)指向下一个片区(即目标写入片区),将当前的写入片区的状态值(SectorStatus)从使用中调整为已满(即从ACTIVE调整为FULLED),此时的CurWrAddress已经指向了目标写入片区对应的地址。当前写入片区有空间写入时,填充数据格式(数据格式为数据ID、数据长度Len、数据Data、校验和CheckSum、结束符EOP),后判断当前写入片区是否写入成功,若写入成功,则记录当前写入地址CurWrAddress,并将其作为下次的读取地址和写入地址,若当前写入片区写入不成功,则更新写入地址CurWrAddress指向下一次写入地址,作为下一次写入时的当前写入地址,并返回写入失败Fail。
在目标写入片区写入成功时,需要判断已满的片区中是否存在需要搬运至目标写入片区的数据,若存在则需要搬运数据后才能擦除状态值为已满的片区。搬运数据至目标片区后,更新写入地址和读取地址,并在擦除后将片区的状态值调整为空(EMPTY)。若不存在待搬运数据,则直接擦除状态值为已满的片区,并在擦除后将片区的状态值调整为空(EMPTY)),最后返回写入成功Success。
本公开实施例的Flash存储器的数据读写方法,在向Flash存储器写入数据时,通过片区的循环写入,可无需在每次写入前均擦除Flash存储器,从而可减少Flash存储器的擦除次数,提升Flash存储器的使用寿命。
在本公开的一个实施例中,Flash存储器的数据读写方法还包括:确认读取Flash存储器中的数据,获取当前读取片区,对当前读取片区中的数据进行校验;检测到校验通过,将当前读取片区中的数据存入缓存器。
其中,获取当前读取片区,是由当前读取地址得到的,对当前读取片区中的数据进行校验,可包括:检测到当前读取片区为静态片区,对当前读取片区中数据的校验码进行校验;检测到当前读取片区为动态片区,对当前读取片区的ID长度、读取地址,以及当前读取片区中数据的校验码进行校验。
具体地,当前读取片区为静态片区时,对当前读取片区中数据的校验码(如上述的校验和)进行校验;当前读取片区为动态片区时,对当前读取片区的ID长度、读取地址,以及当前读取片区中数据的校验码(如上述的校验和)进行校验,具体可依次校验,在任一个校验不通过时,可结束读取流程。
图6是本公开的一个实施例Flash存储器数据读取的流程图。
具体地,如图6所示,执行开始命令Start,输入数据ID和Buff,Buff为数据缓存器。判断数据ID的属性,若输入的数据ID表示静态数据,则从固定地址指向的当前读取片区中获取数据ID,然后判断数据是否有效。判断当前数据是否有效的方法是对当前读取片区中的数据进行校验,即判断当前读取片区的校验和CheckSum。当校验通过时将当前读取片区中的数据存入缓存器Buff,然后返回读取成功Success,若校验不通过则返回读取失败Fail。
若输入的数据ID表示动态数据,则先判断数据ID长度是否有效,若无效则返回读取失败Fail,若数据ID长度有效,则从ID数据中读取ID数据偏移地址并判断读取的偏移地址是否有效,若读取偏移地址无效则返回读取失败Fail。若读取偏移地址有效则对当前读取片区中数据的校验码进行校验(即判断CheckSum是否有效),若校验码无效即校验不通过则返回读取失败Fail,若校验通过则当前片区读取的数据存入缓存器Buff,后成功返回读取成功Success。
对当前片区的数据读取的流程,因为有之前的数据写入的地址索引操作,所以当前片区的数据读取的操作相对简单,只需要使用校验码来确保数据是否正确,大大提高了Flash的数据读取效率。
在本公开的一个实施例中,Flash存储器的数据读写方法还包括:确定Flash存储器所在系统初始化,获取各片区的标记值和状态值;根据各片区的标记值和状态值,确定当前写入地址和当前读取地址并存储。
具体地,如图7所示,当Flash存储器所在系统初始化时,获取各片区的标记值和状态值,根据各片区的标记值和状态值,确定当前写入地址和当前读取地址,其中,所述标记值包括使用和未使用,所述状态值包括已满、使用中和空。如果Flash存储器是第一次使用,则需要初始化各片区的标签(即标记值),如果Flash存储器已有数据存储,则需要索引到当前写入片区,以及当前写入地址CurWrAddress和最新的ID数据偏移地址(即当前读取地址),并将这些数据存入SRAM(Static Random-Access Memory,静态随机存取存储器),其中,当前读取地址存储在IdOffsetAddr[]中。
根据标记值确定Flash存储器首次使用,则当前写入地址为预设写入地址、所述当前读取地址为预设读取地址,若Flash存储器不是首次使用,则还需根据状态值判断状态值是否正常,若根据状态值确定各片区的状态均正常,则根据状态值索引当前写入片区,并根据当前写入片区确定当前写入地址和当前读取地址,若状态值不正常,即存在异常的片区,则返回执行当前写入地址为预设写入地址、当前读取地址为预设读取地址的步骤。
在本公开的一个实施例中,在将待写入数据写入目标写入片区之后,可更新当前写入地址,以便下次写入时获取当前写入片区。
图8是本公开的一个实施例的Flash存储器初始化的流程图。
具体地,如图8所示,开始命令后,先配置Flash操作时钟然后检查当前写入片区的标记值SectorLabel,标记值有使用和未使用两种。若当前写入片区有标签则表示当前写入片区有数据写入即标记值为使用,若当前写入片区没有标签则表示当前写入片区未使用。当当前写入片区没有标签时,则对各片区的标签进行初始化操作,操作成功则继续对各片区的状态值进行初始化,若操作失败则返回初始化失败Fail,对各片区的状态值进行初始化操作若失败也返回初始化失败Fail。若对各片区的状态值进行初始化操作成功,则初始化当前写入地址(Sector0+4)以及初始化ID数据偏移地址(将偏移地址设为0,即当前读取地址)。
当当前写入片区有标签时,代表当前写入片区已经使用过,也就是存储了数据,此时查找当前各片区时使用状态即状态值SectorStatus,若状态异常则初始化各片区的状态值,后执行和无标签初始化各片区的状态一样的操作,在此不再赘述。若状态正常,则索引当前写入地址并将写入地址存入SRAM和索引当前最新ID数据存放偏移地址(即当前读取地址)并存入SRAM,最后返回初始化成功Success,执行上述操作在使用前将Flash初始化完成以方便后续的数据写入和读取操作。
本公开提出的Flash存储器的数据读写方法,通过循环写入的方式,弥补了每写入一次数据就要擦除一次Flash存储器的缺陷,从而大大地减少了Flash存储器的擦除次数,提高了Flash存储器的使用寿命。
基于上述的Flash存储器的数据读写方法,本公开提出了一种计算机可读存储介质。
在本公开的实施例中,计算机程序被处理器执行时,实现上述实施例的Flash存储器的数据读写方法。
基于上述的Flash存储器数据读取方法,本公开提出了一种电子设备。
在该实施例中,电子设备包括存储器、处理器和存储在存储器上的计算机程序,计算机程序被所述处理器执行时,实现如上述实施例的Flash存储器的数据读写方法。
基于上述的电子设备,本公开还提出了一种Flash存储器的数据读写系统。
如图9所示,Flash存储器的数据读写系统100包括电子设备10和Flash存储器20。
本公开实施例的Flash存储器的数据读写系统以及计算机可读存储介质、电子设备,通过上述的Flash存储器的数据读写方法,可减少Flash存储器的擦除次数,提高Flash存储器的使用寿命。

Claims (13)

  1. 一种Flash存储器的数据读写方法,其中,所述Flash存储器包括多个片区,所述方法包括:
    确定向所述Flash存储器写入数据,获取当前写入片区;
    检测到所述当前写入片区的存储空间不满足待写入数据的存储需求,根据所述当前写入片区确定目标写入片区,并将所述当前写入片区的状态值从使用中调整为已满;
    将所述待写入数据写入所述目标写入片区;
    检测到需要擦除状态值为已满的片区,擦除状态值为已满的片区中的数据。
  2. 根据权利要求1所述的Flash存储器的数据读写方法,其中,在擦除状态值为已满的片区中的数据之前,所述方法还包括:
    检测到状态值为已满的片区中存在需要搬运至所述目标写入片区的待搬运数据,将所述待搬运数据搬运至所述目标写入片区。
  3. 根据权利要求1或2所述的Flash存储器的数据读写方法,其中,所述确定需要擦除状态值为已满的片区中的数据,包括:
    统计状态值为已满的片区的数量;
    检测到所述数量达到预设阈值,确定需要擦除状态值为已满的片区中的数据。
  4. 根据权利要求1-3中任一项所述的Flash存储器的数据读写方法,其中,所述多个片区包括静态片区和动态片区,所述方法还包括:
    检测到所述当前写入片区为动态片区,执行对所述当前写入片区的存储空间进行检测的步骤;
    检测到所述当前写入片区为静态片区,擦除所述当前写入片区中的数据,并在擦除后将所述待写入数据写入所述当前写入片区。
  5. 根据权利要求4所述的Flash存储器的数据读写方法,其中,所述方法还包括:
    确定读取所述Flash存储器中的数据,获取当前读取片区;
    对所述当前读取片区中的数据进行校验;
    检测到校验通过,将所述当前读取片区中的数据存入缓存器。
  6. 根据权利要求5所述的Flash存储器的数据读写方法,其中,所述对所述当前读取片区中的数据进行校验,包括:
    检测到所述当前读取片区为静态片区,对所述当前读取片区中数据的校验码进行校验;
    检测到所述当前读取片区为动态片区,对所述当前读取片区的ID长度、读取地址,以及所述当前读取片区中数据的校验码进行校验。
  7. 根据权利要求5或6所述的Flash存储器的数据读写方法,其中,所述方法还包括:
    确定所述Flash存储器所在系统初始化,获取各所述片区的标记值和状态值;
    根据各所述片区的标记值和状态值,确定当前写入地址和当前读取地址并存储。
  8. 根据权利要求7所述的Flash存储器的数据读写方法,其中,所述根据各所述片区的标记值和状态值,确定所述当前写入地址和所述当前读取地址,包括:
    根据所述标记值确定所述Flash存储器首次使用,得到所述当前写入地址为预设写入地址、所述当前读取地址为预设读取地址;
    根据所述标记值确定所述Flash存储器非首次使用,且根据所述状态值确定各所述片区的状态均正常,根据所述状态值索引当前写入片区,并根据所述当前写入片区确定所述当前写入地址和所述当前读取地址;
    根据所述标记值确定所述Flash存储器非首次使用,且根据所述状态值确定存在状态异常的片区,得到所述当前写入地址为预设写入地址、所述当前读取地址为预设读取地址。
  9. 根据权利要求7或8所述的Flash存储器的数据读写方法,其中,
    所述获取当前写入片区,包括:
    根据所述当前写入地址得到所述当前写入片区;
    所述获取当前读取片区,包括:
    根据所述当前读取地址得到所述当前读取片区。
  10. 根据权利要求7-9中任一项所述的Flash存储器的数据读写方法,其中,所述将所述待写入数据写入所述目标写入片区之后,所述方法还包括:
    更新所述当前写入地址和所述当前读取地址。
  11. 一种计算机可读存储介质,其上存储有计算机程序,其中,所述计算机程序被处理器执行时,实现如权利要求1-10中任一项所述的Flash存储器的数据读写方法。
  12. 一种电子设备,包括存储器、处理器和存储在所述存储器上的计算机程序,其中,所述计算机程序被所述处理器执行时,实现如权利要求1-10中任一项所述的Flash存储器的数据读写方法。
  13. 一种Flash存储器的数据读写系统,其中,包括:Flash存储器和如权利要求12所述的电子设备。
PCT/CN2023/075837 2022-03-21 2023-02-14 数据读写方法、系统及介质、设备 WO2023179243A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210283860.5A CN114637469A (zh) 2022-03-21 2022-03-21 Flash存储器的数据读写方法、系统以及介质、设备
CN202210283860.5 2022-03-21

Publications (1)

Publication Number Publication Date
WO2023179243A1 true WO2023179243A1 (zh) 2023-09-28

Family

ID=81950488

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/075837 WO2023179243A1 (zh) 2022-03-21 2023-02-14 数据读写方法、系统及介质、设备

Country Status (2)

Country Link
CN (1) CN114637469A (zh)
WO (1) WO2023179243A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117742588A (zh) * 2023-11-30 2024-03-22 武汉芯必达微电子有限公司 使用Flash模拟EEPROM的数据存储方法及系统

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114637469A (zh) * 2022-03-21 2022-06-17 上海美仁半导体有限公司 Flash存储器的数据读写方法、系统以及介质、设备

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20010024386A1 (en) * 1989-04-13 2001-09-27 Sandisk Corporation Flash EEprom system
JP2010176280A (ja) * 2009-01-28 2010-08-12 Mitsubishi Electric Corp 電子制御装置
CN103268201A (zh) * 2013-04-19 2013-08-28 北京经纬恒润科技有限公司 一种数据存储方法、存储装置及读取方法
CN107608639A (zh) * 2017-10-20 2018-01-19 深圳益邦阳光有限公司 基于闪存的队列式循环存储方法、电子设备和存储介质
CN110764704A (zh) * 2019-10-18 2020-02-07 浙江大华技术股份有限公司 一种环境变量写入方法、存储介质及电子装置
CN112181303A (zh) * 2020-09-29 2021-01-05 广东艾科技术股份有限公司 数据存储方法、装置、计算机设备和存储介质
CN114637469A (zh) * 2022-03-21 2022-06-17 上海美仁半导体有限公司 Flash存储器的数据读写方法、系统以及介质、设备

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20010024386A1 (en) * 1989-04-13 2001-09-27 Sandisk Corporation Flash EEprom system
JP2010176280A (ja) * 2009-01-28 2010-08-12 Mitsubishi Electric Corp 電子制御装置
CN103268201A (zh) * 2013-04-19 2013-08-28 北京经纬恒润科技有限公司 一种数据存储方法、存储装置及读取方法
CN107608639A (zh) * 2017-10-20 2018-01-19 深圳益邦阳光有限公司 基于闪存的队列式循环存储方法、电子设备和存储介质
CN110764704A (zh) * 2019-10-18 2020-02-07 浙江大华技术股份有限公司 一种环境变量写入方法、存储介质及电子装置
CN112181303A (zh) * 2020-09-29 2021-01-05 广东艾科技术股份有限公司 数据存储方法、装置、计算机设备和存储介质
CN114637469A (zh) * 2022-03-21 2022-06-17 上海美仁半导体有限公司 Flash存储器的数据读写方法、系统以及介质、设备

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117742588A (zh) * 2023-11-30 2024-03-22 武汉芯必达微电子有限公司 使用Flash模拟EEPROM的数据存储方法及系统

Also Published As

Publication number Publication date
CN114637469A (zh) 2022-06-17

Similar Documents

Publication Publication Date Title
WO2023179243A1 (zh) 数据读写方法、系统及介质、设备
JP4524309B2 (ja) フラッシュメモリ用のメモリコントローラ
US8683116B2 (en) Controller for one type of NAND flash memory for emulating another type of NAND flash memory
KR101579555B1 (ko) 데이터를 메모리 디바이스로 재-입력하지 않고 페이지들을 재프로그램하기 위한 페이지 버퍼 프로그램 명령 및 방법
CN106598479B (zh) 闪速存储器的故障安全擦除的方法和装置
US9183143B2 (en) Memory device that specifies a size of a segment of write data
KR102641521B1 (ko) 키-밸류 스토리지 장치 및 이의 동작 방법
US20070214309A1 (en) Nonvolatile storage device and data writing method thereof
JP5142685B2 (ja) メモリシステム
KR100816761B1 (ko) 낸드 플래시 메모리 및 에스램/노어 플래시 메모리를포함하는 메모리 카드 및 그것의 데이터 저장 방법
TWI479492B (zh) 記憶體儲存裝置、其記憶體控制器與資料寫入方法
US10613943B2 (en) Method and system for improving open block data reliability
CN112596681B (zh) 一种重读命令处理方法、闪存控制器及固态硬盘
US7773417B2 (en) Semiconductor memory device with memory cell having charge accumulation layer and control gate and memory system
WO2023241160A1 (zh) 基于模拟eeprom的数据写入及管理方法
CN112925481A (zh) 存储器管理方法、存储器存储装置及存储器控制电路单元
WO2019001296A1 (zh) 一种存储记录方法及装置
CN112835536A (zh) 存储器控制方法、存储器存储装置及存储器控制电路单元
CN112988076A (zh) 快闪存储器控制方法、存储装置及控制器
US6898680B2 (en) Minimization of overhead of non-volatile memory operation
JP7291640B2 (ja) 半導体記憶装置及び半導体記憶装置のリフレッシュ方法
TWI826161B (zh) 記憶體管理方法、記憶體儲存裝置及記憶體控制電路單元
JP4245594B2 (ja) メモリコントローラ及びフラッシュメモリシステム
CN115857808A (zh) 存储器管理方法、存储器存储装置及存储器控制电路单元
CN114203239A (zh) 存储器管理方法、存储器存储装置及存储器控制电路单元

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23773494

Country of ref document: EP

Kind code of ref document: A1