Skip to content
SriTu Hobby
0
My Account
Home
Read
Shop
Control
About
How to make an Obstacle avoidance robot (L298N motor driver)
How to make an Obstacle avoidance robot (L298N motor driver)
Hello guys, welcome back to my SrTtu Hobby blog. Today we are going to learn how to make an obstacle avoidance robot at a low cost. Do you remember we created an obstacle avoidance robot in the last article? For this, we used a motor shield with an L293D IC. Through this motor drive shield, we were able to control four motors. Click this link and read it. But today we will use the L298N motor driver board for this robot car. We can only control two motors through this motor driver board. Click this link for more information.
The functionality of the robot car we describe today is similar to the functionality of the previous robot car article. This robot car can avoid obstacles. An ultrasonic sensor is mainly used for this purpose. We can get the distance through this sensor. Also, we can do this by calculating the obstacle distance range. Next, the servo motor is used to rotate the ultrasonic sensor left and right. This robot uses two toy cars and popsicle sticks for the motors, wheels, and chassis. Because I do this design at a low cost. So, all these components are controlled via the Arduino Uno board. For that, you can use any other Arduino board.
Ok, let’s see how does work this robot car
This starts to move forward when the power is applied for the first time. After, the robot car then stops when the ultrasonic sensor reaches a distance of less than 20 cm. After even, through the servo motor, the ultrasonic sensor turns left and right and calculates the distance to the obstacles on either side. Then, turn to the long-distance and go forward. This process continues. Okay, now let’s talk about how to do this project step by step. Below are the components you need for this. Also, you can buy these components easily using the given links.
Ezoic
Arduino Uno board x 1. — Our Store / Amazon
Motor driver board x 1. — Our Store / Amazon
Ultrasonic sensor x 1. — Our Store / Amazon
Servo motor x 1. — Our Store / Amazon
Toy cars x 2.
Popsicle sticks.– Amazon
Jumper wires.— Our Store / Amazon
Phone battery x 2.
Disclosure: These Amazon links are Affiliate links. As an Amazon Associate, I earn from qualifying purchases.
Step 1
Let’s identify these components.
Step 2
First, remove the two toy cars and get the parts we need.
How to make an Obstacle avoidance robot (L298N motor driver)
Step 3
After, set up the robot car chassis using popsicle sticks.
How to make an Obstacle avoidance robot (L298N motor driver)
Step 4
Next, attach the Arduino Uno board to the top of the chassis.
Step 5
How to make an Obstacle avoidance robot (L298N motor driver)
Step 6
After, attach the servo motor and the ultrasonic sensor as shown in the pictures below.
How to make an Obstacle avoidance robot (L298N motor driver)
Step 7
Next, connect these components