Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use IR Line Sensor Module: Examples, Pinouts, and Specs

Image of IR Line Sensor Module
Cirkit Designer LogoDesign with IR Line Sensor Module in Cirkit Designer

Introduction

The IR Line Sensor Module (Manufacturer: Generic, Part ID: TCRT5000 IR Sensor Module) is a compact and efficient sensor designed to detect the presence of a line or path. It operates by emitting infrared (IR) light and measuring the reflected light intensity to distinguish between different surface contrasts. This makes it ideal for applications such as line-following robots, path navigation, and object detection.

Explore Projects Built with IR Line Sensor Module

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Battery-Powered Line Following Robot with IR Sensors and Cytron URC10 Motor Controller
Image of URC10 SUMO AUTO: A project utilizing IR Line Sensor Module in a practical application
This circuit is a robotic control system that uses multiple IR sensors for line detection and obstacle avoidance, powered by a 3S LiPo battery. The Cytron URC10 motor driver, controlled by a microcontroller, drives two GM25 DC motors based on input from the sensors and a rocker switch, with a 7-segment panel voltmeter displaying the battery voltage.
Cirkit Designer LogoOpen Project in Cirkit Designer
IR Sensor-Controlled Relay with LED Indicator
Image of smart TV: A project utilizing IR Line Sensor Module in a practical application
This circuit uses an IR sensor to control a relay module, which in turn switches a 12V blue LED on and off. The IR sensor output is connected to the signal input of the relay, enabling the sensor to activate the relay. The relay's normally closed (NC) contact is connected to the LED, allowing the LED to be powered by a 9V battery when the relay is not activated by the IR sensor.
Cirkit Designer LogoOpen Project in Cirkit Designer
Battery-Powered IR Sensor Controlled Relay Module
Image of New: A project utilizing IR Line Sensor Module in a practical application
This circuit uses an IR sensor to control a 1 Channel 5V Relay Module, which is powered by a 9V battery. The IR sensor detects an object and sends a signal to the relay module to switch its state, enabling or disabling the connected load.
Cirkit Designer LogoOpen Project in Cirkit Designer
Battery-Powered Sumo Robot with IR Sensors and DC Motors
Image of MASSIVE SUMO AUTO BOARD: A project utilizing IR Line Sensor Module in a practical application
This circuit is designed for a robotic system, featuring a Massive Sumo Board as the central controller. It integrates multiple FS-80NK diffuse IR sensors and IR line sensors for obstacle detection and line following, respectively, and controls two GM25 DC motors via MD13s motor drivers for movement. Power is supplied by an 11.1V LiPo battery.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with IR Line Sensor Module

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of URC10 SUMO AUTO: A project utilizing IR Line Sensor Module in a practical application
Battery-Powered Line Following Robot with IR Sensors and Cytron URC10 Motor Controller
This circuit is a robotic control system that uses multiple IR sensors for line detection and obstacle avoidance, powered by a 3S LiPo battery. The Cytron URC10 motor driver, controlled by a microcontroller, drives two GM25 DC motors based on input from the sensors and a rocker switch, with a 7-segment panel voltmeter displaying the battery voltage.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of smart TV: A project utilizing IR Line Sensor Module in a practical application
IR Sensor-Controlled Relay with LED Indicator
This circuit uses an IR sensor to control a relay module, which in turn switches a 12V blue LED on and off. The IR sensor output is connected to the signal input of the relay, enabling the sensor to activate the relay. The relay's normally closed (NC) contact is connected to the LED, allowing the LED to be powered by a 9V battery when the relay is not activated by the IR sensor.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of New: A project utilizing IR Line Sensor Module in a practical application
Battery-Powered IR Sensor Controlled Relay Module
This circuit uses an IR sensor to control a 1 Channel 5V Relay Module, which is powered by a 9V battery. The IR sensor detects an object and sends a signal to the relay module to switch its state, enabling or disabling the connected load.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of MASSIVE SUMO AUTO BOARD: A project utilizing IR Line Sensor Module in a practical application
Battery-Powered Sumo Robot with IR Sensors and DC Motors
This circuit is designed for a robotic system, featuring a Massive Sumo Board as the central controller. It integrates multiple FS-80NK diffuse IR sensors and IR line sensors for obstacle detection and line following, respectively, and controls two GM25 DC motors via MD13s motor drivers for movement. Power is supplied by an 11.1V LiPo battery.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications and Use Cases

  • Line-following robots for automation and robotics competitions
  • Path detection in autonomous vehicles
  • Edge detection for conveyor belts
  • Object detection in industrial automation
  • Proximity sensing in robotics

