Let's Make Robots!

Wall Following RC car using 16F887

Here are two videos of my hobby level radio control car following the wall around a room.  This car uses channel 3 of the radio control system to toggle between RC control and autonomous control.



The idea is to hook middle school kids (USA grades 7th and 8th.  ages 11 - 14) into Science, Technology, Engineering and Math.  This offers the speed and excitement of RC car
 racing, the trial and error of RC race car design plus the clear thinking and discipline of computer programming.

 THE COMPETITION:  A car race.

 Build an oval race track on a polished wooden gymnasium floor defined on the inside by
 cardboard boxes large enough to echo back a SRF05 sonar proximity detector's signal.

 The race is to lap the track, say, six times;  three by radio control;  three by autonomous control.  Either time trials or multiple cars at the same time.  If the race has multiple cars on the track at one time, some more work must be done on the car to avoid collision.

  I will design and build a PIC kit that attaches to almost any RC car that has Electronic Speed Control (ESC) driving the wheels and a servo driven steering mechanism.  It will use the car's 7+ volt battery, knocked down to 5 volts by the ESC.  There must be a third channel on the RC system to tell the car who is boss.

 I need to borrow, steal, or design a microcontroller programming language that forces the students to think about the signals from the front and side facing sonars and create the corresponding commands to the wheels and the steering.  Presently the 16F887 compiler runs on a WINDOWS PC and communicates to the car via special hardware connected to the USB port.  (Available from MicroChip Inc.)

----------The post below seems to be way ahead of me----------

Author: bendjamin
| Title: I made some similar robots a

I made some similar robots a while ago.  I'll try and post a video of them.  They are designed to race around a track, in other words they are doing wall avoiding so when you make a track with walls on the inside and outside they will go around and around.  I made the robots myself, they are differential steering with a body made from laser cut polycarbonate.  I used the sharp IR rangefinders for navigation and have four on each robot, two forward facing and two side facing. They also have four bumber switches, one pair in front and the other at the rear.

| Link: http://letsmakerobots.com/node/696#comment-43464

What do you all think?



Comment viewing options

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

This morning I realized that I have actually made three different robots.  Three different RC cars with three different physical charcteristics dictated this.

First I built the 1/10 scale model level car based on an HPI SPRINT.  It has detailed miniature suspension and handling features, great speed, and proportional control systems based on pulse width modulation.  My PIC kit for this car is simple because the controls are digital signals.  All that is needed is the PIC and a DPDT switch.  The switch - under PIC control - selects which PWM signals (those from the PIC vs those from the radio receiver) go to the steering and driving electronics.  The PIC code is quite simple because of the car's capabilities.  At $200 - $300 for the car and my kit this seems too expensive for our public schools.

Second I built a 1/12 scale toy level car.  This is the same as fritsl made only with a solderless proto board.  This car has bang bang controls.  It requires the PIC, the SONARs and four DPDT relays to steer the DC current into the correct connections.    It runs slowly enough for the PIC and the SONARs to keep it within reasonable behavior limits.  It can be stopped in mid 'flight'  by turning ON the radio transmitter.  The price is right for our schools, but I feel the car is not fast enough nor exciting enough.  It is also too small to carry my KIT under the car skin.

Third I built the 1/10 scale toy car.  This car is much faster than the 1/12 scale toy.  It too has no proportional controls.  The added electronics kit is the same as the 1/12 car, but the code needed adjusting.  ie the 150millisec pulses.  I think the $50 car price is within budget.  My KIT is complex because of the four relays, but hopefully doable by a dedicated teacher and class.  The engineering is interesting because, as one of my videos shows, the behavior is a bit unpredictable.  Maybe if I had some help and a more sophisticated program ------


I wish I could help with the code but it is not my strenght. What is the language of the PIC ?

As I can see you have some good skill working with RC cars. Relays for switching are not as good as pwm for smooth operations.

I will keep up your progress Ken and see what you're up to. Take care.


I meant to say that the STEERING wheels have a spring which returns the whells to neutral - not very quickly nor very accurately.

Seems to me that using radio control vehicles as the base from which to build robots is a good idea - at least from an education point of view.  Much of the design is done.  They are exciting.  They are robust. They misbehave.

Today I was thinking of adding a PIC to a electric motor R/C airplane.  At our local RC store I  discovered that it has already been done.  The box claimed the plane had upward looking and downward looking sensors.  With these the PIC could stablize the plane.

Your ideas would be greatly appreciated.  What can I do with a PIC on a 36 inch long GOODYEAR blimp?


Look up DIY UAV. Find http://diydrones.com

or http://letsmakerobots.com/node/23257 and many others.

Thank you rik.  You have opened up a whole world that I did not know existed.  Everybody seem Arduino oriented.  I stumbled upon the Microchip PIC family on solderless protoboard.  Bad decision??


I am not getting myself into that Holy War. Don't open that whole world without some proper Google prep.

The LEXUS can parallel park itself.  My robocars can race around the room.  Same thing..
I've put up on youtube a new video which attempts to show the relationships between my autonomous radio control vehicles and the REAL WORLD - in particular the ability of the new LEXUS automobile to parallel park itself.  What do you think? 
Ken Jones

Then pick your message.

Using the Lexus example as an introduction is a good idea. To the teachers it introduces the topic of the lesson. To the kids it connects your "toy robot" to "real robots". After that, your video jumps straight into explaining your car modification to fellow engineers. None of you audiences will appreciate that for 4 minutes. I did, but they won't.

So hooking a teacher to this idea for STEM eduction huh? I think Youtube might be a good way to go. Make a video like the many you produced before, but make it appealing rather than educational. As you are describing the public school system in your home town, I think you should include arguments like "affordable" and "engaging" or "hands on". None of your videos have kids in them. Remember, the teacher's mind is not geared towards 1:10 scale vehicles. It is geared towards kids who cannot get their eyes off of their study. In your case: a car that runs itself.

School administrators will ask you about money straight up. Having no exact answer is not the problem. Failing to volunteer an estimate might cause many of them to lose interest in the first two minutes of you talking to them. Either in person or through Youtube.

Just to make your video close the narrative loop, compare your $100 to whatever it costs to upgrade a Lexus to auto park ability.

Thank you, rik.  That is good advice.