blog

Principle of Line-Tracking Module on Cars

循迹post 10241

Detailed Introduction to Types of Line Tracking Modules

What is a line tracking module?

A line tracking module is a basic module for a car to operate by identifying the color (black and white) at the bottom. Generally, there are multiple types.

循迹post 10241

How does a line tracker work?

Simply saying, the principle of line tracking modules is based on the different reflectivities of the ground surface (for example, white has a higher reflectivity and black has a lower reflectivity) to detect whether the car is running correctly along the black line.

Types of Line Tracking Modules

The types of line tracking modules are roughly divided into two categories:

1.Infrared sensor: Generally composed of an emitter and a receiver. The emitter emits infrared rays, and after the infrared rays bounce back, they are received by the receiver. The reflectivity of infrared rays is different on surfaces of different colors, so as to identify the black line.

2.Light sensor: Generally, a light sensor is used together with an LED light. After the LED light emits light, the light bounces back and is received by the light sensor. If the bottom of the light sensor is black, the reflected light decreases, and the resistance value fed back by the light sensor also decreases.

Next, I will give examples to illustrate various common line – tracking sensors.

TCRT5000

The most common infrared sensor used for line tracking is this TCRT5000. It consists of an emitter and a receiver, and is generally installed at the bottom of a car to work. If only TCRT5000 is used for line tracking, generally two or more modules are needed. It has a relatively fast response speed and low power consumption, and is very suitable for beginners’ DIY projects and learning use.

27c635e1349612476a705fc406810576

Working Process

After the infrared sensor is powered on, the infrared emission tube inside the sensor will emit infrared rays.

The emitted infrared rays propagate in the air, and when they encounter an object, they will be reflected. A part of the light will be reflected to the receiving end. Generally speaking, objects with a white surface have better reflectivity than those with a black surface.

The infrared receiving tube of the sensor is relatively sensitive to light of a specific wavelength, so it can accurately receive the infrared rays emitted by the infrared sensor.

After receiving the light, the receiving tube will generate weak electrical signals. These electrical signals need to be amplified by an amplifier and then transmitted to a microcontroller or a comparator to be compared with a threshold voltage. If it is higher than the threshold, a high or low signal level will be output.

But TCRT5000 outputs a low – level signal by comparing with the threshold.

After understanding the working process of TCRT5000, we need to understand its electrical parameters for use.

Electrical Parameter

TCRT5000 Specifications
Parameter Category Parameter Description Key Value Remarks
Emitter Type Core Component Infrared Emitting Diode (IRED) Actively emits infrared light
Receiver Type Core Component NPN Silicon Phototransistor Receives reflected infrared light
Emitter Max Current Absolute Maximum Rating 60 mA Must not be exceeded to prevent damage
Emitter Operating Current Recommended Parameter 10 – 20 mA Safe and efficient standard operating range
Emitter Forward Voltage Circuit Design Parameter 1.2 – 1.6 V Used to calculate the current-limiting resistor value
Receiver Voltage Rating Absolute Maximum Rating 30 V Very safe for 3.3V/5V systems
Typical Detection Distance Performance Parameter Approx. 2.5 mm For highly reflective surfaces, at 20mA current
Output Signal Logic Application Key Active-Low When an object is detected: DO pin outputs LOW (0V), AO voltage decreases

Infrared Sensor (Photoelectric Switch Version)

It has a longer detection range. The working parameters are basically the same as the above ones. It is a new type.

41mm 16.5 short

Photoelectric Reflection Version

It has the same performance as the photoelectric switch board and is more compact in size.

14.2 40 7.51 scaled

Three - Channel Version

The three-channel version uses the TCRT5000 sensor, which can directly function as a line tracking module. Compared to using a single or dual sensors, it offers lower error rates. It can effectively identify the vehicle’s path and is highly suitable for DIY cars or other photoelectric switch applications. Below is a video of this version’s line tracking module driving two motors, which fully and clearly demonstrates the logic of the line tracking module.

27.2 67 131 scaled

Video:

Using TCRT5000 to Control Wheels:

Electronic components used: TCRT5000 Three – channel version, relay, brushless motor, Arduino Uno

Open Arduino IDE and burn the following code into Arduino.

After burning, you can see that TCRT5000 can control the brushless motor. When a black line is detected on one side or the environment is relatively dark, the corresponding brushless motor will start to control the forward direction. For example, if a black line is detected on the left, it means the current traveling direction is to the right, and then the brushless motor on the right will stop, so as to turn left.

