title.jpg (20464 bytes)

Albert Menu:        

 buttblue.jpg (750 bytes) Albert Project Home
The Albert Project Homepage.
 buttblue.jpg (750 bytes) Project Log
Follow Albert's progress.
 buttblue.jpg (750 bytes) Long Term Goals
Read the long term project goals.
 buttblue.jpg (750 bytes) Short Term Goals
Read the short term project goals.
 buttblue.jpg (750 bytes) Gallery
Enjoy pictures of Albert, taken during development.
 buttblue.jpg (750 bytes) Albert's Five Ears
Read this report about Albert's sonar sensors.
 buttblue.jpg (750 bytes) Albert Programming
Read this report about Albert's low level and high level code.
 buttblue.jpg (750 bytes) Speak, Albert, Speak
Read this report about Albert's text-to-speech ability.
 buttblue.jpg (750 bytes) Mood-Based Behaviors
Read this report about Albert's "Mood Matrix".

The Albert Project Log
Project Log Archive (8/26/99 - 4/6/99)

December 20, 1998
Today is the day I started recording my ideas about this project.

January 12, 1999
Today I spent several more hours researching robots.  There are no clear choices, but the Trilobot has a lot of really cool features.  Plus, I've talked to a couple of people who own one and they speak highly of not only the robot, but of Roger Arrick and his company, as well.  I just wish the Trilobot was a little bigger... and a little bit less expensive.  (It has a lot of features that I don't need:  gripper, laser pointer, water sensor, IR transmitter and receiver...) 

January 19, 1999
Well, I did it.  I called Roger and ordered a Trilobot.  Better start looking for a big ring or something to pacify the wife.  <g> 

January 25, 1999
Roger sent me an e-mail this morning and said that my Trilobot should be arriving on Thursday.  Now comes the hard part... the waiting.  <g> 

January 27, 1999
It's been a long week, but Albert should be arriving tomorrow.  <hack>    I'm very <cough> excited to get my hands on him.  <gag>   Gee, I'm not feeling well -- I might have to stay home from work.  <g>

Once I get a chance to start experimenting, these log entries are going to be more substantial... 

February 8, 1999
Well, I had to send the Trilobot back.  It is a great little robot, but it just didn't have enough power or traction to handle our medium pile carpeting and thick pads.   Moving forward and back wasn't a problem, but he just couldn't handle stationary turns... even using the remote control.

My backup plan is going to require more work, and it won't offer all the bells and whistles of the Trilobot, but I think it will handle our rug.  After several weeks of research I purchased a robot base from Zagros Robotics.  The kit includes two motors, drivers, optical encoders, an H8C11 processor (with basic motor/sensor code), and all the hardware.  For an additional charge AJ Neal, the owner, will actually do all the construction and wiring.  I also purchased 5 sonar sensors, a digital compass, and an analog light sensor... which AJ will also install for me.

Initially, I wanted to control the robot by using the RF modem link to my PC.    For voice, I experimented with a transmitter (attached to my PCs sound card), and a receiver/speaker setup on the robot.  Unfortunately, I couldn't get a clear and consistent connection.  So after some more deliberation (which included the idea of abandoning the project), I found a relatively inexpensive Compaq Presario 1220 laptop.    It should not only be capable of low level control, I should get great text-to-speech synthesis, and possibly even voice recognition!  If the latter is possible, I don't know why I couldn't use a microphone as a sound sensor.  I can still attach the RF modem to my PC for internet access, additional storage space, and high level control.

February 17, 1999
The Max 99 base I ordered wasn't big enough for the laptop I purchased, and the Max 97 base (12 x 12) is about half an inch too small because of the vertical posts that support the upper decks.  AJ agreed to build a custom base for me that is 14 x 14.  He told me yesterday that the robot will be mailed out sometime next week.  Oh, how I love to wait.  <g>

Meanwhile, I've been experimenting with Microsoft's Speech SDK, and it's quite good!  I not only have the laptop talking (believe it or not, there are six "robotic" voices to choose from), but it is actually "hearing" what I say, as well!  Last night I added a dozen or so words to the dictionary to test the voice recognition engine, and it caught almost everything -- even when I was across the room and speaking normally.  (As opposed to talking loudly and enunciating every syllable.)  Click here to hear Albert say hello!

