Patent ID: 7921339

Claim:
A flash storage device with data correction function, comprising: a flash memory, which includes at least a memory unit and a page buffer; a transmission buffer, which is used to register the information that the page buffer accesses; an error correction unit, connected to the transmission buffer, for checking and correcting the data in the transmission buffer based on an Error Check Code (ECC) and for generating a check result; a correction information register, connected to the error correction unit, for registering the check result; and a microprocessor, wherein the microprocessor, after generating a read instruction for page copy to the flash memory, reads the data in the page buffer and stores the data to the transmission buffer, and controls the error correction unit and the correction information register to operate, and furthermore generates a corresponding program instruction based on the number of data errors determined via a first threshold and a second threshold in the check result to program a corrected data into the memory unit, wherein the microprocessor further uses a first threshold and a second threshold to determine the number of data errors to generate a corresponding program instruction.