Technical Specifications

The following table outlines the key technical details of the TCRT5000 IR Sensor Module:

Parameter Value
Operating Voltage 3.3V to 5V
Operating Current 10mA (typical)
Output Type Digital (High/Low)
Detection Range 2mm to 15mm (optimal: 2mm to 10mm)
IR Wavelength 950nm
Dimensions 32mm x 14mm x 7mm
Weight ~3g

Pin Configuration and Descriptions

The TCRT5000 IR Sensor Module has a 3-pin interface. The pinout is as follows:

Pin Name Description
1 VCC Power supply pin. Connect to 3.3V or 5V.
2 GND Ground pin. Connect to the ground of the circuit.
3 OUT Digital output pin. Outputs HIGH (1) when no line is detected, LOW (0) when a line is detected.

Usage Instructions

How to Use the Component in a Circuit

  1. Power the Module: Connect the VCC pin to a 3.3V or 5V power source and the GND pin to the ground of your circuit.
  2. Connect the Output: Connect the OUT pin to a digital input pin of your microcontroller (e.g., Arduino UNO).
  3. Position the Sensor: Place the sensor module approximately 2mm to 10mm above the surface to be detected. Ensure the IR emitter and receiver face the surface.
  4. Calibrate the Sensor: Adjust the onboard potentiometer to fine-tune the sensitivity of the sensor for optimal performance.

Important Considerations and Best Practices

  • Surface Contrast: The module works best when there is a high contrast between the line (e.g., black) and the background surface (e.g., white).
  • Ambient Light: Avoid using the sensor in environments with strong ambient IR light, as it may interfere with detection.
  • Distance: Maintain the recommended detection range (2mm to 10mm) for accurate results.
  • Potentiometer Adjustment: Use the onboard potentiometer to adjust the sensitivity based on the surface and lighting conditions.

Example Code for Arduino UNO

The following code demonstrates how to use the TCRT5000 IR Sensor Module with an Arduino UNO to detect a line:

// Define the pin connected to the sensor's OUT pin
const int sensorPin = 2; // Digital pin 2
const int ledPin = 13;   // Built-in LED for visual feedback

void setup() {
  pinMode(sensorPin, INPUT); // Set sensor pin as input
  pinMode(ledPin, OUTPUT);   // Set LED pin as output
  Serial.begin(9600);        // Initialize serial communication
}

void loop() {
  int sensorValue = digitalRead(sensorPin); // Read the sensor output

  if (sensorValue == LOW) {
    // Line detected
    digitalWrite(ledPin, HIGH); // Turn on LED
    Serial.println("Line detected!");
  } else {
    // No line detected
    digitalWrite(ledPin, LOW);  // Turn off LED
    Serial.println("No line detected.");
  }

  delay(100); // Small delay for stability
}

Troubleshooting and FAQs

Common Issues and Solutions

  1. Sensor Not Detecting the Line

    • Cause: Incorrect positioning or insufficient contrast between the line and the surface.
    • Solution: Ensure the sensor is within the recommended detection range (2mm to 10mm) and the line has a high contrast with the background.
  2. False Positives or Unstable Output

    • Cause: Ambient IR light interference or improper sensitivity adjustment.
    • Solution: Reduce ambient IR light exposure and adjust the potentiometer to fine-tune the sensitivity.
  3. No Output from the Sensor

    • Cause: Incorrect wiring or insufficient power supply.
    • Solution: Verify all connections and ensure the module is powered with 3.3V or 5V.
  4. Output Always HIGH or LOW

    • Cause: Faulty module or improper calibration.
    • Solution: Test the module with a different microcontroller or replace the module if necessary.

FAQs

Q1: Can the TCRT5000 IR Sensor Module detect colors?
A1: No, the module detects contrast between surfaces but cannot differentiate specific colors.

Q2: Can I use this module with a 3.3V microcontroller?
A2: Yes, the module is compatible with both 3.3V and 5V systems.

Q3: How do I know if the sensor is working?
A3: The onboard LED will light up when the sensor detects a line. Additionally, you can monitor the digital output pin using a microcontroller.

Q4: Can I use multiple sensors for a line-following robot?
A4: Yes, you can use multiple TCRT5000 modules to detect multiple points along a line for better navigation.

By following this documentation, you can effectively integrate the TCRT5000 IR Sensor Module into your projects for reliable line detection and navigation.