Test System and Method for Reading and Writing Internal Flash Memory of Chip under Power Loss

By using the internal Flash read/write power-down rewrite test system and GPIO timing triggering and programmable power analyzer, we have achieved efficient and low-cost power-down reliability testing. This solves the problems of low fault reproduction efficiency and high cost in existing technologies and can accurately locate and quantify failure modes.

CN123114875APending Publication Date: 2026-11-17ALLYSTAR TECH SHENZHEN CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611620369.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-20
Publication Date
2026-11-17

AI Technical Summary

Technical Problem

Existing methods for power-down reliability testing of internal flash memory in chips cannot accurately reproduce power-down events, resulting in low fault reproduction efficiency, inability to quantify test coverage, high costs, and inability to pinpoint specific failure modes.

Method used

A test system for reading and writing Flash memory under power failure is adopted. It utilizes a GPIO timing trigger module and a programmable power analyzer. By flipping the GPIO flag pin, the Flash operation window becomes externally observable. Combined with the power waveform controlled by the host computer to inject power-up and power-down disturbances, bit flip vector analysis and three-image comparison are performed to automatically locate the failure mode.

Benefits of technology

It enables efficient and low-cost power-down reliability testing, accurately reproduces faults, automatically traverses the parameter space, locates and quantifies failure modes, and guides firmware power-down protection strategies and hardware design improvements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123114875A_ABST
    Figure CN123114875A_ABST
Patent Text Reader

Abstract

This invention discloses a system and method for testing the read / write power-down rewriting of internal Flash memory in a chip. The system includes a host computer, a programmable power analyzer, and a chip under test (DUT). The DUT includes a GPIO timing trigger module, which flips the GPIO flag pin just before a write / erase operation. The programmable power analyzer injects power-up and power-down disturbances during Flash read / write operations within the DUT. The host computer erases the Flash memory in the DUT and writes a baseline image. The host computer reads the disturbed image from the DUT and compares it with the baseline image and the desired image. Based on the comparison results, bit-flip vector analysis is performed, and the test results are output. This invention enables stable reproduction of Flash rewriting faults, and the test is parameterized, quantifiable, localizable, attributable, and has low implementation costs.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of chip testing technology, and in particular to a chip internal Flash read / write power-off rewrite test system and method. Background Technology

[0002] Embedded devices (such as electricity meters, vehicle controllers, IoT terminals, and fast charging protocol devices) use their internal Flash memory for firmware storage (IAP upgrades), parameter areas, and calibration data areas. In actual use, these devices inevitably encounter sudden power outages, voltage drops, or power fluctuations. If this disturbance occurs within the programming or erasing window of the on-chip Flash memory, it can lead to failures such as partial writes to the target area, accidental rewriting of non-target areas, weak erasures, and corruption of option bytes / configuration areas.

[0003] To address the aforementioned power-down reliability issues, existing testing methods mainly include: (1) Manually plugging and unplugging the power supply or randomly cutting off the power via the relay: randomly cut off the power supply during the operation of the equipment, and check whether the equipment can start normally after repeated cycles; (2) Repeated power-on and power-off of the aging table: Powering on and off the entire machine in batches at a fixed cycle, and statistically analyzing the macroscopic failure rate; (3) ATE-level testing by chip manufacturers: memory testing is performed by automated testing equipment during the die mass production screening stage; (4) Fault injection simulation: Injecting interrupt / reset events into Flash operation code in a simulation environment.

[0004] Existing testing methods have the following drawbacks: (1) The operation of the on-chip Flash is not visible to the outside of the chip (no bus can be sniffed), the external test equipment cannot know the start time of the write / erase operation window, the power failure event cannot be precisely aligned with the operation window, the power failure time of manual plugging and unplugging and aging bench mode is random and cannot be reproduced, the fault reproduction efficiency is extremely low and the coverage cannot be quantified. (2) Power-on and power-off events cannot be parameterized: the power-on slope, power-off slope (dV / dt), voltage jitter amplitude and frequency, drop depth, secondary power-off and other real working conditions cannot be reproduced by program control. (3) The failure judgment method is crude: usually only "whether it can be started" is compared, and it is impossible to locate the specific address area that has been rewritten, the bit flip direction (0→1 / 1→0), and to distinguish failure modes such as half-write, rewriting of non-target area, weak erase, and configuration area damage. (4) ATE-level testing is geared towards bare die screening, which is costly and does not cover the real application scenario of "whole system + firmware writing process"; software simulation of injection errors cannot reproduce the physical processes of the simulation domain such as power rail slope and voltage jitter. (5) The "operation type × injection delay × power waveform" parameter space cannot be automatically traversed, and the test coverage and reproducibility are not guaranteed. Summary of the Invention

