Use ping_median for better accuracy of the distance sensor