Method for prolonging service life of EEPROM through bit operation

By dividing the memory area in the EEPROM and performing data displacement operations, the problem of uneven median erase probability of EEPROM is solved, and the life of each bit is uniformly distributed, the life of the EEPROM is extended, and the accurate reading of data is ensured.

CN119649881AActive Publication Date: 2025-03-18RICE MICROELECTRONICS
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
CN202411708531.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-27
Publication Date
2025-03-18
Estimated Expiration
2044-11-27

AI Technical Summary

Technical Problem

The prior art is difficult to effectively extend the life of the EEPROM, especially during the in-bit erase process, the rewritten probability of each bit is uneven, resulting in the life of some bits being consumed too quickly.

Method used

By dividing the EEPROM into a user storage area and a conversion information storage area, and displaced data in the conversion module, ensuring that the life of each bit within each byte is evenly distributed, thereby extending the life of the EEPROM.

Benefits of technology

Without reducing the total number of erases and changing the erases frequency, the erasing probability of each bit is consistent through data conversion, thereby extending the life of the EEPROM and accurately restoring the original data when reading the data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119649881A_ABST
    Figure CN119649881A_ABST
Patent Text Reader

Abstract

The invention discloses a system and a method for prolonging the service life of an EEPROM (Electrically Erasable Programmable Read-Only Memory) through bit operation. The system comprises a conversion module, a function module and the EEPROM, the method comprises the following steps of: dividing an EEPROM (Electrically Erasable Programmable Read-Only Memory) into different storage areas, including a user storage area for storing user data and a conversion information storage area for storing conversion information, so that data erasing and writing are uniformly distributed to each unit of the EEPROM; according to the method, the problem that the service life of the EEPROM is limited due to different bit erasing probabilities in the erasing process is solved, and the effect of better prolonging the service life of the EEPROM is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of storage devices, and in particular to a method for extending the life of an EEPROM through bit operations. Background Art

[0002] like Figure 1 As shown, it shows a schematic diagram of the floating gate tube structure commonly used in EEPROM (Electrically Erasable Programmable read only memory). The basic working principle of floating gate EEPROM memory is based on the different amount of charge stored on the gate medium, thereby distinguishing its stored information "0" and "1", and finally converting it into digital "0" and "1" through the reading circuit to distinguish the readout.

[0003] The basic operation of EEPROM for data processing is erasing and writing. Before each programming, an erase "clear" operation is required. After that, the storage unit that needs to be written with "1" is programmed, and the storage unit that needs to be written with "0" remains unchanged.

[0004] When operating on a single bit, there are four cases based on the original data storage and the results that need to be modified later:

[0005] The first is that the original value of 1 needs to be changed to 1, and the storage area will change twice;

[0006] The second is that the original value of 1 needs to be changed to 0, and the storage area will change once;

[0007] The third type is that the original value is 0 and needs to be changed to 0, and the storage area will not change;

[0008] The fourth type is that the original value of 0 needs to be changed to 1, and the storage area will change once.

[0009] The more changes there are within a storage area, the faster its lifespan is consumed, and when one bit is exhausted, the entire byte becomes unusable.

[0010] Since EEPROM is erased and written in bytes, existing technical solutions all extend the life in bytes. However, in fact, different bits have different erase probabilities during the erase process. If the erase probabilities of these bits can be balanced, the life of the EEPROM can be extended. Summary of the invention

[0011] In order to solve the above problems, the present invention proposes a method for extending the life of EEPROM through bit operation in view of the above prior art, which equalizes the life of each bit in each byte, thereby achieving the effect of extending the life of EEPROM.

[0012] To achieve the above object, according to one aspect of the present invention, a system for extending the life of an EEPROM by bit operation is provided.

[0013] Including: conversion module, functional module and EEPROM;

[0014] The conversion module is used to read and convert the data in the EEPROM conversion information storage area;

[0015] The functional module is used to read the data of the conversion module and interact with the EPROM;

