H-Bridge Motor Control

Hello everyone, I am a soon to graduate student that needs to control a 12v motor's direction as part of a final project. I am using an arduino because there are other constraints and triggers on how the motor will be controlled, so I cannot just hard wire switches to the motor. I googled a tutorial on how to do this with an arduino which brought me to the one in the link below.


I have gotten all of the parts together and set it up exactly as shown on the diagrams on the tutorial, but the motor will only spin one way and stop once the switch is pressed, no reversal occurs. I tested to see if the arduino is working with LEDs and it is, once the switch is pressed, one LED turns off and the other turns on, so it seems that the code is working fine. I then tested the motor output pins on the h-bridge using LEDs and only one lights up when the switch is pressed, the other stay off constantly when they should both reverse just like the arduino's outputs.

My question is, could I have gotten a faulty h-bridge? What other possible things could be happening here that I did not think of and would prevent the motor from turning the other way?
I have already triple checked and re set up everything, so there is no fault in the set up.

How large is your motor? is your motor powered from an external power supply? Note that the H-bridge used in that project will probably only work with small motors.

Hi, have you constructed this project on the type of protoboard shown in the tutorial.
Check the two supply rails that run down the long sides of the protoboard, some boards break the rail halfway along the board so supply is not continuous.

Tom.... :slight_smile:
ps can you post a picture of your project please.

Without more information it sounds like the H-bridge is either faulty or there is a
poor contact / solder-joint somewhere - the bridge can drive an LED but not the motor.

However details matter - which H-bridge, which motor, how connected, etc etc.

Here is the battery and motor that I am using, a 12V battery and a 12V motor.

Here is the setup, and the H-Bridge is the same L293NE used in the tutorial:

Currently I have it set up to LEDs which is how I noticed that pin 6 is not switching to positive when the logic input is switched on. I have used this with the 12V battery and the 12V motor and it does work, but like I mentioned earlier, it will not switch directions, only stop.

The breadboard is small and I tested to make sure that all of the sections are powered. I have also moved the H-Bridge to different areas up and down the board in order to see if there were faulty connections on the breadboard, but I got the same result.

Hi, when you want to show us diagrams and pictures, please use the Attachments and other options, in the bottom left hand corner of the REPLY window.

Tom... :slight_smile:

Hi, again, can you draw out your circuit from what you have on the protoboard, that is reverse engineer what you have, do not consult the documented circuit, include your test LEDs.
Then compare it to the documented one.
Also show us how you are testing the motor output with LED's.

Tom.... :slight_smile: