Abstract:In order to improve the accuracy of ultrasonic ranging, this paper analysis the principle of ultrasonic distance measurement, proposes the solution from the hardware and software in dealing with the main factors affecting the accuracy of ultrasonic ranging -the ambient temperature and the echo time. On the software by performing the propagation velocity correction at different temperatures in order to eliminate temperature’s influence to ranging accuracy; In hardware, the boost driver transmitter circuit, the amplitude compensation circuit of echo signal composed by an instrumentation amplifier and the detection circuit composed by an dual comparator has been designed to improve the quality of ultrasound and determine the travel time better. Experiment on obstacles between 0.5 m and 5 m shows that ranging error of the system can be limited within the scope of 10 mm; Application shows that the system is stable and reliable, and highly accurate, so the system has certain practical value.