[0016] The EEPROM is used to receive data from the functional modules and store the data.

[0017] According to another aspect of the present invention, there is provided a method for extending the life of an EEPROM by bit operation, characterized in that it comprises the following steps:

[0018] The EEPROM is divided into different storage areas, including a user storage area for storing user data and a conversion information storage area for storing conversion information, so that the erasing and writing of data are evenly distributed to each unit of the EEPROM.

[0019] Furthermore, in the user storage area, a physical address is assigned to each Byte.

[0020] Furthermore, in the conversion information storage area, each address stores one page of conversion information.

[0021] Furthermore, the steps of storing the data are:

[0022] S1. Assume that the data to be stored is data_in, the conversion module reads the data y1 in the conversion information storage area at the corresponding position in the EEPROM, and the conversion module shifts the data in the single byte by y1 bits per byte of the data in data_in, that is, the first y1 bits of the data are shifted to the back of the data to form a new data;

[0023] S2. Increase y1 by 1 to change it to y2, output the modified data and y2, and perform operations in the function module after the modified data is output.

[0024] Furthermore, the data reading step is as follows: S3. After being processed by the functional module, it is data_out1.

[0025] Restore it by converting the module;

[0026] S4. The conversion module reads the data y3 in the conversion information storage area at the corresponding position, and then shifts the data of data_out1 in the opposite direction of writing, that is, y3-1 bit, to restore the original data data_out.

[0027] According to another aspect of the present invention, a computer-readable storage medium is provided, on which a computer program is stored. When the program is executed by a processor, the steps of the method for extending the life of an EEPROM through bit operations of the present invention are implemented.

[0028] According to another aspect of the present invention, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of the method for extending the life of an EEPROM through bit operations of the present invention are implemented.

[0029] Compared with the prior art, the present invention has at least the following beneficial effects:

[0030] 1. Without reducing the total number of erase and write times and changing the erase and write frequency, the erase and write probability of each bit of data is ensured to be consistent through data conversion, thereby extending the life of the EEPROM;

[0031] 2. When reading data, the original data can be accurately restored through the accessed data conversion information;

[0032] 3. It can be combined with other methods to extend the life of EEPROM to a greater extent;

[0033] 4. Data conversion information is represented by special coding to reduce the number of bit erases and writes, ensuring the service life of the data conversion storage area. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings of the embodiments will be briefly introduced below. Obviously, the drawings in the following description only relate to some embodiments of the present invention, but are not intended to limit the present invention.

[0035] Figure 1 This is a schematic diagram of the floating gate tube structure commonly used in EEPROM;

[0036] Figure 2 It is a general framework diagram of a preferred embodiment of the present invention;

[0037] Figure 3 It is a schematic diagram of the internal storage of EEPROM in a preferred embodiment of the present invention. DETAILED DESCRIPTION

[0038] To make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution of the embodiments of the present invention will be described clearly and completely in conjunction with the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of them.

[0039] Unless otherwise defined, technical or scientific terms used herein shall have the same meaning as commonly understood by one of ordinary skill in the art to which the invention belongs.

[0040] The following is combined with Figure 2-3 The specific embodiments of the present invention are described in detail with examples.

[0041] Example 1: Figure 2 As shown, the present invention provides a system for extending the life of EEPROM by bit operation.

[0042] It includes a conversion module 201 , a functional module 202 and an EEPROM 203 .

[0043] The conversion module 201 is used to read and convert the data in the conversion information storage area of ​​the EEPROM 203;

[0044] Function module 202, used for reading data from conversion module 201 and interacting with EPROM 203;

[0045] EEPROM 203 is used to receive data from the functional module 202 and store the data.

[0046] The implementation principle is introduced below in terms of storage and reading.

[0047] The storage steps include:

[0048] Step 1: Assume that the data to be stored is data_in, and the conversion module 201 processes it. The principle is that the conversion module 201 reads the data y1 in the conversion information storage area at the corresponding position in the EEPROM 203, and the conversion module 201 treats the data in data_in as a whole per byte, and shifts the data in a single byte by y1 bits (moves the first y1 bits of the data to the back of the data to form a new data).