March 10, 1999
The 14 x 14 Max base should be here tomorrow.  I'm not sure what caused all the delays, but AJ said the robot has been shipped out and I'll have it by Friday at the latest.  I met a robot builder at the Seattle Robotics Society named Chris "The One" Hostetler, and he has kindly agreed to help me put the robot together this weekend.

March 11, 1999
Well, my Zagros Max base is here!  I'm a little disappointed because I had asked AJ to send me (and I paid for) a "pre-built" robot, but this still needs a lot of work.  Most of the circuits are built, but very few things are connected.  Also, the battery won't fit on the second platform, like I thought.  Hopefully, Chris will be able to help me this weekend.

March 13, 1999
I arrived at Chris's apartment at a little after noon, and didn't leave until nearly 2:30... in the morning.  Chris said he really enjoyed helping me with the robot, but he definitely went above and beyond the call of duty here!

Chris started by installing a 4 amp fuse to protect against short circuits, then he mounted all the boards (including the sonars), removed the front caster wheel, and replaced the PVC platform spacers with metal rods so the middle platform could be raised to make room for the battery.  My base was supposed to come with a light sensor, but we couldn't find it anywhere, so Chris gave me one of his and he mounted it to the power supply with a small resistor.

My wife always worries about my when I'm gone, but Chris has a live webcam trained on his workbench, so I just told her to log on to his website if she wanted to see what we were up to.  About five hours after I arrived I tried to call and tell her that I was going to be late, but the phone was busy.  On a whim I walked over to the webcam, held the phone up, and pointed.  Sure enough, fifteen seconds later the phone rang!    Melanie and Autumn had been checking in on us!

March 17, 1999
Chris and I never got Albert to actually move on Saturday because we didn't have the right serial connector between the robot and my laptop.  I found one several days later, and after some rather humorous circumstances, finally got Albert to take his first 'step'!

March 21, 1999
Okay, now I'm really starting to have fun!  Albert's onboard processor boots into a language called Forth, but most of the sample code I received from Zagros is written in 'C'... unfortunately, I'm not familiar with either language, so I went to the bookstore yesterday and picked up a book on C programming.  I'm picking it up faster than I expected, and I'm happy to report that earlier today I wrote half a dozen lines of C code that read the light meter!  (I wanted to make sure it was working.)  I also checked the encoders by programming Albert to roll forward 15 encoder clicks (about 30 inches), turn right for 10 encoder clicks, then roll forward for another 20 encoder clicks.  It's fun to watch him move around!

March 23, 1999
AJ Neal at Zagros has some sample VB code on his website, but it allows him to control a robot using the parallel port only.  I want to use a VB program to send and receive data over the serial port and I have been more than a little worried that it won't work.  Tonight I wrote a small piece of Visual Basic code to simply send a "T" to the serial port, and I added a couple lines of C code to the HC11 to look for the "T".  It worked!  Tomorrow I'll see if I can communicate back to the laptop.  Maybe I'll have Albert read the light meter out loud.

March 25, 1999
Tonight, I successfully managed to get my VB program to communicate with the HC11 processor onboard the robot, and it spoke back!  Albert will now announce what the light meter reading says.  Didn't even take much work.  So far, everything I've tried to do has been fairly easy.  That's probably a bad sign.    <g>

March 28, 1999
I spent last night (and much of this morning) with Chris Hostetler.  Once again he was a huge help!  I arrived at about 4:00 this time, and didn't leave until about the same time the following morning.  But during that time, we (Chris): hooked up all five sonar sensors, connected the compass to the robot's power supply, installed two bump sensors, tightened the wheels, added an LED near the HC11 power switch, put in spring "shocks" on the front caster wheel -- to make sure the drive wheels stay in contact with the floor when Albert goes over a bump or something -- checked the current draw of the motors running normally, and under load.  (Less than 1 amp normal, about 1.3 amps under partial load.)  Chris was great, and we had some really fun discussions about home robots.

    

