The L293D is a dedicated module to fit in Arduino UNO R3 Board, and Arduino MEGA, It is actually a motor driver shield that has full featured Arduino Shield can be used to drive 2 to 6 DC motor and 4 wire Stepper motor and it has 2 set of pins to drive a SERVO.

L203D is a monolithic integrated that has a feature to adopt high voltage, high current at four channel motor driver designed to accept load such as relays solenoids, DC Motors and Stepper Motors and switching power transistor. To simplify to use as two bridges on each pair of channels and equipped with an enable input. A separate supply input is provided for the logic, allowing operation at a lower voltage and internal clamp diodes are included.

The device is suitable for use in switching applications at frequencies up to 5kHz. The L293D is assembled in a 16 lead plastic package which has 4 center pins connected together and used for heat sinking. The L293DD is assembled in a 20 lead surface mount which has 8 center pins connected together and used for heat shrinking.

L294D Shield Feature:

L293D-Hbridge-Motor-control-shield

L293D-Hbridge-Motor-control-shield-Power-Detail

• Control up to 4 DC motors.
• Control 2 Servos.
• Logic Control Voltage VSS: 4.5 ~ 5.5 V
• Motor Supply Voltage VSS: 15v
• Drive operating current IO: 1.2A
• 8 Stage Serial Shift Registers

Wiring a DC Motor

L293D-Wired-4-Motor-with-servo

Motor requires more energy specially cheap motors since chip motors less efficient. The important thing you need is find out what voltage require your going to use. some small motors are only intended to run at 1.5 volts but it is just a common to have 6 ~ 12v motors. The motor controller on L294D shield is design to run at 4.5v to 25v. most 1.5 ~ 3 volts motor will not works on this shield. another thing you need is to figure it out how much current the motor will support? The L293D chip support up to 600 mA per motor, with 1.2A peak current. Note ones you head towards 1A you’ll probably want to put a heat sink on the chip, otherwise it will get thermal failure or burning out the chip.

On using the SN754410 motor driver chip because it has pin compatible, has an output diodes and can provide 1A per motor, 2A peak, you can download the datasheet below.

If you want more power you need to add a set of L293D driver and solder them right on top of the board it has now a double current capability. You can cannot run motor of a a 9v battery it drain very fast. Use NiMH or Lead ACID or LiPo Batteries it can provide 99% performance of the Motor.

Note: Do not connect the motor to 5v line on the board. There are two places you can get your motor high voltage supply.
Wiring and Installation the DC Motor to the l293D Shield

The DC motor are used for all sort of robotics projects. The motor shield can drive up to 4 or 6 DC motors bi directional, it means that they can be driven forward and backward. The speed can also be varied at 0.5% increments using PWM(Pulse with Modulation) this means that speed can be controlled.

Note: The H-Bridge Chip is not supported for driving load over 0.6A over 1.2A so this it means that this chip is for small motors. check the datasheet below to learn more. To connect simply place the 2 wires to the terminal with screw and then connect them to either M1, M2, M3, or M4 follow the example diagram above.

Working on IDE

Before you can use the motor shield, you need to download the Arduino IDE  Motor Library this will create a bridge between the shield and the Arduino.

Download the library here

Place the DCMotor folder into arduino sketch folder/libraries.

For windows

My Documents > Libraries
My Documents\Arduino\libraries\ArduinoParty\ArduinoParty.cpp My Documents\Arduino\libraries\ArduinoParty\ArduinoParty.h My Documents\Arduino\libraries\ArduinoParty\examples

For MAC

Documents / Arduino / Libraries.
Documents/Arduino/libraries/ArduinoParty/ArduinoParty.cpp Documents/Arduino/libraries/ArduinoParty/ArduinoParty.h Documents/Arduino/libraries/ArduinoParty/examples

For Linux

Documents/Arduino/libraries/ArduinoParty/ArduinoParty.cpp Documents/Arduino/libraries/ArduinoParty/ArduinoParty.h Documents/Arduino/libraries/ArduinoParty/examples

There be more files than just *.cpp and *.h files just make sure that they are all there.

Note: The library wont work if you put *.cpp and *.h files directly into the libraries folder or if they are nested in an extra folder.

Restart the Arduino IDE. Make sure that new libraries appers in the Sketch > Import Library Menu Item.

Sample Sketch

Download the motor library here | ZIP
Download the L293D datasheet here | PDF
Download the schematic here | PDF
Download the 74HC595 Datasheet here | PDF

Controlling the L293D UNO/MEGA Shield with DC Motors
Facebooktwitterredditpinterestmail
Tagged on:         

JLCPCBPCBgogoPCBway4pcb

6 thoughts on “Controlling the L293D UNO/MEGA Shield with DC Motors

Leave a Reply

Your email address will not be published. Required fields are marked *