0
$\begingroup$

I want to turn some motors using my raspberry pi. I am able to turn an LED on and off using the 3.3V GPIO pin. For the motors, I tried using a L293D chip as per the instructions on this link.

What happened is that the very first time I set the circuit up for one motor, it worked perfectly. But then, I moved the pi a little and the motor has since refused to work. I even bought a new pi and still no luck with the circuit. I then bought a L298N board that fits smugly on top of the GPIO pins of the pi and followed the instructions on the this video

Still no luck, the motor just won't run with either pi. I am using four AA batteries to power the motor and a connecting the pi to a power supply from the wall. What could possibly be the problem here?

$\endgroup$
  • $\begingroup$ Can you post pictures and/or schematics of how you have this set up? The "moved it a little and then it stopped working" is probably a red herring; probably something else is going on and that's the last time you remember it working. $\endgroup$ – Chuck Nov 11 '15 at 23:07
1
$\begingroup$

If you have changed the Pi and changed the L298N board then I would suspect there is a problem with the motor. Is it possible to drive the motor without the Pi?

You could try replacing the batteries with a second power supply, I'm assuming you have checked the batteries aren't flat :)

$\endgroup$
  • $\begingroup$ Sorry - forgot to mention.. I did try connecting the motors directly to the battery as well and they seem to work fine. $\endgroup$ – Rohit Pandey Nov 10 '15 at 18:53
  • $\begingroup$ Have you checked/changed all the wires? Did you disconnect the wires when you moved the pi? If so its possible the wiring diagram is wrong and you put a wire in the wrong place first time? Have you rubbed the batteries between your hands? :) $\endgroup$ – Code Gorilla Nov 10 '15 at 20:02
  • $\begingroup$ Yeah, I checked the wiring diagram multiple times and still no luck :(. Can you recommend a motor shield that worked for you with the RPi? $\endgroup$ – Rohit Pandey Nov 10 '15 at 20:13
  • $\begingroup$ Sorry, but I've never used a pi and a motor. I have used an Arduino and a motor driver board, the cheep $1 ones of eBay/AliExpress. aliexpress.com/item/… But I'm not sure that will help, because it needs 5V logic. $\endgroup$ – Code Gorilla Nov 13 '15 at 12:56
0
$\begingroup$

run a continuity test on the windings using your voltmeter and let us know what the resistance is compared to what the datasheet on your motor states. That will give you a clue as to whether your motor is ok or not, if you get no reading, then your motor is gone.

$\endgroup$
0
$\begingroup$

The same thing happens to me. When i connect my motor it works for the first time and after that it stop working.

Finally i figured out my breadboard was faulty. It may not be your case but do one thing connect all the wire by hand by pressing your finger tip and see what happens.

$\endgroup$
-1
$\begingroup$

The datasheet of the l298n motor clearly states that you need a minimum of 4.5V of Vss,that is logic supply.Try giving it a higher voltage. 3.3V wont work.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.