A detection method, system, intelligent terminal and computer-readable storage medium for Flash intelligent analysis and detection

By alternately updating the total set of bad pages and bad columns in Nand Flash and using the error threshold iteration strategy, the accuracy and effective capacity of Flash analysis and detection are improved, and the problem of insufficient detection accuracy in the existing technology is solved.

CN113053450BActive Publication Date: 2024-09-13SHENZHEN SANDIYIXIN ELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110247275.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-03-05
Publication Date
2024-09-13
Estimated Expiration
2041-03-05

AI Technical Summary

Technical Problem

Existing Flash analysis and detection methods have poor accuracy when detecting Bad Page and Bad Column in Nand Flash, resulting in a reduction in the effective capacity of Flash.

Method used

By obtaining the Column total set, the Page total set and the Block total set, alternately follow the bad page selection strategy and the bad column selection strategy, update the bad Page total set and bad Column total set based on the error threshold, and iteratively update the error threshold to improve the number of bad Blocks. Template accuracy.

Benefits of technology

It improves the effective capacity of Nand Flash after analysis and detection, reduces the generation of false Bad Column, and enhances the accuracy of detection and the stability of data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113053450B
    Figure CN113053450B
Patent Text Reader

Abstract

The present invention relates to a detection method, system, intelligent terminal and computer-readable storage medium applied to Flash intelligent analysis and detection, which includes S1, obtaining a total set of Columns, a total set of Pages and a total set of Blocks, presetting a total set of bad Columns, a total set of bad Pages, an error threshold, and an initial bad Block template; S2, alternately obtaining bad Page elements and bad Column elements from the total set of Blocks based on the error threshold, and alternately updating the total set of bad Pages and the total set of bad Columns in turn; S3, based on each bad Column total set corresponding to different error thresholds and each bad Page total set corresponding to different error thresholds, updating the error threshold according to a bad template iteration strategy, obtaining a final total set of Columns from each bad Column total set, and obtaining a final total set of Pages from each bad Page total set; S4, obtaining a final bad Block template. The present invention has the effect of reducing the influence of bad Page on the subsequent operation of selecting bad Column elements, reducing the generation of false bad Columns, and thus improving the effective capacity after Nand Flash analysis and detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of Flash analysis and detection methods, and in particular to a detection method, system, intelligent terminal and computer-readable storage medium applied to Flash intelligent analysis and detection. Background Art

[0002] Flash, also known as flash memory, is a type of memory that allows multiple erasures or writes during operation. Currently, Flash is mainly divided into Nand Flash and Nor Flash. Compared with Nor Flash, Nand Flash has the advantages of fast erasing and writing speed, large storage capacity, and low unit cost. Therefore, Nand Flash is more widely used. Our commonly used Nand Flash products include flash drives and digital memory cards.

[0003] Nand Flash can be physically divided into blocks (also called Blocks), pages (also called Pages), columns (also called Columns) or physical units (also called Cells). Nand Flash consists of several blocks, each block consists of several pages, and each page consists of several columns (or physical units). For different types of Flash, each column (or physical unit) can store at least 1 bit of data. Therefore, the addresses of Nand Flash are divided into three categories: BlockAddress (also called block number) corresponding to the block, Page Address (also called page number within the block) corresponding to the page, and Column Address (also called byte number within the page) corresponding to the column (or physical unit).

[0004] During the long-term use of Nand Flash, storage units that cannot be stored or read correctly may appear in each block. In order to ensure the integrity of the stored data, these abnormal storage units need to be skipped when storing data. In order to find the address information of these broken storage units, it is necessary to analyze and detect Nand Flash to find the Bad Page (also called bad page) and Bad Column (also called bad column) in the block.

[0005] With the development of Flash process technology, people pay more and more attention to the detection and analysis of Bad Page and / or Bad Column. However, the inventor believes that the detection and analysis method in the related art is relatively simple. After analyzing the bad Page and / or bad Column in the Flash by the detection and analysis method in the related art, the accuracy of the bad Page and / or bad Column is poor, which may cause the effective capacity of the Flash to be reduced. Summary of the invention

[0006] The first object of the present invention is to provide a detection method applied to Flash intelligent analysis and detection, which has the characteristic of improving the effective capacity of NandFlash after analysis and detection.

[0007] The above-mentioned object of the present invention is achieved through the following technical solutions:

[0008] S1. Obtain the total set of columns, the total set of pages, and the total set of blocks including the total set of columns and the total set of pages, preset the total set of bad columns, the total set of bad pages, an error threshold that can be updated with the number of iterations, and an initial bad block template including the total set of bad columns and the total set of bad pages;

[0009] S2. Alternately follow the bad page selection strategy and the bad column selection strategy, alternately obtain bad Page elements and bad Column elements from the total Block set based on the error threshold, and alternately update the total bad Page set and the total bad Column set;

[0010] S3, based on the total sets of bad columns corresponding to different error thresholds and the total sets of bad pages corresponding to different error thresholds, the error threshold is updated according to the bad template iteration strategy, and the final total set of columns is obtained from the total sets of bad columns, and the final total set of pages is obtained from the total sets of bad pages;

[0011] S4. Update the initial bad Block template based on the final Column total set and the final Page total set to obtain the final bad Block template.

[0012] By adopting the above technical solution, the Column total set includes all the columns in a Block, and the Page total set includes all the Pages in a Block. The bad Column total set includes all the columns that are evaluated as bad Columns through instruction error correction, and the bad Page total set includes all the Pages that are evaluated as bad Pages through instruction error correction. The initial bad Block template refers to a template obtained by combining the bad Column total set and the bad Page total set. If the initial bad Block template is used to analyze all the Blocks in the read and write Flash, the effective capacity of the Flash can be evaluated.

[0013] The bad page selection strategy is a method for selecting bad Page elements from the total Page set based on the error threshold, while the bad column selection strategy is a method for selecting bad Column elements from the total Column set based on the error threshold. Selecting bad Page elements and / or bad Column elements is equivalent to the operation of selecting bad elements, and updating the total bad Page set and / or the total bad Column set based on the bad Page elements is equivalent to the operation of updating the total bad set; step S2 is equivalent to making the operation of selecting bad elements and the operation of updating the total bad set alternate in sequence. Because when instruction error correction selects bad Page elements from the total Page set based on the error threshold, the bad Column elements will affect the instruction error correction's judgment on the total Page set, so first obtaining a more accurate total bad Column set and then evaluating the total Page set through instruction error correction can improve the accuracy of instruction error correction and make the acquired total bad Page set more accurate; similarly, when instruction error correction selects bad Column elements from the total Column set based on the error threshold, the bad Page elements will also affect the instruction error correction's judgment on the total Column set, so first obtaining a more accurate total bad Page set and then evaluating the total Column set through instruction error correction can improve the accuracy of instruction error correction and make the acquired total bad Column set more accurate.

[0014] The error threshold refers to the condition for evaluation in instruction error correction, which is equivalent to the standard for judging a Column as a bad Column and / or a Page as a bad Page. The change of the error threshold will affect the error threshold of the number of bad Columns and / or bad Pages, but in the actual analysis and detection process, it is difficult for the error threshold to directly obtain the correct value. By changing the error threshold, multiple bad Page sets and / or bad Column sets corresponding to different error thresholds can be obtained, and by screening, comparing and judging, the final Column set and / or final Page set can be selected from each bad Page set and / or bad Column set, which is equivalent to selecting a relatively accurate error threshold from multiple error thresholds, so that the final bad Block template obtained is more accurate.

