CN112347002B - flash data storage method, system, computer equipment and storage medium - Google Patents

flash data storage method, system, computer equipment and storage medium Download PDF

Info

Publication number
CN112347002B
CN112347002B CN202011268987.7A CN202011268987A CN112347002B CN 112347002 B CN112347002 B CN 112347002B CN 202011268987 A CN202011268987 A CN 202011268987A CN 112347002 B CN112347002 B CN 112347002B
Authority
CN
China
Prior art keywords
data
group
sector
last
writing
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN202011268987.7A
Other languages
Chinese (zh)
Other versions
CN112347002A (en
Inventor
方利红
柳振强
包建意
陈波
徐韡
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou Xinjushi Artificial Intelligence Technology Co ltd
Original Assignee
Hangzhou Xinjushi Artificial Intelligence Technology Co ltd
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 Hangzhou Xinjushi Artificial Intelligence Technology Co ltd filed Critical Hangzhou Xinjushi Artificial Intelligence Technology Co ltd
Priority to CN202011268987.7A priority Critical patent/CN112347002B/en
Publication of CN112347002A publication Critical patent/CN112347002A/en
Application granted granted Critical
Publication of CN112347002B publication Critical patent/CN112347002B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • G06F12/0238Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory
    • G06F12/0246Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory in block erasable memory, e.g. flash memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1032Reliability improvement, data loss prevention, degraded operation etc
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The application relates to a flash data storage method, a flash data storage device, computer equipment and a storage medium. Wherein the method comprises the following steps: configuring A, B two sectors, dividing each sector into n groups; reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors; judging an invalid sector by combining the valid mark value of the specific group, and erasing the data of the invalid sector; new data is written by the next set of locations of the last data record. According to the technical scheme, the positions of last data records are searched through the effective mark values of each group, invalid sectors in the two sectors are judged, the data of the invalid sectors are deleted before the data are written, meanwhile, the data are written from the next group of last data record positions, the effective writing address is improved, the sector erasing operation is reduced, and the timeliness is improved.

Description

flash data storage method, system, computer equipment and storage medium
Technical Field
The present invention relates to the field of depth cameras, and in particular, to a method, a system, a computer device, and a storage medium for storing flash data.
Background
In the current computer system, a plurality of flash chips are mounted so as to achieve the effect of permanently storing more data, which is not the case. The larger the capacity of the memory chip is, the more data the memory chip stores is, so how to efficiently and safely read and write the flash chip is important. In addition, the smaller the embedded equipment is, the more difficult the embedded equipment is to be implanted into a UPS power supply system, and at the moment, the abnormal power failure processing of the flash chip is also worth focusing.
In the current flash data writing process, the method generally comprises two steps, namely, firstly erasing the sector where the designated address is located, and then writing data on the designated address. When some data needs to be written frequently, the following problems may be caused by this rough operation manner: each time the program is written into the flash, the whole sector is erased before each time the data is written, and when the program needs to write the data into the flash frequently, the erasing process consumes extremely large time, and the timeliness of the program is seriously affected.
Disclosure of Invention
Based on this, it is necessary to provide a method for saving flash data in order to solve the above technical problems.
A flash data storage method comprises the following steps:
configuring A, B two sectors, dividing each sector into n groups;
reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors;
judging an invalid sector by combining the valid mark value of the specific group, and erasing the data of the invalid sector;
new data is written by the next set of locations of the last data record.
In one embodiment, the method further comprises the steps of:
reading the data of the next group according to the position of the last data record;
judging whether the read group of data exists or not;
if the data exists, the last time of the failure of the electrical conduction is represented, the data writing failure is caused, and the last time of the writing failure mark is recorded.
In one embodiment, the searching for the position of the last data record according to the valid flag value of the same set of data in the two sectors specifically includes the following steps:
reading valid flag values of a first group of data of the A sector and the B sector;
the position of the last data record is found according to the valid marker values of the two first sets of data.
In one embodiment, the searching for the position of the last data record according to the valid flag values of the two first sets of data specifically includes the following steps:
The first group of data of the sector A is marked as A1, and the first group of data of the sector B is marked as B1;
reading effective mark values in A1 and B1, wherein the effective mark value of A1 is marked as X, the effective mark value of B1 is marked as Y, and simultaneously, the data are invalid when the value of the effective mark value is 0xFF, and the data are valid when the value of the effective mark value is 0X 7F;
if X, Y is equal to 0xFF, the data representing the sector A and the sector B are invalid, the default data An or Bn is the position of the last data record, the data An or Bn is read when the data is read next time, an is the last group of data of the sector A, and Bn is the last group of data of the sector B;
if X, Y is equal to 0x7F, the valid flag value Z in An must be read again, and if Z is equal to 0xFF, the last data record is at A1; if Z is not equal to 0xFF, the position of the last data record is B1;
if X is equal to 0xFF and Y is equal to 0X7F, reading the last group of data of the B sector forwards, and searching the group data Bt with the first effective mark value of 0X7F as the position of the last data record, wherein Bt is represented as the data of the t group of the B sector;
if X is equal to 0X7F and Y is equal to 0xFF, the last group data of the A sector is read forward, the group data At with the first effective mark value of 0X7F is found and is the position of the last data record, and At is expressed as the data of the t group of the A sector.
In one embodiment, the method for judging the invalid sector in combination with the valid flag value of the specific group, and erasing the data of the invalid sector specifically comprises the following steps:
when X, Y is equal to 0x7F, the valid flag value Z in An is read again, and if Z is equal to 0xFF, all data in the sector B are erased; if Z is not equal to 0xFF, all data in the A sector is erased.
In one embodiment, the method further comprises the steps of:
judging whether the sector erase failure exists in the last power failure or not;
if the position of the last data record is in the sector A, reading the effective mark value of Bn; when the valid flag value of Bn is not equal to 0xFF, then re-erasing the B sector;
if the position of the last data record is in the sector B, reading the effective mark value of An; when the valid flag value of An is not equal to 0xFF, the a sector is re-erased.
In one embodiment, the method further comprises the steps of:
when writing new data, analyzing the value of the last writing failure mark;
if the last write failure flag indicates failure, skipping the group failed in the last write operation;
if the last writing failure mark is characterized as successful, the writing is normally judged.
In one embodiment, if the last write failure flag indicates a failure, the group that failed the last write operation needs to be skipped, which specifically includes the following steps:
If the read group is the last group of the sectors, erasing the data of another sector, and switching to the first group of the just erased sectors for writing when writing, wherein the sectors are fully written after writing is completed and before erasing;
if the read group is the last-to-last group of the sectors, switching to a first group of another sector for writing when writing, and erasing the full sector after writing is completed;
if the read group is any group except the two cases, writing the next group of the read group;
in addition to the above, if the last writing failure flag indicates success, the writing is normally judged, and the method specifically includes the following steps:
if the read group is the last group of the sectors, switching to the first group of the other sector for writing when writing, and erasing the sectors fully written before writing;
if the read group is any group other than the last group, the next group of the read group is written.
A flash data storage system includes:
a configuration module, configured to configure A, B two sectors, and divide each sector into n groups;
the searching module is used for reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors;
The erasing module is used for judging an invalid sector by combining the valid mark value of the specific group and erasing the data of the invalid sector; a kind of electronic device with high-pressure air-conditioning system
And the writing module is used for writing new data by the next group of positions of the last data record.
A computer device comprising a memory and a processor, said memory storing a computer program, characterized in that said processor, when executing said computer program, implements the steps of a method for saving flash data.
A computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of a method of saving flash data.
The method adopts a flash memory space partition management method, in a memory, a storage space required to store specific data is divided into two sectors for management, each sector is divided into groups according to the size of the specific data, and the flash read-write operation is performed by taking the groups as units; during writing operation, the information in the sector is read first, the address written at this time is judged, a specific effective mark value is added to the end of the data during writing, and the specific effective mark value is used for indicating whether the group of data is effective or not, so that the situation that the data is unreliable due to power failure during half of data writing is prevented. And simultaneously, after the writing is finished, immediately reading the written data, comparing the read data with the written data, and if the read data is inconsistent with the written data, carrying out flash life exhaustion early warning.
And an erase sector operation of erasing another sector only when the address of the written data is the first group of the current sector. This avoids the problem of program operation aging, which would be affected by erasing the sector in which the data is located before each write.
During the reading operation, the information of each sector is read first, and the address read at this time is judged. And the read data is identified and judged, so that the true effectiveness of the data is ensured. If not, the last written data may be considered for retrieval.
Drawings
FIG. 1 is an application environment diagram of a method for saving flash data in one embodiment;
FIG. 2 is a flow chart of a method for storing flash data in one embodiment;
FIG. 3 is a block diagram of a flash data storage system in one embodiment;
fig. 4 is an internal structural diagram of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
The flash data storage party can be applied to an application environment shown in fig. 1. Wherein the terminal 102 communicates with the server 104 via a network. The terminal 102 may be, but not limited to, various personal computers, notebook computers, smartphones, tablet computers, etc., and the server 104 may be implemented as a stand-alone server or a server cluster composed of a plurality of servers.
In one embodiment, as shown in fig. 2, a method for storing flash data is provided. The following description will take an example in which the method is applied to the terminal in fig. 1, and the method includes the steps of:
s100, configuring A, B two sectors, and dividing each sector into n groups.
S200, reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors.
S300, judging an invalid sector by combining the valid mark value of the specific group, and erasing the data of the invalid sector;
s400, new data is written by the next group of locations of the last data record.
The specific content of step S100 includes the following steps:
after power-on operation, the initial state of each variable value is set. Two sectors of A, B are configured for storing specific data, the first addresses of the sectors of A, B are respectively effective mark values fvalue2=0x7f, sector marks fsaction=0, group numbers fgroup=0, flash life alarm marks ferror=0, and last write failure marks fw_fail=0 in the sectors of Paddr1, paddr2, A, B. Where fsection=1 is an a sector, fsection=2 is a B sector, fvalue2=0xff indicates that the data is invalid (set to valid by default, that is fvalue2=0x7f).
In another embodiment, the step S100 further includes the following steps:
at the time of configuring the initial state of each variable value, at the same time, one address Paddr0 is configured to store the enable flag value fvalue1=0xaa 55.
After the initial state configuration of each variable value, firstly detecting whether a flash data storage method is started or not, and reading two-byte data from an address Paddr0, and marking the two-byte data as T:
if T is equal to Fvalue1, the method for storing flash data is started, and A, B sectors do not need to be erased;
if T is not equal to Fvalue1, indicating that the flash data storage method is not started, the A, B sector needs to be erased, and Fvalue1 is written in the Paddr0 address.
Each sector is equally divided into n groups, n groups of data of the a sector are A1-An respectively, n groups of data of the B sector are B1-Bn respectively, and the group size is the size of specific data plus one byte (for putting valid flag value), so the above group number fgroup= (1, 2,3 … … n). If the sector space remains less than one set of space after the division, the space is abandoned.
The specific contents of step S200 and step S300 include the following steps:
the position of the last data record can be found according to the effective mark value of the same group of data in the two sectors, and the same group of data can be any one group of data in the sectors, for example, the position of the last data record can be found through the effective mark values of A1 and B1, can also be found through An and Bn, and can also be found through At and Bt (At is the data of the t group in the A sector, bt is the data of the t group in the B sector, and t is any number in 1-n).
In this embodiment, a detailed description will be given by way of examples of A1 and B1:
the method comprises the steps of reading effective marking values in A1 and B1, marking the effective marking value of A1 as X, marking the effective marking value of B1 as Y (X, Y only represents marking values in each group without other specific meanings, and Z is the same as the above), and simultaneously, representing that the group of data is invalid when the value of the effective marking value is 0xFF, and representing that the group of data is valid when the value of the effective marking value is 0X 7F;
if X, Y is equal to 0xFF, the data representing the sector a and the sector B are invalid, the default An or Bn is the position of the last data record, the data of An or Bn is read when the data is read next time, an is the last group of data of the sector a, bn is the last group of data of the sector B, and at this time, the initial variable is set to fsection=1 or fsection=2, and fcroup=n;
if X, Y is equal to 0x7F, the valid flag value Z in An should be read again, if Z is equal to 0xFF, the last data record is at A1, and at the same time, the initial variable fsection=1 is set to erase all data in the B sector; if Z is not equal to 0xFF, the last data record is at B1, and at the same time, the initial variable fsection=2 is set, and all data in the sector a are erased;
if X is equal to 0xff and y is equal to 0X7F, reading the last group of data of the B sector forward, searching the group data Bt with the first effective mark value of 0X7F as the position of the last data record, wherein Bt is represented as the data of the t group of the B sector, and setting an initial variable fsection=2 and fgroup=t at the moment;
If X is equal to 0X7F and y is equal to 0xFF, the last group of data of the a sector is read forward, the first group of data At with the effective mark value of 0X7F is found, that is, the position of the last data record, at is represented as the data of the t group of the a sector, and At this time, the initial variable fsection=1 and fgroup=t are set.
In consideration of the accuracy of the special case influencing method, therefore, the judgment S500 is made as to whether there is an erase sector failure in the last power down, and the step S500 specifically includes the following steps:
if the position of the last data record is in the sector a (fsection=1), reading the valid flag value of Bn; when the valid flag value of Bn is not equal to 0xFF, then re-erasing the B sector;
if the position of the last data record is in the sector B (fsection=2), reading the valid mark value of An; when the valid flag value of An is not equal to 0xFF, the a sector is re-erased.
In another embodiment, before writing new data, a power-down writing judging step S600 is performed, and the step S600 specifically includes the following steps:
reading the data of the next group according to the position of the last data record;
judging whether the read group of data has invalid data or not;
if invalid data exists (i.e. there is data not equal to 0 xFF), the last-time power-down-induced data writing failure is characterized, and the last-time writing failure mark is recorded, and at this time, the last-time writing failure mark fw_fail=1 is set.
In the above process, the data of the next group of operation addresses is read, and the operation address calculation formula is as follows:
if fsection=1, operation address=padd1+ (Fgroup-1) (data size+1);
if fsection=2, the operation address=padd2+ (Fgroup-1) ×1.
The specific content of step S400 includes the following steps:
when writing new data, analyzing the value of the last writing failure mark;
if the last write failure flag is characterized as failed (fw_fail=1), the group failed by the last write operation is skipped;
if the last write failure flag is characterized as successful (fw_fail=0), the write is normally judged.
If fw_fail=1, the method specifically includes the following steps:
if the read group is the last group of sectors (i.e. fgroup=n, which indicates that the last writing of group 1 of another sector fails), then erasing the data of another sector, when new data is written, switching to the first group of the just erased sectors for writing, after writing, setting the last writing failure mark fw_fail=0, simultaneously, after writing, comparing the read and written data with target data, if not, setting the flash life alarm mark ferror=1;
If the read group is the last-to-last group of sectors (i.e. fgroup+1=n, which indicates that the last group of sectors fails in writing), when new data is written, switching to the first group of another sector for writing, after writing, erasing the previously written sectors, placing a last writing failure mark fw_fail=0, simultaneously, after writing, comparing the read and written data with target data, and if the read and written data are inconsistent, placing a flash life alarm mark Ferror=1;
if the read group is any group (i.e., fgroup+ 1<n) other than the above two cases, new data is written into the next group (i.e., fgroup=fgroup+1) of the read group, and at the same time, after the writing is completed, the last write failure flag fw_fail=0 is set. Then, the read-in data are compared with target data, if the read-in data are inconsistent with the target data, a flash life alarm mark Ferror=1 is set;
if fw_fail=0, the method specifically includes the following steps:
if the read group is the last group of the sectors (i.e. Fgroup=n), switching to the first group of the other sector for writing when writing, and erasing the sector fully written before writing, and simultaneously, comparing the read and written data with the target data after writing, if the read and written data are inconsistent, setting a flash life alarm mark Ferror=1;
If the read group is not any group of the last group (namely Fgroup < n), writing the next group of the read group, and simultaneously, after the writing is completed, comparing the read and written data with target data, and if the read and written data are inconsistent, setting a flash life alarm mark Ferror=1.
Because the flash life alarm mark Ferror exists during data writing, the flash data storage method can perform early warning, and the read data is prevented from being unreliable and influencing the normal operation of the flash data.
In another embodiment, the method for saving flash data of the present invention further includes the following steps:
in the reading operation, whether the last data read is the data which is successfully written or the last data which is failed to be written can be determined according to the value of Fw_fail and the operation addresses represented by Fselect and Fgroup.
According to the flash data storage method, the problem that flash is damaged too early due to the fact that the flash is written frequently at a fixed address each time is solved through the partition grouping storage, the service life of the flash is prolonged, and meanwhile, historical written data can be queried; the strategy that the erasing operation is performed only when the sector is full is adopted, so that the problem that the whole sector needs to be erased before data is written each time, which results in more time consumption, is solved, and the operation timeliness is optimized; by comparing the effective mark values, the problem that the data is unreal and the normal operation of the data is influenced when the power is turned on next time in the process of data writing is solved;
In one embodiment, as shown in fig. 3, a flash data storage system further includes a configuration module 1, a search module 2, an erasing module 3, and a writing module 4. Configuration module 1 is configured to configure A, B two sectors, each of which is divided into n groups; the searching module 2 is used for reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors; the erasing module 3 is used for judging an invalid sector in combination with the valid mark value of the specific group and erasing the data of the invalid sector; the writing module 4 is used for writing new data by the next group of locations of the last data record.
For specific limitation of the above-mentioned flash data storage system, reference may be made to the limitation of the flash data storage method, which is not described herein. Each of the modules in the above-described apparatus may be implemented in whole or in part by software, hardware, and combinations thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a server, the internal structure of which may be as shown in fig. 4. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database of the computer equipment is used for storing the data of the human face living body detection method based on the infrared image. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program, when executed by a processor, implements a face in-vivo detection method based on infrared images.
Those skilled in the art will appreciate that the structures shown in FIG. 4 are block diagrams only and do not constitute a limitation of the computer device on which the present aspects apply, and that a particular computer device may include more or less components than those shown, or may combine some of the components, or have a different arrangement of components.
In one embodiment, a computer device is provided comprising a memory storing a computer program and a processor that when executing the computer program performs the steps of:
s100, configuring A, B two sectors, and dividing each sector into n groups.
S200, reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors.
S300, judging the invalid sector by combining the valid mark value of the specific group, and erasing the data of the invalid sector.
S400, new data is written by the next group of locations of the last data record.
The specific content of step S100 includes the following steps:
after power-on operation, the initial state of each variable value is set. Two sectors of A, B are configured for storing specific data, the first addresses of the sectors of A, B are respectively effective mark values fvalue2=0x7f, sector marks fsaction=0, group numbers fgroup=0, flash life alarm marks ferror=0, and last write failure marks fw_fail=0 in the sectors of Paddr1, paddr2, A, B. Where fsection=1 is an a sector, fsection=2 is a B sector, fvalue2=0xff indicates that the data is invalid (set to valid by default, that is fvalue2=0x7f).
In another embodiment, the step S100 further includes the following steps:
at the time of configuring the initial state of each variable value, at the same time, one address Paddr0 is configured to store the enable flag value fvalue1=0xaa 55.
After the initial state configuration of each variable value, firstly detecting whether a flash data storage method is started or not, and reading two-byte data from an address Paddr0, and marking the two-byte data as T:
if T is equal to Fvalue1, the method for storing flash data is started, and A, B sectors do not need to be erased;
if T is not equal to Fvalue1, indicating that the flash data storage method is not started, the A, B sector needs to be erased, and Fvalue1 is written in the Paddr0 address.
Each sector is equally divided into n groups, n groups of data of the a sector are A1-An respectively, n groups of data of the B sector are B1-Bn respectively, and the group size is the size of specific data plus one byte (for putting valid flag value), so the above group number fgroup= (1, 2,3 … … n). If the sector space remains less than one set of space after the division, the space is abandoned.
The specific contents of step S200 and step S300 include the following steps:
the position of the last data record can be found according to the effective mark value of the same group of data in the two sectors, and the same group of data can be any one group of data in the sectors, for example, the position of the last data record can be found through the effective mark values of A1 and B1, can also be found through An and Bn, and can also be found through At and Bt (At is the data of the t group in the A sector, bt is the data of the t group in the B sector, and t is any number in 1-n).
In this embodiment, a detailed description will be given by way of examples of A1 and B1:
the method is divided into reading effective mark values in A1 and B1, wherein the effective mark value of A1 is marked as X, the effective mark value of B1 is marked as Y (X, Y only represents mark values in each group and has no other specific meaning, and the following Z is the same as the above): meanwhile, the data are invalid when the value of the effective mark value is 0xFF, and the data are valid when the value of the effective mark value is 0x 7F;
if X, Y is equal to 0xFF, the data representing the sector a and the sector B are invalid, the default An or Bn is the position of the last data record, the data of An or Bn is read when the data is read next time, an is the last group of data of the sector a, bn is the last group of data of the sector B, and at this time, the initial variable is set to fsection=1 or fsection=2, and fcroup=n;
if X, Y is equal to 0x7F, the valid flag value Z in An should be read again, if Z is equal to 0xFF, the last data record is at A1, and at the same time, the initial variable fsection=1 is set to erase all data in the B sector; if Z is not equal to 0xFF, the last data record is at B1, and at the same time, the initial variable fsection=2 is set, and all data in the sector a are erased;
if X is equal to 0xff and y is equal to 0X7F, reading the last group of data of the B sector forward, searching the group data Bt with the first effective mark value of 0X7F as the position of the last data record, wherein Bt is represented as the data of the t group of the B sector, and setting an initial variable fsection=2 and fgroup=t at the moment;
If X is equal to 0X7F and y is equal to 0xFF, the last group of data of the a sector is read forward, the first group of data At with the effective mark value of 0X7F is found, that is, the position of the last data record, at is represented as the data of the t group of the a sector, and At this time, the initial variable fsection=1 and fgroup=t are set.
In consideration of the accuracy of the special case influencing method, therefore, the judgment S500 is made as to whether there is an erase sector failure in the last power down, and the step S500 specifically includes the following steps:
if the position of the last data record is in the sector a (fsection=1), reading the valid flag value of Bn; when the valid flag value of Bn is not equal to 0xFF, then re-erasing the B sector;
if the position of the last data record is in the sector B (fsection=2), reading the valid mark value of An; when the valid flag value of An is not equal to 0xFF, the a sector is re-erased.
In another embodiment, before writing new data, a power-down writing judging step S600 is performed, and the step S600 specifically includes the following steps:
reading the data of the next group according to the position of the last data record;
judging whether the read group of data has invalid data or not;
if invalid data exists (i.e. there is data not equal to 0 xFF), the last-time power-down-induced data writing failure is characterized, and the last-time writing failure mark is recorded, and at this time, the last-time writing failure mark fw_fail=1 is set.
In the above process, the data of the next group of operation addresses is read, and the operation address calculation formula is as follows:
if fsection=1, operation address=padd1+ (Fgroup-1) (data size+1);
if fsection=2, the operation address=padd2+ (Fgroup-1) ×1.
The specific content of step S400 includes the following steps:
when writing new data, analyzing the value of the last writing failure mark;
if the last write failure flag is characterized as failed (fw_fail=1), the group failed by the last write operation is skipped;
if the last write failure flag is characterized as successful (fw_fail=0), the write is normally judged.
If fw_fail=1, the method specifically includes the following steps:
if the read group is the last group of sectors (i.e. fgroup=n, which indicates that the last writing of group 1 of another sector fails), then erasing the data of another sector, when new data is written, switching to the first group of the just erased sectors for writing, after writing, setting the last writing failure mark fw_fail=0, simultaneously, after writing, comparing the read and written data with target data, if not, setting the flash life alarm mark ferror=1;
If the read group is the last-to-last group of sectors (i.e. fgroup+1=n, which indicates that the last group of sectors fails in writing), when new data is written, switching to the first group of another sector for writing, after writing, erasing the sector full before writing, placing a last writing failure mark fw_fail=0, simultaneously, after writing, comparing the read and written data with target data, and if the read and written data are inconsistent, placing a flash life alarm mark Ferror=1;
if the read group is any group (i.e., fgroup+ 1<n) other than the above two cases, new data is written into the next group (i.e., fgroup=fgroup+1) of the read group, and at the same time, after the writing is completed, the last write failure flag fw_fail=0 is set. Then, the read-in data is compared with the target data, if the read-in data is inconsistent with the target data, a flash life alarm mark Ferror=1 and a last write failure mark Fw_fail=0 are set;
if fw_fail=0, the method specifically includes the following steps:
if the read group is the last group of the sectors (i.e. Fgroup=n), switching to the first group of the other sector for writing when writing, and erasing the sector fully written before writing, and simultaneously, comparing the read and written data with the target data after writing, if the read and written data are inconsistent, setting a flash life alarm mark Ferror=1;
If the read group is not any group of the last group (namely Fgroup < n), writing the next group of the read group, and simultaneously, after the writing is completed, comparing the read and written data with target data, and if the read and written data are inconsistent, setting a flash life alarm mark Ferror=1.
Because the flash life alarm mark Ferror exists during data writing, the flash data storage method can perform early warning, and the read data is prevented from being unreliable and influencing the normal operation of the flash data.
In another embodiment, the method for saving flash data of the present invention further includes the following steps:
in the reading operation, whether the last data read is the data which is successfully written or the last data which is failed to be written can be determined according to the value of Fw_fail and the operation addresses represented by Fselect and Fgroup.
In one embodiment, a computer readable storage medium is provided having a computer program stored thereon, which when executed by a processor, performs the steps of:
s100, configuring A, B two sectors, and dividing each sector into n groups.
S200, reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors.
S300, judging the invalid sector by combining the valid mark value of the specific group, and erasing the data of the invalid sector.
S400, new data is written by the next group of locations of the last data record.
The specific content of step S100 includes the following steps:
after power-on operation, the initial state of each variable value is set. Two sectors of A, B are configured for storing specific data, the first addresses of the sectors of A, B are respectively effective mark values fvalue2=0x7f, sector marks fsaction=0, group numbers fgroup=0, flash life alarm marks ferror=0, and last write failure marks fw_fail=0 in the sectors of Paddr1, paddr2, A, B. Where fsection=1 is an a sector, fsection=2 is a B sector, fvalue2=0xff indicates that the data is invalid (set to valid by default, that is fvalue2=0x7f).
In another embodiment, the step S100 further includes the following steps:
at the time of configuring the initial state of each variable value, at the same time, one address Paddr0 is configured to store the enable flag value fvalue1=0xaa 55.
After the initial state configuration of each variable value, firstly detecting whether a flash data storage method is started or not, and reading two-byte data from an address Paddr0, and marking the two-byte data as T:
if T is equal to Fvalue1, the method for storing flash data is started, and A, B sectors do not need to be erased;
If T is not equal to Fvalue1, indicating that the flash data storage method is not started, the A, B sector needs to be erased, and Fvalue1 is written in the Paddr0 address.
Each sector is equally divided into n groups, n groups of data of the a sector are A1-An respectively, n groups of data of the B sector are B1-Bn respectively, and the group size is the size of specific data plus one byte (for putting valid flag value), so the above group number fgroup= (1, 2,3 … … n). If the sector space remains less than one set of space after the division, the space is abandoned.
The specific contents of step S200 and step S300 include the following steps:
the position of the last data record can be found according to the effective mark value of the same group of data in the two sectors, and the same group of data can be any one group of data in the sectors, for example, the position of the last data record can be found through the effective mark values of A1 and B1, can also be found through An and Bn, and can also be found through At and Bt (At is the data of the t group in the A sector, bt is the data of the t group in the B sector, and t is any number in 1-n).
In this embodiment, a detailed description will be given by way of examples of A1 and B1:
the method is divided into reading effective mark values in A1 and B1, wherein the effective mark value of A1 is marked as X, the effective mark value of B1 is marked as Y (X, Y only represents mark values in each group and has no other specific meaning, and the following Z is the same as the above): meanwhile, the data are invalid when the value of the effective mark value is 0xFF, and the data are valid when the value of the effective mark value is 0x 7F;
If X, Y is equal to 0xFF, the data representing the sector a and the sector B are invalid, the default An or Bn is the position of the last data record, the data of An or Bn is read when the data is read next time, an is the last group of data of the sector a, bn is the last group of data of the sector B, and at this time, the initial variable is set to fsection=1 or fsection=2, and fcroup=n;
if X, Y is equal to 0x7F, the valid flag value Z in An should be read again, if Z is equal to 0xFF, the last data record is at A1, and at the same time, the initial variable fsection=1 is set to erase all data in the B sector; if Z is not equal to 0xFF, the last data record is at B1, and at the same time, the initial variable fsection=2 is set, and all data in the sector a are erased;
if X is equal to 0xff and y is equal to 0X7F, reading the last group of data of the B sector forward, searching the group data Bt with the first effective mark value of 0X7F as the position of the last data record, wherein Bt is represented as the data of the t group of the B sector, and setting an initial variable fsection=2 and fgroup=t at the moment;
if X is equal to 0X7F and y is equal to 0xFF, the last group of data of the a sector is read forward, the first group of data At with the effective mark value of 0X7F is found, that is, the position of the last data record, at is represented as the data of the t group of the a sector, and At this time, the initial variable fsection=1 and fgroup=t are set.
In consideration of the accuracy of the special case influencing method, therefore, the judgment S500 is made as to whether there is an erase sector failure in the last power down, and the step S500 specifically includes the following steps:
if the position of the last data record is in the sector a (fsection=1), reading the valid flag value of Bn; when the valid flag value of Bn is not equal to 0xFF, then re-erasing the B sector;
if the position of the last data record is in the sector B (fsection=2), reading the valid mark value of An; when the valid flag value of An is not equal to 0xFF, the a sector is re-erased.
In another embodiment, before writing new data, a power-down writing judging step S600 is performed, and the step S600 specifically includes the following steps:
reading the data of the next group according to the position of the last data record;
judging whether the read group of data has invalid data or not;
if invalid data exists (i.e. there is data not equal to 0 xFF), the last-time power-down-induced data writing failure is characterized, and the last-time writing failure mark is recorded, and at this time, the last-time writing failure mark fw_fail=1 is set.
In the above process, the data of the next group of operation addresses is read, and the operation address calculation formula is as follows:
if fsection=1, operation address=padd1+ (Fgroup-1) (data size+1);
If fsection=2, the operation address=padd2+ (Fgroup-1) ×1.
The specific content of step S400 includes the following steps:
when writing new data, analyzing the value of the last writing failure mark;
if the last write failure flag is characterized as failed (fw_fail=1), the group failed by the last write operation is skipped;
if the last write failure flag is characterized as successful (fw_fail=0), the write is normally judged.
If fw_fail=1, the method specifically includes the following steps:
if the read group is the last group of sectors (i.e. fgroup=n, which indicates that the last writing of group 1 of another sector fails), then erasing the data of another sector, when new data is written, switching to the first group of the just erased sectors for writing, after writing, setting the last writing failure mark fw_fail=0, simultaneously, after writing, comparing the read and written data with target data, if not, setting the flash life alarm mark ferror=1;
if the read group is the last-to-last group of sectors (i.e. fgroup+1=n, which indicates that the last group of sectors fails in writing), when new data is written, switching to the first group of another sector for writing, after writing, erasing the sector full before writing, placing a last writing failure mark fw_fail=0, simultaneously, after writing, comparing the read and written data with target data, and if the read and written data are inconsistent, placing a flash life alarm mark Ferror=1;
If the read group is any group (i.e., fgroup+ 1<n) other than the above two cases, new data is written into the next group (i.e., fgroup=fgroup+1) of the read group, and at the same time, after the writing is completed, the last write failure flag fw_fail=0 is set. Then, the read-in data are compared with target data, if the read-in data are inconsistent with the target data, a flash life alarm mark Ferror=1 is set;
if fw_fail=0, the method specifically includes the following steps:
if the read group is the last group of the sectors (i.e. Fgroup=n), switching to the first group of the other sector for writing when writing, and erasing the sector fully written before writing, and simultaneously, comparing the read and written data with the target data after writing, if the read and written data are inconsistent, setting a flash life alarm mark Ferror=1;
if the read group is not any group of the last group (namely Fgroup < n), writing the next group of the read group, and simultaneously, after the writing is completed, comparing the read and written data with target data, and if the read and written data are inconsistent, setting a flash life alarm mark Ferror=1.
Because the flash life alarm mark Ferror exists during data writing, the flash data storage method can perform early warning, and the read data is prevented from being unreliable and influencing the normal operation of the flash data.
In another embodiment, the method for saving flash data of the present invention further includes the following steps:
in the reading operation, whether the last data read is the data which is successfully written or the last data which is failed to be written can be determined according to the value of Fw_fail and the operation addresses represented by Fselect and Fgroup.
The invention adopts a flash memory space partition management method, in a memory, a storage space required to store specific data is divided into two sectors for management, each sector is divided into groups according to the size of the specific data, and the flash read-write operation is performed by taking the groups as units; during writing operation, the information in the sector is read first, the address written at this time is judged, a specific effective mark value is added to the end of the data during writing, and the specific effective mark value is used for indicating whether the group of data is effective or not, so that the situation that the data is unreliable due to power failure during half of data writing is prevented. And simultaneously, after the writing is finished, immediately reading the written data, comparing the read data with the written data, and if the read data is inconsistent with the written data, carrying out flash life exhaustion early warning.
And an erase sector operation of erasing another sector only when the address of the written data is the first group of the current sector. This avoids the problem of program operation aging, which would be affected by erasing the sector in which the data is located before each write.
During the reading operation, the information of each sector is read first, and the address read at this time is judged. And the read data is identified and judged, so that the true effectiveness of the data is ensured. If not, the last written data may be considered for retrieval.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the various embodiments provided herein may include non-volatile and/or volatile memory. The nonvolatile memory can include Read Only Memory (ROM), programmable ROM (PROM), electrically Programmable ROM (EPROM), electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double Data Rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous Link DRAM (SLDRAM), memory bus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), among others.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples merely represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the invention. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application is to be determined by the claims appended hereto.

