Patent ID: 7051232

Claim:
A method of accessing data on an optical disk with an optical drive, the Optical drive comprising a memory having a plurality of buffers for recording data; the optical disk having a plurality of data area packets (DA packets) and a plurality of spare area packets (SA packets), each DA packet having a plurality of data blocks for recording user data, each SA packet having a plurality of spare blocks for replacing corresponding defect data blocks or defect spare blocks to record data; the method comprising: when writing data recorded in a first buffer to a first SA packet, if the first SA packet has a plurality of defective first spare blocks, searching for an SA packet as a second SA packet having a plurality of second spare blocks for replacing the plurality of defective first blocks; if the second SA packet and the first SA packet are different packets, reading data of the second SA packet to a second buffer, and recording data of the first buffer for preparing to write the defective first spare blocks to the second spare blocks; when writing data of the second buffer to the second SA packet, if the SA packet has at least one defective second spare block, searching for an SA packet as a third SA packet having a third spare block for replacing the defective second spare block; and if the third SA packet and the second SA packet are different packets, reading data of the third SA packet and overwriting data of the first buffer, so that the first buffer no longer records data written to the first block.