[0049] Step 2: Increase y1 by 1 to become y2, and output the modified data and y2. After the modified data is output, it can be operated in the functional module 202, such as comparing with the data currently stored in EEPROM203 to avoid repeated modification and performing other shift operations to extend the life, etc. The modified y2 value can be directly written into the conversion information storage area at the corresponding position.

[0050] The reading steps include:

[0051] Step 3: After being processed by the functional module 202, it becomes data_out1, which is restored by the conversion module 201.

[0052] Step 4: The conversion module 201 reads the data y3 in the conversion information storage area at the corresponding position, and then shifts the data of data_out1 by (y3-1) bits in the opposite direction of writing, so as to restore the original data data_out.

[0053] like Figure 3 As shown, the internal storage of the EEPROM of the present invention is shown. The EEPROM memory is divided into three areas, namely, a user storage area, a conversion information storage area, and other information storage area.

[0054] In the user storage area, a physical address is assigned to each Byte. The size of the user storage area in the figure is 256 Bytes, and every 4 Bytes are divided into 1 page (the number of bytes divided into 1 page can be modified according to the actual application scenario). In particular, the address 0x00-0x03 is divided into one page.

[0055] Each address in the conversion information storage area stores one page of conversion information. The specific representation is as follows: the data at address 0x100 represents the conversion information of the first page. The data format is that the yth bit is 1 and the remaining bits are 0. After reading the information, it can be operated to represent it as a decimal number y (which can be achieved through a simple digital logic). This data format can reduce the number of erases and writes each time it is modified, while taking into account the life of the conversion information storage area.

[0056] In summary, by adding a conversion module to perform a shift operation on the original data, for each data input, the number of bits shifted is random, which can ensure that under a large sample, each bit of the EEPROM tends to the same number of erase and write times, that is, the lifespan is roughly the same.

[0057] The following model is used to illustrate how much the present invention can extend the life of the EEPROM: Assuming that a string of numbers is to be recorded, and that the decimal number in reality is converted into binary using BCD code, for each user storage address, it is only modified when it changes (this can reduce the number of erasures and prolong the life), consider a two-digit decimal number, which will be converted into an eight-digit binary number, assuming that this decimal number will not be greater than 40 in real life, then the 7th and 8th bits (from low to high) of its binary number are always 0, plus the probability that the highest bit of the BCD code is 1 is 0.2 (assuming uniformity), so the probability that the 4th bit is 0 is 0.8, assuming that the other bits 0 and 1 are balanced, then through the shift transformation, 2.7 bits of the original 8 bits are expected to be erased, and 2.7 bits are expected to be programmed, so the probability of a single bit being erased is 33.8%, and if no bit operation is performed, the probability of erasing the most frequently erased bit is 50%, from which it can be calculated that the life of the EEPROM is extended by about 48%. In fact, there are many other situations that will cause different probabilities of each bit in the EEPROM being erased or written, such as using ASCII code to record English (different English letters have different probabilities in actual use). The fundamental reason for this is the uneven data used in the real world and the uneven bit usage of the encoding method itself.

[0058] Embodiment 2:

[0059] The computer-readable storage medium of this embodiment stores a computer program thereon, and when the program is executed by a processor, the steps in the method of extending the life of an EEPROM by bit operation in Embodiment 1 are implemented.

[0060] The computer-readable storage medium of this embodiment may be an internal storage unit of the terminal, such as a hard disk or memory of the terminal; the computer-readable storage medium of this embodiment may also be an external storage device of the terminal, such as a plug-in hard disk, a smart memory card, a secure digital card, a flash memory card, etc. equipped on the terminal; further, the computer-readable storage medium may also include both an internal storage unit of the terminal and an external storage device.