Claims (9)

1. The flash data storage method is characterized by comprising the following steps of:
configuring A, B two sectors, dividing each sector into n groups;
reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors;
judging an invalid sector by combining the valid mark value of the specific group, and erasing the data of the invalid sector;
New data is written by the next group of locations of the last data record;
the method for searching the position of the last data record according to the valid mark value of the same group of data in two sectors specifically comprises the following steps:
reading valid flag values of a first group of data of the A sector and the B sector;
searching the position of the last data record according to the effective mark values of the two first groups of data;
the first group of data of the sector A is marked as A1, and the first group of data of the sector B is marked as B1;
reading effective mark values in A1 and B1, wherein the effective mark value of A1 is marked as X, the effective mark value of B1 is marked as Y, and simultaneously, the data are invalid when the value of the effective mark value is 0xFF, and the data are valid when the value of the effective mark value is 0X 7F;
if X, Y is equal to 0xFF, the data representing the sector A and the sector B are invalid, the default data An or Bn is the position of the last data record, the data An or Bn is read when the data is read next time, an is the last group of data of the sector A, and Bn is the last group of data of the sector B;
if X, Y is equal to 0x7F, the valid flag value Z in An must be read again, and if Z is equal to 0xFF, the last data record is at A1; if Z is not equal to 0xFF, the position of the last data record is B1;
If X is equal to 0xFF and Y is equal to 0X7F, reading the last group of data of the B sector forwards, and searching the group data Bt with the first effective mark value of 0X7F as the position of the last data record, wherein Bt is represented as the data of the t group of the B sector;
if X is equal to 0X7F and Y is equal to 0xFF, the last group data of the A sector is read forward, the group data At with the first effective mark value of 0X7F is found and is the position of the last data record, and At is expressed as the data of the t group of the A sector.
2. The method for saving flash data according to claim 1, further comprising the steps of:
reading the data of the next group according to the position of the last data record;
judging whether the read group of data exists or not;
if the data exists, the last time of the failure of the electrical conduction is represented, the data writing failure is caused, and the last time of the writing failure mark is recorded.
3. The method for storing flash data according to claim 1, wherein said judging the invalid sector by combining the valid flag value of the specific group, and erasing the data of the invalid sector, comprises the steps of:
when X, Y is equal to 0x7F, the valid flag value Z in An is read again, and if Z is equal to 0xFF, all data in the sector B are erased; if Z is not equal to 0xFF, all data in the A sector is erased.
4. A method for saving flash data according to claim 1 or 3, further comprising the steps of:
judging whether the sector erase failure exists in the last power failure or not;
if the position of the last data record is in the sector A, reading the effective mark value of Bn; when the valid flag value of Bn is not equal to 0xFF, then re-erasing the B sector;
if the position of the last data record is in the sector B, reading the effective mark value of An; when the valid flag value of An is not equal to 0xFF, the a sector is re-erased.
5. The method for saving flash data according to claim 2, further comprising the steps of:
when writing new data, analyzing the value of the last writing failure mark;
if the last write failure flag indicates failure, skipping the group failed in the last write operation;
if the last writing failure mark is characterized as successful, the writing is normally judged.
6. The method for saving flash data according to claim 5, wherein if the last write failure flag indicates failure, the group failed in the last write operation is skipped, comprising the steps of:
if the read group is the last group of the sectors, erasing the data of another sector, and switching to the first group of the just erased sectors for writing when writing, wherein the sectors are fully written after writing is completed and before erasing;
If the read group is the last-to-last group of the sectors, switching to a first group of another sector for writing when writing, and erasing the full sector after writing is completed;
if the read group is any group except the two cases, writing the next group of the read group;
in addition to the above, if the last writing failure flag indicates success, the writing is normally judged, and the method specifically includes the following steps:
if the read group is the last group of the sectors, switching to the first group of the other sector for writing when writing, and erasing the sectors fully written before writing;
if the read group is any group other than the last group, the next group of the read group is written.
7. A flash data storage system, comprising:
a configuration module, configured to configure A, B two sectors, and divide each sector into n groups;
the searching module is used for reading the effective mark value of the same group of data in the A sector and the B sector, and searching the position of the last data record according to the effective mark value of the same group of data in the two sectors;
the method for searching the position of the last data record according to the valid mark value of the same group of data in two sectors specifically comprises the following steps:
Reading valid flag values of a first group of data of the A sector and the B sector;
searching the position of the last data record according to the effective mark values of the two first groups of data;
the first group of data of the sector A is marked as A1, and the first group of data of the sector B is marked as B1;
reading effective mark values in A1 and B1, wherein the effective mark value of A1 is marked as X, the effective mark value of B1 is marked as Y, and simultaneously, the data are invalid when the value of the effective mark value is 0xFF, and the data are valid when the value of the effective mark value is 0X 7F;
if X, Y is equal to 0xFF, the data representing the sector A and the sector B are invalid, the default data An or Bn is the position of the last data record, the data An or Bn is read when the data is read next time, an is the last group of data of the sector A, and Bn is the last group of data of the sector B;
if X, Y is equal to 0x7F, the valid flag value Z in An must be read again, and if Z is equal to 0xFF, the last data record is at A1; if Z is not equal to 0xFF, the position of the last data record is B1;
if X is equal to 0xFF and Y is equal to 0X7F, reading the last group of data of the B sector forwards, and searching the group data Bt with the first effective mark value of 0X7F as the position of the last data record, wherein Bt is represented as the data of the t group of the B sector;
If X is equal to 0X7F and Y is equal to 0xFF, reading the last group of data of the sector A forwards, searching the group data At with the first effective mark value of 0X7F as the position of the last data record, wherein At is expressed as the data of the t group of the sector A;
the erasing module is used for judging an invalid sector by combining the valid mark value of the specific group and erasing the data of the invalid sector; a kind of electronic device with high-pressure air-conditioning system
And the writing module is used for writing new data by the next group of positions of the last data record.
8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 6 when the computer program is executed.
9. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
CN202011268987.7A 2020-11-13 2020-11-13 flash data storage method, system, computer equipment and storage medium Active CN112347002B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011268987.7A CN112347002B (en) 2020-11-13 2020-11-13 flash data storage method, system, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011268987.7A CN112347002B (en) 2020-11-13 2020-11-13 flash data storage method, system, computer equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112347002A CN112347002A (en) 2021-02-09
CN112347002B true CN112347002B (en) 2023-07-28