[0005] The technical problem to be solved by the embodiments of the present invention is to provide a chip internal Flash read / write power-down rewrite test system and method to achieve low cost and high efficiency power-down reliability.

[0006] To address the aforementioned technical problems, this invention proposes a chip internal Flash read / write power-down rewrite test system, comprising a host computer, a programmable power supply analyzer, and a chip under test, wherein the chip under test includes a GPIO timing trigger module. The GPIO timing trigger module flips the GPIO flag pin just before initiating a write / erase operation in the Flash memory of the chip under test; The host computer controls the programmable power analyzer to power on and off the chip under test using a preset power waveform, injecting power-on and power-off disturbances during Flash read / write operations within the chip under test. The host computer erases the Flash memory in the chip under test and writes a preset pattern with partitioned differences as a baseline image. The host computer reads the pattern written in the chip under test, obtains the perturbed image, and compares it with the baseline image and the expected image. Based on the comparison results, it performs bit-flip vector analysis and outputs the test results.

[0007] Accordingly, embodiments of the present invention also provide a method for testing the read / write rewriting of internal Flash memory of a chip after power failure, including: Initialization steps: Erase the Flash memory in the chip under test and write a preset pattern as a baseline image; perform a CRC check on the entire chip under test. Parameter loading steps: Send the preset power waveform parameters of the disturbance, and set the injection delay Td and the target operation type for this round; Trigger capture steps: Flip the GPIO flag pin before initiating the write / erase operation in the Flash memory of the chip under test; Disturbance injection step: After injection delay Td, the chip under test is subjected to power-down / power-on / voltage jitter according to the preset power waveform; Power restoration procedure: Restore power supply according to the set low-level hold time and power-on slope; Readback and comparison steps: Read back the entire chip under test to obtain the perturbed image, and compare it with the baseline image and the expected image. Perform bit-flip vector analysis. Categorization and storage steps: Record each injection to form an invalid database; Parameter scanning steps: Update the injection delay Td and power waveform parameters according to the preset scanning strategy, reconstruct the baseline image, and return to the parameter loading step for loop after the CRC check passes; Summary output steps: Based on the results of multiple tests, the following are summarized: sensitive time window spectrum, failure probability-injection delay curve, failure mode distribution, overwritten address heatmap and test report.

[0008] The beneficial effects of this invention are as follows: (1) Observable and alignable: GPIO firmware marking enables the on-chip Flash, which is "not visible to the outside", to be mapped to the outside of the chip in real time. The disturbance injection delay establishes microsecond-level deterministic alignment with the operation window. The Flash rewriting fault can be stably reproduced, solving the fundamental problem of "occasional and unreproducible" in traditional random power failure testing. (2) Parameterizable: With the help of the arbitrary waveform capability of the programmable power supply analyzer, the real working conditions such as power-on slope, power-off slope, voltage jitter, drop depth, and secondary power failure are all programmable, covering scenarios such as slow discharge, voltage sag recovery, and power failure during recovery that cannot be reproduced by manual plugging and unplugging. (3) Quantifiable: Automatically traverses the parameter space of "operation type × injection delay × power waveform" and outputs the sensitive time window spectrum and failure probability curve. The test coverage is measurable and the results are reproducible. (4) Locable and attributable: Three-image data comparison + bit flip vector analysis automatically distinguishes four types of failure modes: half-write, non-target area rewriting, weak erasure, and configuration area corruption, and locates the rewritten address, directly guiding the improvement of firmware power-down protection strategies (dual-area backup, pre-write flag, CRC log) and hardware design (BOR threshold, energy storage capacitor capacity). (5) Low implementation cost: The core instrument is a general-purpose programmable power analyzer. Only one GPIO and a small amount of firmware are needed on the DUT side. No customized ATE equipment is required. It is suitable for chip selection verification, firmware power-down protection verification and whole machine reliability testing. Attached Figure Description

[0009] Figure 1 This is a schematic diagram of the chip internal Flash read / write power-off rewrite test system according to an embodiment of the present invention.

[0010] Figure 2 This is an injection timing diagram according to an embodiment of the present invention.

[0011] Figure 3 This is a flowchart illustrating the chip internal Flash read / write power-off rewrite test method according to an embodiment of the present invention.