[0015] By selecting bad elements and updating the bad set alternately, the accuracy of the bad column set and / or the bad page set can be improved, and after multiple iterations, the bad column set and / or the bad page set will become more and more accurate, thereby making the obtained bad block template more accurate. On the other hand, due to the physical properties of Nand Flash, some pages are bad pages themselves. Therefore, by selecting bad page elements first and then selecting bad column elements, these bad pages can be selected from the block set as bad page elements, reducing the impact of these bad pages on the subsequent selection of bad column elements, reducing the generation of false bad columns, making the final bad block template more accurate, and thereby improving the effective capacity after Nand Flash analysis and detection.

[0016] Optionally, the step S2 includes:

[0017] S21. According to the bad column interference elimination strategy, a page subset to be tested is obtained from the page total set based on the bad column total set. According to the bad page judgment strategy, each page subset to be tested is analyzed in turn based on the error threshold, bad page elements are obtained from the block total set, and the bad page total set is updated based on the bad page elements.

[0018] S22. According to the bad page interference elimination strategy, each Column subset to be tested is obtained from the Column total set based on the bad Page total set. According to the bad column judgment strategy, each Column subset to be tested is analyzed in turn based on the error threshold, the bad Column element is obtained from the Block total set, and the bad Column total set is updated based on the bad Column element.

[0019] By adopting the above technical solution, when the total set of Pages needs to be corrected for instructions, the bad column interference elimination can select some columns with fewer bad columns from the total set of Pages as each subset of Pages to be tested, and then analyze each subset of Pages to be tested in turn to obtain each bad Page element, and update the bad Page element to the total set of bad Pages, thereby obtaining a more accurate total set of bad Pages. Similarly, when the total set of Columns needs to be corrected for instructions, the bad row interference elimination can select some pages with fewer bad pages from the total set of Columns as each subset of Columns to be tested, and then analyze each subset of Columns to be tested to obtain each bad Column element, and update the bad Column element to the total set of bad Columns, thereby obtaining a more accurate total set of bad Columns.

[0020] Optionally, in step S1, the step further includes: obtaining each original Column subset and each original Page subset, wherein the Column total set includes each original Column subset, and the Page total set includes each original Page subset;

[0021] The step S21 includes:

[0022] S211, mapping the total set of bad columns to each original page subset to obtain each interference page subset;

[0023] S212, sequentially obtaining the complement of each interference Page subset in each corresponding original Page subset to generate each Page subset to be tested;

[0024] S213, according to the bad page judgment strategy, analyze each of the to-be-tested Page subsets in turn based on the error threshold, obtain the bad Page element from the total Block set, and update the total bad Page set based on the bad Page element;

[0025] The step S22 includes:

[0026] S221, mapping the total set of bad pages to each original column subset to obtain each interference column subset;

[0027] S222, sequentially obtaining the complement of each interference Column subset in each corresponding original Column subset as each Column subset to be tested;

[0028] S223. According to the bad column judgment strategy, each bad column element is obtained from each column subset to be tested based on the error threshold, and the total set of bad columns is updated.

[0029] By adopting the above technical solution, the original Column subset includes each storage unit located in the same Column, and the original Page subset includes each storage unit located in the same Page. After mapping the total set of bad columns to any original Page subset, the storage units that will intersect with the total set of bad columns can be obtained in the original Page subset, and the interference Column subset includes this part of the storage units. The storage units in the interference Column subset are all part of the bad Page that have been judged to be. When storing data, the storage units in the interference Column subset will be skipped. Therefore, when analyzing and detecting how many storage units in the original Page subset need to be skipped, the complement of the interference Page subset in the original Page subset is obtained as the Page subset to be tested for analysis, which can reduce the interference of the current bad Page on the analysis of the bad Column. Similarly, when analyzing and detecting how many storage units in the original Column subset need to be skipped, the complement of the interference Column subset in the original Column subset is obtained as the Column subset to be tested for analysis, which can reduce the interference of the current bad Column on the analysis of the bad Page.

[0030] Optionally, the step S213 includes:

[0031] S2131, according to the instruction error correction strategy, sequentially obtain the Page error value of each Page subset to be tested;

[0032] S2132, based on the error threshold and each Page error value, in accordance with the bad Page screening strategy, select the Page subsets to be tested that do not meet the Page validity condition from each Page subset to be tested as the failed Page subset;

[0033] S2133, obtaining bad Page elements based on the original Page subset corresponding to the invalid Page subset, and obtaining a set including all bad Page elements as a total bad Page set;

[0034] The step S223 includes:

[0035] S2231, according to the instruction error correction strategy, sequentially obtain the column error value of each column subset to be tested;

[0036] S2232, based on the error threshold and the column error value, according to the threshold comparison strategy, select the column subsets to be tested that do not meet the column accuracy condition from each column subset to be tested as the failed column subset;

[0037] S2233. Obtain bad Column elements based on the original Column subset corresponding to the failed Column subset, and obtain a set containing all bad Column elements as the total bad Column set.

[0038] By adopting the above technical solution, the instruction error correction strategy can first write data to each storage unit of the Column subset to be tested, and then read it out for comparison, and then count the number of erroneous bits. The more erroneous bits there are, the higher the error value. When the error value is higher than the error threshold, the subset to be tested does not meet the Column accuracy condition. The subset to be tested can be evaluated as a failed Column subset, and the original subset corresponding to the failed Column subset is used as a bad Column. The bad Column is recorded by including the bad Page element in the total bad Page set. After all the bad Page elements are recorded, the current total bad Page set is equivalent to a bad Column template that records each bad Column. The old bad Column template is replaced with the current bad Column template, thereby completing the update of the bad Column template. Similarly, by calculating the Column error value of each Column subset to be tested and comparing it with the error threshold, each failed Page subset that does not meet the Page validity condition can be obtained, and then the bad Page template that records each bad Page can be obtained. The old bad Page template is replaced with the current bad Page template, thereby completing the update of the bad Page template.

[0039] Optionally, the S3 step includes:

[0040] S31, establishing a template library for storing templates to be compared corresponding to different error thresholds;

[0041] S32, according to the template comparison strategy, determine whether the complete error threshold in the current template library has a minimum value that meets the effective capacity condition, if so, execute S34; if not, execute S33;

[0042] S33, update the error threshold, update the template to be compared based on the total set of bad columns and the total set of bad pages, store them in the template library, and return to S2;

[0043] S34. Generate a final Column total set and a final Page total set based on the judgment result.

[0044] By adopting the above technical solution, the template to be compared is the previous bad column set and / or bad page set of the current bad column set and / or bad page set. The template library can store bad column sets and / or bad page sets corresponding to different error thresholds. By comparing multiple bad column sets and / or bad page sets corresponding to different error thresholds, a more suitable error threshold can be found. The bad column set and / or bad page set corresponding to this error threshold should be more accurate and meet the effective capacity requirements of the Flash.

[0045] Optionally, in step S32, including:

[0046] S321, determine whether there is a template to be compared in the current template library, if yes, execute S322; if not, execute S323;

[0047] S322, determine whether the template to be compared meets the iteration termination condition, if yes, execute S34; if not, execute S33;

[0048] S323, obtaining a template to be compared that includes the current total set of bad columns and the current total set of bad pages, and storing the template to be compared in a template library;

[0049] In the step S34, it also includes: obtaining the total set of bad columns in the template to be compared as the final total set of columns, and obtaining the total set of bad pages in the template to be compared as the final total set of pages.