Family

ID=74363648

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011268987.7A Active CN112347002B (en) 2020-11-13 2020-11-13 flash data storage method, system, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112347002B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113220239A (en) * 2021-05-24 2021-08-06 厦门四信通信科技有限公司 Erasing and writing method, device and equipment for flash storage and readable storage medium
CN113656081B (en) * 2021-08-05 2023-08-22 深圳市同泰怡信息技术有限公司 Method, device and computer equipment for synchronizing configuration information of baseboard management controller

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2582487B2 (en) * 1991-07-12 1997-02-19 インターナショナル・ビジネス・マシーンズ・コーポレイション External storage system using semiconductor memory and control method thereof
CN1937077B (en) * 2005-09-22 2011-03-23 康佳集团股份有限公司 Multi-state management method for data in flash-memory medium
JP4910360B2 (en) * 2005-10-20 2012-04-04 ソニー株式会社 Storage device, computer system, and data writing method
JP2010061705A (en) * 2008-09-01 2010-03-18 Toshiba Storage Device Corp Method for controlling storage device, and storage device
EP2413329B1 (en) * 2010-07-28 2014-03-26 Fujitsu Semiconductor Europe GmbH Electronic apparatuses
CN102890656B (en) * 2012-09-25 2016-09-28 Tcl光电科技(惠州)有限公司 The method improving FLASH service life
US9424176B2 (en) * 2013-02-25 2016-08-23 Freescale Semiconductor, Inc. Robust sector ID scheme for tracking dead sectors to automate search and copydown
TWI557744B (en) * 2015-01-27 2016-11-11 緯創資通股份有限公司 Data storing method and embedded system
US10528273B2 (en) * 2017-11-07 2020-01-07 Nxp Usa, Inc. Dynamic compression in an electrically erasable programmble read only memory (EEPROM) emulation system
CN110209349B (en) * 2019-04-25 2022-12-09 广东科华乾昇云计算科技有限公司 Data processing method and terminal equipment

