Dual Motor TinyShield Tutorial

by TinyCircuits Staff March 22, 2016

Dual Motor TinyShield Tutorial

Description:

The Dual Motor TinyShield allows you to drive two independently controlled DC brushed motors from your TinyDuino! Create your own tiny robots or drones! Using two of the super miniature but very powerful 2mm x 2mm TI DRV8837 Motor Driver (H-Bridge) IC, this shield will allow for to 1.8A per channel and operate motors between 1.8 to 11V. This TinyShield includes a built in motor controller to make driving motors simple and uses the TinyDuino I2C interface - saving GPIO pins on the TinyDuino processor for other tasks, and an easy to use Arduino library is provided to control this.

Since this TinyShield uses I2C for communication, multiple Dual Motor TinyShields can be used on the same (up to four Dual Motor TinyShields), and there are resistors that can be changed to set the I2C address.

The board includes a bypass capacitors, as well as heatsinking the chips to a large plane on the bottom side of the board to help with heat dissipation. An external power connection is supplied to connect up to your motor power source (like a battery), and all the connections to the motors are with standard 0.1″ spaced holes, that you can solder your motor leads into or use the supplied 0.1″ headers. This shield is also available with JST connectors to allow easy connection to motors with this connection (future option).

The TI DRV8837 has one H-bridge driver consisting of N-channel power MOSFETs to drive a DC motor or one winding of a stepper motor, or other devices like solenoids. An internal charge pump generates needed gate-drive voltages. There are internal shutdown functions for overcurrent protection, short-circuit protection, undervoltage lockout and over temperature. The DRV8837 can supply up to 1.8 A of output current. It operates on a motor power-supply voltage from 1.8 V to 11 V .

Note: While the DRV8837 supports 1.8A @ 11V, we highly recommend operating under 500mA @ 5V per channel unless you have some really good heat sinking in place.

 


The sample sketch below will demonstrate how to drive two brushed motors connected to M1 and M2. 

Note: 

  • Up to 4 Dual Motor TinyShields can be stacked together in one TinyDuino stack.  However the I2C address needs to be different for each TinyShield and this can be changed with resistors R1 and R2 (soldering is required for this).   
  • By default, the motor power supply input connection is connected to the VBATT connection on the TinyDuino to power it as well.  Therefore you can run your TinyDuino and the motors off the same battery when it's plugged into this TinyShield.  However when using this, be sure not to exceed 5.5V on this power input or it will damage the TinyDuino circuitry.  If a higher motor voltage is required, you can remove resistor R3 which will allow you to run the motor voltage independently from the TinyDuino logic voltage.   
  • Even though the motor driver can support 11V at 1.8Amps, we do not recommend using more than a 5V motor at 500mA due to the small size.  
  • Be sure that your power supply is sufficient to operate these motors as well as your logic – batteries are the best. If you are running both the motors and the logic off of one power supply, we recommend avoid using a switching power supply as the transients caused can potentially damage items connected to the logic side.

     



    TinyCircuits Staff
    TinyCircuits Staff

    Author



    Also in Learn

    Tiny Arcade Assembly Instructions
    Tiny Arcade Assembly Instructions

    by TinyCircuits Staff September 18, 2016

    Learn how to assemble your Tiny Arcade. You can read the step by step guide, or there's a video tutorial...

    View full article →

    Tiny Arcade Menu Update
    Tiny Arcade Menu Update

    by TinyCircuits Staff May 18, 2016

    Update your Tiny Arcade software to the latest version from your computer.

    View full article →

    TinyScreen+ Windows 7/8 Driver Installation
    TinyScreen+ Windows 7/8 Driver Installation

    by TinyCircuits Staff May 18, 2016

    Install the required drivers to use TinyScreen+ with Windows 7 and Windows 8.

    View full article →