Only one motor turns


#1

Hi,

My son Leo built a BrickPi robot (see http://brickpi.blogspot.com).

It had been working, but right now only one motor turns, even when he uses the example Python script: LEGO-Motor_Test.py that was provided by Dexter.

When we swap wires, the other motor turns. Rebooting has no effect. We tried motor ports A, B, C, and D… no matter what, only one motor turns.

Any idea what might be going on?

(thanks)

– Michael


#2

Wait! There’s an update.

By carefully experimenting, Leo discovered that motors A and B work together just fine.

The example code seems to try to turn on all ports, any idea why we may have lost C or D?


#3

Hey Michael, great blog! I have been loosely following it showed up in my Google feed a few days ago. Cool stuff!

When you run the BrickPi, it sounds like motors A and B work ok, C and D are not responding. This is when you run this script:

https://github.com/DexterInd/BrickPi_Python/blob/master/Sensor_Examples/LEGO-Motor_Test.py

Is that right? If you swap motors, do the C and D work?

John


#4

Also, I see this on your blog " but as I quickly found out, it is not enough voltage to turn the LEGO Mindstorms motors:"

Indeed, we warn against doing this! This could result in destruction of your Pi or your BrickPi (and might be why the motors aren’t working):

http://www.dexterindustries.com/BrickPi/getting-started/power-up-the-brickpi/


#5

The answer is yes, motors C and D do not respond.

I also note that the test script makes the motors change direction repeatedly, which might cause the current draw to spike? Leo’s actual robot scripts run at lower power and don’t change direction.

Leo tried running off just USB power supply initially because his BrickPi arrived without the AA battery holder (we ordered one separately from Amazon). I don’t think any damage was done there, because his first iteration of robot used the AA batteries and motors B & C. He chose B & C to make the wiring tidier. A photo of that iteration of the robot is attached.

(if attempting to run motors from a USB power supply might damage the Pi or BrickPi, you may want to make a prominent warning on the web page that you referenced)

Are the C and D motors controlled by a common circuit? And is that separate from A and B?

(thanks for the help)

– Michael


#6

Hi Michael,

Makes sense. I just want to be 100% sure that this program hasn’t been changed (https://github.com/DexterInd/BrickPi_Python/blob/master/Sensor_Examples/LEGO-Motor_Test.py). If possible, can you try to use “wget” on the commmand line, get a fresh version, and run it to make sure that the motors are not spinning?

From what I can tell, it looks like you have everything hooked up correctly. Both sides of the board (S1, S2, MA, MB) run off one chip, and the other side (S3, S4, MC, MD). So I’m interested if you get a response from S3 or S4.

Either way, I appreciate your patience with the BrickPi; if we can’t get this to work, we’ll replace your hardware.

Best,

John


#7

Thanks for getting back to me.

I downloaded the motor test python script from GitHub and did a diff (attached), it’s exactly the same as the script on the Pi.

The robot does not use S3 or S4. I could ask Leo to plug in some simple LEGO sensor to check for a response.