Adam by Rana Basheer

Adam was my first autonomous robot, I built him basically
to see if I could design and build a "simple" robot.
Although Adam was not as simple as I had thought he would
be, I did however, gain much knowledge about
robotics, and a greater respect for the people who build
robots, now knowing how hard it is and how much work
it takes to design and build a working robot from scratch.
Controller: The controller I used for Adam is an Atmel89C52
produced by Atmel corp.. www.atmel.com
Software Development Environment/Methods: I use SDCC C-Cross
compiler developed by Sandeep Dutta.
Sensors: For object detection I originally had planned to
use whiskers, but after some tries( none of which
worked very well ) I decided that infrared would be easier
to use for object detection. So Adam now has an
infra red sensor from Reynold Electronics. I am plannig
to add three cadmium sulfide photo cells ( photo
resistors ) for seeking, tracking, or avoiding light. I
am planning to add two more photo resistors, and a LED
for light, to the bottom of Adam so that he can also
function as a line tracker, allowing him to follow a black
line drawn on white paper.
Height: Adam stands about twenty centimeters tall.
Width: Adam is ten centimeters wide.
Length: Adam is about twenty centimeters long.
Weight: Adam weighs 750g.
Power source: Adam operates on two different power
supplies; The first is a four AA batteries running through a
five-volt regulator for the microcontroller and the
electronics. The second power supply consists of another
four AA batteries for the two servos.
Construction history:When I was at 9th standard I
happened to see a movie "Short Circuit" I was fascinated
with this video, I watched it over and over again always
finding something I had not noticed before or trying
to figure out how the robot worked and how I could
duplicate it. At that time I was severly handicapped due to
my lack of knowledge in electronic circuit but I made
a humanoid which I presented for my school science
exhibition. My humanoid was awarded the best design
and it was a morale booster for me. From then on I tried to
make some kind of robot or other.That was my first
experience in building a robot. It lacked impressive
features, it worked through switches which I manualy
used to set and reset. It had two arms each fitted with a
grabber made from pencil box and the arms were made
from broom stick as my motors, without any gear system,
where unable to carry much load. It had an impressive
head which could turn and two LED's formed its eyes.
During my under graduate studies at College of Engineering,
Trivandrum, I used to read a lot about walking
robots and their control systems I even tried to build a
mock leg to better understand the mechanics of the
legs and how the robot walked but it was a total failure,
designing precise gear systems proved to be too much
for me.This was around April '96. After researching some
more on walking robots, I decided that I was going to
try to design and build my own eight-legged walking robot,
but about two months into the designing process, I
realized that I knew basically nothing about actually
building or designing robots, especially walking ones!
and the fabrication of mechanical parts was too much for
me. The most important thing was getting the finance
for these works. So I stopped developing robots for
some time as I felt I was taxing my parents too much and I
started concentrating on High frequency RF circuits which
was purely electronics and I could manage RF circuits
with my limted finance then. After two years in software
industry I got too much involved in software and I
wanted a break I thought of starting my interest in
robotics again. One of the greatest impediment earlier was
finance but with that was not that of an issue now. So
I decided to make sure that I could at least design and
build a simple robot before I tried to build a walking
one. For the "simple" robot I was going to design and
build, I decided on a small wheeled one(caterpillar wheels),
and so Adam began.
The first thing that I did in making Adam was to construct
the 89C52 microcontroller board. 89C52, which is the
Atmel variant of the highly popular 8051 microcontroller,
was supposed to be one of the easiest micrcontrollers
to use, it proved to be rather difficult. Though I had
previously worked with 8051, 89C52 with 4K internal
flash Memory and 256 byte RAM was quite new to me. The
on-board flash memory made my life quite easy with no
aditional RAM chip or EEPROMs I could download my code
directly into its internal flash RAM. For writing into
its flash RAM I made a 89C52 flash programmer the circuit
diagram could be downloaded from here. One problem
that I did not anticipate was that the microcontroller was
not able to source much current through its ports
and I had to add extra pull-up resistors this I found out
very late, after integrating my servos and I had to
spend some sleepless nights to find out the problem with
my servos as the Pulse Width Modulated output was not
found to be varying linearly as I had expected. Also there
was lot of noise introduced by the dc motor for
which I needed large fiter capacitors to reduce it.
The seond thing I did in building Adam was to construct
the infra red sensor that I got from Reynold
Electronics the sensor is an integrated package with an
infrared transmitter and a receiver. Initialy I thought
the sensor worked on the time difference between the
transmitted and the reflected ray but I with the speed of
light being in the range of 3*10^8 m/s the time difference
is tooo small for any electronic circuit to detect.
The working of the sensor is very interesting, it senses
the angle between the transmitted and received
infra-red ray. An object very near produces large angle
while an object very far will give lesser angle. The
sensor ouputs a voltage which is propotional to the above
angle. The variation was not linear but still I could
live with that after all I need to find out if some object
is infront of Adam or not. Though its data sheet
specifies its detection range as from 10 cm to 80 cm
I found it to be much lesser than that.
The third thing I did was making the motor control servo.
The motor control servo used L293D motor driver chip
from National Semiconductors. The motors were contolled
through a PWM signals generated by 74LS193 4 bit
asynchronous preset binary counter and some logic gates.
The circuit for this is quite simple and straight
forward. The microcontroller outputs an 8 bit value to
control the speed of the motor. The MSB indicates the
direction and the subsequent 7 bits specifies a motor
speed form 0 to 127 scale. The data outputted by the
micro controller is latched by an 74LS573 octal latch.
This value is used to preset the counter whenever the
base clock generated by a dual 555 timer (LM556)
ouputs a low value.
Finally I added a transreceiver circuit to Adam so that
it can communicate with my PC but the circuit is yet to
start working and I am still finding a lot of hurdles
in make it fool proof. The most important thing is in
making its transmitterr and receiver sheild against
external noise generated by the motor.
Operational description: I have programmed Adam to
avoid obstacles.
I will describe a scenario to make it easier to explain...
One fine obstacle detecting day, Adam is running
forward when all-of-a-sudden, BAM! Adam's infra red sensor
detects an obstacle. Adam, not wanting a conflict
with the obstacle, reverses and then turns his right servo
causing him to turn in place to the left, away from
the obstacle. Detecting that no obstacle is in front of it,
Adam resumes his journey forward.
Future Enhancements/Plans: From now on I will probably
just enhance or replace Adam's program.
Status: Adam is partly finished, and as for the software
Adam serves as a kind of "test bed" for when I have a
"bright idea" for a new program.
Email: mrbxcf@umr.edu
Return to The Robot Menu