Waveshare AlphaBot 2 User Manual page 13

Table of Contents

Advertisement

share awesome hardware
AlphaBot 2 User Manual
In this example, the robot goes straight when there is no obstacle, and turns right
when obstacle is detected.
Ultrasonic distance measurement
Compile and download the program Ultrasonic_Ranging. Open the serial monitor,
and set the baud rate to 115200. Then, the monitor displays the current measured
distance.
Ultrasonic obstacle avoidance
Compile and download the program Ultrasonic-Obstacle-Avoidance. In this
example, the robot goes straight when there is no obstacle, and turns right when
obstacle is detected. Since the ultrasonic can be reflected, if the obstacle is not in
the front of the robot, but is at an angle with the robot, the distance measured
between the robot and the obstacle may be inaccurate.
13

Hide quick links:

Advertisement

Table of Contents
loading

Related Products for Waveshare AlphaBot 2

Table of Contents