[0061] The computer-readable storage medium of this embodiment is used to store computer programs and other programs and data required by the terminal. The computer-readable storage medium can also be used to temporarily store data that has been output or is to be output.

[0062] Embodiment 3:

[0063] The computer device of this embodiment includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the steps of the method for extending the life of an EEPROM through bit operations based on random sample consistency of Embodiment 1 are implemented.

[0064] In this embodiment, the processor may be a central processing unit, or other general-purpose processors, digital signal processors, application-specific integrated circuits, readily available programmable gate arrays or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The memory may include a read-only memory and a random access memory, and provide instructions and data to the processor. A portion of the memory may also include a non-volatile random access memory. For example, the memory may also store information about the device type.

[0065] Those skilled in the art will appreciate that the disclosed content of the embodiments may be provided as methods, systems, or computer program products. Therefore, the present solution may adopt the form of hardware embodiments, software embodiments, or embodiments combining software and hardware. Moreover, the present solution may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage and optical storage, etc.) containing computer-usable program codes.

[0066] The present solution is described with reference to the method according to the embodiment of the present solution and the flowchart and / or block diagram of the computer program product. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions; these computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 one or more processes and / or methods Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0067] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 one or more processes and / or methods Figure 1 A function specified in one or more boxes.

[0068] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 one or more processes and / or methods Figure 1The steps for the functions specified in one or more boxes.

[0069] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the program can be stored in a computer-readable storage medium, and when the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The storage medium can be a disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM), etc.

[0070] The examples described in the present invention are merely descriptions of the preferred implementation modes of the present invention, and are not intended to limit the concept and scope of the present invention. Without departing from the design concept of the present invention, various modifications and improvements made to the technical solutions of the present invention by engineers and technicians in this field should all fall within the protection scope of the present invention.

Claims

1. A system for extending the life of an EEPROM by bit manipulation, characterized in that: include: Conversion module, functional module and EEPROM; The conversion module is used to read and convert the data in the EEPROM conversion information storage area; The functional module is used to read the data of the conversion module and interact with the EPROM; The EEPROM is used to receive data from the functional modules and store the data.

2. A method for extending the life of an EEPROM by bit manipulation, characterized in that: The steps include: The EEPROM is divided into different storage areas, including a user storage area for storing user data and a conversion information storage area for storing conversion information, so that the erasing and writing of data are evenly distributed to each unit of the EEPROM.

3. The method according to claim 2, characterized in that In the user storage area, each Byte is assigned a physical address.

4. The method according to claim 3, characterized in that In the translation information storage area, each address stores translation information of one page.

5. The method according to claim 4, characterized in that The steps for storing data are as follows: S1. Assume that the data to be stored is data_in, the conversion module reads the data y1 in the conversion information storage area at the corresponding position in the EEPROM, and the conversion module shifts the data in the single byte by y1 bits per byte of the data in data_in, that is, the first y1 bits of the data are shifted to the back of the data to form a new data; S2. Increase y1 by 1 to change it to y2, output the modified data and y2, and perform operations in the function module after the modified data is output.

6. The method according to claim 5, characterized in that The data reading steps are as follows: S3. After being processed by the function module, it is data_out1, which is restored by the conversion module; S4. The conversion module reads the data y3 in the conversion information storage area at the corresponding position, and then shifts the data of data_out1 in the opposite direction of writing, that is, y3-1 bit, to restore the original data data_out.

7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the method for extending the life of an EEPROM by bit operation according to any one of claims 2 to 6 are implemented.

8. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the steps in the method for extending the life of an EEPROM by bit operation according to any one of claims 2 to 6 are implemented.

Citation Information

Patent Citations

  • Storage device and method of operating the same

    CN111312305A

  • Method and device for prolonging erasing and writing life of nonvolatile flash memory, storage medium and terminal

    CN112256207A

  • Data storage method and system based on Internet of Things equipment and electronic equipment

    CN116048392A

  • Management system for of number of times of writing programmable read only memory

    JP1987283497A

  • Memory card device

    JP1993047191A