Introduction: L293D Motor Direction Control for Under $2.20

Picture of L293D Motor Direction Control for Under $2.20

Further to my instructable 12V NE555 PWM Controller for Under $3 I have designed and built a simple and cheap DC Motor Direction Controller that can either be used with the PWM Controller, for speed control or by itself with a 12V power supply.

I designed this DC Motor Direction Controller so that I could give direction control to DC motors that I am building into mini tools (drill, lathe, table saw, solder smoke extractor, etc.). While, I don't need direction control for all of the tools that I'm building, it IS necessary for some. Plus, who doesn't want to spin their DC motor backwards?

The overarching design principles that I've used here are:

  1. Works with my NE555 PWM Controller;
  2. Works without my NE555 PWM Controller;
  3. It's cheap;
  4. It uses minimum parts; and
  5. It works

For the direction controller to work with the NE555 PWM Controller, it will take the PWM modified power from that device and modify the polarity of the signal and push it on to the DC Motor. As I mentioned with the NE555 PWM Controller, I'm only interested in a 12V motor.

To achieve this magic, I'm using an L293D Quadruple Half-H Driver, well ... I'm using half of one. If you're interested, the L293D can manage 36V, however, as discussed in my previous instructable, the NE555 PWM Controller (as designed) will handle 18V max. So there's your upper limit.

The parts list and costing for this instructable is:

  • 1 x LM7805 Voltage Regulator ($0.40)
  • 2 x 100 nF electrolytic capacitor ($0.06)
  • 2 x 2 pin header ($0.26)
  • 1 x 1k ohm resistor ($0.01)
  • 1 x SPDT slide switch ($0.05)
  • 1 x L293D Quad Half-H Driver ($0.85)
  • 1 x 16 pin DIL ($0.35)
  • 1 x 50 x 33mm PCB ($0.14)

The prices quoted are for parts purchased from eBay that I've accumulated over some time. These prices change over time ... so caveat emptor, dude.

Step 1: The Horse Before the Cart

Picture of The Horse Before the Cart

If you are using this with the NE555 PWM Controller, that device comes first. The reason for this is simply that if the LD293D direction controller were first, you'd be switching polarity and THEN feeding it to the NE555 PWM Controller. And that would mean that the polarity would be wrong and the NE555 PWM Controller wouldn't work when the polarity was reversed.

When designing this circuit, I made a couple of mistakes ... such as, I was feeding 12V from the NE555 PWM controller BEFORE it was square waved and feeding that into the 5V regulator. All that happened was that the NE555 PWM Controller rendered itself totally redundant. No, don't do that!

Another design fault that you will see in the scan of the PCB is that the GND connections for the L293D don't go anywhere ... I had to solder in a jumper under the board to connect to the common GND of the LM7805 to make it do anything (groan!).

The above Fritzing PCB view shows both of those problems fixed.

I have also designed in two M3 holes on either end of the L293D so that I can bolt in a piece of aluminium to act as a heat sink. Feel free to add a proper heat sink if you like (you'd like to if your L293D is getting hot). The L293D will start to get hot if you are pumping > 1.5 W into it. Under 1.5 W, free air will reduce the temperature to a safe operating range. If you are going above that, you're going to need some heat sink (and a good read of the schematic and search for advice on the interweb).

Step 2: The PCB

Picture of The PCB

Attached are the copper bottom and silk screen top from my Fritzing design.

These can be printed and transferred using whatever method you prefer. Personally, I prefer laser toner transfer and an Hydrochloric Acid and Peroxide etch bath.

As this design is a minimal component design and all of the traces are extra thick (48 mil), it shouldn't be too had to place and solder by eye ... well, you should use a soldering iron rather than your eye, unless you've got heat ray eyes.

Use a non-conductive washer or non-conductive bolt when bolting the heat sink to the copper trace ...

I have now added a "schematic" to the instructable. Please be kind ... I'm not very good at schematics.

Step 3: All Done

Picture of All Done

To connect the two boards together, I've made a pair of DuPont Male pin jumpers (male to male).

To connect the motor to the board, I've gone with a DuPont Male/4.1mm Spade connector (male to female) jumper. This way, I can easily switch the motor and or motorised device without having to worry about soldering/desoldering (such a drag).

Anyway, that's it. This is a pretty straight forward circuit and build.

Check back again later, I've ordered a couple more JT0 chucks and I'm planning a mini-lathe.



pglassbrenner (author)2016-11-01

Clean layout, which you do not see everyday. I'm saving this instructable for future use. BTW, I also started in IT in 81 just as the punch cards were being phased out. You must be getting long in the tooth.

Thanks pglassbrenner,

Lol, long in the tooth ... well short in the tooth, truth be told ;) to quote Python, My "Eyes are gnarled, my teeth are dim".

Thanks for the comment and good luck with your future use.


grumpyrich (author)2016-09-29

Looks good. Definitely be giving this a go

baelza.bubba (author)grumpyrich2016-09-30

Thanks grumpyrich, make sure to post an I Made It when you do ;)


KISELIN made it! (author)2016-09-26

