First Steps: Setting the Stage for Building a Robot
Doug Leppard (DLeppard@CCCI.Org)
Benjamin Leppard (Benjamin@Leppard.Com)
I will be doing a series of articles outlining the steps we have taken in building our
robot. Both Benjamin and I are newbies at this and thus it will be written for newbies.
Articles will be focused on a robot that will compete in the Fire Fighting contest, be able to roam around
the house and just be a fun learning tool. The 68HC912B32 is our processor, so articles
will be on interfacing to the B32 to various mechanical devices and sensors using Sbasic
as our programming language. Who are we?
We are a father and son team.
I (Doug) am the father old enough to have a son in college. I am an Electronic Engineer by
training and I direct the international division for information systems of Campus Crusade
for Christ. As a hobby, I built my first three computers from scratch, called Home Brew in
those days. My son,Benjamin, is a second year Computer Engineering student at UCF
(University of Central Florida). I am the main builder with my son the consultant, who has
put me many hours ahead on this project with his extensive knowledge.
Why a robot?
Count on it, if someone finds out you are building a robot they will ask why and what
will it do. Almost no matter what you say it will do, it will leave them cold. It will
never do enough to meet their movie expectations. Plus they dont, for the most part,
understand the why of building a robot. You and I do because we want to create and explore
and we like the challenge. So I tell them that I am entering the computer in the Fire
Fighting contest. This is something they can understand plus it gives you me goals to
My real reason for building a robot goes back to a night when I was in grammar school
and stayed up dreaming about it. It has taken 35 years to become a reality. This is
actually my second attempt at a robot. The first one was a couple of years ago based on an
IBM PC 386SX. Weighted a ton, actually moved around but the CPU ate too much power and
would not stay alive for more than minutes at a time. It was a failure in the robot sense,
but I gained knowledge especially on what not to do.
Setting your goals
In any project you need to set goals or you will just wander around and maybe
accomplishing nothing. So you should have goals that you can aim towards. It may be small
(fire up a micro and turn on a led) or large (enter a contest). If it is a large goal then
it needs to be broken down into manageable and achievable goals or discouragement will set
in. Steps in setting your goals maybe:
- Do research on what has
already been written and done. Get on the net and explore and learn what others are doing.
Go to the local library and explore books on robots. Take your time and enjoy this
step. Write things down as you go.
- Analyze what you can do. If you are a beginner in electronics and
computers, start small and then build from there.
- Write down your goals.
- Get started. Once the above is done, just start moving. Its
called tossing your hat over the fence. Once the hat is over the fence you are committed
to climbing the fence. My hat in this case was deciding on the CPU and buying it. With
real money committed you have to do it.
For example our goals are:
- Enter the Fire Fighting contest. Therefore
it must meet those requirements and has enough abilities to compete.
- Have a robot that can just wander around the house and be a building base for future
Note: These goals are not mutually exclusive, but do cause compromises that will cause the
robot not to be the best in each world. Fire Fighting robot need to be as small as
possible to get through the doors quickly and still do the job. House robot and building
platform needs to be large enough to go on carpets and carry various sensors and have
strong enough motors to do the job.
- Robot can be no bigger than 12" by 12" by 12" (fire contest)
- Needs strong base with strong motors
- Large enough wheels to go across carpet
- Need wheel sensors to judge speed and to keep going straight
- Candle detection sensor(s)
- Floor detection, edge for real world and line for Fire contest
- Wall sensors (no touching)
- Way to blow out candle
- Portable power source
- A electronics platform that wiring can be easily changed
- Feedback device while robot is on own to know what is happening on inside of CPU
Principles in building a robot
- Use kill and control switches, the robot has a mind of its own
and will do unexpected things.
- Use connectors between assemblies so you can connect and reconnect as
much as possible. This will happen a lot!
- If your robot base is layered like ours, make sure the layers come apart
easily and the wire connectors are long enough to test while layers are apart. This is
important for you will have to test between layers and having it lay open allows you to
see if it has the right voltages, etc.
- Three ring binders. Building robots is about building information. I
have two binders, one holds all the information on the B32, second holds Encoder and other
articles, spec sheets. This has greatly increased the speed of the projects for I can
always find that article or information I need.
- Document what you have done. Keep a notebook of ideas. Paper is better
for remembering then gray matter. Save the gray matter for creativity.
- Tools. Get the right tools and have them there at all times. These
- Digital Volt Meter. Need the accuracy of digital. Analog has it place
- Digital Logic Probe to test what is
happening on the input and outputs. Will tell you if it is a pulse, if it is high or low
and you can judge roughly the duty of the cycle (by how leds change brightness). Get this
a Radio Shack for about $20.
- Proto-Board breadboard (where you can put
chips on and use wires between connections). I have two. One that sits on the desk with
its own power supply to test circuits and for some of the interfacing to robot. Second is
on the robot itself to hold the electronic. You can get these at Radio Shack or
- A scope would be nice but expensive. Borrow one if you can. While at
Radio Shack I found on sale a ProbeScope that
has an RS232 connector into your PC and turns your PC into a simple scope. Last one there
and got it for $30. It lets me see the signal, lets me know the period and frequency doing
the math for me and its duty rate.
- A work space with everything handy. I had to
carve out a work space that would allow me to work a few minutes at a time without having
to set it up each time.
- A PC to program and download to robot. With a family of four kids the
family computer is maxed. So I borrow my work notebook that is usually home with me. If
that is not possible get a low end PC that is cheap on the second hand market. Any 486
should do it for this project. The most CPU intensive part of this is the browsing on the
net which can be done on another computer.
- Organization bins. My wife got fed up with our
mess in our work area and we straightened up my stuff. With the various needed pieces in
bins everything is now locatable.
Have fun working on your robot, it will be a worthwhile experience. The next
article will be on the choice of the 68HC912B32 and why; choosing the programming language
and choosing the CPU kit. It will be hopefully a lot more into making it happen. Future
articles after that will include: using Sbasic with the B32 board, hooking up H bridge
wheel drivers, using an RF link to/from PC to robot, using the Victor compass and wheel
||Doug and Benjamin in front of work area.
||ProbeScope and Digital
Logic Probe. The ProbeScope was great in testing and debugging the shaft
encoder. It hooks up to your computer and uses it's power. Only problem is on
my notebook computer has only one RS232 port. I could freeze the signal and analysis
The Logic Probe is great for testing CMOS logic. You can test if it is
high/low or pulsing and shows the results using both LEDs and sounds.
||Work area. Not a lot of space but it does
the job. Far left is all the books on the shelf. The two notebooks on floor is
the documentation. The table is left over from the kids home school days.
to the right. I can't seem to figure out where to put the Nuts and Volts Magazines.
They are so oversized they don't fit anywhere.
The important thing is keeping everything within reach so time is not lost getting up.
||I bought this protoboard over 23 years ago (what
else in electronics can you use 23 years later). It is great for protoboarding new
circuits. It has 5V, -12V, 15V unregulated.
(I did a lot of research on the Net. Below are some notes I kept in a Word file.
No real order just random findings with some comments. You may find it
- uses Sbasic http://www.seanet.com/~karllunt/
- use 68hc11 (or newer 12)
- get fire fighting video (requested 5/2/98, out July 98)
- bend sensor though IMAGES COMPANY ( http://www.imagesco.com
) at POB 140742, Staten Island NY 10314 (718) 698-8305. http://www.robotmag.com/hardware/bendsens.html
- send for rs232 radio chips (ordered 5/2/98)
- SN754410 QUADRUPLEHALF-H DRIVER can drive4 1-Amp motors in one direction or two 1-Amp
motors in two directions from TTL or CMOS inputs.
- Eltec 442-3 Pyroelectric Sensor package robot to interact with people and/or find
sources of heat such as candle http://www.acroname.com/robotics/parts/R3-PYRO1.html
- Polaroid Instrument Grade Transducer, 6500 Ranging Module, interface cable, and
application notes and specifications $46 http://www.acroname.com/robotics/parts/R14-SONAR1.html
- A companion kit for the book, Mobile Robots: Inspiration to Implementation. $289 email@example.com
- MAX 97 specs 12 by 12 robot base $179 + shipping http://www.zagrosrobotics.com/max97.htm
- excellent links see Embedded Microcontrollers 68hc11 in bookmarks
- Ferret chip FT639 controls up to 5 servos http://www.busprod.com/ferrettronics
, FT629 detects 5 switches sends back serial (ordered 5/3)
- Handy Board system is US$284 MIT 68hc11 board http://www.gleasonresearch.com/ or Robot
($190, with Interactive C $210) The Handyboard consists of a 8-bit CPU (Motorola
MC68HC11A1) with 32K on-board RAM that runs on Interactive-C (C like programming
language). It can drive up to 4 DC motors and 2 servo motors. It also has digital and
analog inputs that allow the board to interface different sensors easily.
- Futaba S148 servo, a solid, economical model LA5026 for $13.99. http://www.towerhobbies.com/
- Finger Board II: $130.00 (Handy Board w/o IO)
- Mekatronix is a manufacturer of Autonomous Mobile Robots, Robot Kits interesting bases http://www.mekatronix.com/
- Interactive C from Mekatronix $32
- various sensors http://members.aol.com/fuboco/optical.htm
- 68HC11F1 F1 most powerful board $129 http://www.emacinc.com/uphc11.htm#PRICING:
- PLCC prototype adapters for breadboarding, wire wrap and design prototyping http://www.hooked.net/users/amaze/plcc.html
- Motorola HC11 Reference Manual - $5.00 http://www.access.digex.net/~pha/
- Sbasic http://www.seanet.com/~karllunt/
- simulator:for 68hc11 under windows http://dj.cse.rmit.edu.au/Simulator/6811wsim.htm#WhatIsIt
- M68HC11 Emulator http://www.geocities.com/SiliconValley/Heights/8543/index.html
- 68mc11 pinouts http://www.bsyse.wsu.edu/~rnelson/microcontrollers/mc6811_pins.htm
- 68HC11 MicroController Development Tools: http://ourworld.compuserve.com/homepages/grantb/
- Commercial IC Producers http://www.mrc.uidaho.edu/vlsi/com.html
- Assembled and tested Finger Board II: $130.00 http://www.wenet.net/~jfong/
- 68HC11 Controller &Languages $79.00 http://www.newmicros.com/y20ad/y20word8.htm
- 68K development suite, http://www.sdsi.com
- examples of assembly code http://www.interlog.com/~gretchev
- Chip Directory This is a database for the ENTIRE world of chips, great reference. http://www.hitex.com/chipdir/
- An Overview of the 68HC12 http://www.seattlerobotics.org/encoder/jan97/The68HC12.html
- Seattle Robotics Society http://www.seattlerobotics.org/encoder/jan97/index.html
- Where to buy 68HC11 chips and documents http://www.seattlerobotics.org/encoder/feb97/basics.html
- Cheap Sonar http://www.seattlerobotics.org/encoder/apr97/sonar.html
- Ultrasonics and Robotics http://www.seattlerobotics.org/encoder/may97/sonar2.html
- Design Overview of a Home Robot: http://www.seattlerobotics.org/encoder/jul97/gensys.html
- The Basics Sensor http://www.seattlerobotics.org/encoder/jul97/basics.html
- RS-232 to TTL cable http://www.seattlerobotics.org/encoder/aug97/cable.html
- Motorola 68HC12 products http://www.nwlink.com/~kevinro/products.html
- Sbasic overview http://www.seattlerobotics.org/encoder/aug97/basics.html
- A Few Words About Motors PART 1 http://www.seattlerobotics.org/encoder/sep97/motors.html
- 68HC812A4 Development Board http://www.seattlerobotics.org/encoder/sep97/12014.html
- SBasic FAQ http://www.seattlerobotics.org/encoder/sep97/viceprez.htm
- 68HCxx Internet Resources http://www.eg3.com/embe/gatox68h.htm
- Surplus Electronics Source List A lot of neat stuff.
http://www.robotics.com/surplus.html and http://www.eio.com/
- The Acrylic Base http://www.seattlerobotics.org/guide/index.html
- Mechanical Devices for the Electronics Experimenter amazon.com (done)
- Examples of SBASIC Code. http://www.rdrop.com/users/marvin/sbasic.htm
- Infrared Emitter and Decoder http://www.boondog.com/
- DPRG L298 (1 amp PWM) H-Bridge Project http://www.dprg.org/l298.html
- HBRobotics Club Builders Book http://www.wildrice.com/HBRobotics/HBRCBuildersBook.html#DRS
- Robotics Frequently Asked Questions List http://www.frc.ri.cmu.edu/robotics-faq/
- M68HC812A4 Evaluation Board http://freeware.mcu.motsps.com/dev_tools/hc12/index.html#evb912
- M68HC12 Family Device Technical Documentation http://mot2.indirect.com/books/mcu/mcu_m68hc12_family.html
- A small pc board for the 68HC812A4 http://www.rdrop.com/users/marvin/12a4.htm
- DEVELOPMENT BOARD $300 http://www.inforamp.net/~ulogic/products/hc12_dsp.html
- M68HC912B32 Evaluation Board Brochure http://mot-sps.com/books/mcu/mcu_m68hc12_family.html#Development_Tools_Documetation
- ADAPT-912 M68HC912B32 $129 http://www.interlog.com/~techart/myfiles/ad912.html