49
Figure 4-5-5 Infrared remote control instructions
4.6 Ultrasonic obstacle avoidance
4.6.1 Introduction to Ultrasound
In the "Panther-Tank" car, we use the HC-SR04 ultrasonic module to measure distance and obstacles.
The module can provide 2cm-400cm non-contact distance sensing function, ranging accuracy up to 3mm;
The temperature sensor corrects the ranging result and uses GPIO communication mode with a watchdog
inside, which is stable and reliable. The module includes an ultrasonic transmitter, a receiver, and a control
circuit. Figure 4-6-1 is a relatively common ultrasonic sensor.
Figure 4-6-1 Ultrasonic module physical map
4.6.2 Module parameter
Working voltage: 4.5V~5.5V. In particular, it is absolutely not allowed to exceed 5.5V.
Power consumption current: minimum 1mA, maximum 20mA
Resonant frequency: 40KHz
;
Detection range: 4 mm to 4 m. Error: 4%
;
Dimensions: 48mm * 39mm * 22mm (H
)