Also Published As

Publication number Publication date
CN112347002A (en) 2021-02-09

Similar Documents

Publication Publication Date Title
CN107168647B (en) FLASH data read-write method and system
US7246268B2 (en) Method and apparatus for dynamic degradation detection
KR100977899B1 (en) Method and apparatus for effectively enabling an out of sequence write process within a non-volatile memory system
US20170139839A1 (en) Data storage device and data maintenance method thereof
US20140289588A1 (en) Memory system
CN112347002B (en) flash data storage method, system, computer equipment and storage medium
US20090228634A1 (en) Memory Controller For Flash Memory
US9563551B2 (en) Data storage device and data fetching method for flash memory
JP2005258851A (en) Memory card
CN109597571B (en) Data storage method, data reading method, data storage device, data reading device and computer equipment
CN111475425B (en) Method for managing flash memory module and related flash memory controller and electronic device
US6839798B1 (en) Flash memory capable of storing frequently rewritten data
EP0615193A1 (en) Memory card device
KR101826778B1 (en) EEPROM Emulation Method Considering implementation of Flash Life Cycle and Performance Improvement
CN112800123B (en) Data processing method, device, computer equipment and storage medium
CN109960611B (en) Data recovery method and device, electronic equipment and machine-readable storage medium
CN113885791A (en) Data writing method, reading method and device of Flash memory
CN110471623B (en) Hard disk file writing method, device, computer equipment and storage medium
CN111324549B (en) Memory and control method and device thereof
CN112579004A (en) Method, system, computer equipment and storage medium for quickly deleting flash data
CN112433959A (en) Method and device for realizing data storage processing, computer storage medium and terminal
CN111091861A (en) Solid state disk power failure protection method based on high-speed nonvolatile memory
CN111090542A (en) Abnormal block identification method and device based on abnormal power failure and computer equipment
CN111708487A (en) Data storage method and device and computer storage medium
CN112214160A (en) Method for prolonging FLASH service life applied to electric energy meter

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right

Effective date of registration: 20230324

Address after: Room 418, Building 1, No. 66, Dongxin Avenue, Puyan Street, Binjiang District, Hangzhou City, Zhejiang Province, 310000

Applicant after: Hangzhou Xinjushi Artificial Intelligence Technology Co.,Ltd.

Address before: 310051 rooms 1505 and 1506, 5th floor, building 1, Edie building, 66 Dongxin Avenue, Binjiang District, Hangzhou City, Zhejiang Province

Applicant before: HANGZHOU AIXIN INTELLIGENT TECHNOLOGY CO.,LTD.

TA01 Transfer of patent application right
GR01 Patent grant
GR01 Patent grant