[0050] By adopting the above technical solution, the final Column total set and / or the final Page total set refers to the bad Column total set and / or the bad Page total set that is relatively accurate and can meet the effective capacity requirements of Flash. In order to obtain the final Column total set and / or the final Page total set, it is necessary to update the error threshold so that the bad Column total set and / or the bad Page total set are continuously updated and iterated. When the final Column total set and / or the final Page total set are not successfully selected, the current bad Column total set and / or the bad Page total set will be stored in the template library as a template to be compared. The template library is equivalent to storing the candidate templates of the final Column total set and / or the final Page total set. Until the final Column total set and / or the final Page total set appear, the bad Column total set and / or the bad Page total set will be continuously iterated and updated with the change of the error threshold, so that the final Column total set and / or the final Page total set that meet the requirements can be selected. When there is no template to be compared in the template library, the current bad Column total set and the current bad Page total set are added to the template library as templates to be compared.

[0051] Optionally, the step S322 includes:

[0052] S3221, preset a column effective threshold, and determine whether the total set of bad columns in the current template to be compared meets the effective capacity condition based on the column effective threshold. If yes, execute S3222; otherwise, execute S33;

[0053] S3222, preset a Column iteration threshold, analyze the template to be compared and the total set of bad columns based on the Column iteration threshold, and determine whether the template to be compared meets the capacity change condition. If so, execute S3223; if not, execute S33;

[0054] S3223, preset a Page validity threshold, and determine whether the total set of bad Pages in the current template to be compared meets the valid capacity condition based on the Page validity threshold. If yes, execute S3224; otherwise, execute S33;

[0055] S3224. Preset a Page iteration threshold, analyze the template to be compared and the total set of bad Pages based on the Page iteration threshold, and determine whether the template to be compared meets the capacity change condition. If so, execute S34; otherwise, execute S33.

[0056] By adopting the above technical solution, the error threshold corresponding to the current bad column set and / or bad page set is equivalent to the updated value of the error threshold corresponding to the template to be compared stored in the template library. By comparing the current bad column set and / or bad page set with the current template to be compared, it can be evaluated whether the change of the error threshold has a sufficiently large impact on the generation of the current bad column set and / or bad page set. If the impact is small, it means that the accuracy of the current bad column set and / or bad page set after the update iteration is small; at the same time, if the error threshold is too small, it may cause too many bad column sets and / or bad page sets, which directly affects the effective capacity of Flash after the entire analysis and detection is completed. Therefore, the final column set and / or final page set is equivalent to achieving a balance between the accuracy of the bad column set and / or bad page set and the effective capacity of Flash. A relatively accurate bad block template that meets the effective capacity requirements can be obtained through the final column set and the final page set.

[0057] The second object of the present invention is to provide a detection system applied to Flash intelligent analysis and detection, which has the characteristic of improving the effective capacity of NandFlash after analysis and detection.

[0058] The second object of the present invention is achieved by the following technical solutions:

[0059] A detection system for Flash intelligent analysis and detection, comprising:

[0060] An initial template establishment module is used to obtain a total set of columns, a total set of pages, and a total set of blocks including the total set of columns and pages, preset a total set of bad columns, a total set of bad pages, an error threshold that can be updated with the number of iterations, and an initial bad block template including the total set of bad columns and the total set of bad pages;

[0061] The template update module is used to alternately obtain bad Page elements and bad Column elements from the total set of Blocks according to the bad page selection strategy and the bad column selection strategy based on the error threshold, and alternately update the total set of bad Pages and the total set of bad Columns;

[0062] A template iteration module is used to update the error threshold according to the bad template iteration strategy based on each bad column total set corresponding to different error thresholds and each bad page total set corresponding to different error thresholds, obtain the final column total set from each bad column total set, and obtain the final page total set from each bad page total set;

[0063] The final template generation module is used to update the initial bad Block template based on the final Column total set and the final Page total set to obtain the final bad Block template.

[0064] The third object of the present invention is to provide an intelligent terminal having the characteristic of improving the effective capacity after Nand Flash analysis and detection.

[0065] The third object of the present invention is achieved through the following technical solutions:

[0066] An intelligent terminal comprises a memory and a processor, wherein the memory stores a computer program which can be loaded by the processor and executes the above-mentioned detection method.

[0067] The fourth object of the present invention is to provide a computer storage medium capable of storing corresponding programs and having the characteristic of facilitating the improvement of the effective capacity after Nand Flash analysis and detection.

[0068] The fourth object of the present invention is achieved by the following technical solutions:

[0069] A computer-readable storage medium stores a computer program that can be loaded by a processor and executes a detection method as described above. BRIEF DESCRIPTION OF THE DRAWINGS

[0070] Figure 1 It is a schematic diagram of the process of the detection method of the present application.

[0071] Figure 2 It is a flow chart of the interference elimination step in the detection method of the present application.

[0072] Figure 3 It is a flowchart of the step of obtaining the total set of bad Pages in the detection method of the present application.

[0073] Figure 4 It is a flowchart of the step of obtaining the total set of bad columns in the detection method of the present application.

[0074] Figure 5 It is a flow chart of updating the total set of Columns and updating the total set of Pages in the detection method of the present application.

[0075] Figure 6 It is a flow chart of the step of obtaining the template to be compared in the detection method of the present application.

[0076] Figure 7 It is a flowchart of the steps of obtaining the final Column set and obtaining the final Page in the detection method of the present application.

[0077] Figure 8 It is a structural block diagram of the detection system of this application.

[0078] In the figure, 1. Initial template establishment module; 2. Template update module; 3. Template iteration module; 4. Final template generation module. DETAILED DESCRIPTION

[0079] The Flash detection and analysis method in the related art is:

[0080] Extract blocks from various blocks in the Flash as template blocks, and preset bad block templates based on the template blocks;

[0081] Extract a template block, analyze all columns in the template block through ECC error correction, and obtain each bad column;

[0082] Map each bad column to all pages, and obtain each page to be tested that excludes the influence of each bad column from all pages;

[0083] Through ECC error correction analysis template Block all the pages to be tested, and obtain each bad page;

[0084] Based on each bad column and each bad page, update the bad block template of the template block;

[0085] Use the bad block template to analyze and read and write each block in the Flash to obtain the effective capacity of the Flash.

[0086] In addition, in the above Flash detection and analysis method, multiple blocks can be extracted as template blocks, and finally multiple bad block templates can be obtained. By using multiple bad block templates to analyze and read and write each block in the Flash, a more accurate effective capacity of the Flash can be obtained.

[0087] With respect to the above-mentioned related technologies, the inventor believes that when the above-mentioned detection and analysis method obtains the bad column, it is equivalent to treating all pages as good pages, that is, ignoring the influence of bad pages on bad columns. However, due to the physical properties of Nand Flash, some pages are bad pages themselves. If the influence of these bad pages on the error detection analysis of each column is not reduced, false bad columns may appear in each column, and bad columns and bad pages affect each other. These false bad columns will cause the error correction capability of ECC error correction analysis to decrease, affecting the analysis of each page in the next step. The number of bad pages finally obtained will also be large, greatly reducing the effective capacity of Nand Flash after analysis and detection.

[0088] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0089] In addition, the term "and / or" in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article, unless otherwise specified, generally means that the associated objects before and after are in an "or" relationship.

[0090] The following is attached to the instruction manual Figure 1-8 The embodiments of the present application are described in further detail.

[0091] Embodiment 1

[0092] The present application embodiment provides a detection method for Flash intelligent analysis detection, and the main process of the method is described as follows:

[0093] Reference Figure 1 , S1, extract the template Block from all the Blocks of Flash, based on the template Block, obtain the original Column subset, the original Page subset, the Column set containing all the original Column subsets, the Page set containing all the original Page subsets, and the Block set containing the Column set and the Page set, preset the bad Column set, the bad Page set, the error threshold that can be updated with the number of iterations, and the initial bad Block template containing the bad Column set and the bad Page set, the error threshold includes the Column error threshold corresponding to the bad Column set and the Page error threshold corresponding to the bad Page set.