[0012] Figure 4This is a schematic diagram of the test waveform of Embodiment 1 of the present invention. Detailed Implementation

[0013] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0014] In this embodiment of the invention, directional indicators (such as up, down, left, right, front, back, etc.) are only used to explain the relative positional relationship and movement of each component in a specific posture (as shown in the figure). If the specific posture changes, the directional indicator will also change accordingly.

[0015] Furthermore, in this invention, descriptions involving "first," "second," etc., are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of those features.

[0016] Please refer to Figure 1 The chip internal Flash read / write power-down rewrite test system of this invention includes a host computer, a programmable power supply analyzer, and a chip under test (DUT). The programmable power supply analyzer can be an N6705C DC power supply analyzer.

[0017] As one implementation method, the chip internal Flash read / write power-off rewrite test system also includes a delay / logic conditioning unit.

[0018] The connection is as follows: The host computer connects to the programmable power analyzer via LAN / USB / GPIB interface using SCPI commands to send disturbance waveform parameters and read recorded data; the output channel of the programmable power analyzer connects to the power input terminal VDD of the DUT to provide controlled power to the chip under test; one GPIO flag pin of the DUT connects to the digital trigger input port of the programmable power analyzer (or connects after a delay / logic conditioning unit); the host computer also connects to the DUT via SWD / JTAG debug port or UART for programming test firmware and reading back on-chip Flash data. The DUT receives control through SWD / UART to read / write / erase the on-chip Flash, and simultaneously marks it with GPIO. The programmable power analyzer's DIG IO captures the markings, achieving timing alignment between waveform and Flash operations.

[0019] The chip under test (DUT) includes a GPIO timing trigger module, which is, in practice, firmware loaded within the DUT. The GPIO timing trigger module addresses the core issue of "the on-chip Flash operation window being invisible to the outside." The GPIO timing trigger module toggles the GPIO flag pin just before initiating a write / erase operation on the DUT's Flash memory. That is, the GPIO flag pin is set high just before the write / erase operation and set low after the operation is complete (BSY flag is cleared). The high-level range of the GPIO pin maps the internal Flash operation window (connected to the digital trigger input port of the programmable power analyzer) to the outside of the chip in real time.

[0020] In practical implementation, multi-pin or pulse counting / pulse width encoding methods can be used to distinguish operation types (e.g., 1 pulse = page programming, 2 pulses = page erase, long level = batch write). GPIO toggle instructions and Flash start instructions are executed adjacent to each other. The inherent deviation of the flag relative to the operation start point is a fixed number of instruction cycles (sub-microseconds). This can be calibrated using an oscilloscope by comparing with the power supply current step and compensated for in the delay setting, thereby obtaining a deterministic time base T0.

[0021] The programmable power supply analyzer parameterizes and waveforms power-on / off events. GPIO flags are connected to its digital trigger input. The power supply is pre-loaded with a power waveform (ARB arbitrary waveform) for disturbance. Upon receiving a trigger, the output is executed after a set delay Td, achieving deterministic alignment between the disturbance event and the Flash operation window. In other words, after a Flash write / erase operation within the chip under test, the programmable power supply analyzer performs the power-on / off operation on the chip under test after injecting a delay Td.

[0022] Waveform parameters include: power-on slope (e.g., 0.1V / ms~100V / ms, covering large capacitor slow-up and hard-up), power-down slope (simulating large capacitor slow-down and hard-cutoff), voltage jitter (a programmable amplitude / frequency square wave / sine wave / random jitter superimposed on VDD, such as ±0.2~±0.5V, 10Hz~10kHz), voltage sag (recovering after dropping to the middle level near the BOR threshold), low-level hold time, and secondary power-down (re-injection in the firmware recovery process after the first power-down recovery). Simultaneously, the voltage / current digital acquisition function of the programmable power analyzer is used to record the actual VDD waveform and Flash operating current characteristics for each injection, serving as a test evidence chain. In practice, power-on and power-off operations can also be performed by binding the enable pins of the DC-DC chip or LDO chip on a common test board via GPIO.

[0023] The present invention provides fully parameterized waveforms for power-on and power-off disturbances—power-on slope, power-off slope, voltage jitter (amplitude / frequency / waveform), voltage sag depth, low-level hold time, and secondary power-off are all programmably implemented using the arbitrary waveform function of a programmable power analyzer, and together with the injected delay Td, form an traversable parameter space (i.e., Flash storage space), which is used in conjunction with three scanning strategies: linear stepping, binary convergence, and Monte Carlo to perform automated testing; while existing technologies only have two states for power-off events, "on" and "off", and cannot reproduce real operating conditions such as slow power-off, voltage jitter, sag recovery, and power-off during recovery.

