Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Forums > Electronic Projects Design/Ideas/Reviews


Electronic Projects Design/Ideas/Reviews Are you building an electronic project or want to? Maybe you need some assistance? Come and submit your electronic questions here and let our experienced members find a solution.

Reply
 
LinkBack Thread Tools Display Modes
Old 12th February 2008, 06:51 PM   (permalink)
Default 8051 microcontroller to control servo: any ideas?

Hey everyone. I ran a search but came up with nothing, so maybe you can help.

I'm using an 8051 microcontroller to control the movement of a Radio Controlled Toy Car. Basically, I want to be able to program the movement and let it run its course.

I'm removing the RF control portion of the car. The controllers for the steering servo and the rear wheel will stay in place and both use PWM. So basically, the microcontroller will have to reproduce the PWM waveforms to the servo controllers.

The voltages are at 5V, so there's no voltage amplification/reduction needed from the microcontroller. I guess there just needs to be a drive circuit between the two so that I don't burn up the controller.

Any ideas? Thanks in advance!

-Mike
ZX3ST is offline  
Old 12th February 2008, 07:12 PM   (permalink)
Default

YOu are on the right track. If it is a remote control car, the motor drive rshould also respond in the same way to the radio receiver's signals which can also be reproduced by the 8051.

What kind of toy car is it? Like a REAL radio control car? Or a toy radio control car made for 5-year olds?
dknguyen is online now  
Old 12th February 2008, 07:18 PM   (permalink)
Default

It's a "real RC car". Although it's not an overly expensive one.

I guess the main question I'm asking is what the heck am I gonna have to build between the microcontroller's output and the input to the motor/servo controllers? To make things clear: I am NOT driving the servo or the rear wheel directly. There are small control modules that are already in place.

If you guys need more information, just say the words. I'm trying to stay to the point and to avoid complicating my post with information that just isn't needed.

Last edited by ZX3ST; 12th February 2008 at 07:22 PM.
ZX3ST is offline  
Old 12th February 2008, 07:59 PM   (permalink)
Default

Well by definition an RC servo has the power electronics built into it already since the radio receiver obviously can't drive the DC motor inside the servo directly.

So by this (dare I say infallible?) logic, there must be a motor controller that responds to the same type of signals the servos do from the same radio receiver, otherwise how would everything work?

So, if this is the case, and it is a real RC car (with "real" swappable parts), then the radio receiver outputs PWM signals and the servo reads them and interprets them as a position and it's power electronics inside the box do the rest of the job to actually drive the motor. It is the same for the motor driver, except that it interprets the signal as a speed.

So the answer to your question is most likely NOTHING since you make it sound like the car came with servos, motors, motor drivers (ie. the modules) and was all ready to run. Just run a PWM line to each servo and motor driver (and provude them power from their non-logic power source of course). If it was not all ready to run though, you might need to get another one of the "modules", be it a servo or motor driver. You don't have to build it unless you want to control it in some other way (like if you didn't want the 8051 to simulate the signals of a radio receiver). But otherwise, just buy one- much cheaper and faster and easier.

Easy as apple pie.

EDIT: By real RC car vs toy RC car, I am asking if it is hobby grade or not.

Last edited by dknguyen; 12th February 2008 at 08:05 PM.
dknguyen is online now  
Old 15th February 2008, 12:29 AM   (permalink)
Default

It's a hobby grade car, although an entry level one. The kit with starter battery was like 150.

I took some measurements today, and found exactly what you said, dknguyen. Thanks!

To give a little more detail, here's what I found:
There are 3 wires running from the AM radio receiver to the steering servo controller, and also to the speed controller. One wire supplies a constant +5V and another Ground. The third is the control signal.

This control signal provides a roughly 4.7V square wave at 66.67Hz. (Plus some noise due to the radio receiver being AM. The servo (and speed control) modules respond by changing the duty cycle of the signal, but nothing else.

In my haste, I didn't grab the input impedance to each of the modules. What kind of output impedance does an 8051 have on its pins, and what kind of current can it supply?

Lastly, what's an easy way to program the controller to modify the duty cycle as such? Any ideas?
ZX3ST is offline  
Reply

Bookmarks

Thread Tools
Display Modes



Similar Threads
Title Starter Forum Replies Latest
Fast Line-Follower Motor Selection? What to Look For... richardv2 Robotics Chat 10 25th January 2008 03:02 AM
Need some servo control application ideas for a project!!! lompa Electronic Projects Design/Ideas/Reviews 5 18th January 2005 01:06 AM
Project title: Position Control system, and ideas a example? lompa Electronic Projects Design/Ideas/Reviews 4 24th October 2004 10:45 PM
Angular Control of Stepper Motor by 8051 cyw1984 General Electronics Chat 3 10th October 2004 01:43 PM
radio control servo motors mechatonics Robotics Chat 1 3rd June 2004 02:36 AM



All times are GMT. The time now is 06:55 AM.


Electronic Circuits  |  Learning Electronics
Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.

eXTReMe Tracker