Posts: 8
Joined: Thu May 19, 2016 6:57 pm

Steering toy car with raspberry

Tue Dec 04, 2018 12:31 pm

Hello everyone!

I wanted to put rpi inside of RC toy car and program it to drive itself based on camera input.

Firstly I needed to dismantle the car of course. I expected to see servo for steering front wheels left and right but to my surprise there was a standard DC motor.

When disconnected from gears/wheels it spins normally, when mounted it stops after turning right or left which I guess is by somehow reading if the motor actually can spin further?

Now my question is if I can do the steering with raspberry pi. I know how to do it with servo, I would just send pwm signal to turn it but how do I steer with a standard motor?

I would probably connect the controller (something like L293D) so it would draw current from external source and steer it with rpi but how do I detect if the motor is still turning or not?

Sorry if this is noob question, I am beginner when it comes to electronics, trying to learn by myself :/

Posts: 4775
Joined: Fri May 31, 2013 9:28 pm
Location: Mansfield UK

Re: Steering toy car with raspberry

Thu Dec 06, 2018 10:07 am

Yes if the motor only draws a small current the L293D would be suitable to drive it , I suspect the original driver circuit had some current limiting it it which just allowed the motor to stall at the end of the travel .

The L293D does not any option like this so you would probably have to add limit switches to detect when the steering had reach full travel and the centre positions.

The other option would be to look at the original circuit board and see if you could use the pi gpio to drive the original driver circuit, it might have a pwm signal driving it from the original RC receiver, you may have to built an interface circuit as I doubt it will operate at 3.3v
Remember we want information no help
The use of crystal balls & mind reading is not supported

Posts: 78
Joined: Sat Jul 21, 2018 8:37 pm
Location: harrisonville mo

Re: Steering toy car with raspberry

Fri Dec 07, 2018 1:03 am

I am doing the same thing! We might need to talk about this because mine had the same oddity.
I have a pi3 two arduinos and a build it personality. I will do this!

Posts: 1
Joined: Sun Jan 13, 2019 7:13 pm

Re: Steering toy car with raspberry

Sun Jan 13, 2019 7:49 pm

Hello, I'm exact same point. I also use the L293D. I can run the rear motor (forward/backwards). The problem is the the DC motor with steering. I don't know how I should handle this. I read somewhere that you can put a resistor to reduce the torque of the steering motor. But that's not a very elegant solution.

How did you solve it? @Will5455 @Thun

EDIT: I had a closer look how my cheap toy car works as out of the box... There's a spring limiting the movement of the axis which also causes the steering to fall back to a neutral position (straight). It looks similar to this: There's no electronic limiting element.

Return to “Automation, sensing and robotics”