[0024] Delay / Logic Conditioning Unit: When a delay resolution superior to that of the power analyzer trigger link is required, or when pulse counting decoding of GPIO operation type encoding is needed, a hardware delay / logic unit implemented by a timer or CPLD is inserted between the GPIO and the power trigger input. The delay resolution is ≤1μs. The GPIO edge → power trigger → waveform output link does not involve the host computer software, ensuring the reproducibility of the injected delay Td.

[0025] The host computer controls the programmable power analyzer to power on and off the chip under test using a preset power waveform, injecting power-on and power-off disturbances during Flash read / write operations within the chip under test. The host computer erases the Flash within the chip under test and writes a preset pattern with partitioned differences as a baseline image. The host computer reads the pattern written within the chip under test, obtains the disturbed image, and compares it with the baseline image and the desired image. Based on the comparison results, it performs bit-flip vector analysis and outputs the test results.

[0026] In practice, after the host computer powers on and recovers, it performs a full-chip Flash readback via SWD / JTAG or serial port testing firmware. This involves a byte-by-byte comparison of the baseline image (known pattern before writing), the expected image (content to be written), and the image after disturbance. For each inconsistent byte, the number of 0→1 and 1→0 bits is counted. Based on the Flash's physical characteristics (programming can only be 1→0, erasure can only be 0→1), the failure mechanism is deduced, and failure modes are automatically classified. These failure modes include partial write, overwriting of non-target areas, weak erasure, and configuration area corruption.

[0027] Each injection by the host computer records the operation type, injection delay Td, power waveform parameters, failure mode, list of overwritten addresses, bit flip statistics, and measured VDD waveform to form a failure database; the operation types include read, write, and erase.

[0028] The host computer updates the Td and power waveform parameters according to the preset scanning strategy, reconstructs the baseline image, and retests after the CRC check passes, until the parameter space (i.e., the Flash storage space) is traversed. Based on the results of multiple tests, it summarizes the sensitive time window spectrum, failure probability-injection delay curve, failure mode distribution, rewritten address heatmap and test report.

[0029] Please refer to Figure 3 The chip internal Flash read / write power-off rewrite test method of this invention includes an initialization step, a parameter loading step, a trigger capture step, a disturbance injection step, a power restoration step, a readback comparison step, a classification and storage step, a parameter scanning step, and a summary output step.

[0030] Initialization steps: Erase the Flash memory in the chip under test and write a preset pattern with partitioned differences as a baseline image. Write an incrementing address sequence to the target test page (to locate the source address of erroneous writes), write a 0xAA / 0x55 checkerboard pattern to adjacent pages (most sensitive to bit flips), and write several sets of all 0xFF and all 0x00 to the farthest page (to detect unexpected programming and unexpected erasure, respectively). Perform a CRC check on the entire chip under test. Also, calibrate the inherent deviation of the GPIO flags relative to the actual starting point of the Flash operation. The purpose is to ensure that unexpected rewriting in any area can be detected and the failure mechanism can be deduced, establishing a deterministic time reference.

[0031] Parameter loading steps: Preset power waveform parameters for the disturbance are sent, and the injection delay Td and the target operation type for this round are set. In specific implementation, the host computer sends the disturbance waveform parameters (power-on slope, power-off slope, jitter amplitude / frequency, drop depth, hold time) to the programmable power supply via SCPI, and sets the injection delay Td and the target operation type for this round (read / write / erase). The purpose is to achieve complete parameterization of power-on and power-off disturbances.

[0032] Trigger capture steps: Before initiating a write / erase operation on the Flash memory of the chip under test, the GPIO flag pin is toggled. In practice, the firmware within the chip under test executes the target Flash operation, toggles the GPIO flag pin before the operation, and the power-triggered input captures this edge as T0. Its function is to transform the invisible start point of the on-chip Flash operation window into an externally captureable hardware trigger event.

[0033] Disturbance injection step: After an injection delay Td, the chip under test is subjected to power-down / power-on / voltage jitter according to a preset power supply waveform. That is, at time T0+Td, the power supply performs power-down / power-on / voltage jitter according to the pre-installed waveform, and the actual VDD voltage and current waveforms are simultaneously digitally recorded. (Please specify parameters.) Figure 2 , Figure 2This demonstrates firmware startup Flash programming, GPIO flag rising edge (T0), programmable delay Td, VDD waveform drop / jitter, and the relative relationship between the programming window and the injection point. Its purpose is to ensure microsecond-level deterministic alignment between the disturbance timing and the operation window, and to preserve evidence of measured waveforms.

