This paper capitalizes the commercialized production of DSP (digital signal process)chip, and make use of digital distance algorithm to realize digital distance relays. When a fault occurs on line during operation, the signals of voltage and current would be severely distorted. These signals may contain decaying dc components. It could seriously influence the judgment and accuracy of relays. For the purpose of achieving the goal of fast response, relays have to quickly obtain the fundamental signals of voltage and current from the input signal containing noise. This paper accomplishes COSFilter by TMS320VC33 DSP,simulation and verify to realize the digital distance relays.