[0094] Nand Flash can be physically divided into Block, Page and Column. Nand Flash consists of several Blocks, each Block consists of several Pages, each Page consists of several Columns, and any storage unit in each Column is related to one of the Pages. Nand Flash addresses are divided into three categories: Block Address corresponding to Block, Page Address corresponding to Page, and Column Address corresponding to Column. For the same Block, each Page and each Column is equivalent to forming a matrix. Page Address and Column Address jointly determine the address of each storage unit in the same Block, where Page Address is equivalent to the x-coordinate in the coordinate system, and Column Address is equivalent to the y-axis coordinate in the coordinate system.

[0095] In step S1, an original Column subset refers to a Column, and each element in the original Column subset can represent the position of each storage unit in a Column; an original Page subset refers to a Page, and each element in the original Page subset can represent the position of each storage unit in a Page. The Page total set refers to the total set containing all original Column subsets, which is equivalent to containing all Columns; the Page total set refers to the total set containing all original Page subsets, which is equivalent to containing all Pages; the Block total set refers to the total set containing all Columns and all Pages, which is equivalent to containing all storage units in the template Block.

[0096] The total set of bad columns refers to the set containing all bad column values. When a column value corresponding to any original column subset is evaluated as a bad column value, a bad column element can be generated based on the original column subset and added to the total set of bad columns. The total set of bad pages refers to the set containing all bad pages. When a page corresponding to any original page subset is evaluated as a bad page, a bad page element can be generated based on the original page subset and added to the total set of bad pages. The total set of bad columns is equivalent to a bad column value template that marks all bad column values. When Flash stores data, it will skip all storage units on this part of the columns in the bad column value template. Similarly, the total set of bad pages is equivalent to a bad page template that marks all bad pages. When Flash stores data, it will skip all storage units on this part of the pages in the bad page template. Therefore,

[0097] In this embodiment, the initial set of the total set of bad Pages and the initial set of the total set of bad Columns are both empty sets, and the total set of bad Pages and / or the total set of bad Columns need to gradually become accurate by extracting bad Page elements and / or bad Column elements and updating them iteratively; in other embodiments, if individual bad Pages and / or bad Columns can be determined before analysis and detection, the corresponding bad Page elements and / or bad Column elements can be pre-added to the total set of bad Pages and / or the total set of bad Columns.

[0098] The initial block template contains the total set of bad columns and the total set of bad pages, which is equivalent to containing the badColumnolmun template and the bad Page template. If the initial bad block template is used to analyze all blocks in the read and write Flash, the effective capacity of the Flash can be evaluated. The error threshold is one of the conditions for evaluating bad columns and / or bad pages in instruction error correction, which is equivalent to the standard for judging a column as a bad column and / or a page as a bad page. The value of the error threshold directly affects the number of elements in the total set of bad columns and / or bad pages.

[0099] It is worth noting that the error threshold is not a definite absolute value, and there is no absolute limit for bad columns and / or bad pages. The larger the error threshold, the stricter the evaluation of bad columns and / or bad pages. The number of bad columns and / or bad pages obtained will tend to decrease, and the effective capacity of the Flash after analysis and detection will increase. Otherwise, the number of bad columns and / or bad pages obtained will tend to increase, and the effective capacity of the Flash after analysis and detection will decrease.

[0100] Specifically, the error threshold includes a Page error threshold for evaluating a bad Page and a Column error threshold for evaluating a bad Column. In this embodiment, the ECC instruction is used for error correction, the data is first written to all Pages, then read out for comparison, and the number of erroneous bits of each Page is counted, and then the average number of erroneous bits of all Pages is taken as the initial Page error threshold; similarly, the ECC instruction is used for error correction, the number of erroneous bits of each Column is counted, and the average number of erroneous bits of all Columns is taken as the initial Column error threshold.

[0101] Reference Figure 1 , S2, alternately follow the bad page selection strategy and the bad column selection strategy, alternately obtain bad Page elements and bad Column elements from the total Block set based on the error threshold, and alternately update the total bad Page set and the total bad Column set.

[0102] Among them, the bad page selection strategy is a method of obtaining bad Page elements from the total set of Blocks, and replacing the total set of bad Pages with a set containing all bad Page elements, that is, updating the total set of bad Pages, which is equivalent to updating the bad Page template. The bad column selection strategy is a method of obtaining bad Column elements from the total set of Blocks, and replacing the total set of bad Columns with a set containing all bad Column elements, that is, updating the total set of bad Columns, which is equivalent to updating the bad Column template, thereby obtaining a more accurate bad Page template and / or bad Column template.

[0103] Specifically, since the bad page selection strategy and the bad column selection strategy are performed alternately, the update of the total set of bad pages and the total set of bad columns are also performed alternately, that is, the order of first selecting the bad page, updating the bad page template, then selecting the bad column based on the current bad page template, and then updating the bad column template is formed. It is worth noting that due to the physical properties of Nand Flash, some pages are bad pages themselves. Therefore, updating the bad page template first can select these pages that are originally bad pages first, reduce the impact of these pages on the update of the bad column template, and improve the accuracy of the bad column template.

[0104] Reference Figure 2 , in step S2, including:

[0105] S21. According to the bad column interference elimination strategy, a subset of pages to be tested is obtained from the total set of pages based on the total set of bad columns. According to the bad page judgment strategy, each subset of pages to be tested is analyzed in turn based on the page error threshold, bad page elements are obtained from the total set of blocks, and the total set of bad pages is updated based on the bad page elements.

[0106] Among them, the bad column interference elimination strategy refers to a method of reducing the interference of the current bad column on the evaluation of the bad page in this step. The tested page subset refers to the storage unit that needs to be tested for error correction instructions in the corresponding page set. The bad page judgment strategy refers to a method of evaluating whether the page corresponding to the tested page subset is a bad page by reading and writing the number of errors in the tested page subset and comparing it with the page error threshold.

[0107] Since all storage units in each bad column in the bad column set have been evaluated as storage units that need to be skipped when storing data, if these storage units participate in the analysis of the page again, it will affect the accuracy of the analysis results and cause too many bad pages. Therefore, it is necessary to first extract a subset of the pages to be tested from each page set to reduce the impact of the current bad column on each page set, and then update the bad page template.

[0108] Reference Figure 3 , in step S21, including:

[0109] S211, map the total set of bad columns to each original page subset to obtain each interference page subset.

[0110] Among them, by mapping the total set of bad columns to the original page subset, the intersection between the total set of bad columns and the original subset can be obtained, which is equivalent to obtaining the overlapping storage units between the bad column and the page. Each original page subset is corresponding to a corresponding interference page subset, and the interference page subset includes all storage units in the original page subset that overlap with the current bad column.

[0111] S212 , sequentially obtaining the complement of each interfering Page subset in each corresponding original Page subset to generate each Page subset to be tested.

[0112] Each original Page subset has a corresponding interference Page subset. For any original Page subset, the interference Page subset includes the storage units in the original Page subset that overlap with the current bad Column; therefore, the complement of the interference Page subset in the original Page subset, i.e., the interference Page subset, includes all storage units that are less affected by the current bad Column and need to participate in Page analysis.

[0113] S213 , according to the bad page judgment strategy, analyze each of the to-be-tested Page subsets in turn based on the Page error threshold, obtain the bad Page element from the total Block set, and update the total bad Page set based on the bad Page element.

[0114] Among them, the bad page judgment strategy refers to a method of evaluating the damage degree of the page corresponding to the tested page subset by analyzing the storage units in the tested page subset. If the damage degree of the page reaches the degree corresponding to the page error threshold, the page needs to be evaluated as a bad page, and a bad page element is generated based on the page and recorded in the total bad page set.

