Arduino Nano - BTS7960 Motor Driver
This tutorial instructs you how to use Arduino Nano with the BTS7960 motor driver to run a large 12V DC motor in both directions. Picture a small test bench on your desk for a 12V windshield wiper motor from a car. Such a motor wants far more current than a tiny driver chip can give, and this is the job the BTS7960 was built for. In detail, we will learn:
- What the BTS7960 module is, and what each pin of its control header does
- How to connect Arduino Nano, the BTS7960 module, a 12V DC motor and a 12V power adapter
- How to program Arduino Nano to speed the motor up and down, brake it, turn it backward and let it coast
- How to keep the 12V motor supply away from the Nano

We suggest:
- Utilizing the DRV8833 motor driver if your motors are small and their supply stays below 10.8V, like the wheels of a mini robot.
- Reading the Arduino Nano - DC Motor tutorial for the basics of speed and direction with a small 5V motor and the DRV8833.
Hardware Preparation
Or you can buy the following kits:
| 1 | × | DIYables Sensor Kit (18 sensors/displays) |
Additionally, some of these links are for products from our own brand, DIYables .
Overview of BTS7960 Motor Driver
The BTS7960 module is often sold under the names IBT-2 or HW-039. The board carries two Infineon BTS7960B chips, cooled by a big heat sink. Each chip is one half-bridge, and the pair works as one full H-bridge. That means one module runs one brushed DC motor, forward or backward, and the Arduino Nano sets the speed with a PWM signal. Compared with the L298N and the DRV8833, this board is the heavy-duty option. People use it for wiper motors, winches, large gear motors, electric scooters, wheelchair motors and heavy robots.
| BTS7960 Module (IBT-2) | |
|---|---|
| Power chips | 2 x Infineon BTS7960B half-bridge (one H-bridge together) |
| Motors driven | 1 brushed DC motor, forward and reverse |
| Motor voltage on B+ / B- | 5.5V to 27V DC (fits 6V, 12V and 24V motors) |
| Current | up to 43A (the current-limit level of the chip) |
| Highest PWM frequency (RPWM, LPWM) | 25 kHz |
| Logic chip | 74HC14 buffer, powered from the VCC pin |
| Logic voltage with Arduino Nano | 5V |
| Protection | current limiting and over-temperature protection |
Read the 43A figure as a peak. It is the level where the chip starts to limit the current. If your motor has to run for a long time, keep its current far below that number. In the end, the heat sink decides how much current the board can carry for minutes or hours.
The BTS7960 Motor Driver Pinout

The board is split into a signal part and a power part. The signal part is a header of 2 x 4 male pins that talks to the Arduino Nano. RPWM is pin 1 and LPWM is pin 2 at one end, and VCC is pin 7 and GND is pin 8 at the other end. The power part is a screw terminal for the supply and the motor.
Control header:
- RPWM pin: must be connected to a PWM pin of Arduino Nano. PWM here drives the motor forward (right half-bridge)
- LPWM pin: must be connected to a second PWM pin. PWM here drives the motor in reverse (left half-bridge)
- R_EN pin: must be connected to a digital pin. HIGH turns the right half-bridge on
- L_EN pin: must be connected to a digital pin. HIGH turns the left half-bridge on
- R_IS and L_IS pins: they report the motor current and faults. This tutorial does not use them, so they stay unconnected
- VCC pin: must be connected to 5V on the Arduino Nano. It powers only the 74HC14 logic chip and the power LED, never the motor
- GND pin: must be connected to a GND pin of Arduino Nano. On the module, this pin is already joined to B-
Screw terminal:
- B+ terminal: must be connected to the + side of the motor supply (12V here)
- B- terminal: must be connected to the - side of the motor supply
- M+ and M- terminals: must be connected to the two wires of the DC motor
※ NOTE THAT:
The labels on your module are the ones to trust. The silkscreen of many boards prints R_IS and L_IS as "R_S" and "L_S", and the header order may change from one maker to another. Check the small text next to each pin before you push a wire on it.
How RPWM, LPWM, R_EN and L_EN Move the Motor
Each half-bridge works like a very fast switch for one motor wire. When one side pulses its wire to the supply and the other side holds its wire at ground, current flows through the motor one way. Swap the two roles and the motor turns the other way. The PWM duty cycle sets how long the switch stays on in each pulse, and so how fast the motor spins.
With R_EN and L_EN both HIGH, the two PWM pins choose what happens:
| RPWM | LPWM | Result |
|---|---|---|
| PWM (0 to 255) | 0 | forward, a higher duty cycle means a higher speed |
| 0 | PWM (0 to 255) | reverse, a higher duty cycle means a higher speed |
| 0 | 0 | brake, the driver joins the two motor wires and the motor stops fast |
Now set R_EN and L_EN LOW. Both half-bridges switch off and nothing holds the motor any more, so it coasts and rolls to a stop by itself. Brake gives a short, hard stop. Coast gives a long, soft one.
There is one firm rule: at least one of RPWM and LPWM is always 0. The two PWM pins must never be active together.
Where the Motor Gets Its Power
The motor does not take any power from the Arduino Nano. A 12V power adapter feeds the module through a DC power jack: adapter + goes to B+, and adapter - goes to B-. Choose an adapter that can give more current than your motor needs. A wiper motor, for example, pulls much more than a small hobby motor.
On the module, GND and B- are joined together. So the single GND wire from the Nano to the module already gives the common ground with the 12V supply. B+ must never touch any pin of the Nano.
Why 5V for VCC? VCC sets the logic level of the 74HC14 buffer, and the Arduino Nano is a 5V board, so its HIGH signals match that level. No signal travels back from the module to the Nano, because R_IS and L_IS are left free.
Wiring Diagram
Six wires run from the control header to the Arduino Nano, and the 12V supply and the motor go only to the screw terminal. RPWM and LPWM need PWM, so they use D9 and D10; the two enable pins only need HIGH and LOW, so R_EN uses D12 and L_EN uses D11.

