

An H-Bridge is an electronic circuit that enables a voltage to be applied across a load in either direction. This functionality makes it a critical component in applications requiring bidirectional control of DC motors. H-Bridges are widely used in robotics, motorized systems, and other applications where precise motor control is essential. They are also commonly integrated into motor driver ICs for ease of use.








The specifications of an H-Bridge can vary depending on the specific implementation (discrete components or integrated circuits). Below are general specifications for a typical H-Bridge:
Below is a typical pinout for an H-Bridge motor driver IC (e.g., L298N):
| Pin Name | Description |
|---|---|
| VCC | Power supply for the motor (e.g., 5V to 50V). |
| GND | Ground connection. |
| IN1 | Logic input 1 for controlling motor direction. |
| IN2 | Logic input 2 for controlling motor direction. |
| ENA | Enable pin for motor A (used to turn the motor on/off). |
| OUT1 | Output 1 connected to one terminal of the motor. |
| OUT2 | Output 2 connected to the other terminal of the motor. |
| SenseA | Current sensing pin for motor A (optional, used for monitoring current draw). |
Note: The exact pin configuration may vary depending on the specific H-Bridge IC or module.
VCC pin and ground to the GND pin.OUT1 and OUT2 pins.IN1 and IN2 pins to control the motor's direction:IN1 HIGH and IN2 LOW for forward rotation.IN1 LOW and IN2 HIGH for reverse rotation.IN1 and IN2 LOW to stop the motor.ENA pin is HIGH to enable the motor. If PWM control is required, connect a PWM signal to this pin for speed control.SenseA pin to an appropriate monitoring circuit.IN1 and IN2 HIGH simultaneously, as this can cause a short circuit across the power supply.Below is an example of controlling a DC motor using an H-Bridge and an Arduino UNO:
// Define control pins for the H-Bridge
const int IN1 = 9; // Pin connected to IN1 on the H-Bridge
const int IN2 = 10; // Pin connected to IN2 on the H-Bridge
const int ENA = 11; // Pin connected to ENA (PWM for speed control)
void setup() {
// Set control pins as outputs
pinMode(IN1, OUTPUT);
pinMode(IN2, OUTPUT);
pinMode(ENA, OUTPUT);
}
void loop() {
// Rotate motor forward
digitalWrite(IN1, HIGH); // Set IN1 HIGH
digitalWrite(IN2, LOW); // Set IN2 LOW
analogWrite(ENA, 128); // Set motor speed to 50% (PWM value: 128)
delay(2000); // Run for 2 seconds
// Stop the motor
digitalWrite(IN1, LOW); // Set IN1 LOW
digitalWrite(IN2, LOW); // Set IN2 LOW
delay(1000); // Wait for 1 second
// Rotate motor in reverse
digitalWrite(IN1, LOW); // Set IN1 LOW
digitalWrite(IN2, HIGH); // Set IN2 HIGH
analogWrite(ENA, 128); // Set motor speed to 50% (PWM value: 128)
delay(2000); // Run for 2 seconds
// Stop the motor
digitalWrite(IN1, LOW); // Set IN1 LOW
digitalWrite(IN2, LOW); // Set IN2 LOW
delay(1000); // Wait for 1 second
}
Motor Not Spinning:
ENA pin is set HIGH or receiving a valid PWM signal.IN1 and IN2) are set correctly.Motor Spins in the Wrong Direction:
OUT1 and OUT2.IN1 and IN2.H-Bridge Overheating:
Arduino Not Controlling the H-Bridge:
Q: Can I use an H-Bridge to control a stepper motor?
A: Yes, but you will need two H-Bridges (or a dual H-Bridge IC) to control the two coils of a stepper motor.
Q: What happens if both IN1 and IN2 are HIGH?
A: This creates a short circuit across the power supply, which can damage the H-Bridge. Always avoid this condition.
Q: Can I use an H-Bridge with a 3.3V microcontroller?
A: Yes, as long as the H-Bridge supports 3.3V logic levels. Otherwise, use a level shifter.
Q: How do I control motor speed with an H-Bridge?
A: Use a PWM signal on the ENA pin to adjust the motor's speed.