Pololu VNH5019 User manual

Pololu Dual VNH5019 Motor
Driver Shield User's Guide
1. Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.a. Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
1.b. Included Hardware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
2. Contacting Pololu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
3. Getting Started with an Arduino . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
3.a. What You Will Need . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
3.b. Assembly for Use as an Arduino Shield . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
3.c. Shield Connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
3.d. Programming Your Arduino . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
4. Using as a General-Purpose Motor Driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
4.a. Assembly for Use as a General-Purpose Motor Driver . . . . . . . . . . . . . . . . . . . . . . . . . 15
4.b. Board Connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
5. Schematic Diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
6. Customizing the Shield . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
6.a. Remapping the Arduino Connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
6.b. Accessing ENA/DIAGA and ENB/DIAGB Pins Separately . . . . . . . . . . . . . . . . . . . . . . 21
7. Using the Driver in Single-Channel Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
http://www.pololu.com/docs/0J49 Page 1 of 25

Pololu dual VNH5019 motor driver shield
for Arduino.
1. Overview
The Pololu dual VNH5019 motor driver shield for Arduino
[http://www.pololu.com/catalog/product/2502] and its corresponding
Arduino library make it easy to control two bidirectional, high-
power DC motors with an Arduino [http://www.pololu.com/catalog/
product/1616] or Arduino clone. The board features a pair of
robust VNH5019 motor drivers from ST, which operate from
5.5 to 24 V and can deliver a continuous 12 A (30 A peak) per
channel, and incorporates most of the components of the typical
application diagram on page 14 of the VNH5019 datasheet
[http://www.pololu.com/file/download/VNH5019A-E.pdf?file_id=0J504]
(629k pdf), including pull-up and protection resistors and FETs
for reverse battery protection. It ships fully populated with its
SMD components, including the two VNH5019 ICs, as shown
in the picture to the right; stackable Arduino headers and
terminal blocks for connecting motors and motor power are
included but are not soldered in (see the Included Hardware section below).
This versatile motor driver is intended for a wide range of users, from beginners who just want a plug-and-play
motor control solution for their Arduinos (and are okay with a little soldering) to experts who want to directly
interface with ST’s great motor driver ICs. The Arduino pin mappings can all be customized if the defaults are not
convenient, and the VNH5019 control lines are broken out along the left side of the board, providing a convenient
interface point for other microcontroller boards (see the right connection diagram below). This versatility, along
with an option to power the Arduino directly from the shield, sets this board apart from similar competing motor
shields.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
1. Overview Page 2 of 25

Pololu dual VNH5019 motor
driver shield, assembled and
connected to an Arduino Uno.
Pololu dual VNH5019 motor
driver shield for Arduino, bottom
view with board dimensions.
1.a. Features
• Wide operating voltage range: 5.5 – 24 V1
• High output current: up to 12 A continuous (30 maximum) per
motor
• Motor outputs can be combined to deliver up to 24 A continuous
(60 A maximum) to a single motor (see Section 7)
• Inputs compatible with both 5V and 3.3V systems (logic high
threshold is 2.1 V)
• PWM operation up to 20 kHz, which is ultrasonic and allows for
quieter motor operation
• Current sense voltage output proportional to motor current (approx.
140 mV/A)
• Motor indicator LEDs show what the outputs are doing even when
no motor is connected
• Can be used with an Arduino or Arduino clone (through shield
headers) or other microcontroller boards (through 0.1″ header along the
left side)
• When used as a shield, the motor power supply can optionally be
used to power the Arduino base as well
• Arduino pin mappings can be customized if the default mappings
are not convenient
•Arduino library [http://github.com/pololu/Dual-VNH5019-Motor-Shield]
makes it easy to get started using this board as a motor driver shield
• Reverse-voltage protection
• Robust drivers:
◦ Can survive input voltages up to 41 V
◦ Undervoltage and overvoltage shutdown
◦ High-side and low-side thermal shutdown
◦ Short-to-ground and short-to-Vcc protection
1While the overvoltage protection typically activates at 27 V, it can trigger at voltages as low as
24 V, so we do not recommend using this motor driver with 24 V batteries, which significantly
exceed 24 V when fully charged. If the shield is configured to power an Arduino or Arduino clone,
the supply voltage must conform to that Arduino’s input voltage requirements.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
1. Overview Page 3 of 25

Pololu dual VNH5019 motor driver shield for
Arduino with included hardware.
1.b. Included Hardware
This motor driver board ships with all of the surface-
mount parts populated. However, soldering is required
for assembly of the included through-hole parts. The
following through-hole parts are included:
• two extended 1×8 female headers (for Arduino
shields)
• two extended 1×6 female headers (for Arduino
shields)
• three 2-pin 5mm terminal blocks
[http://www.pololu.com/catalog/product/2440] (for shield
power and motor outputs)
• 40-pin 0.1″ straight breakaway male header
[http://www.pololu.com/catalog/product/965] (may ship in
several pieces, such as two 20-pin strips)
A0.1″ shorting block [http://www.pololu.com/catalog/product/968] (for optionally supplying shield power to Arduino)
is also included.
You can use the terminal blocks to make your motor and motor power connections, or you can break off an 8×1
section of the 0.1″ header strip and solder it into the smaller through-holes that border the four large motor and
motor power pads. Note, however, that the terminal blocks are only rated for 16 A, and each header pin pair is
only rated for a combined 6 A, so for higher-power applications, thick wires should be soldered directly to the
board.
When not using this board as an Arduino shield, you can solder the 0.1″ headers to the logic connections along
the left side of the board to enable use with custom cables [http://www.pololu.com/catalog/category/70] or solderless
breadboards [http://www.pololu.com/catalog/category/28], or you can solder wires directly to the board for more
compact installations. Note that motor and motor power connections should not be made through a breadboard.
The motor driver includes three 47 uF electrolytic power capacitors, and there is room to add additional capacitors
(e.g. to compensate for long power wires or increase stability of the power supply). Additional power capacitors
are usually not necessary, and no additional capacitors are included with this motor driver.
The two mounting holes are intended for use with #2 screws [http://www.pololu.com/catalog/category/101] (not
included). They have a horizontal separation of 0.30″ and a vertical separation of 1.70″.
An Arduino [http://www.pololu.com/catalog/product/1616] is not included.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
1. Overview Page 4 of 25

Pololu dual VNH5019 motor
driver shield, assembled and
connected to an Arduino Uno.
2. Contacting Pololu
We would be delighted to hear from you about any of your projects and
about your experience with the dual VNH5019 motor driver shield for
Arduino [http://www.pololu.com/catalog/product/2502]. If you need technical
support or have any feedback you would like to share, you can contact us
[http://www.pololu.com/contact] directly or post on our forum
[http://forum.pololu.com/viewforum.php?f=15]. Tell us what we did well, what
we could improve, what you would like to see in the future, or anything
else you would like to say!
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
2. Contacting Pololu Page 5 of 25

3. Getting Started with an Arduino
As with virtually all other Arduino shields, connections between the Arduino and the motor driver are made via
extended stackable headers that must be soldered to the through-holes along the top and bottom edges of the
shield. This section explains how to use this motor driver as an Arduino shield to quickly and easily add control
of up to two DC motors to your Arduino project. For information on how to use this board as a general-purpose
motor driver controlled by something other than an Arduino, see Section 4.
3.a. What You Will Need
The following tools and components are required for getting started using this motor driver as an Arduino shield:
•An Arduino. Using this product as an Arduino shield (rather than a general-purpose motor driver board)
requires an Arduino [http://www.pololu.com/catalog/product/1616]. This shield should work with all Arduino and
Arduino clones that have the standard Arduino pinout. You will also need a USB cable for connecting your
Arduino to a computer. We have specifically tested this shield (using our Arduino library) with:
◦Arduino Uno [http://www.pololu.com/catalog/product/1616]
◦ Arduino Duemilanove (both with ATmega168 and ATmega328P)
◦Arduino Mega 2560 [http://www.pololu.com/catalog/product/1698]
◦ chipKIT Max32 Arduino-Compatible Prototyping Platform (PIC32-based Arduino clone)
•A soldering iron and solder. The through-hole parts included with the shield must be soldered in before
you can plug the shield into an Arduino or before you can connect power and motors. An inexpensive
soldering iron [http://www.pololu.com/catalog/product/156] will work, but you might consider investing in a
higher-performance soldering iron [http://www.pololu.com/catalog/product/1625] if you will be doing a lot of
work with electronics.
•A power supply. You will need a power supply, such as a battery pack, capable of delivering the current
your motors will draw. See the Power Connections and Considerations portion of Section 3.c for more
information on selecting an appropriate power supply.
•One or two brushed DC motors. This shield is a dual motor driver, so it can independently control two
bidirectional brushed DC motors. See the Motor Connections and Considerations portion of Section 3.c for
more information on selecting appropriate motors.
3.b. Assembly for Use as an Arduino Shield
1. Stackable Arduino headers: Before you can use this board as an Arduino shield, you need to solder the
four included Arduino header strips to the set of holes highlighted in red in the picture above. The headers
should be oriented so that the female sockets rest on the top side of the shield and face up while the male pins
protrude down through the board, and the solder connections should be made on the underside of the shield.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 6 of 25

2. Motor and power connections: The six large holes/twelve small holes on the right side of the board,
highlighted in yellow in the above diagram, are the motor outputs and power inputs. You can optionally
solder the included 5mm-pitch terminal blocks to the board to enable temporary motor and motor power
connections, or you can break off an 12×1 section of the included 0.1″ header strip and solder it into
the smaller through-holes that border the six large motor and motor power pads. Note, however, that the
terminal blocks are only rated for 16 A, and each header pin pair is only rated for a combined 6 A, so for
higher-current applications, thick wires with high-current connectors [http://www.pololu.com/catalog/product/
925] should be soldered directly to the board.
3. Arduino power jumper: If you want the option of powering your Arduino and motor shield from the
same source, you can solder a 2×1 piece of the included 0.1″ male header strip to the pins highlighted in
orange in the above picture. Shorting across these pins with the included shorting block will connect the
shield power to the Arduino’s VIN pin. You should not use this to power the shield from the Arduino as
this connection is not designed to handle high currents, and you should never supply power to the Arduino’s
VIN pin or power jack while this shorting block is in place, because it will create as short between the shield
power supply and the Arduino power supply.
4. Additional power capacitor: The motor driver shield includes three pre-installed 47 uF electrolytic
power capacitors, and there is space—highlighted in blue in the above picture—to add an additional
capacitor (e.g. to compensate for long power wires or increase stability of the power supply). An additional
power capacitor is usually not necessary, and no additional capacitors are included with this shield.
The other through-holes on the shield are used for more advanced things like customizing the Arduino pin
mappings and are not necessary for getting started using this shield with an Arduino. They are discussed in more
detail later in this guide.
3.c. Shield Connections
Dual VNH5019 motor driver shield with an Arduino (shield and Arduino powered separately).
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 7 of 25

All of the necessary logic connections between the Arduino and the motor driver shield are made automatically
when the shield is plugged into the Arduino. However, the shield’s power connections must be made directly to
the shield itself via its large VIN and GND pads. The picture above shows the typical connections involved in
using this board as an Arduino shield.
Default Arduino Pin Mappings
The following table shows how the shield connects your Arduino’s pins to the motor drivers’ pins:
Arduino Pin VNH5019 Driver Pin Basic Function
Digital 2 M1INA Motor 1 direction input A
Digital 4 M1INB Motor 1 direction input B
Digital 6 M1EN/DIAG Motor 1 enable input/fault output
Digital 7 M2INA Motor 2 direction input A
Digital 8 M2INB Motor 2 direction input B
Digital 9 M1PWM Motor 1 speed input
Digital 10 M2PWM Motor 2 speed input
Digital 12 M2EN/DIAG Motor 2 enable input/fault output
Analog 0 M1CS Motor 1 current sense output
Analog 1 M2CS Motor 2 current sense output
See the Pinout portion of Section 4.b for detailed descriptions of the VNH5019 driver pins and
Section 5 for a schematic diagram of the shield. See Section 6.a for instructions on how to
customize your board’s Arduino pin mappings if the above defaults are not convenient.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 8 of 25

Power Connections and Considerations
Dual VNH5019 motor driver shield power buses when connected
to an Arduino.
In the shield’s default state, the motor driver shield and Arduino are powered separately. When used this way,
the Arduino must be powered via USB, its power jack, or its VIN pin, and the shield must be supplied with 5.5
to 24 V through the large VIN and GND pads on the right side of the board. Attempting to power the shield
through other means, such as from the Arduino or through the small VOUT pin, can permanently damage both
the Arduino and the shield (only the large power traces on the right side of the shield are designed to handle the
high currents involved in powering motors). A high-side reverse-voltage protection MOSFET prevents the shield
from being damaged if shield power is inadvertently connected backwards. Logic power, VDD, is automatically
supplied by the Arduino.
Note that the motor driver features over-voltage protection that can activate at voltages as low as
24 V, so we do not recommend using it with 24 V batteries (such batteries can significantly exceed
24 V when fully charged).
It is important that you use a power source that is capable of delivering the current your motors will
require. For example, alkaline cells are typically poor choices for high-current applications, and you
should almost never use a 9V battery (the rectangular type with both terminals on the same side) as
your motor power supply.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 9 of 25

Dual VNH5019 motor driver shield with an Arduino (Arduino powered by the shield).
It is also possible to power your Arduino directly from the motor shield, as shown in the diagram above, which
eliminates the need for a separate Arduino power supply. When the ARDVIN=VOUT shorting block is in place,
the shield’s reverse-protected input power, VOUT, is connected to the Arduino’s VIN pin. (When power is
connected properly, VOUT is essentially the same as the shield’s VIN.) It is okay to connect your Arduino to a
computer via USB when this jumper is on, but the Arduino’s power jack must remain disconnected at all times.
Warning: When powering the Arduino from the motor shield, you must never connect a different
power supply to the Arduino’s VIN pin or plug a power supply into the Arduino’s power jack, as doing
so will create a short between the shield’s power supply and the Arduino’s power supply that could
permanently damage both the Arduino and the motor shield. In this case, it is also important that your
shield power supply is an acceptable voltage for your Arduino, so the full shield operating voltage
range of 5.5 – 24 V probably will not be available. For example, the recommended operating voltage
of the Arduino Uno is 7 – 12 V.
Motor Connections and Considerations
This motor driver shield has two motor channels, M1 and M2, each of which can be used to independently control
a bidirectional brushed DC motor. Each motor channel is comprised of a pair of pins—MxA and MxB—that
connect to the two terminals of a DC motor and can deliver a continuous 12 A (30 A peak).
Note: It is also possible to connect a single brushed DC motor to both motor channels
simultaneously to deliver nearly twice the current as is available from a channel by itself. See
Section 7 for more information.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 10 of 25

Each VNH5019 motor driver IC has a maximum continuous current rating of 30 A. However, the chips by
themselves will overheat at lower currents. In our tests on a sample unit, we were able to deliver 30 A for a few
milliseconds, 20 A for several seconds, 15 A for over a minute, and 12 A for around five minutes. At 6 A, the
chip just barely gets noticeably warm to the touch. The actual current you can deliver will depend on how well
you can keep the motor driver cool. The shield’s printed circuit board is designed to draw heat out of the motor
driver chips, but performance can be improved by adding a heat sink.
This product can get hot enough to burn you long before the chip overheats. Take care when handling
this product and other components connected to it.
Many motor controllers or speed controllers can have peak current ratings that are substantially higher than the
continuous current rating; this is not the case with these motor drivers, which have a 30 A continuous rating and
over-current protection that can activate at currents as low as 30 A (50 A typical). Therefore, the stall current of
your motor should not be more than 30 A. (Even if you expect to run at a much lower average current, the motor
can still draw short bursts of high currents, such as when it is starting, if special steps are not taken.)
If your motor has a stall current over the driver’s continuous current rating of 12 A per channel, we recommend
you take extra steps to make sure that your motor will not be exposed to loads that will cause it to exceed 12 A for
prolonged periods of time (or you take extra steps to keep the motor drivers cool, such as increasing air flow or
adding heat sinks). Exceeding 12 A for long durations should not damage the shield, but it will eventually activate
the driver’s thermal protection, which might result in inadequate performance for your application.
It is not unusual for the stall current of a motor to be an order of magnitude (10×) higher than
its free-run current. If you do not know your motor’s stall current, you can approximate it by
measuring the current it draws while held stalled at a lower voltage (such as when powered from a
single battery cell) and then scaling that value linearly with voltage. For example, the stall current
of a motor at 6 V is six times the stall current of that motor at 1 V. Another, less accurate method
is to use a multimeter to measure the resistance between the motor terminals and then use Ohm’s
law to compute the stall current Iat voltage V:I=V/R. This last method generally is not as reliable
because it can be difficult to measure such small resistances accurately.
Occasionally, electrical noise from a motor can interfere with the rest of the system. This can depend on a number
of factors, including the power supply, system wiring, and the quality of the motor. If you notice parts of your
system behaving strangely when the motor is active, first double-check that your power supply is adequate, then
consider taking the following steps to decrease the impact of motor-induced electrical noise on the rest of your
system:
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 11 of 25

Motor with one 0.1 uF capacitor
soldered across its terminals.
Motor with two 0.1 uF capacitors
soldered from its terminals to its
case.
1. Solder a 0.1 µF ceramic capacitor [http://www.pololu.com/catalog/
product/1166] across the terminals of your motors, or solder one
capacitor from each terminal to the motor case (see the pictures to the
right). For the greatest noise suppression, you can use three capacitors
per motor (one across the terminals and one from each terminal to the
case).
2. Make your motor leads as thick and as short as possible, and twist
them around each other. It is also beneficial to do this with your power
supply leads.
3. Route your motor and power leads away from your logic
connections if possible.
4. Place decoupling capacitors (also known as “bypass capacitors”)
across power and ground near any electronics you want to isolate from
noise. These can typically range from 10 uF to a few hundred uF.
3.d. Programming Your Arduino
Our Arduino library for the dual VNH5019 motor driver shield makes it easy to get started writing your Arduino
sketches. A link to download the library, installation instructions, and the library command reference can be found
on the library’s github page [http://github.com/pololu/Dual-VNH5019-Motor-Shield]. Once installed, we recommend
you try out the example sketch by selecting
File > Examples > DualVNH5019MotorShield > Demo
from the Arduino IDE, or by copying the following code into a new sketch:
#include "DualVNH5019MotorShield.h"
DualVNH5019MotorShield md;
void stopIfFault()
{
if (md.getM1Fault())
{
Serial.println("M1 fault");
while(1);
}
if (md.getM2Fault())
{
Serial.println("M2 fault");
while(1);
}
}
void setup()
{
Serial.begin(115200);
Serial.println("Dual VNH5019 Motor Shield");
md.init();
}
void loop()
{
for (int i = 0; i <= 400; i++)
{
md.setM1Speed(i);
stopIfFault();
if (i%200 == 100)
{
Serial.print("M1 current: ");
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 12 of 25

Serial.println(md.getM1CurrentMilliamps());
}
delay(2);
}
for (int i = 400; i >= -400; i--)
{
md.setM1Speed(i);
stopIfFault();
if (i%200 == 100)
{
Serial.print("M1 current: ");
Serial.println(md.getM1CurrentMilliamps());
}
delay(2);
}
for (int i = -400; i <= 0; i++)
{
md.setM1Speed(i);
stopIfFault();
if (i%200 == 100)
{
Serial.print("M1 current: ");
Serial.println(md.getM1CurrentMilliamps());
}
delay(2);
}
for (int i = 0; i <= 400; i++)
{
md.setM2Speed(i);
stopIfFault();
if (i%200 == 100)
{
Serial.print("M2 current: ");
Serial.println(md.getM2CurrentMilliamps());
}
delay(2);
}
for (int i = 400; i >= -400; i--)
{
md.setM2Speed(i);
stopIfFault();
if (i%200 == 100)
{
Serial.print("M2 current: ");
Serial.println(md.getM2CurrentMilliamps());
}
delay(2);
}
for (int i = -400; i <= 0; i++)
{
md.setM2Speed(i);
stopIfFault();
if (i%200 == 100)
{
Serial.print("M2 current: ");
Serial.println(md.getM2CurrentMilliamps());
}
delay(2);
}
}
This example ramps motor 1 speed from zero to max speed forward, to max speed reverse, and back to zero again
over a period of about 3 s, while checking for motor faults and periodically printing the motor current to the serial
monitor. It then performs the same process on motor 2 before repeating all over again.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 13 of 25

Note: Even if you don’t have any motors yet, you can still try out this sketch and use the motor
indicator LEDs for feedback that it’s working properly.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
3. Getting Started with an Arduino Page 14 of 25

4. Using as a General-Purpose Motor Driver
The set of pins along the left side of the shield provides direct access to the VNH5019 motor drivers, which
means this board can be used as a general-purpose motor driver controlled by devices other than Arduinos. This
section explains how to use the dual VNH5019 motor driver shield this way and provides some basic information
about the motor driver pins to help get you started. However, we strongly encourage you to consult the VNH5019
datasheet [http://www.pololu.com/file/download/VNH5019A-E.pdf?file_id=0J504] (629k pdf) for detailed pin descriptions,
truth tables, and electrical characteristics. This shield is essentially a breakout board for two VNH5019 motor
driver ICs, so the datasheet is your best resource for answering questions not covered by this user’s guide.
4.a. Assembly for Use as a General-Purpose Motor Driver
1. Logic connections: The 13 small holes along the left side of the board, highlighted in red in the above
diagram, are used to interface with the motor drivers. You can optionally solder a 13×1 piece of the included
0.1″ male header strip to these pins. Soldering the pins so they protrude down allows the logic side of
the motor driver to be plugged into a standard solderless breadboard [http://www.pololu.com/catalog/category/
28] or perfboard. You can also solder 0.1″ female headers [http://www.pololu.com/catalog/category/50] or custom
connectors to these pins.
2. Motor and power connections: The six large holes/twelve small holes on the right side of the board,
highlighted in yellow in the above diagram, are the motor outputs and power inputs. You can optionally
solder the included 5mm-pitch terminal blocks to the board to enable temporary motor and motor power
connections, or you can break off an 12×1 section of the included 0.1″ header strip and solder it into
the smaller through-holes that border the six large motor and motor power pads. Note, however, that the
terminal blocks are only rated for 16 A, and each header pin pair is only rated for a combined 6 A, so for
higher-current applications, thick wires with high-current connectors [http://www.pololu.com/catalog/product/
925] should be soldered directly to the board.
3. Additional power capacitor: The motor driver shield includes three pre-installed 47 uF electrolytic
power capacitors, and there is space—highlighted in blue in the above picture—to add an additional
capacitor (e.g. to compensate for long power wires or increase stability of the power supply). An additional
power capacitor is usually not necessary, and no additional capacitors are included with this shield.
With the exception of the pins labeled “MxEN A=B” and “MxCS_DIS”, all of the through-holes not highlighted
in the above diagram are only relevant when using this driver as an Arduino shield. The “MxEN A=B” and
“MxCS_DIS” pins are explained in the “Pinout” portion of Section 4.b, but they will not be needed in typical
applications and can generally be ignored.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
4. Using as a General-Purpose Motor Driver Page 15 of 25

4.b. Board Connections
Dual VNH5019 motor driver shield connected to a microcontroller (gray connections are
optional).
The above diagram shows the minimum connections typically required to interface this motor driver with a
microcontroller. Note that it is possible to get by with even fewer connections if you use pulse-width modulation
(PWM) on the MxINA and MxINB pins directly while holding the MxPWM pin high (e.g. by connecting it
directly to VDD). This approach also results in a different kind of motor-driving: supplying the PWM signal to
the MxINA/B pins directly results in drive-brake operation (outputs drive during the high portion of the PWM
and are shorted together during the low portion), while supplying the PWM signal to the MxPWM pin results in
drive-coast operation (outputs alternate between driving and high-impedance).
Pinout
The following table explains the board pins in detail. See the VNH5019 datasheet":/file/download/VNH5019A-
E.pdf?file_id=0J504 (629k pdf) for even more detailed information about these pins, including the truth table that
explains how the MxPWM and MxINA/B pins affect the MxA/B motor outputs.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
4. Using as a General-Purpose Motor Driver Page 16 of 25

PIN Default State Description
VIN
The connection point for the positive side of the 5.5 – 24 V motor power supply.
Since the overvoltage protection can be as low as 24 V, we do not recommend
using 24 V batteries for VIN.
VDD
The connection point for the positive side of the logic power supply (typically
2.5 – 5 V). The only function of this pin is to power the internal pull-ups on the
enable lines, M1EN/DIAG and M2EN/DIAG.
VOUT
This pin gives you access to the motor power supply after the reverse-voltage
protection MOSFET (see the board schematic in Section 5). It can be used to
supply reverse-protected power to other components in the system, but it should
not be used for high currents. This pin should only be used as an output.
GND Ground connection points for logic and motor power supplies. The controlling
device and the motor driver must share a common ground.
MxA/B Output of half-bridge A/B. Each half-bridge connects to one terminal of a DC
motor.
MxPWM LOW
Pulse-width modulation input: a PWM signal on this pin corresponds to a PWM
output on the corresponding driver’s motor outputs. When this pin is low, the
motor outputs are high impedance. When it is high, the output state is
determined by the states of the MxINA/B and MxEN/DIAG pins.
MxINA FLOATING Motor direction input A (“clockwise” input).
MxINB FLOATING Motor direction input B (“counterclockwise” input).
MxCS
Current sense output. The pin voltage is roughly 140 mV per amp of output
current when the CS_DIS pin is low or disconnected. The current sense reading
is more accurate at higher currents. (Note that while the CS voltage can
potentially exceed 3 V at high currents, the current sense circuit is safe for use
with 3V analog inputs. The MCU’s analog input voltage will be clamped to a
safe value by its protection diode, and only a few hundred microamps at most
will flow through that diode.)
MxEN/
DIAG HIGH
Combination enable input/diagnostic output. When the driver is functioning
normally, this pin acts as an enable input, with a logical high enabling the motor
outputs and a logical low disabling motor outputs. When a driver fault occurs,
the IC drives this pin low and the motor outputs are disabled. Note that the
VNH5019 actually has separate EN/DIAG pins for each half bridge (ENA/
DIAGA and ENB/DIAGB), but these are tied together on the board by default
to create a single enable input/diagnostic output for each driver. See Section 6.b
for information on how to individually access ENA/DIAGA and ENB/DIAGB
pins (this is typically not necessary).
MxCS_DIS LOW Disables the current sense output, MxCS, when high. Can be left disconnected
in most applications.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
4. Using as a General-Purpose Motor Driver Page 17 of 25

Power Considerations
Dual VNH5019 motor driver shield power buses when not used with
an Arduino shield.
The shield must be supplied with 5.5 to 24 V through the large VIN and GND pads on the right side of the
board. A high-side reverse-voltage protection MOSFET prevents the shield from being damaged if shield power
is inadvertently connected backwards.
Note that the motor driver features over-voltage protection that can kick it at voltages as low as
24 V, so we do not recommend using it with 24 V batteries (such batteries can significantly exceed
24 V when fully charged).
It is important that you use a power source that is capable of delivering the current your motors will require. For
example, alkaline cells are typically poor choices for high-current applications, and you should almost never use
a 9V battery (the rectangular type with both terminals on the same side) as your motor power supply.
Logic power at the same level as your controlling device should be supplied to the VDD pin. This will typically
be between 2.5 and 5 V, but the VNH5019 motor drivers are guaranteed to treat any logic input voltage over 2.1 V
as high. The only purpose of the VDD pin is to power the pull-up resistors on the EN/DIAG lines.
Motor Considerations
The motor considerations are the same as those detailed in Section 3.c.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
4. Using as a General-Purpose Motor Driver Page 18 of 25

5. Schematic Diagram
Schematic diagram of the Pololu dual VNH5019 motor driver shield for Arduino.
This schematic is also available as a downloadable pdf: dual VNH5019 motor driver shield schematic
[http://www.pololu.com/file/download/dual_VNH5019_shield_schematic.pdf?file_id=0J513] (87k pdf)
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
5. Schematic Diagram Page 19 of 25

6. Customizing the Shield
This motor driver shield has several features that will not be useful in a typical application but that might benefit
an advanced user. This section explains how to modify the shield from its default state to access these features.
6.a. Remapping the Arduino Connections
For some applications, this shield’s default Arduino pin mappings might not be convenient. For example, maybe
you want to use the 16-bit Timer 1 for making music on a buzzer and would rather use PWMs from Timer 0 to
control your motor speed. Or maybe you don’t care about monitoring the motor current and would rather use all
of your analog inputs for reading sensors. With this in mind, we designed the shield to have break points in the
connection between the Arduino pins and the motor drivers. It is easy to cut the connections at these points and
establish new connections to replace the broken ones if desired.
The connections between the Arduino pins and the VNH5019 motor driver pins are each made through a pair of
0.1″-spaced holes that are connected on the underside of the shield by a thin trace:
Cuttable traces on the dual VNH5019 motor
driver shield for changing default Arduino pin
mappings.
The following two diagrams show the default pin mapping for motor drivers 1 and 2:
Dual VNH5019 motor driver shield:
Arduino pin mappings for motor driver
1.
Dual VNH5019 motor driver shield:
Arduino pin mappings for motor driver
2.
Pololu Dual VNH5019 Motor Driver Shield User's Guide © 2001–2011 Pololu Corporation
6. Customizing the Shield Page 20 of 25
Table of contents
Other Pololu Control Unit manuals
Popular Control Unit manuals by other brands

SSS Siedle
SSS Siedle ELM 611-0 manual

Honeywell
Honeywell TRADELINE VR8345M manual

Sanhua
Sanhua RFGB Series instructions

Duratrax
Duratrax SPRINT Forward Hardware installation guide

Gossen MetraWatt
Gossen MetraWatt U180A user manual

Rockwell Automation
Rockwell Automation Allen-Bradley 1770-KFC15 user manual

Distech Controls
Distech Controls Smart Air Control Valve installation guide

M-system
M-system R7M-EC16A instruction manual

Siemens
Siemens CZM-4 installation instructions

Panduit
Panduit VeriSafe VS2-NET installation manual

Asco
Asco 317 Series Installation and maintenance instructions

Burkert
Burkert ME44 quick start