-->

Tuesday, December 19, 2017

Line Following Robot – Arduino Line Following Robot – Electronic Project




Now day’s several industries are exploitation robots as a result of their high level of performance and responsibleness and that could be a great help for people in general. The Line follower is an autonomous robot which follows either black line in white are or white line in black area. Robot must be able to detect particular line and keep following it.

In this project, a Line Follows Robot is designed. It is an Arduino based robot that uses Digital Line flowing  sensor  to Following Line.

Watch the below video to get an idea of what you could build by following this article.




Video Source By- Learning Engineering


Hardware Required:-



• Arduino UNO .
• Digital Line Following Sensor.
• Robot chassis & 1 Castor Wheel .
• Some Screws & Nuts.
• 2 DC Gear Motors.
• L293D Motor Driver.
• Some Jumper Wires.
• Power source: 9V Battery and 5V battery pack.
• Softwares: Arduino IDE.




Connection  Diagram:- 


The control circuitry of this autonomous robot is built around Arduino UNO. The Digital Line Following Sensor and motor driver L293D IC coupled with two geared DC motors are interfaced with the Arduino board. The control circuitry has the following components and circuit connections –




To control A  and B DC motors is sort of easy with the L298D Motor Driver IC. 1st connect every motor to the A and B connections on L298D Motor Driver. If you’re using 2 motors for a robocar make sure that the polarity of the motors is that the same on each input. Otherwise you'll need to swap them over when you set each motors to forward and one goes backwards.

Next, connect your 9V power supply to the L298D Motor Driver – the positive to pin Vcc on the module and negative/GND to pin GND. 
The Digital Line Following sensor has 4 pins: Vcc, SEN1, SEN2 and Gnd. Vcc and Gnd are connected to the supply pins 5V and GND of the Arduino. SEN1 is connected to the 2nd pin and SEN2 is connected to 3rd pin of the Arduino.
L293D could be a sixteen pin IC. Pins one and nine are enable pins. they're connected to Vcc. Pins two and seven ar control inputs from microcontroller for 1st motor. they're connected to pins nine and eight of Arduino severally.
Similarly, pins ten and fifteen are control inputs from microcontroller for second motor. they're connected to pins four and three of Arduino. Pins 4, 5, 12 and 13 of L293D ar ground pins and ar connected to Gnd.

Finally, connect the Arduino digital output pins to the Motor driver. In our example we have two DC motors, so digital pins D4, D5, D6 and D7 will be connected to pins IN1, IN2, IN3 and IN4 respectively. 


Circuit Diagram of the L293D Motor Driver IC:- 




Upload the below code to arduino:- 



#define LS 2       
#define RS 3       

#define LM1 4        
#define LM2 5        
#define RM1 6        
#define RM2 7        
void setup()
{
  pinMode(LS, INPUT);
  pinMode(RS, INPUT);
  pinMode(LM1, OUTPUT);
  pinMode(LM2, OUTPUT);
  pinMode(RM1, OUTPUT);
  pinMode(RM2, OUTPUT);
}
void loop()
{
  if(digitalRead(LS) && digitalRead(RS))      
  {
    digitalWrite(LM1, HIGH);
    digitalWrite(LM2, LOW);
    digitalWrite(RM1, HIGH);
    digitalWrite(RM2, LOW);
  }
  
  if(!(digitalRead(LS)) && digitalRead(RS))      
  {
    digitalWrite(LM1, LOW);
    digitalWrite(LM2, LOW);
    digitalWrite(RM1, HIGH);
    digitalWrite(RM2, LOW);
  }
  
  if(digitalRead(LS) && !(digitalRead(RS)))     
  {
    digitalWrite(LM1, HIGH);
    digitalWrite(LM2, LOW);
    digitalWrite(RM1, LOW);
    digitalWrite(RM2, LOW);
  }
  
  if(!(digitalRead(LS)) && !(digitalRead(RS)))    
  {
    digitalWrite(LM1, LOW);
    digitalWrite(LM2, LOW);
    digitalWrite(RM1, LOW);
    digitalWrite(RM2, LOW);
  }
}


Applications:- 

• Industrial Applications: These robots can be used as automated equipment carriers in industries     replacing traditional conveyer belts.
• Automobile applications: These robots can also be used as automatic cars running on roads with embedded magnets.
• Domestic applications: These can also be used at homes for domestic purposes like floor cleaning etc.
• Guidance applications: These can be used in public places like shopping malls, museums etc to provide path guidance.


NEXT ARTICLE Next Post
PREVIOUS ARTICLE Previous Post
NEXT ARTICLE Next Post
PREVIOUS ARTICLE Previous Post