Four - channel Version

The 4 – channel line – tracking module has strong adaptability to ambient light. It is equipped with a pair of infrared emission and receiving tubes. The detection distance can be adjusted via the potentiometer knob. Turning clockwise increases the distance. The effective distance range is 1 – 12 cm, and the detection angle is 35°, which is suitable for long – distance line tracking, such as robot line tracking.

312048

Performance Parameters:

Working voltage: DC 3.3V – 5V

Working current: It is better to choose a power supply with more than 1A for power supply.

Working temperature: -10°C to +50°C

Hollow board: 4.4mm (length) * 4.0mm (width) * 12mm (height)

Size: Small board: 25mm (length) * 12mm (width) * 12mm (height)

Output interface: 6 – wire interface (1, 2, 3, 4 are 4 – channel signal output terminals; VCC is the positive power supply; GND is the negative power supply, which is also the ground wire)

Output signal: TTL level (can be directly connected to the I/O port of the single – chip microcomputer. When the red light reflected back by the sensor is sensed, the red indicator light is on and a low level is output; when there is no infrared light, the indicator light is off and a high level is output)

Five - channel line tracking

The five – channel line tracking still uses the TCRT5000 IR sensor. By expanding to five channels, it can more precisely adjust your DIY car. Additionally, the board frame of this version is largely compatible with the DIY car, allowing it to be installed without appearing突兀, and it offers excellent performance.

97 20 101 scaled

Five - channel line tracking with button

The five-channel line tracking with button version is designed for installation at the front of the vehicle. It incorporates an additional IR sensor for detecting obstacles ahead, along with an extra digital pinout interface, compared to the version mentioned above. This configuration enables both line tracking and obstacle avoidance, making it ideal for DIY car projects.

127 4 101 scaled

Light Sensor Version

The structure of a light sensor is relatively simple. It consists only of an LED light and a photoresistor, but it can still be used for line tracking.The resistance value of the photoresistor is affected by light. The light intensity and the resistance value are inversely proportional. The higher the light intensity, the lower the resistance value.Generally, a light sensor outputs an analog signal. It needs to adjust the threshold through a microcontroller (such as a single – chip microcomputer) to control the operation of the vehicle, so as to realize the line – tracking function.

21 24 81 scaled

Working Process

The working process of the light sensor for line tracking is as follows:

After being powered on, the LED light in the module will emit light.

The light travels in the air and is received by the photoresistor after reflection.

When the photoresistor receives light, its resistance value will decrease.

After the photoresistor receives light, its own resistance value becomes smaller, and the amplifier amplifies the electrical signal and then outputs it.

Electrical Parameters

Module Specifications
Operating Voltage 3.3V or 5V
Operating Current < 20mA
Operating Temperature Range -10℃ ~ +70℃
Detection Resolution 10%
Interface Type Analog Signal Output
Module Dimensions 23 × 20mm
Pin Definitions OUT (Signal Output), VCC (Power), GND (Ground)

E18-D80NK Photoelectric Switches Product Introduction

The E18-D80NK photoelectric switch is a type of IR sensor. Compared to the TCRT5000, it offers greater range and higher accuracy, as well as a larger size, making it more suitable for use as a line tracking module in large DIY vehicles.

switch link tracting11

Add Your Heading Text Here

Parameter Specification
Input Voltage 5V DC
Load Current 100mA
Sensing Distance 3~80cm (adjustable)
Diameter 17.5mm
Sensor Length 50mm
Lead Length 70mm
修改图片尺寸标注2048111

FAQ

How to use lR sensor module?

To use an IR sensor module, you just need to connect its pins. When it detects an object or a black line, it can output a digital signal. You can use this digital signal via a microcontroller to achieve the desired effect.

How to test if an lR sensor is working?

If there is a working indicator light, you can observe whether the indicator light is different when it is blocked and when it is not. If there isn’t one, you can measure the output pin with a multimeter. If the voltage of the output pin is different from usual when blocked, it also proves that it can work normally.

What triggers an lR sensor?

All objects can trigger an IR sensor. As long as you block within its measurement range, it can be detected (it will be affected by color).

How is the tracking module used on a small car?

To install tracking modules of different models, typically position them at the front of the vehicle. After installation, connect wires and configure code according to the module’s wiring instructions. Generally, sensors should be evenly distributed on both sides of the centerline. This ensures optimal utilization of the tracking module.

Leave a Reply

Your email address will not be published. Required fields are marked *