Let's Make Robots! | RobotShop

Raspberry Pi Dagu Rover 5 4WD driving issue

Hi there,

I'm very new to robotics & I'm having an issue getting the Rover Wheels to spin properly. I've been able to get it to turn only in 1 direction, but only 1 channel at a time. When I attempt more than 1 channel, either they both slow down drastically or 1 stops turning while the other spins very slowly. (I guess this is a sign of power drain)

Below are a list of the parts that I'm using:

1) Raspberry Pi 2
2) Adafruit 8 channel bi-directional level shifter
3) Dagu 4WD motor controller
4) Dagu Rover 5 4WD chassis w/Encoders 

Attached is my wiring diagram.
Note: I'm using the RPi GPIO to send the PWM signals as well as control the direction pin.

Please let me know if I'm on the right path, and if you need further info just let me know.
Thanks for your assistance in advance. 

RPi-with-LLC-and-Motor-Controller.png30.57 KB

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Your wiring diagram shows PWM & DIR both set to steady state values. Do you have a scope or logic analyzer to verify that PWM * & DIR are behaving as expected? Pulsing the PWM via RPi software loops is likely to be quite sloppy. Many builders install a cheap Arduino style board that talks SPI or I2C to the RPi and generates PWM for the motors.


Hi there,

thanks very much for your reply. I have tested the PWM signal that is being generated via the RPi, and it's ok, though not as clean as compared to a hardware generated PWM signal. 

I am able to vary the PWM via code and see the changes in a single motor. The Dir Pin however is what's confusing.

For instance, a Low Signal on the Dir Pin should cause the wheel to rotate in an opposite Direction as opposed to a High Signal.
However, the wheel will only turn on a High Signal (4.75V => ~5V). The Low Signal that I'm getting out of the LLC is ~2.45V. So, I'm guessing that that voltage is not registering as a Low Signal.

I can upload a video of the issue, if you like.


P.S: Do you think I should get a mini-arduino board? 

For driving the PWM & DIR pins you should be ok directly from the RPi. Going the other way (encoder signals) would need the shift. I think you could have picked a simpler level shifter as you are not using the bidirectional feature. Is it possible that the RPi DIR pin is configured as an input?.


Both the PWM & Dir pins are configured as output pins. I have it in a script & I also test it directly from the Python Console.
Based on the Motor Controller Spec-sheet, it looked as though it needed 5V logic to work, that's why I chose a bi-directional shifter. So, that I can send the 5V logic signals, and when time comes I'll be able to receive the Encoder Signals. 

How is it that you came to know, the Motor Controller can take a 3V logic output straight from the RPi?
Would you like for me to bypass the Shifter & test it straight from the RPi? 


Typical TTL input logic levels are about 0.8 for a low and 2.0 for a high. This puts them within the 3.3V output range. The specific device will have exact specifications but I usually don't investigate unless there is a problem. Some 3.3V CPU chips (microchip PIC24 for example) have a number of I/O pins that are 5V tolerant. I often drive h-bridge with 3.3V logic and process 5V motor encoder signals without level shifters.

What is the model number of your motor driver board?


Understood, thanks.

I'm not seeing any model or version numbers on the Motor Driver Board. Below is a link to the board that I'm using.
Motor Driver Board: https://www.sparkfun.com/products/retired/11593 

I will test driving the motors without the level shifter later tonight, and I'll let you know how it goes.

When I visited Rover 5 on Sparkfun they said I last purchased one and the motor driver board on December 20, 2011. I found them and a couple of RPi's. Recall putting it way while awaiting a CPU module with enough I/O pins. I have since moved and lots of stuff is still among the missing. Guess I will be following your progress a little closer now.

Hi there,

I'm so happy right now. Thank you very much.
I've bypassed the level shifter, and used the GPIO pins from the RPi straight to the motor driver just for the Dir & PWM pins, and it works.
I've only tested with a single channel. So, I'm going to connect 2 channels on the same side of the rover for 1 track, and see how that goes.
And finally, I'll connect all 4 channels, test and report back here.

Thank you so much, everything makes sense now.
Because, I was using 5V logic on the Dir & PWM pins, when I send a Low Signal on the Dir pin, it was still being read as a High, and therefore not turning in the opposite direction.

Note: When I reach the encoders part etc, I will continue to update. So, at the end you can see my complete project.
My project, is to have an A.I program that will control the Robot to map out unknown terrain, it will be taking into consideration track slippage etc. for proper navigation & control.

Thanks again.