[0034] Power waveform parameters include one or more of the following: power-on slope, power-off slope, voltage jitter (amplitude / frequency / waveform), voltage sag, low-level hold time, and secondary power-off.

[0035] Power restoration steps: Power is restored according to the set low-level hold time and power-on slope. Optionally, a secondary power-down injection can be performed during the firmware power-down recovery process to test the robustness of the recovery mechanism itself.

[0036] Readback and comparison steps: The entire chip under test is read back to obtain a perturbed image, which is then compared with the baseline image and the expected image. Bit-flip vector analysis is performed. A partial 1→0 transition in the target area is considered a half-write; a 1→0 transition in a non-target area is considered an unexpected programming / address decoding error, i.e., "non-target area overwritten"; a 0→1 transition outside the target area is considered an erase range overflow, i.e., weak erase; changes in option bytes / protection bits are considered configuration area overwritten, i.e., configuration area corruption. A stable value is considered only if N consecutive reads (e.g., N=3) are consistent, eliminating false alarms from read perturbations. Its function is to locate the overwritten area and automatically attribute the cause.

[0037] Categorization and database entry steps: Each injection is recorded to form a failure database. Record items include operation type, injection delay Td, power waveform parameters, failure mode, list of overwritten addresses, bit flip statistics, and measured VDD waveform, etc.

[0038] Parameter scanning steps: Update the injection delay Td and power waveform parameters according to the preset scanning strategy, reconstruct the baseline image, and return to the parameter loading step after CRC verification is passed, repeating until the parameter space traversal is complete; if the chip under test suffers irreversible damage, mark the device as faulty and record the cumulative number of injections. Its function is to systematically traverse the "operation type × injection delay × power waveform" parameter space to prevent cumulative failure contamination in the judgment. The preset scanning strategy is linear step / binary convergence / random Monte Carlo.

[0039] Summary output steps: Based on the results of multiple tests, the following are summarized: sensitive time window spectrum, failure probability-injection delay curve, failure mode distribution, overwritten address heatmap and test report.

[0040] This invention outputs timing flags via GPIO before and after read / write / erase operations on the on-chip Flash firmware of the chip under test. This maps the externally invisible on-chip Flash operation window to the outside of the chip in real time. Using this flag as a trigger reference, a programmable power supply is controlled to inject a disturbance after a set delay Td, achieving microsecond-level deterministic alignment between power-down / jitter events and the Flash operation window. In contrast, existing technologies (manual insertion / removal, aging bench) result in random and unreproducible power-down moments, making alignment with the operation window impossible. This invention compensates for this by encoding the operation type (multi-pin / pulse counting / pulse width encoding) of the GPIO flag and calibrating the inherent deviation of the flag.

[0041] The failure determination of this invention adopts a three-way data comparison of "baseline mirror - expected mirror - perturbation mirror" and bit flip direction vector analysis (1→0 / 0→1× target area / non-target area two-dimensional matrix), combined with partitioned differential baseline pattern (address increment sequence + checkerboard + all FF / all 00 partition), to automatically locate the rewritten address and classify it into four failure modes: half-write, non-target area rewritten, weak erasure, and configuration area destruction; while the existing technology only compares "whether it can start" or simple CRC, and cannot locate the rewritten area or attribute the failure mechanism.

[0042] Example 1: Power-on and power-off tests were conducted by controlling the 6705C programmable power supply.

[0043] Test process: 1. Loop Phase: Clear Flash file → Write preset file → Wait (1 + step × n) ms; 2. Detection phase: Power off → Wait 1 second → Power on → FS power-off detection and recovery; 3. Verification phase: Write several new files → Read several new files → Determine if the read data is normal.

[0044] Test waveform as follows Figure 4 As shown.

[0045] The test results are shown in Table 1.

[0046] Table 1 ; Example 2: Power-on / off tests were performed by receiving Flash read / write GPIO signals using a microcontroller.

[0047] Test process: 1. Test the chip by burning firmware with Flash read / write GPIO signals.

[0048] 2. Use an STM32 microcontroller to receive GPIO signals and control the power-on and power-off operation of the test sample by controlling the enable pin of the power supply chip.