Hi. I made a driver with the same function, (to drive a DC-motor in both direction).
My use’s a DPDT (dual pole, dual throw), relay, and with 2 microswitches.
The function is straight forward:
1.) When ”NOT” activated, it run’s to ”Home” position & stops at microsw.
2.) When ”ACTIVATED” (J3), it run’s to ”End” pos. & stops at microsw.
The position Led’s indicate the actual position, (when running to <==> from neither is lit), thus during running time there are 2 other Led’s indicating the direction ”Where to” it’s running.
3.) The output has ”double” flyback diodes: 1 to positive & 1 to negative on both poles.
Why to both poles you may ask? Actually it is noth necessary to connect to both potentials, anyhow, I learned this connection for ”decades ago” from a world-leading DC-motor manufacturer, ABB (Asea Brown-Bowery), that ”they” use this double flyback in all their DC_motors. And on ”both” sides beacause, (of course), the motor runs in both directions.
I’ll attach some pics. of this. If interrested contact me: and I’ll send you them ”Gerber” files to you.

baelza.bubba (author)KISELIN2016-09-26

Hi KISELIN, nice. Just a couple of questions ... 1. Is this is a double sided PCB? and 2. what's the estimated cost of the circuit? There are usually many ways to skin a cat, so the question of cost and ease of fabrication tend to be the deciding factors.



KISELIN made it! (author)baelza.bubba2016-09-27

Hi baelza. Anserws: 1. Yes it is a double sided PCB, nevertheless,
It could be designed as 1-sided, though with some jumpers req.
I ordered thiese PCB from a chinese manuf. i -TEAD, (with good quality).
They offer 50X50mm sized double-sided, with silkscreen (on both sides), solder resist mask etc… PCB’s for a bunch of 10pcs. for ~ $ 10,00 USD. ($ 1,00/each),
The relay I use here is AXICOM P2 V23079 , (DPDT), cost ~ $ 1,50 USD
The microswitches I use here are OMRON D2MQ ~ $ 1,00/each
Terminals; 3pcs. ~ $ 1,50 USD total
Misc. LED’s & resistors for ~ $ 1,00 USD
Summa: 1+1,50+2+1,50+1 = $ 7,00USD
Attach them ”gerber files” as

PS. The microswitches on the PCB are arranged so that

they can be "break-out" to be positioned elsewhere.

PhilG16 (author)2016-09-20

Am I the only one who thinks you meant L293D instead of L239D? I can't find an L239D dual H bridge or quad half bridge.

baelza.bubba (author)PhilG162016-09-20

whoops typo yep 293d ?

cuyler1 (author)baelza.bubba2016-09-21

i thought i was the only one going nuts trying to locate the chip.i did find a lm239 from texas instruments but it is an op amp and was curious if there wasn't a typo. thank you for correcting this.

baelza.bubba (author)cuyler12016-09-21

Hey cuyler1, if you're nuts ... you're in good company ;)

Fixed, thanks for the call-out PhilG16

JohnC430 (author)2016-09-20

Looks like I missed the schematic somewhere???? Did I?

baelza.bubba (author)JohnC4302016-09-20

l didn't schematic the circuit. I'll give it a go .

schematic now added, JohnC430. I'm not too good at schematics :) I've colourised the connections to make it a bit easier to read. (doesn't help me much, I'm colourblind)

mach1950 (author)2016-09-20

Hi, well put together 'able. I don't quite understand though, it seems you're using a brushed dc motor. Can't you simply reverse the polarity with a switch? Forgive me, my knowledge is limited.

baelza.bubba (author)mach19502016-09-20

Hi mach1950 ... thanks for the comment. You're right, you "can" simply switch the polarity, however, the L239D does the switch from pole to pole gracefully and with no kickback by using internal clamping diodes. When you switch from pole to pole without protection, you have a charge going in both directions from the source to the motor and, because the motor is still spinning, from the motor back to the source and run the risk of blowing one or both the motor or source.

Anyways, that's my (also limited) knowledge of motor switching (not being cute or condescending) I've only been playing with DC motors for a short time and this is the best solution/cheapest solution that meets the objectives of my project.

If anyone out there knows better, feel free to stick your oar in!

WilsonL15 (author)baelza.bubba2016-09-20

You could use an on-off-on switch with the two "ON"s cross connected so that essentially you're just switching the wires round. Because you pass through zero (i.e. the off position) no nasty things happen. I have done this for a friends 3ph AC motor to switch direction. I don't see why it shouldn't also work for DC.

JohnC430 (author)WilsonL152016-09-20

because the AC goes thru Zero volts and DC can be full on when u try to change direction so opening a switch is bad news for the driver.

baelza.bubba (author)JohnC4302016-09-20

cool. good explanation! see this is why i love instructables.

mach1950 (author)baelza.bubba2016-09-20

Thanks baelza.bubba that's a great explanation, and makes perfect sense. I need to make some of these!!!

baelza.bubba (author)mach19502016-09-20

cheers :) post an "I made it" when you do! also check some of the other comments. There's one about on/off/on switch that may apply ... an in4001 diode may be a solution.

JunezRiyaz (author)2016-09-20


baelza.bubba (author)JunezRiyaz2016-09-20

Cheers :)

thefrogman123 (author)2016-09-20

Could you post links to the parts?

the parts have been gathered over 2 years. I bought all of the parts on eBay ...

About This Instructable



Bio: I have been working in IT since the mid 1980's. Most of that has been database and application development. I've been working on ... More »
More by baelza.bubba:Simple Breadboard Switchable Power SupplyL293D Motor Direction Control for under $2.2012V NE555 PWM Controller Under $3
Add instructable to: