Increase Ultrasonic Distance Resolution
A quick fix that gives your ultrasonic sensor higher resolution and less distance reading failures
The trouble with the sensor when mounted in a case, similar to how EZ-Robot ships theirs, is sound echoes. The ultrasonic sensor uses sound, which echoes inside the plastic case. Even when a sensor is not mounted in a case, it may echo around behind it by the robot. The solution is to wrap it in foam or cotton balls, exposing only the receiver and transmitter.