[0115] Reference Figure 3 , in step S213, including:

[0116] S2131. According to the instruction error correction strategy, the Page error value of each Page subset to be tested is obtained in sequence.

[0117] Among them, the instruction error correction strategy refers to a method of correcting errors through ECC instructions, first writing data to each storage unit of the Page subset to be tested, then reading it out for comparison, and counting the number of erroneous bits. The larger the absolute value of the number of bits calculated by the ECC instruction error correction, the larger the Page error value of the Page subset to be tested.

[0118] S2132: Based on the Page error threshold and each Page error value, and in accordance with the bad Page screening strategy, select the Page subsets to be tested that do not meet the Page validity condition from each Page subset to be tested as the failed Page subset.

[0119] The bad page screening strategy is a method of judging whether the tested page subset meets the page validity condition by comparing the page error value and the page error threshold. If the page error value of the tested page subset is greater than or equal to the page error threshold, the tested page subset can be judged as an invalid page subset.

[0120] S2133. Obtain bad Page elements based on the original Page subset corresponding to the invalid Page subset, and obtain a set including all bad Page elements as a total bad Page set.

[0121] Among them, the tested Page subsets corresponding to each invalid Page subset do not meet the Page validity condition, so the Pages corresponding to each invalid Page subset can be evaluated as bad Pages, and obtaining each bad Page element based on each bad Page is equivalent to marking each bad Page with each bad Page element. After resetting the total set of bad Pages to an empty set, adding all the obtained bad Page elements to the total set of bad Pages is equivalent to making the current total set of bad Pages include all bad Pages, completing the update of the bad Page template.

[0122] It is worth noting that in the current step, each Page that is not a bad Page will be evaluated as a good Page, and the number of good Pages should be at least 30% of the total number of Pages.

[0123] S22. According to the bad page interference elimination strategy, based on the bad Page total set, the Column subset to be tested is obtained from the Column total set. According to the bad column judgment strategy, each Column subset to be tested is analyzed in turn based on the Column error threshold, the bad Column element is obtained from the Block total set, and the bad Column total set is updated based on the bad Column element.

[0124] Among them, the bad page interference elimination strategy refers to a method of reducing the interference of the current bad page on the evaluation of the bad column in this step. The column subset to be tested refers to the storage unit that needs to be tested for error correction instructions in the corresponding column set. The bad column judgment strategy refers to a method of evaluating whether the column corresponding to the column subset to be tested is a bad column by reading and writing the number of errors in the column subset to be tested and comparing it with the column error threshold.

[0125] Since all storage units in each bad Page in the bad Page set have been evaluated as storage units that need to be skipped when storing data, if these storage units participate in the analysis of the Column again, it will affect the accuracy of the analysis results, resulting in an excessive number of bad Columns, which is equivalent to the generation of false bad Columns; therefore, it is necessary to first extract a subset of the columns to be tested in each Column set to reduce the impact of the current bad Page on each Column set, and then update the bad Column template.

[0126] Reference Figure 4 , in step S22, including:

[0127] S221. Map the total set of bad Pages to each original Column subset to obtain each corresponding interference Column subset.

[0128] Among them, by mapping the total set of bad pages to the original Column subset, the intersection between the total set of bad pages and the original subset can be obtained, which is equivalent to obtaining the overlapping storage units between the bad page and the column. Each original Column subset is corresponding to an interference Column subset, and the interference Column subset includes all the storage units in the original Column subset that overlap with the current bad page.

[0129] S222. Obtain the complement of each interfering Column subset in each corresponding original Column subset in sequence, and generate each Column subset to be tested corresponding to each original Column subset.

[0130] Each original Column subset has a corresponding interference Column subset. For any original Column subset, the interference Column subset includes the storage units in the original Column subset that overlap with the current bad page; therefore, the complement of the interference Column subset in the original Column subset, i.e., the interference Column subset, includes all storage units that are less affected by the current bad page and need to participate in the Column analysis.

[0131] S223. According to the bad page judgment strategy, each Column subset to be tested is analyzed in turn based on the Column error threshold, the bad Column element is obtained from the total Block set, and the total bad Column set is updated based on the bad Column element.

[0132] Among them, the bad page judgment strategy refers to a method of evaluating the damage degree of the column corresponding to the column subset to be tested by analyzing the storage units in the column subset to be tested. If the damage degree of the column reaches the degree corresponding to the column error threshold, the column needs to be evaluated as a bad column, and a bad column element is generated based on the column and recorded in the total bad column set.

[0133] Reference Figure 4 , in step S223, including:

[0134] S2231. According to the instruction error correction strategy, the column error value of each column subset to be tested is obtained in turn.

[0135] Among them, the instruction error correction strategy refers to a method of correcting errors through ECC instructions, first writing data to each storage unit of the column subset to be tested, then reading it out for comparison, and counting the number of erroneous bits. The larger the absolute value of the number of bits calculated by the ECC instruction error correction, the larger the column error value of the column subset to be tested.

[0136] S2232. Based on the Column error threshold and each Column error value, according to the bad Column screening strategy, select the Column subsets to be tested that do not meet the Column validity condition from each Column subset to be tested as the failed Column subset.

[0137] The bad column screening strategy is a method of judging whether the column subset to be tested meets the column validity condition by comparing the column error value and the column error threshold. If the column error value of the column subset to be tested is greater than or equal to the column error threshold, the column subset to be tested can be judged as an invalid column subset.

[0138] S2233. Obtain bad Column elements based on the original Column subset corresponding to the failed Column subset, and obtain a set containing all bad Column elements as the total bad Column set.

[0139] Among them, the Column subset to be tested corresponding to each invalid Column subset does not meet the Column validity condition, so the Column corresponding to each invalid Column subset can be evaluated as a bad Column, and obtaining each bad Column element based on each bad Column is equivalent to marking each bad Column with each bad Column element. After resetting the total set of bad columns to an empty set, adding all the obtained bad Column elements to the total set of bad columns is equivalent to making the current total set of bad columns include all bad columns, completing the update of the bad column template.

[0140] It is worth noting that in the current step, the columns that are not bad columns will be evaluated as good columns, and the number of good columns should be at least 30% of the total number of columns.

[0141] S3. Based on the bad column sets and bad page sets corresponding to different column error thresholds, the column error threshold is updated according to the bad template iteration strategy, and the final column set is obtained from the bad column sets, and the final page set is obtained from the bad page sets.

[0142] Among them, by updating the error threshold, multiple bad Page sets and / or bad Column sets corresponding to different error thresholds can be obtained, and by screening, comparing and judging, an error threshold that is sufficient to meet the needs can be selected from multiple error thresholds, and the bad Page set corresponding to the Page error threshold is obtained as the final Page set, and the bad Column set corresponding to the Column error threshold is obtained as the final Column set, so that the bad Block template finally obtained is more accurate.

[0143] Reference Figure 5 , in the steps of S3, including:

[0144] S31 . Establish a template library for storing templates to be compared corresponding to different error thresholds.

[0145] The template to be compared is the badPage template and / or bad Column template of the current bad Page template and / or bad Column template before updating; the template library stores the template to be compared for comparison with the current bad Page template and / or bad Column template. It is worth noting that the template to be compared is equivalent to a candidate template of the final bad Block template. When the template to be compared meets the requirement, the final bad Block template can be obtained from the template to be compared.

[0146] S32. According to the template comparison strategy, determine whether the complete error threshold in the current template library has a minimum value that meets the effective capacity condition. If so, execute S34; otherwise, execute S33.

