The LN298, manufactured by QWER (Part ID: QWD), is a dual H-bridge motor driver IC designed for controlling two DC motors or a single stepper motor. It enables bidirectional motor control and provides current amplification, making it ideal for robotics, automation, and other motor control applications. The LN298 is widely used in projects requiring precise motor control, such as robotic arms, conveyor belts, and automated vehicles.
Explore Projects Built with ln298
Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
This circuit is designed to control a two-wheeled robot using an L298N motor driver, powered by two 18650 Li-ion batteries. It includes two KY-033 line tracking sensors for navigation and a 74HC04 inverter to process sensor signals and control the motor driver inputs.
This circuit is designed for a 4-wheeled WiFi-controlled car with a basket, which uses an ESP8266 NodeMCU microcontroller for logic control. It features an IR sensor for basket full detection, a GPS module for location tracking, and a GSM module (Sim800l) for sending SMS notifications. The L298N motor driver controls four DC gearmotors for movement, and the system is powered by a Li-ion battery with a 7805 voltage regulator providing stable power to the GSM module.
This circuit is a line-following robot that uses an Arduino Expansion Board to control two DC motors via an L298N motor driver. The robot uses a 5-channel IR sensor array to detect the line and adjust the motor speeds accordingly, powered by a 2200mAH LiPo battery and controlled through a PID algorithm implemented in the Arduino code.
This is a robotic control circuit featuring an Arduino UNO microcontroller that interfaces with two SG90 servo motors for movement, an HC-SR04 ultrasonic sensor for distance measurement, and an HC-05 Bluetooth module for wireless communication. The L298N motor driver is incorporated for potential motor control, and the system is powered through a standard power jack.
The LN298 is a robust and versatile motor driver IC with the following key specifications:
General Specifications
Manufacturer: QWER
Part ID: QWD
Operating Voltage: 4.5V to 46V
Output Current (per channel): Up to 2A
Peak Output Current: 3A (non-repetitive, per channel)
Logic Input Voltage: 5V TTL-compatible
Power Dissipation: 25W (with proper heat sinking)
Operating Temperature Range: -25°C to +130°C
Pin Configuration and Descriptions
The LN298 IC comes in a 15-pin package. Below is the pin configuration:
Pin Number
Pin Name
Description
1
Enable A
Enables H-bridge A (active HIGH).
2
Input 1
Logic input for controlling motor direction (H-bridge A).
3
Output 1
Output for motor connection (H-bridge A).
4
Ground
Ground connection.
5
Ground
Ground connection.
6
Output 2
Output for motor connection (H-bridge A).
7
Input 2
Logic input for controlling motor direction (H-bridge A).
8
VCC (Motor Supply)
Power supply for motors (4.5V to 46V).
9
Enable B
Enables H-bridge B (active HIGH).
10
Input 3
Logic input for controlling motor direction (H-bridge B).
11
Output 3
Output for motor connection (H-bridge B).
12
Ground
Ground connection.
13
Ground
Ground connection.
14
Output 4
Output for motor connection (H-bridge B).
15
Input 4
Logic input for controlling motor direction (H-bridge B).
Usage Instructions
How to Use the LN298 in a Circuit
Power Supply: Connect the motor power supply to the VCC (Motor Supply) pin (Pin 8). Ensure the voltage is within the range of 4.5V to 46V. Connect the ground pins (Pins 4, 5, 12, and 13) to the circuit ground.
Logic Inputs: Use the logic input pins (Pins 2, 7, 10, and 15) to control the direction of the motors. These pins are TTL-compatible and can be connected to a microcontroller like an Arduino.
Enable Pins: The enable pins (Pins 1 and 9) must be set HIGH to activate the corresponding H-bridge. These can also be connected to a PWM signal for speed control.
Motor Connections: Connect the motor terminals to the output pins (Pins 3, 6 for H-bridge A; Pins 11, 14 for H-bridge B).
Heat Dissipation: Use a heat sink if the IC is expected to operate at high currents for extended periods.
Example: Connecting LN298 to an Arduino UNO
Below is an example of how to control a DC motor using the LN298 and an Arduino UNO:
// Define motor control pins
const int enableA = 9; // Enable pin for H-bridge A
const int input1 = 8; // Input 1 for H-bridge A
const int input2 = 7; // Input 2 for H-bridge A
void setup() {
// Set motor control pins as outputs
pinMode(enableA, OUTPUT);
pinMode(input1, OUTPUT);
pinMode(input2, OUTPUT);
// Initialize motor in stopped state
digitalWrite(enableA, LOW); // Disable motor
digitalWrite(input1, LOW); // Set direction to LOW
digitalWrite(input2, LOW); // Set direction to LOW
}
void loop() {
// Example: Rotate motor forward
digitalWrite(enableA, HIGH); // Enable motor
digitalWrite(input1, HIGH); // Set direction forward
digitalWrite(input2, LOW); // Set direction forward
delay(2000); // Run motor for 2 seconds
// Example: Rotate motor backward
digitalWrite(input1, LOW); // Set direction backward
digitalWrite(input2, HIGH); // Set direction backward
delay(2000); // Run motor for 2 seconds
// Stop motor
digitalWrite(enableA, LOW); // Disable motor
delay(2000); // Wait for 2 seconds
}
Important Considerations
Always ensure the motor supply voltage does not exceed the maximum rating of 46V.
Use appropriate decoupling capacitors near the VCC (Motor Supply) pin to reduce noise.
Avoid exceeding the maximum current rating of 2A per channel to prevent damage to the IC.
Use a heat sink for high-current applications to prevent overheating.
Troubleshooting and FAQs
Common Issues and Solutions
Motor Not Running:
Ensure the enable pin is set HIGH.
Verify the motor power supply is connected and within the specified voltage range.
Check the logic input pins for proper HIGH/LOW signals.
Overheating:
Use a heat sink to dissipate heat effectively.
Ensure the current drawn by the motor does not exceed 2A per channel.
Erratic Motor Behavior:
Check for loose connections in the circuit.
Add decoupling capacitors to the motor power supply to reduce noise.
No Output from the IC:
Verify that the ground pins are properly connected.
Ensure the logic input voltage levels are within the TTL range.
FAQs
Q: Can the LN298 drive stepper motors?
A: Yes, the LN298 can drive a stepper motor by controlling both H-bridges simultaneously. You will need to sequence the logic inputs appropriately.
Q: What is the maximum PWM frequency supported by the LN298?
A: The LN298 can handle PWM frequencies up to 20 kHz, making it suitable for most motor control applications.
Q: Can I use the LN298 without a heat sink?
A: For low-current applications (below 1A per channel), a heat sink may not be necessary. However, for higher currents, a heat sink is recommended to prevent overheating.
Q: Is the LN298 compatible with 3.3V logic?
A: The LN298 is designed for 5V TTL logic. To use it with 3.3V logic, you may need a level shifter or ensure the 3.3V logic levels meet the IC's input threshold.