[0049] The test results are shown in Table 2.

[0050] Table 2 ;

[0051] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A chip internal Flash read / write power-off rewrite test system, characterized in that, It includes a host computer, a programmable power supply analyzer, and the chip under test (DUT). The DUT includes a GPIO timing trigger module. The GPIO timing trigger module flips the GPIO flag pin just before initiating a write / erase operation in the Flash memory of the chip under test; The host computer controls the programmable power analyzer to power on and off the chip under test using a preset power waveform, injecting power-on and power-off disturbances during Flash read / write operations within the chip under test. The host computer erases the Flash memory in the chip under test and writes a preset pattern with partitioned differences as a baseline image. The host computer reads the pattern written in the chip under test, obtains the perturbed image, and compares it with the baseline image and the expected image. Based on the comparison results, it performs bit-flip vector analysis and outputs the test results. Each injection by the host computer records the operation type, injection delay Td, power waveform parameters, failure mode, list of overwritten addresses, bit flip statistics, and measured VDD waveform to form a failure database. The operation types include read, write, and erase, and the failure modes include half-write, overwriting of non-target areas, weak erase, and destruction of configuration areas. The host computer updates the Td and power waveform parameters according to the preset scanning strategy, reconstructs the baseline image, and retests after the CRC check passes, until the parameter space traversal is completed. Based on the results of multiple tests, it obtains the sensitive time window spectrum, failure probability-injection delay curve, failure mode distribution, rewritten address heatmap and test report.

2. The chip internal Flash read / write power-off rewrite test system as described in claim 1, characterized in that, After performing a write / erase operation on the Flash memory of the chip under test, the programmable power analyzer then injects a delay Td before performing power-on and power-off operations on the chip under test.

3. The chip internal Flash read / write power-off rewrite test system as described in claim 1, characterized in that, The preset power waveform parameters include one or more of the following: power-on slope, power-off slope, voltage jitter amplitude / frequency, voltage sag, low-level hold time, and secondary power-off.

4. A method for testing the read / write rewriting of internal Flash memory of a chip after power failure, characterized in that, include: Initialization steps: Erase the Flash memory inside the chip under test and write a preset pattern as a baseline image; Perform CRC verification on the entire chip under test; Parameter loading steps: Send the preset power waveform parameters of the disturbance, and set the injection delay Td and the target operation type for this round; Trigger capture steps: Flip the GPIO flag pin before initiating the write / erase operation in the Flash memory of the chip under test; Disturbance injection step: After injection delay Td, the chip under test is subjected to power-down / power-on / voltage jitter according to the preset power waveform; Power restoration procedure: Restore power supply according to the set low-level hold time and power-on slope; Readback and comparison steps: Read back the entire chip under test to obtain the perturbed image, and compare it with the baseline image and the expected image. Perform bit-flip vector analysis. Categorization and storage steps: Record each injection to form an invalid database; Parameter scanning steps: Update the injection delay Td and power waveform parameters according to the preset scanning strategy, reconstruct the baseline image, and return to the parameter loading step for loop after the CRC check passes; Summary output steps: Based on the results of multiple tests, the following are summarized: sensitive time window spectrum, failure probability-injection delay curve, failure mode distribution, overwritten address heatmap and test report.

5. The chip internal Flash read / write power-off rewrite test method as described in claim 4, characterized in that, During the power restoration process, a secondary power failure injection is performed to test the robustness of the restoration mechanism itself.

6. The chip internal Flash read / write power-off rewrite test method as described in claim 4, characterized in that, In the readback comparison step, if some bits in the target area change from 1 to 0, it is judged as a half-write; if bits in the non-target area change from 1 to 0, it is judged as the non-target area being overwritten; if bits outside the target area change from 0 to 1, it is judged as a weak erase. Changes in option bytes / protection bits are considered a violation of the configuration area.

7. The chip internal Flash read / write power-off rewrite test method as described in claim 4, characterized in that, The power waveform parameters include one or more of the following: power-on slope, power-off slope, voltage jitter amplitude / frequency, voltage sag, low-level hold time, and secondary power-off.

8. The chip internal Flash read / write power-off rewrite test method as described in claim 4, characterized in that, The classification and storage process records the operation type, injection delay Td, power waveform parameters, failure mode, list of overwritten addresses, bit flip statistics, and measured VDD waveform to form a failure database. The operation types include read, write, and erase, and the failure modes include half-write, overwriting of non-target areas, weak erase, and configuration area corruption.