This image is created using Fritzing. Click to enlarge image
| BTS7960 Pin | Connect To |
|---|---|
| RPWM | Arduino Nano D9 |
| LPWM | Arduino Nano D10 |
| R_EN | Arduino Nano D12 |
| L_EN | Arduino Nano D11 |
| VCC | Arduino Nano 5V |
| GND | Arduino Nano GND |
| R_IS, L_IS | nothing (leave free) |
| B+ | 12V adapter + (via the DC power jack) |
| B- | 12V adapter - (via the DC power jack) |
| M+, M- | motor wire 1 and motor wire 2 |
Want a stronger connection than jumper wires? You can plug the Arduino Nano into a Screw Terminal Expansion Board for Arduino Nano and connect the wires to its screw terminals. See the diagram below for the screw terminal version.

This image is created using Fritzing. Click to enlarge image
See The best way to supply power to the Arduino Nano and other components.
※ NOTE THAT:
- Do all the wiring while the 12V adapter is unplugged. Plug it in only at the very end.
- Look at the + and - of the DC power jack twice before you plug in the adapter. Reversed polarity can damage the module.
- A big motor makes the module and its wires warm. Use thick wires for B+, B-, M+ and M-, and tighten the screws well.
How To Program For BTS7960 Motor Driver
No library is required. Two functions that come with Arduino do all the work: analogWrite() sets the speed and digitalWrite() switches the driver on and off.
- The first step is to give the four control pins a name:
- In setup(), set the four pins as outputs. Put both PWM inputs at 0 first, and only then pull the two enable pins HIGH:
- To turn forward at a speed from 0 to 255, clear LPWM and then write the speed to RPWM:
- To turn in reverse, do the mirror image:
- To brake, write 0 to both PWM pins and keep the enable pins HIGH. To coast, also pull R_EN and L_EN LOW:
Arduino Nano Code for BTS7960 Motor Driver
This sketch runs the same six-step test again and again, like a bench check for a wiper motor. The motor speeds up forward, holds full speed, slows down, brakes, turns backward at about half speed, and finally coasts with the driver off. Small helper functions keep the loop easy to read, and each step prints one line to the Serial Monitor.
Detailed Instructions
- If this is your first project with Arduino Nano, set up Arduino IDE first with the Arduino Nano software installation guide.
- Make every connection from the wiring diagram, but keep the 12V adapter out of the socket for now.
- Plug the Arduino Nano into your computer with the Mini-B USB cable.
- Start Arduino IDE, choose Arduino Nano as the board and pick the COM port it uses.
- Copy the sketch above into Arduino IDE.
- Press Upload and wait until the IDE reports that the upload is done.
- Now plug the 12V adapter into the DC power jack.
- Open the Serial Monitor and pick 9600 baud in its drop-down list.
- Watch the motor while the steps scroll by:
During steps 1 to 3 the motor climbs to full speed and comes back down. At step 4 it stops almost at once. Step 5 spins it the other way, more slowly. At step 6 it keeps turning for a moment and then winds down on its own. With a heavy motor, the gap between the brake stop and the coast stop is easy to see.
Does the motor turn backward at step 1? Swap the M+ and M- wires on the screw terminal. Hear a soft hum or whine at low speed? That is normal. The Nano's PWM on D9 and D10 runs at about 490 Hz, which is low enough for the ear to pick up.
Additional Knowledge
BTS7960 vs L298N vs DRV8833
| BTS7960 | L298N | DRV8833 | |
|---|---|---|---|
| Motors per board | 1 | 2 | 2 |
| Motor supply | 5.5V to 27V | 5V to 35V | 2.7V to 10.8V |
| Current | up to 43A (peak, chip limit) | about 2A per motor | about 1.5A per motor (2A peak) |
| Voltage lost inside the driver | very little | about 2V | small |
| Typical motors | wiper motors, winches, heavy robots | medium gear motors | small battery robots |
It is evident that the BTS7960 wins on current, but it drives only one motor per board. For a robot with two big wheels, use two BTS7960 modules. For small motors, the DRV8833 is the smaller and simpler choice. The L298N loses about 2V inside, so a 12V motor gets only about 10V from it.
Project Ideas
- A wiper motor tester with a potentiometer for speed and two buttons for direction
- An electric winch that pulls a small cart up a ramp and stops at a limit switch
- An automatic chicken coop door that opens in the morning and closes at night
- A heavy robot base with two BTS7960 modules, one for each drive wheel