Drive Your Robot
You can
build a simple mobile robot using two DC
motors and two wheels. And now I am going to explain you how you can drive your
robot. The driving mechanism now I am going to explain is differential drive.
The
differential drive design has two DC motors in left and right which are attached
to two wheels. And since we need three
ground contacts we need extra castor wheel.
Here by
changing the speeds of the two motors we can make robot to go on different
paths.
So using
differential drive we can achieve movements as follows
Driving straight forward : VLeft
= VRight
Driving a right curve : VLeft > VRight
Spot turning : Vleft = -VRight
So by
adjusting the speeds of two motors we can move the robot as we need. So to
control the motor speeds we need a motor controller circuit. If you don't know
about motor controller you can view the article about the motor controller in
this blog. DC Motor Control Circuit For Your Robot.
So we can
change the motor speed by changing the given voltage to it, otherwise we can
change the voltage given at enable pin of the motor controller to change the
speed.
This could be achieved by using the PWM output pins in your micro controller. So let's see what is Pulse Width Modulation
This could be achieved by using the PWM output pins in your micro controller. So let's see what is Pulse Width Modulation
Pulse Width Modulation
In order to control the motor speed we
can generate a voltage signal that is proportional to the motor speed. In other
words we can generate an analog voltage signal to control the speed. But
instead of generating analog signals we can use pulses of digital signal to achieve
this. By changing the width of pulse we can generate the analog voltage signal
to control the motor. This method is known as Pulse width modulation. And in
most microcontrollers there are PWM output pins to control DC motors, or drive
servo motors etc.
So by
changing the voltage at enable pin of the motor controller we can drive our
robot.
So next our
target is to drive the robot according to its environment, for example following
an line, or avoiding obstacles etc. So in my next post I will explain how to
control the robot motion according to its environment. There I
will discuss about the PID control theory to move robot.
No comments:
Post a Comment