[0147] Among them, according to the template comparison strategy refers to a method of comparing the current bad Page template and / or bad Column template with the previous bad Page template and / or bad Column template to evaluate the impact of the error threshold update; since the larger the error threshold, the smaller the effective capacity after the Flash analysis detection is completed, but the larger the error threshold, the smaller the accuracy of the bad Page template and / or bad Column template, so it is necessary to select the minimum error threshold that meets the effective capacity; if this error threshold is not selected in the current step, the error threshold should continue to be updated and iterated until the minimum error threshold that meets the effective capacity condition is successfully selected. It is worth noting that the complete error threshold in the current template library has a minimum value that meets the effective capacity condition, which means that there is both a minimum Column error threshold that meets the effective capacity condition and a minimum Page error threshold that meets the effective capacity condition.

[0148] Reference Figure 5 and Figure 6 , in the step of S3, including: in the step of S32, including:

[0149] S321, determine whether the current template library contains a template to be compared, if so, execute S322; if not, execute S323.

[0150] If there is no template to be compared in the current template library, it means that the current bad Page template and / or bad Column template has not been updated with the error threshold, and there is no template to be compared in the template library, so it is impossible to determine whether the requirement is met. If there is a template to be compared in the current template library, it is necessary to compare and analyze the current bad Page template and / or bad Column template with the current template to be compared.

[0151] S322, determine whether the template to be compared meets the iteration termination condition, if yes, execute S34; if no, execute S33.

[0152] Among them, when the total set of bad columns in the template to be compared and the total set of bad pages in the template to be compared simultaneously meet the iteration termination conditions, the minimum error threshold that meets the effective capacity appears, so the update of the error threshold can be stopped, and the final total set of columns and / or the final total set of pages are selected based on the judgment results.

[0153] Reference Figure 6 and Figure 7 , in step S322, including:

[0154] S3221. Preset a column validity threshold, and determine whether the total set of bad columns in the current template to be compared meets the valid capacity condition based on the column validity threshold. If yes, execute S3222; otherwise, execute S331.

[0155] Among them, since the more bad columns there are, the more columns need to be skipped when storing data in each column, so the total number of bad columns needs to be limited, and the column effective threshold refers to the maximum number of bad columns. When the number of elements in the total set of bad columns is greater than or equal to the column effective threshold, it means that the current number of bad columns is too large and the effective capacity of each column does not meet the demand, so it is necessary to reduce the value of the column error threshold and iteratively update the bad column template.

[0156] S3222. Preset a Column iteration threshold, analyze the template to be compared and the total set of bad columns based on the Column iteration threshold, and determine whether the template to be compared meets the capacity change condition. If so, execute S3223; otherwise, execute S331.

[0157] Among them, the total set of bad columns in the template to be compared is the previous bad column set of the current bad column set; when the column error threshold changes, the difference between the total number of elements in the current bad column set and the total number of elements in the previous bad column set can reflect the impact of the change of the column error threshold on the previous bad column set. The smaller the impact, the less significance the change of the column error threshold has on the update and iteration of the template to be compared, and the column error threshold needs to be updated; on the contrary, the greater significance the change of the column error threshold has on the update and iteration of the template to be compared. The column iteration threshold refers to the minimum value of the change in the number of bad columns before and after the update. In order to make the final bad column template more accurate and less affected by the change of the column error threshold, it is necessary to select the template to be compared whose change in the number of bad columns before and after the update is less than the column iteration threshold as the bad column template. Therefore, if the change in the number of bad columns before and after the update is less than the column iteration threshold, the current template to be compared meets the capacity change condition.

[0158] Specifically, the template to be compared and the total set of bad columns are analyzed based on the column iteration threshold to determine whether the template to be compared meets the capacity change condition. If so, S3223 is executed; if not, S331 is executed, including:

[0159] The absolute value of the difference between the total number of elements in the total set of bad columns in the template to be compared and the total number of elements in the current total set of bad columns is obtained as the Column comparison value, and the Column comparison value and the Column iteration threshold are compared. If the Column comparison value is less than the Column iteration threshold, execute S3223; if the Column comparison value is greater than or equal to the Column iteration threshold, execute S331.

[0160] S3223, preset a Page validity threshold, and determine whether the total set of bad Pages in the current template to be compared meets the valid capacity condition based on the Page validity threshold. If yes, execute S3224; otherwise, execute S332.

[0161] At this point, a more accurate bad Column template has been obtained, and a more accurate badPage template needs to be selected. Since the more bad Pages there are, the more Pages need to be skipped when storing data in each Page, so the total number of bad Pages needs to be limited, and the Page effective threshold refers to the maximum number of bad Pages. When the number of elements in the total bad Page set is greater than or equal to the Page effective threshold, it means that the current number of bad Pages is too large and the effective capacity of each Page does not meet the demand, so it is necessary to reduce the value of the Page error threshold and iteratively update the bad Page template.

[0162] S3224, preset a Page iteration threshold, analyze the template to be compared and the total set of bad Pages based on the Page iteration threshold, and determine whether the template to be compared meets the capacity change condition. If so, execute S34; otherwise, execute S332.

[0163] Among them, the total set of bad pages in the template to be compared is the previous bad page set of the current bad page set; when the Page error threshold changes, the difference between the total number of elements in the current bad page set and the total number of elements in the previous bad page set can reflect the impact of the change in the Page error threshold on the previous bad page set. The Page iteration threshold refers to the minimum value of the change in the number of bad pages before and after the update. In order to make the final bad Page template more accurate and less affected by the change in the Page error threshold, it is necessary to select the template to be compared whose change in the number of bad pages before and after the update is less than the Page iteration threshold as the bad Page template. Therefore, if the change in the number of bad pages before and after the update is less than the Page iteration threshold, the current template to be compared meets the capacity change condition.

[0164] Specifically, the step of analyzing the template to be compared and the total set of bad pages based on the Page iteration threshold to determine whether the template to be compared meets the capacity change condition, if yes, executing S34; otherwise, executing S332 includes:

[0165] The absolute value of the difference between the total amount of elements in the total set of bad Pages in the template to be compared and the total amount of elements in the current total set of bad Pages is obtained as the Page comparison value, and the Page comparison value and the Page iteration threshold are compared. If the Page comparison value is less than the Page iteration threshold, execute S34; if the Page comparison value is greater than or equal to the Page iteration threshold, execute S332.

[0166] S323. Obtain a template to be compared that includes the current total set of bad columns and the current total set of bad pages, and store the template to be compared in a template library.

[0167] At this point, there is no template to be compared in the current template library, the current bad Page template is the bad Page template obtained in the first update, and the current bad Column template is also the bad Column template obtained in the first update. Therefore, the current bad Page template and the current bad Page template bad Column template need to be added to the template library as templates to be compared.

[0168] Reference Figure 6 , S33, update the error threshold based on the judgment result, update the template to be compared based on the total set of bad columns and the total set of bad pages, store them in the template library, and return to S2.

[0169] Among them, since the error threshold includes the Column error threshold and the Page error threshold, it is necessary to determine based on the judgment result whether the current Column error threshold is not the minimum value that satisfies the effective capacity condition, or the Page error threshold is not the minimum value that satisfies the effective capacity condition; and after the Column error threshold and / or the Page error threshold are updated, the current bad Column total set and the current bad Page total set need to be stored in the template library as new templates to be compared. At this time, the old template to be compared is replaced by the current bad Column total set and the current bad Page total set.

[0170] Reference Figure 6 and Figure 7 , in step S33, including:

[0171] S331. Preset the Column update value, obtain the absolute value of the difference between the Column update value and the Column error threshold as the Column error threshold, update the current total set of bad Columns to the template to be compared, and return to S211.