Project Log Archive (12/98 - 3/99)

April 6, 1999
I spent a lot of time working on Albert's "skin" this weekend.   I started with an old Tupperware-style storage container.  It was too long so I had to cut it in half, slide the front half into the back half and bolt them together.   I attached a hole cutting blade to my drill and cut nice round holes for the sonar sensors.  I glued blue rings over these holes in the front (partly for protection, but mostly so they would look more like eyes.)  I also glued two washers between the eyes to cover the holes I cut for the light sensor and microphone. 

I also cut a fairly wide rectangular hole for the lower sonar sensor because I originally planned to have the cover turn left and right following accidental collisions and I didn't want any part of it to cover up the sonar.  I used velcro to mount the bump sensors and attached wires to the lever arms for wider coverage left and right.  The wires stick out of this hole, so I guess it wasn't a total waste.  (I'm a little bit worried about the wires getting caught on things, or poking people.  But I guess I can deal with that problem later.)

I'd like to figure out a way to paint Albert, but I haven't found a paint that will stick to the Tupperware plastic.

April 27, 1999
I haven't had a lot of time to work on Albert recently... the game I had been working on for the last two years got cancelled a couple of weeks ago, so I'm scrambling to get a new project started.  Once it's in production I'll be able to devote more time to Albert.  Meanwhile, I'll write the occasional article for the website, and I'll take a weekend here and an evening there to work on him...  

May 10, 1999
Several months ago, on a whim, I entered my "The Home Robot Project" website in an Earthlink homepage contest.  A couple of days ago I got an e-mail from a representative from the contest committee:  My website won the "beginner" division of the contest!

May 30, 1999
I took some time over the Memorial day weekend to work on Albert.  Friday night I stopped by a local hobby store and bought some gray primer, and several sheets of a self-adhesive plastic material that I cut into decals.  I was up until 4:00 am on Friday and spent about half the day on Saturday giving Albert a new look.  There are pictures in the Gallery.

June 9, 1999
I've spent a fair amount of time over the last few days working on Albert's HC11 program. Earlier tonight I think I finally got it all working! There are still some things I'd like to implement, but what I've got should work for now. I'm not sure how much more I'm going to be able to add, though. The program was crashing whenever I wrote past 0x2000 for some reason -- not sure if that's a memory limit or not. I'll have to check with New Micros (the makers of my HC11 board).  Anyway, I've implemented the following commands:

 
!SP: reads the light meter ("P" for photoresistor)
!SC: reads the compass
!S1: reads sonar sensor #1
!S2: reads sonar sensor #2
!S3: reads sonar sensor #3
!S4: reads sonar sensor #4
!S5: reads sonar sensor #5
!SL: reads left touch sensor
!SR: reads right touch sensor
!S<: gives me left encoder count
!S>: gives me right encoder count

 
!MLFXX: command to make left motor go forward at XX% power
!MLBXX: command to make left motor go backward at XX% power
!MRFXX: command to make right motor go forward at XX% power
!MRBXX: command to make right motor go backward at XX% power

!MXX10: command to make all motors stop
 
Tomorrow I'll start working on the VB side. I've already done a simple test and I don't think it's going to be TOO difficult. If all goes well, I might even be able to get Albert to explore a little bit tomorrow night!

June 11, 1999 (Milestone!)
Earlier tonight I wrote a complete VB program that accesses every feature of my HC11 program!  The control window has a button and a text box for my ten sensors (I have 11, but I combined the touch sensors into one variable instead of two).  When I click on a button, a reading immediately appears in the text box.  I'm happy to report that it worked on the first try!  I also have some miscellaneous buttons that let me test out different behavior routines.   "Explore", makes Albert explore using his front sonars.   "Direction" makes Albert announce his current facing.  "Turn to Light" makes him rotate 360 degrees, look for the brightest direction, then rotate to that direction and stop.   

 
In addition, I wrote some functions to make the VB code easier to work with.  To make Albert talk I used to type: 'DirectSS1.TextData CHARSET_TEXT, 1, "Hello world!"'  I replaced this long command with a function called Say().  So now I can just type: 'Say("Hello world!")'  I also wrote functions for the sonar sensors so I can write commands like: 'If Sonar(1) <7000 then [Command]'   There's even a Compass() function that I use inside a Direction() function.  This allows me to write simple commands like:  'Say ("I am currrently looking " & Direction())' which will make Albert announce the direction he is facing.
 
Finally, I wrote a short subroutine that allows me to pass simple parameters and control the speed and direction of both motors.  The command: 'LeftMotor (75)' would send 75% power to the left motor, in a forward direction.  The command 'RightMotor (-50)' would make the right wheel turn backward at 50% power.
 
I'll add more details, and even post my source code in a few days.

June 26, 1999
Albert is down for awhile.  His right front sonar has been giving me very inconsistent results, so Friday night I traced the wires and looked for problems (didn't find any), but now that sonar doesn't work at all!  It will "click" when I ping it, but it always gives me a range of around a foot whether there is actually anything there or not.  The solder joints are kind of sloppy on that connection, so I may have to get a soldering iron and try to fix it myself.  <gulp>  (I've never used a soldering iron before.)

I need to put Albert's encoder code in an interrupt so I don't miss any "counts", but I hit a memory limit on my 68HC11.  The Zagros website says the processor has 32K but I was running out of space after 8K, so I called them to ask what to do.  AJ Neal said there was a mistake and he is going to send me a chip that will bring my processor up to 32K.  In the meantime, I can't do too much on that side of Albert's programming.

July 2, 1999
Well, the joints are a mess, the insulation is melted halfway down the wires, I burned myself three times... but I'm happy to report that I got Albert's front sonar sensor working again! 

July 10, 1999
I've been reading about subsumption and other behavioral control methods, and I think I'm getting closer to a simple (yet flexible) system that I can implement. I'm imagining a priority-based behavior list of reactions, tasks, and activities.  The main program loop would check for emergencies and other sensor-driven catalysts (bumper hits, a sudden change in light, a loud noise, a mood change), and then "push" the appropriate behavior into the list, along with the priority of that behavior.   I'll sort the list by priority, send control to the highest ranking behavior, then loop back and do it all again.  (To make this work, the behaviors will have to be simple finite state machines.)

In the next few weeks I'll write a report that provides a bit more detail.

August 8, 1999
It's been almost a month since my last update -- I've been very busy at work, and there was a vacation and a camping trip in there, too.  In my spare time I've been thinking a lot about Albert's behavior controller, and I think I'm about ready to start working on this code. 

I also need to get the memory chip installed for the HC11 (recently found out that my board only had 8K and it was supposed to have 32K), and then I have to figure out why my encoders aren't providing accurate measurements.

August 18, 1999
It was a chore, but I finally managed to get the new RAM chip for my 68HC11 installed.  I had to remove the old chip, install the new one, and make jumper changes in 3 places.  Doesn't sound too difficult, but I didn't want to take Albert apart so I was forced to use tweezers and long nosed pliars just to reach some of the parts.  It was sort of like building a ship in a bottle, but I managed to do it and everything is working just fine!

August 20, 2000
The RAM chip is working, but my RTI (real-time interrupt) routine is not. I've talked to the folks at New Micros, the makers of my HC11 board, and I posted to comp.robotics.misc with some questions, but I'm still stumped.  Hopefully, I'll get it working this weekend. I'm anxious to start work on Albert's controller code.

Meanwhile, I've made a number of small changes to the website.  I added a hit/stats counter and a GuestBook, updated a couple of reports with some new information, and tweaked the way I'm using this Log page.  (I'm going to limit my "What's New" entries on the front page to one or two lines MAX, and put the details here.)   I've also figured out the Bookmark command, so my links will now take visitors directly to the latest update.

August 22, 1999
Sometimes the smallest of journeys require the largest of steps.

About a month ago I was working on a subroutine to make Albert rotate (clockwise or counterclockwise) by X degrees.  After some experimentation, I was surprised to find that the encoder ticks per degree was .21 for clockwise rotations, and .18 for counterclockwise movement. These results indicated a problem with my encoders, though I wasn't sure if it was a hardware or software issue.

When I initially implemented my odometry routines I put the code to read the encoders in my main program loop. Although this appeared to be working okay, I knew there was a chance that I was missing encoder clicks while the processor was waiting or looping, such as when I am receiving serial commands or waiting for sonar echo returns.

My first attempt at writing an RTI (real time interrupt) was painfully unsuccessful. I spent hours researching, writing code, revising the code, and trying it again -- but nothing worked.  Finally, in desperation, I decided to check if my program was too big.  My board was supposed to have 32K and I figured I was only using around 8K, so I didn't think THAT was the problem, but as a test I took out my interrupt code and added some dummy lines as "padding". It crashed. I was, indeed, out of memory.

I contacted AJ Neal at Zagros Robotics and explained the problem. He apologized for the mix up and eventually sent me a 32K RAM chip... but no instructions. So I contacted the folks at New Micros, Inc. (the maker of my HC11 board) and a guy named "Chris" was able to help me out.

After getting the chip installed I was dismayed to find that the interrupt routine STILL wasn't working. I contacted the SRS and sent a post to comp.robotics.misc.  Though I received some great replies (especially a lengthy one from Bob Dain) the suggestions I received proved ineffective.

Finally, I noticed that the New Micros sample code I had been studying used a library called "progee11.c" that I wasn't loading. Adding it fixed my problem, and earlier tonight I got my encoders working again. This time, running under an interrupt!

August 24, 1999
Last night, Chris Hostetler and I paid a visit to Bill Bailey to see his new AIBO (Sony's robot dog). Chris knew Bill through work, but had never met him, and we both figured that he was just a guy who likes high-tech toys. But as it turns out, Bill is an amazing robot builder! His robots won the North American Mirosot competitions (robot soccer) in 1996 and 1997, and his tennis ball collecting robot won a prestigious AI event around the same time. Alan Alda hosts a Scientific American "Frontiers" episode called "Robots Alive" that covered that event, and you can see Bill in several of the shots.  Anyway, Chris and I stayed at Bill's house for several hours and talked about robots.  It was a great time!

And we were both extremely impressed with Sony's robot dog, AIBO. I've done a lot of reading about this little guy, so I knew what to expect; but several things really surprised me:  1) His tail was very well articulated. It could wag back and forth, droop, and would stand up straight (curved even) whenever AIBO spotted his pink ball.   2) The dog did an amazing job of following the ball with his head/eyes. It was fast and precise, and could follow it up, down, and left and right... smoothly! 

It was really hard to look at this thing and realize that it was just a machine. The movement was so lifelike and endearing I found myself reacting as though it was truly alive. Computers are getting faster and electronic components are getting smaller and less expensive -- if they can build something like AIBO now I can't wait to see what the future brings.

August 26, 1999
If this past nine months has taught me anything, it's that robotics is an imprecise science. You can't really count on ANYTHING. Still, after I fixed the problem with my encoders, the erratic results from my sonar sensors started to bother me. So I took some time last night and this evening to fix the problem. (I'm anxious to get started on Albert's behavior programming, but I want to make sure everything is working properly before I get started.)

When I first tested my five sonar sensors I was surprised to find that they lacked fine resolution. Objects in their path had to move six inches or more before I could detect any difference in the sonar readings. That didn't seem right so after a little investigation and research I tracked down the problem. The sample code I received from Zagros relied on software to record the time of the pulse, and the time of the echo return. This is too slow! The pulse was travelling six inches or so in the time it took me to check the timer!

There is a great Handy Board FAQ that has some information about programming a 6500 series Polaroid sonar on an HC11. I tweaked this code a bit and I'm happy to report that my sonars can now sense movements of less than an inch!  The difference is that I'm using the HC11's timer subsystem (2,000,000 counts per second) to capture the time of the echo return. This is MUCH more accurate than the software solution I had before.

 


Copyright 1999-2000, John Cutter.
For feedback, problems, questions, or to share your own stories or ideas, please contact john@home-robot.com.
Last updated: October 25, 1999.