A method of determining errors in a data storage device is disclosed. The
disclosed method includes receiving a first code word from the data
storage device. The method further includes determining whether a data
error exists in the code word by analyzing a plurality of subsequent code
words. Detecting a data error includes calculating first, second, and
third checksums for each of a plurality of subsequent code words and
determining whether there is an insertion or deletion error based on the
calculated checksums. A further method includes receiving location
information of errors on a data medium and adjusting a write clock
frequency to reduce the probability of creating errors on the data medium
during a write process.