[0172] The process of updating the Column error threshold is the process of gradually reducing the Column error threshold. The Column update value refers to the value that needs to be subtracted each time the Column error threshold is updated. When the Column error threshold is updated, the current bad Column total set replaces the bad Column total set in the template to be compared, which is equivalent to using the current bad Column template as a new template to be compared, waiting to be compared with the subsequently updated bad Column template. Both the Column error threshold and the bad Column template will be updated until a more accurate bad Column template that meets the requirements appears.

[0173] S332, preset a Page update value, obtain the absolute value of the difference between the Page update value and the Page error threshold as the Page error threshold, update the current total set of bad Pages to the template to be compared, and return to S211.

[0174] At this point, a more accurate bad column template has been obtained, and a more accurate bad page template needs to be selected by updating the page error threshold. The page update value refers to the value that needs to be subtracted each time the page error threshold is updated. When the page error threshold is updated, the current bad page total set replaces the bad page total set in the template to be compared, which is equivalent to using the current bad page template as a new template to be compared, waiting to be compared with the subsequently updated bad page template.

[0175] S34. Generate a final Column total set and a final Page total set based on the judgment result.

[0176] At this time, the Column error threshold corresponding to the total set of bad columns in the template to be compared is the minimum value that meets the effective capacity condition, so the total set of bad columns in the template to be compared is obtained as the final total set of columns; at the same time, the Page error threshold corresponding to the total set of bad pages in the template to be compared is the minimum value that meets the effective capacity condition, so the total set of bad pages in the template to be compared is obtained as the final total set of pages.

[0177] S4. Update the initial bad block template based on the final Column total set and the final Page total set, obtain the final bad block template, use the final bad block template to analyze and read and write all blocks, and obtain the effective capacity of the Flash.

[0178] At this point, the bad column template represented by the final Column set is the final more accurate bad column template, and the bad page template represented by the final Page set is the final more accurate bad page template. Therefore, the final Column set replaces the bad column set in the initial bad block template, and the final Page set replaces the bad page set in the initial bad block template, and then the initial bad block template is obtained as the final bad block template, so that a more accurate bad block template can be obtained. After using the final bad block template to analyze and read and write all blocks, the effective capacity of the Flash can be obtained more accurately.

[0179] The implementation principle of this embodiment is as follows: Nand Flash contains multiple Blocks, one Block is equivalent to a matrix, Page is equivalent to a row in the matrix, and Column is equivalent to a column in the matrix; the bad Page template can mark several Pages, and these Pages need to be skipped when storing data; the bad Column template can mark several Columns, and these Columns need to be skipped when storing data. In the analysis and detection of Nand Flash, an initial badPage template and an initial bad Column template are first preset, and at this time, the bad Page template and the bad Column template are both empty sets, and then the bad Page is obtained from each Page and the bad Page template is updated, and then the bad Column is obtained from each Column and the bad Column template is updated. This process of updating the bad Page template and the bad Column template in sequence is equivalent to first updating the bad Page template assuming that there is no bad Column, and then updating the bad Column template based on the current bad Page template. Since the above process obtains the bad Page from the beginning, the part of each Page that has been damaged due to physical properties can be obtained first, reducing the interference of this part of the Page on the evaluation of each Column, thereby improving the accuracy of the bad Column template, reducing the generation of false bad Columns, and reducing the risk of too low effective capacity after Nand Flash analysis and detection due to too many false bad columns.

[0180] On the other hand, the updates of the bad Page template and the bad Column template in sequence form the update of the bad Block template, and in this embodiment, the bad Block template will undergo multiple update iterations, and the updates of the bad Page template and the bad Column template will affect each other. Improving the accuracy of the bad Column template from the beginning can improve the overall accuracy of the bad Block template in subsequent iterative updates.

[0181] Since there is no absolutely clear boundary between the quality of bad Page and bad Column, that is, there is no completely accurate standard for bad Page and bad Column, it is necessary to preset the error threshold and update the error threshold, and then obtain a relatively accurate error threshold from multiple error thresholds as a relative standard for judging the quality of bad Page and / or bad Column. The error threshold includes the Page error threshold and the Column error threshold. Each time the Page error threshold and / or the Column error threshold is updated, the bad Block template is iterated. The update of the Page error threshold can cause the bad Page template to iterate. By comparing the current bad Page template with the bad Page template before iteration, it can be evaluated whether the bad Page template before iteration is less affected by the Column error threshold and meets the effective capacity requirements, and finally obtain a more accurate bad Page template; similarly, the update of the Column error threshold can cause the bad Column template to iterate.

[0182] After obtaining the final bad Page template and the final bad Column template, the final bad Block template can be obtained. After writing and reading all blocks through the final bad Block template, the effective capacity of the current NandFlash can be obtained. The bad Block template after multiple iterations is more accurate. On the one hand, it reduces the generation of false bad Columns and increases the effective capacity of Nand Flash after analysis and detection. On the other hand, it can make the data stored in Nand Flash more stable.

[0183] Embodiment 2:

[0184] Reference Figure 8 In one embodiment, a detection system for intelligent analysis and detection of Flash is provided, which corresponds to the detection method in the first embodiment and is applied to the analysis and detection of the effective capacity of Nand Flash. The system includes an initial template establishment module 1, a template update module 2, a template iteration module 3 and a final template generation module 4. The functional modules are described in detail as follows:

[0185] The initial template establishment module 1 is used to obtain the total set of columns, the total set of pages, and the total set of blocks including the total set of columns and the total set of pages, preset the total set of bad columns, the total set of bad pages, an error threshold that can be updated with the number of iterations, and an initial bad block template including the total set of bad columns and the total set of bad pages;

[0186] The template updating module 2 is used to alternately obtain bad Page elements and bad Column elements from the total set of Blocks according to the bad page selection strategy and the bad column selection strategy based on the error threshold, and alternately update the total set of bad Pages and the total set of bad Columns;

[0187] The template iteration module 3 is used to update the error threshold according to the bad template iteration strategy based on each bad column total set corresponding to different error thresholds and each bad page total set corresponding to different error thresholds, obtain the final column total set from each bad column total set, and obtain the final page total set from each bad page total set;

[0188] The final template generation module 4 is used to update the initial bad Block template based on the final Column total set and the final Page total set to obtain the final bad Block template.

[0189] Embodiment three:

[0190] In one embodiment, a smart terminal is provided, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the memory stores training data, algorithm formulas, and filtering mechanisms in a training model. The processor is used to provide computing and control capabilities, and when the processor executes the computer program, the following steps are implemented:

[0191] S1. Obtain the total set of columns, the total set of pages, and the total set of blocks including the total set of columns and the total set of pages, preset the total set of bad columns, the total set of bad pages, an error threshold that can be updated with the number of iterations, and an initial bad block template including the total set of bad columns and the total set of bad pages;

[0192] S2. Alternately follow the bad page selection strategy and the bad column selection strategy, alternately obtain bad Page elements and bad Column elements from the total Block set based on the error threshold, and alternately update the total bad Page set and the total bad Column set;

[0193] S3, based on the total sets of bad columns corresponding to different error thresholds and the total sets of bad pages corresponding to different error thresholds, the error threshold is updated according to the bad template iteration strategy, and the final total set of columns is obtained from the total sets of bad columns, and the final total set of pages is obtained from the total sets of bad pages;

[0194] S4. Update the initial bad Block template based on the final Column total set and the final Page total set to obtain the final bad Block template.

[0195] Embodiment 4:

[0196] In one embodiment, a computer-readable storage medium is provided, which stores a computer program that can be loaded by a processor and execute the above-mentioned small-area fingerprint image feature extraction method. When the computer program is executed by the processor, the following steps are implemented:

[0197] S1. Obtain the total set of columns, the total set of pages, and the total set of blocks including the total set of columns and the total set of pages, preset the total set of bad columns, the total set of bad pages, an error threshold that can be updated with the number of iterations, and an initial bad block template including the total set of bad columns and the total set of bad pages;

