Performance analysis of ultrasonic ranging using a digital polarity correlator