Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

How to Use TB6612FNG: Examples, Pinouts, and Specs

Image of TB6612FNGDesign with TB6612FNG in Cirkit Designer

Introduction

The TB6612FNG is a dual H-bridge motor driver IC manufactured by ASD. It is designed to control two DC motors or one stepper motor with precision and efficiency. This component supports PWM (Pulse Width Modulation) for speed control, direction control, and includes built-in safety features such as overcurrent protection and thermal shutdown. Its compact design and versatile functionality make it a popular choice for robotics, automation, and other motor control applications.

Explore Projects Built with TB6612FNG

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 Arduino Nano Controlled Robot with Ultrasonic Sensor and Dual Motor Drivers: A project utilizing TB6612FNG in a practical application
Arduino Nano Controlled Robot with Ultrasonic Sensor and Dual Motor Drivers

This circuit features an Arduino Nano microcontroller interfaced with a TB6612FNG motor driver to control two DC Mini Metal Gear Motors. It also includes an HC-SR04 Ultrasonic Sensor for distance measurement, a 5 channel IR sensor for line tracking, and a Servomotor SG90 for positioning tasks. The system is powered by a 12V battery, with the Arduino Nano managing sensor inputs and motor outputs to perform tasks such as navigation or automation.

Open Project in Cirkit Designer

Common Applications

Technical Specifications

The TB6612FNG is a robust motor driver IC with the following key specifications:

Parameter Value
Operating Voltage (Vcc) 2.7V to 5.5V
Motor Voltage (VM) 4.5V to 13.5V
Output Current (per channel) 1.2A (continuous), 3.2A (peak)
Control Interface PWM and logic inputs
Standby Current 1 µA (typical)
Operating Temperature -20°C to +85°C
Built-in Protections Overcurrent, thermal shutdown

Pin Configuration and Descriptions

The TB6612FNG comes in a 16-pin package. Below is the pin configuration and description:

Pin Number Pin Name Description
1 AIN1 Input signal for Motor A (controls direction)
2 AIN2 Input signal for Motor A (controls direction)
3 PWMA PWM input for Motor A (controls speed)
4 A01 Output 1 for Motor A
5 A02 Output 2 for Motor A
6 VM Motor power supply (4.5V to 13.5V)
7 GND Ground
8 STBY Standby control (active high to enable the IC)
9 B02 Output 2 for Motor B
10 B01 Output 1 for Motor B
11 PWMB PWM input for Motor B (controls speed)
12 BIN2 Input signal for Motor B (controls direction)
13 BIN1 Input signal for Motor B (controls direction)
14 VCC Logic power supply (2.7V to 5.5V)
15 GND Ground
16 NC No connection

Usage Instructions

How to Use the TB6612FNG in a Circuit

  1. Power Connections:

    • Connect the VM pin to the motor power supply (4.5V to 13.5V).
    • Connect the VCC pin to the logic power supply (2.7V to 5.5V).
    • Connect the GND pins to the ground of the circuit.
  2. Motor Connections:

    • Connect the motor terminals to A01 and A02 for Motor A, and B01 and B02 for Motor B.
  3. Control Signals:

    • Use the AIN1 and AIN2 pins to control the direction of Motor A, and BIN1 and BIN2 for Motor B.
    • Provide PWM signals to the PWMA and PWMB pins to control the speed of Motor A and Motor B, respectively.
    • Set the STBY pin high to enable the IC.
  4. Logic Levels:

    • Ensure that the control signals are within the logic voltage range (2.7V to 5.5V).

Example Arduino Code

Below is an example of how to control two DC motors using the TB6612FNG and an Arduino UNO:

// Define motor control pins
const int AIN1 = 2;  // Motor A direction pin 1
const int AIN2 = 3;  // Motor A direction pin 2
const int PWMA = 5;  // Motor A speed control (PWM)
const int BIN1 = 7;  // Motor B direction pin 1
const int BIN2 = 8;  // Motor B direction pin 2
const int PWMB = 6;  // Motor B speed control (PWM)
const int STBY = 4;  // Standby pin

void setup() {
  // Set motor control pins as outputs
  pinMode(AIN1, OUTPUT);
  pinMode(AIN2, OUTPUT);
  pinMode(PWMA, OUTPUT);
  pinMode(BIN1, OUTPUT);
  pinMode(BIN2, OUTPUT);
  pinMode(PWMB, OUTPUT);
  pinMode(STBY, OUTPUT);

  // Enable the motor driver
  digitalWrite(STBY, HIGH);
}

void loop() {
  // Example: Run Motor A forward at 50% speed
  digitalWrite(AIN1, HIGH);
  digitalWrite(AIN2, LOW);
  analogWrite(PWMA, 128);  // 50% duty cycle (0-255)

  // Example: Run Motor B backward at 75% speed
  digitalWrite(BIN1, LOW);
  digitalWrite(BIN2, HIGH);
  analogWrite(PWMB, 192);  // 75% duty cycle (0-255)

  delay(2000);  // Run for 2 seconds

  // Stop both motors
  analogWrite(PWMA, 0);
  analogWrite(PWMB, 0);

  delay(2000);  // Pause for 2 seconds
}

Important Considerations

Troubleshooting and FAQs

Common Issues and Solutions

  1. Motors Not Running:

    • Verify that the STBY pin is set high to enable the IC.
    • Check the power supply connections for VM and VCC.
  2. Motor Running in the Wrong Direction:

    • Swap the logic levels on the direction control pins (AIN1, AIN2, BIN1, BIN2).
  3. Overheating:

    • Ensure that the current drawn by the motors does not exceed the IC's maximum rating.
    • Add a heatsink or improve ventilation if necessary.
  4. PWM Signal Not Working:

    • Verify that the PWM signal is within the correct frequency range (typically 20kHz or lower).
    • Check the connections to the PWMA and PWMB pins.

FAQs

Q: Can the TB6612FNG drive stepper motors?
A: Yes, the TB6612FNG can control a bipolar stepper motor by using both H-bridge channels.

Q: What happens if the IC overheats?
A: The TB6612FNG has a built-in thermal shutdown feature that disables the outputs to protect the IC.

Q: Can I use the TB6612FNG with a 3.3V microcontroller?
A: Yes, the logic voltage range (2.7V to 5.5V) is compatible with 3.3V microcontrollers.

Q: Is it necessary to use external diodes for motor protection?
A: No, the TB6612FNG has built-in flyback diodes for motor protection.