[0198] S2. Alternately follow the bad page selection strategy and the bad column selection strategy, alternately obtain bad Page elements and bad Column elements from the total Block set based on the error threshold, and alternately update the total bad Page set and the total bad Column set;

[0199] S3, based on the total sets of bad columns corresponding to different error thresholds and the total sets of bad pages corresponding to different error thresholds, the error threshold is updated according to the bad template iteration strategy, and the final total set of columns is obtained from the total sets of bad columns, and the final total set of pages is obtained from the total sets of bad pages;

[0200] S4. Update the initial bad Block template based on the final Column total set and the final Page total set to obtain the final bad Block template.

[0201] The computer-readable storage medium includes, for example, various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0202] The embodiments of the specific implementation methods are all preferred embodiments of the present application, and are not intended to limit the protection scope of the present application. Therefore, any equivalent changes made based on the structure, shape, and principle of the present application should be included in the protection scope of the present application.

Claims

1. A detection method applied to Flash intelligent analysis detection, characterized in that: The following steps are involved: S1. Obtain the total set of columns, the total set of pages, and the total set of blocks including the total set of columns and the total set of pages, preset the total set of bad columns, the total set of bad pages, an error threshold that can be updated with the number of iterations, and an initial bad block template including the total set of bad columns and the total set of bad pages; S2. Alternately follow the bad page selection strategy and the bad column selection strategy, alternately obtain bad Page elements and bad Column elements from the total Block set based on the error threshold, and alternately update the total bad Page set and the total bad Column set; S3, based on the total sets of bad columns corresponding to different error thresholds and the total sets of bad pages corresponding to different error thresholds, the error threshold is updated according to the bad template iteration strategy, and the final total set of columns is obtained from the total sets of bad columns, and the final total set of pages is obtained from the total sets of bad pages; S4. Update the initial bad block template based on the final Column total set and the final Page total set to obtain the final bad block template; Among them, the step S2 includes: S21. According to the bad column interference elimination strategy, a page subset to be tested is obtained from the page total set based on the bad column total set. According to the bad page judgment strategy, each page subset to be tested is analyzed in turn based on the error threshold, bad page elements are obtained from the block total set, and the bad page total set is updated based on the bad page elements. S22, according to the bad page interference elimination strategy, based on the bad Page total set, each Column subset to be tested is obtained from the Column total set, according to the bad column judgment strategy, each Column subset to be tested is analyzed in turn based on the error threshold, the bad Column element is obtained from the Block total set, and the bad Column total set is updated based on the bad Column element; The steps in S3 include: S31, establishing a template library for storing templates to be compared corresponding to different error thresholds; S32, according to the template comparison strategy, determine whether the complete error threshold in the current template library has a minimum value that meets the effective capacity condition, if so, execute S34; if not, execute S33; S33, update the error threshold, update the template to be compared based on the total set of bad columns and the total set of bad pages, store them in the template library, and return to S2; S34. Generate a final Column total set and a final Page total set based on the judgment result.

2. The method according to claim 1, characterized in that In step S1, it also includes: obtaining each original Column subset and each original Page subset, the Column total set includes each original Column subset, and the Page total set includes each original Page subset; The step S21 includes: S211, mapping the total set of bad columns to each original page subset to obtain each interference page subset; S212, sequentially obtaining the complement of each interference Page subset in each corresponding original Page subset to generate each Page subset to be tested; S213, according to the bad page judgment strategy, analyze each of the to-be-tested Page subsets in turn based on the error threshold, obtain the bad Page element from the total Block set, and update the total bad Page set based on the bad Page element; The step S22 includes: S221, mapping the total set of bad pages to each original column subset to obtain each interference column subset; S222, sequentially obtaining the complement of each interference Column subset in each corresponding original Column subset as each Column subset to be tested; S223. According to the bad column judgment strategy, each bad column element is obtained from each column subset to be tested based on the error threshold, and the total set of bad columns is updated.

3. The method according to claim 2, characterized in that The step S213 includes: S2131, according to the instruction error correction strategy, sequentially obtain the Page error value of each Page subset to be tested; S2132, based on the error threshold and each Page error value, in accordance with the bad Page screening strategy, select the Page subsets to be tested that do not meet the Page validity condition from each Page subset to be tested as the failed Page subset; S2133, obtaining bad Page elements based on the original Page subset corresponding to the invalid Page subset, and obtaining a set including all bad Page elements as a total bad Page set; The step S223 includes: S2231, according to the instruction error correction strategy, sequentially obtain the column error value of each column subset to be tested; S2232, based on the error threshold and the column error value, according to the threshold comparison strategy, select the column subsets to be tested that do not meet the column accuracy condition from each column subset to be tested as the failed column subset; S2233. Obtain bad Column elements based on the original Column subset corresponding to the failed Column subset, and obtain a set containing all bad Column elements as the total bad Column set.

4. The method according to claim 1, characterized in that: The step S32 includes: S321, determine whether there is a template to be compared in the current template library, if yes, execute S322; if not, execute S323; S322, determine whether the template to be compared meets the iteration termination condition, if yes, execute S34; if not, execute S33; S323, obtaining a template to be compared that includes the current total set of bad columns and the current total set of bad pages, and storing the template to be compared in a template library; In the step S34, it also includes: obtaining the total set of bad columns in the template to be compared as the final total set of columns, and obtaining the total set of bad pages in the template to be compared as the final total set of pages.

5. The method according to claim 4, characterized in that The step S322 includes: S3221, preset a column effective threshold, and determine whether the total set of bad columns in the current template to be compared meets the effective capacity condition based on the column effective threshold. If yes, execute S3222; otherwise, execute S33; S3222, preset a Column iteration threshold, analyze the template to be compared and the total set of bad columns based on the Column iteration threshold, and determine whether the template to be compared meets the capacity change condition. If so, execute S3223; if not, execute S33; S3223, preset a Page validity threshold, and determine whether the total set of bad Pages in the current template to be compared meets the valid capacity condition based on the Page validity threshold. If yes, execute S3224; otherwise, execute S33; S3224. Preset a Page iteration threshold, analyze the template to be compared and the total set of bad Pages based on the Page iteration threshold, and determine whether the template to be compared meets the capacity change condition. If so, execute S34; otherwise, execute S33.

6. A detection system for Flash intelligent analysis and detection, used to execute the detection method according to any one of claims 1 to 5, characterized in that: include, The initial template establishment module (1) is used to obtain the total set of columns, the total set of pages, and the total set of blocks including the total set of columns and the total set of pages, preset the total set of bad columns, the total set of bad pages, an error threshold that can be updated according to the number of iterations, and an initial bad block template including the total set of bad columns and the total set of bad pages; The template update module (2) is used to alternately obtain bad Page elements and bad Column elements from the total set of Blocks according to the bad page selection strategy and the bad column selection strategy based on the error threshold, and alternately update the total set of bad Pages and the total set of bad Columns; The template iteration module (3) is used to update the error threshold according to the bad template iteration strategy based on the bad column total sets corresponding to different error thresholds and the bad page total sets corresponding to different error thresholds, obtain the final column total set from the bad column total sets, and obtain the final page total set from the bad page total sets; The final template generation module (4) is used to update the initial bad block template based on the final column total set and the final page total set to obtain the final bad block template.

7. An intelligent terminal, characterized in that: The method comprises a memory and a processor, wherein the memory stores a computer program that can be loaded by the processor and executes any one of the detection methods according to claims 1 to 5.

8. A computer-readable storage medium, characterized in that: A computer program is stored which can be loaded by a processor and executes the detection method according to any one of claims 1 to 5.