Skip to Content

Line Follower 1 Channel Infrared Tracking Detection Sensor On Back TCRT5000

This IR Reflective Sensor Module is based on the TCRT5000 infrared reflective optical sensor and is designed to detect color contrast and short-range distance by emitting infrared light and sensing the reflected signal. It is widely used in line follower robots, object detection, and automatic data logging on utility meters, as it can reliably distinguish between white and black surfaces.

Package Includes

  • 1 x TCRT5000 IR Reflective Sensor Module
Line Follower Sensor Module
6.30 AED 6.30 AED (Tax included)

Terms and Conditions
30-day money-back guarantee
Shipping: 2-3 Business Days

 

The module operates by continuously emitting infrared light when powered. If the emitted IR light is reflected back with sufficient strength, the sensor detects the object or surface. If no reflection or insufficient reflection is detected, the module remains in the OFF state. An onboard potentiometer allows easy adjustment of sensitivity, making the module flexible for different environments and surface types.

Features

  • Based on the TCRT5000 IR reflective sensor
  • Detects black and white surfaces using IR reflection
  • Suitable for line follower robots and proximity detection
  • Adjustable sensitivity via onboard potentiometer
  • Digital output for easy microcontroller interfacing
  • Onboard indicator LED for detection status
  • Compact and easy-to-use module

Specifications

  • Supply Voltage: 3.3V – 5V
  • Detection Distance: 1 mm – 8 mm
  • Optimal Detection Point: ~2.5 mm
  • Digital Output: LOW when object detected
  • Indicator: Onboard LED
  • Sensitivity Adjustment: Onboard potentiometer

How a Line Follower Robot Works

A line follower robot is a robot that follows a predefined path, usually a black line on a white surface. This behavior is achieved using IR sensors like the TCRT5000. White surfaces reflect infrared light, while black surfaces absorb it. By detecting this difference in reflection, the robot can determine its position relative to the line and adjust its movement accordingly.

Light Absorption on Black Surface

Light absorbed by black surface

Light Reflection on White Surface

Light reflected by white surface

Working Principle with Two Sensors

In a typical line follower robot, two IR sensors are used: one on the left and one on the right.

Both Sensors on White Surface – Robot Moves Forward

Robot moving forward

Left Sensor on Black Line – Robot Turns Left

Robot turning left

Right Sensor on Black Line – Robot Turns Right

Robot turning right

Both Sensors on Black Line – Robot Stops

Robot stopping

Arduino Code Example

The following Arduino sketch demonstrates how to use two TCRT5000 IR sensors with an L293 motor driver to build a simple line follower robot.


int vSpeed = 110;        // MAX 255
int turn_speed = 230;   // MAX 255
int turn_delay = 10;

// L293 Motor Driver Connections
const int motorA1 = 8;
const int motorA2 = 10;
const int motorAspeed = 9;
const int motorB1 = 12;
const int motorB2 = 13;
const int motorBspeed = 11;

// Sensor Connections
const int left_sensor_pin = A0;
const int right_sensor_pin = A1;

int left_sensor_state;
int right_sensor_state;

void setup() {
  pinMode(motorA1, OUTPUT);
  pinMode(motorA2, OUTPUT);
  pinMode(motorB1, OUTPUT);
  pinMode(motorB2, OUTPUT);
  Serial.begin(9600);
  delay(3000);
}

void loop() {
  left_sensor_state = analogRead(left_sensor_pin);
  right_sensor_state = analogRead(right_sensor_pin);

  if (right_sensor_state > 500 && left_sensor_state < 500) {
    Serial.println("turning right");
    digitalWrite(motorA1, LOW);
    digitalWrite(motorA2, HIGH);
    digitalWrite(motorB1, LOW);
    digitalWrite(motorB2, HIGH);
    analogWrite(motorAspeed, vSpeed);
    analogWrite(motorBspeed, turn_speed);
  }

  if (right_sensor_state < 500 && left_sensor_state > 500) {
    Serial.println("turning left");
    digitalWrite(motorA1, HIGH);
    digitalWrite(motorA2, LOW);
    digitalWrite(motorB1, HIGH);
    digitalWrite(motorB2, LOW);
    analogWrite(motorAspeed, turn_speed);
    analogWrite(motorBspeed, vSpeed);
    delay(turn_delay);
  }

  if (right_sensor_state > 500 && left_sensor_state > 500) {
    Serial.println("going forward");
    digitalWrite(motorA2, LOW);
    digitalWrite(motorA1, HIGH);
    digitalWrite(motorB2, HIGH);
    digitalWrite(motorB1, LOW);
    analogWrite(motorAspeed, vSpeed);
    analogWrite(motorBspeed, vSpeed);
    delay(turn_delay);
  }

  if (right_sensor_state < 500 && left_sensor_state < 500) {
    Serial.println("stop");
    analogWrite(motorAspeed, 0);
    analogWrite(motorBspeed, 0);
  }
}

Applications

  • Line follower robots
  • Obstacle and edge detection
  • Color detection (black vs white)
  • Automatic meter reading systems
  • Educational robotics projects
  • DIY and prototyping projects