For the past three years or so I have been working on constructing the robot described in the 1979 book “How to Build Your Own Working Robot Pet” by Frank DaCosta. While it could use some more work, I feel I have reached the point where I can call it completed, and so I thought I would post it here.
The robot consists of a tricycle like chassis with a steerable powered wheel in the front, and two free spinning wheels in the back. On the head there are three sonar sensors facing right, left and to the front, and on the neck, there is a microphone for voice control. There is also a speaker for emitting electronic “barks.” I have tried to stay as true to the original design as possible, so the electronic mostly consists of 74LS series parts, some linear ICs, and a bunch of desecrate components.
Steering System: The steering system consists of a servo system, motor drivers, and some glue logic. The servo system is made with an ADC and a feedback potentiometer which is coupled to the steering column. The ADC is constructed by clocking a 4-bit counter who’s count is fed to both a latch and a resistor ladder. The resistor ladder, with the aid of an op-amp, produces a 16 step voltage ramp as the counter increments from 0 to 16. This voltage ramp is fed into one input of a voltage comparator, while the other input is connected to the feedback potentiometer. Exactly when the voltage ramp passes the voltage level of the potentiometer, the comparator triggers, clocking the latch, which saves the current count of the 4-bit counter. This produces a 4 bit representation of the position of the potentiometer, and thus, the steering column. The 4-bit counter resets after reaching 16, so the ADC runs continuously. The output of this ADC is fed into one input of a 4-bit magnitude comparator, while the other 4-bit input is connected to one of the processor’s I/O ports. The comparator is wired to the motor driver, such that when the value from the ADC is greater than the value from the processor, the steering motor turns left, and when it is less than that value, it turns right. Finally, when the value from the ADC equals the value from the processor, the steering motor is stopped and is electrically braked. This system allows for the processor to control the position of the steering column with a 4 bit word.
Sonar: The sonar system is can be split up into two main circuits, the transmitter, and the receiver. The transmitter consists of a pulse generator, ultrasonic transducers, and their driving circuitry. The pulse generator is constructed to produce a 430 microsecond burst of a 37.5 kHz square wave, every 27 milliseconds. The output of this pulse generator is fed into the input of a demultiplexer who's outputs are connected to the front, right, and left facing Tx transducers. The processor is connected to the demultiplexer, so that it can select which transducer to transmit from. The receiver circuit consists of a two stage amplifier and a frequency detector for each Rx transducer. The frequency detectors are used to ascertain whether or not an amplified signal from a transducer is, in fact, 37.5 kHz, frequency of the signal that is outputted by the transmission circuitry. The output of all the frequency detectors are gated together so that if any of them indicate that a echo has been received, an input line to the processor will go high. In operation, the processor will have the sonar system transmit from the transducer selected by the demultiplexer, and will also start a timer. The processor will then poll the input pin connected to the frequency detectors, and if a echo is detected, it will halt the timer. The processor will then use the timer’s value calculate the distance from the transducer to the object which reflected the transmission pulse.
Voice Control: The voice control system allows the operator to communicate with the robot by singing a sequence of tones of varying frequencies. To initiate communication, the operator first sings a reference pitch, and then sings 4 data pitches. If a data pitch has a higher frequency than the initial reference pitch, it is considered to be a 1, otherwise, a 0. After they have been decoded, the four data pitches are assembled to create a 4-bit control word which the processors acts on to perform different actions. The voice control system consists of two main circuits: an amplifier, and a frequency counter. The amplifier is just a microphone coupled to a simple op-amp setup with some filtering. The frequency counter circuit starts with a comparator which converts the output from the amplifier to a square wave. The square wave is then used to clock an 8-bit counter whose output is fed into a latch. A 555 clocks the latch, and clears the counter every 0.2 seconds. This produces the frequency of the signal from the amplifier, divided by five, on the output of the latch. Some glue logic is used to determine if the frequency of the signal is greater than 160 Hz, and if it is, it triggers an external interrupt on the processor, indicating that there is valid communication data on the latch. The 160 Hz cutoff offers some crude filtering to prevent stray noises in the environment from putting the robot into a communication session.
Bark Generator: The bark generator is a purely aesthetic. It produces electronic “barks” with the aid of several 555 timers and a demultiplexer to select different timing capacitors for the 555s.
Control System: The control system consists of an Intel 8085 processor clocked at 1.5 MHz and two Intel 8155 peripheral chips. Each 8155 has 256 bytes of RAM, two 8-bit I/O ports, one 6-bit I/O port, and a 14-bit timer/counter.
Programmers: There are two programmers that I made for the robot. The first one is the manual programmer which was described in the book, and it is incredibly painful to operate. To use the programmer, the operator must first set up an address with pushbuttons, latch the address, setup the data, and then write the data to the memory. Since the robot’s program memory is RAM, the robot must be reprogrammed each time its power is cycled, and since the program is several hundred lines long, it is quite panful to use the manual programmer. For the original robot, the author constructed a tape interface that would allow the operator to upload and download programs to and from a cassette tape. The circuitry for the tape interface was complicated enough that I decided I would construct a more modern solution to the problem. The automatic programmer I designed, is a simple AVR microcontroller board that plugs into the programming port on the back of the robot. To use it, the operator simply presses a button, and the AVR loads the robot’s RAM with the data that is stored in its flash.
I decided to build this robot because I wanted to learn more about electronics and low level programming. Since I was pretty new to those fields, I made a bunch of pretty stupid mistakes, but I learned a whole lot in the process. You can see the build log here:
http://www.societyofrobots.com/robotforum/index.php?topic=18083.0 If there are any other pictures you would like to see, or schematics, tell me, and I will post them here.