Group #1
Interim Report
Submitted 3/26/01
Technical Advisor:
Professor Hong Man <hman@stevens-tech.edu>
Group Members:
Gerald Conde <gconde@stevens-tech.edu>
Manuel Valle <valle72@yahoo.com>
Ivy Chen <ychen2@stevens-tech.edu>
Edward Vishnyak <evishnya@stevens-tech.edu>
I pledge my honor that I have abided by the Stevens Honor System.
Figure 1: Robot Body
Figure 2: Rabbit 2000 core
Figure 3: Block Diagram
Table 1: Budget
Table 2: Gantt Chart
The focus of this project is developing and implementing an autonomous robot with artificial intelligence.
The construction of the Autonomous Intelligent Robot involves the design and integration of several major systems. These systems are the robot platform, sensors, microprocessor, and software development. The robot platform consists of a wooden body with various holes and slots for assembly and to hold the various components of the robot. Wheels are attached to modified servos for mobility. The microcontroller will most likely be housed in the interior of the robot. The primary sensors, ultrasonic and infrared, are located along the perimeter of the top of the robot. Bumper sensors are located at the base. These sensor systems are to detect the robot’s environment. Additional sensors used are wheel encoders and an analog compass to give information about the robot’s orientation and the distance traveled. The custom software that we are developing will provide the robot with artificial intelligence and help it perform useful tasks. This software will consist of two primary modules, a probability map and an artificial neural network.
The major objectives for this project are:
· Neural network modeled decision routines.
· Obstacle avoidance.
· Navigation within its environment.
· Learning algorithm.
These objectives demonstrate that robots can be more useful and interesting when equipped with AI. Our design can also be used as a basis for a more application specific robot such as a housekeeping robot or a warehouse stock transportation robot.
Hong Man, Ph.D., Assistant Professor – For general technical advice and guidance on the functionality of the robot.
Stanley H. Smith, Ph.D., Professor - For advice and recommendations on sensors, microprocessors, and circuits.
The overall development of the Autonomous Intelligent Robot has mostly gone as planned. Each team member is assigned to implementing specific subsystems of the robot. Generally, the group meets about once a week to discuss any major development and get an idea of each other’s progress. This also helps everyone get focused on the overall goals of the project.
Development of the artificial neural network has been steady. The Matlab environment has proven to be very flexible and robust in the design and training of neural networks. The included documentation is very thorough and easy to understand.
Matlab provides a comprehensive solution that was specifically designed for use on microcontrollers. The Neural Network Toolbox extends the Matlab computing environment to provide tools for the design, implementation, visualization, and simulation of neural networks. The Neural Network Toolbox provides comprehensive support for many proven network paradigms, as well as a graphical user interface that allows users to design and manage their networks. Much of the testing of the neural network can be done in Matlab before converting the file to C code.
Matlab
provides a full programming language that enables the user to write a series
of Matlab statements into a file and then execute them with a single command.
User writes his program in an ordinary text file, giving the file a name of filename.m.
The file extension of .m
makes this a Matlab M-file. The Matlab Compiler takes M-files as input and
generates C source code as output. The Matlab Compiler automatically converts
M-files into C source code, eliminating time-consuming and error-prone manual
translation and reducing development time for applications that run outside
the Matlab environment (requires the C/C++ Math Library component).
A problem, which came up quite unexpectedly, was the discovery of several limitations of the Matlab compiler. Under certain circumstances with some programming objects the compiler would be unable to generate stand-alone C code. This would effectively bind any C code generated to the Matlab application, which for obvious reasons would be impossible to use on the Rabbit 2000. In this case we can still develop the neural network in Matlab but we will have to write C code to simulate the network. This will take additional time but should be possible with some extra work.
Overall, Matlab and the Neural Network Toolbox have performed excellently which is better than was expected. The features included in the package have greatly simplified development and testing of neural networks. The compiler will have to be further tested to determine if it meets our needs.
The function of the neural network is to help the robot interpret sensor readings and act accordingly. Sensor readings are sent into the neural network, which then processes the readings and outputs an array of numbers. These numbers can then be interpreted as instructions to the robot to perform some action. Research into the use of neural networks has presented many variations to integrate the neural network into our design. Depending on the processing requirements, the neural network may also be used to help build the probability map. Once the sensors are functional, the training of the neural network can begin. This will be accomplished by recording sensor readings in a variety of orientations and deciding what actions we want the robot to take in these situations. We will then come up with a code to represent these actions and train the network to output these values when it is in that situation. The code will most likely be binary. All training will be performed in Matlab. The training will adjust the weights of the neural net connections, which will then be stored as a matrix in the Rabbit 2000.
It is difficult at this point to predict exactly how well the neural network will perform. So far all the research conducted earlier has proven to be accurate from the testing in Matlab. Ultimately, the performance of our programs will be based on how well the neural network runs on the Rabbit 2000, the characteristics of the sensors, and the efficiency of our code.
So far the project has experienced some minor problems with the neural net. The first major concern was the issue of performance. The processing involved in simulating neural networks requires many multiplication calculations even for a modest sized network. Although the Rabbit 2000 is a very capable microprocessor, it was very hard to determine the appropriate size of the neural network so that the robot doesn’t perform too slowly. Since all development of the neural network was taking place in Matlab on a PC, the actual downloading of the neural network program code would not take place until very late into the project at which time any major change would be difficult. This could have a major impact on the project.
After much discussion, we decided to slow development of the neural network to program a small benchmark program for the Rabbit 2000. This program would simulate the calculations involved in a typical neural network. The program was written in a way to allow the size of the network to be easily varied. This will help us get a better idea of the complexity of the network that the Rabbit 2000 can handle. The program is being debugged and should be ready for testing soon. It would also be possible to extend this program to a fully functional neural network simulation which, considering the problems with the Matlab compiler, would save some time if we had to write our own neural network simulation. No other problems are anticipated with the neural network at this time.
The Rabbit 2000 only has one A/D converter and most of our sensors are analog, so we need an analog multiplexor to interface to the sensors and to read multiple analog signals. After some circuitry research, the group has figured out that building a multiplexer would be time consuming and would add extra work to the project; therefore, the group has decided to purchase an analog multiplexer to meet our needs. Initial parts research for the multiplexer has just begun. A 16-channel CMOS analog multiplexer seems to be a good match. Further research will be conducted soon in order to find the best analog multiplexer for our project. Further circuitry might be necessary to connect some subsystems together however this should not be too difficult as this will mostly consist of some simple switches, wires, and lowering some voltages.
Figure 1: Robot Body
The robot body that is used for our project is Talrik Jr., which was purchased from NovaSoft. It was designed to house a microcontroller, as well as the number of sensors. It has two wheels, which are controlled by modified servos.
Two servos, which, were also purchased from NovaSoft, will be used to turn the wheels, in order to move the robot around in its environment. Originally, servos were designed to turn by a specified angle, based on the input signal. For our purposes we will need to ‘hack’ the servos to turn 360° in order for the robot to move continuously.
Three types of sensors will be used for our project. These are infrared, sonar, and bumper sensors. Each of these has an importance for helping a robot to recognize its surroundings. Ultrasonic, or sonar, sensors work over the range of 6’’ to 10’, with 0.1% accuracy over the entire range. It has some disadvantages; such as it spans the 15° angle, which means it is more useful to measure the distances to a wall, rather than a leg of a table or a chair. In addition, it requires the use of a multiplexer, to compensate for the limited amount of analog ports. There will be two sonar sensors located at the head of the robot. Infrared sensors work best over the distances between 10 and 80 cm, so they are useful for detecting nearby objects. We will use four IR sensors, two in the front and two in the back of the robot, in order to provide a better idea about the surrounding environment. Bumper sensors are needed in case a robot fails to detect a nearby obstacle, and actually comes in contact with in. In this case, a signal from bumper sensor will direct the robot to stop and change its course. Four bumper sensors will be located around the circumference of the robot.
![]() |
|
Figure 2: Rabbit Core |
We chose Rabbit 2000 microcontroller, as the on-board computer of the robot. This is a deviation from the original plan to use Motorola’s MRC11-based board. The Rabbit product was chosen because of several competitive features. Rabbit was designed to handle fast floating-point instructions, a feature that would be useful for processing neural network calculations. It features glueless interfacing to memory and I/O devices. With 256 K of Flash memory, 128 K of SRAM, and 18.4 MHz speed, Rabbit was decided to be the best product at its price range. Also, it has 40 parallel I/O lines (including 13 address lines, and 8 data lines), which allow us to interface a number of sensors. One of the most useful features of Rabbit microcontroller is that it comes with a software development package that allows us to program Rabbit using Dynamic C.
As our research has shown, Rabbit is not as powerful microprocessor, as were used in similar projects. However, by scaling down the functionality of our robot, we can duplicate a lot of the features that were implemented in other experiments.
The microcontroller was obtained two weeks ago, and during that time we were successfully able to test several programs that involved the use of I/O ports, and math functions. The next step would be to obtain the source code for simulating a neural network, and determine how efficiently will the Rabbit handle a large number of floating point instructions. We also made plans to test the sensors using the microcontroller in order to try to get a feel for how accurate they are.
The use of Dynamic C offers a lot of advantages to our project. The most significant one is that we do not have to program our Rabbit in Assembly language. Dynamic C is a proprietary version of C programming language that was designed for the use in embedded systems (as opposed to the use on a computer running an operating system). However, the syntax is sufficiently similar to the C language, so that we can paste code generated by Matlab Neural Networks package, with minor changes, into the Rabbit programs. Dynamic C comes with Math library, which implements useful operations, needed for NN calculations. It also has such features as costatements, which simulate concurrent parallel processes in a single program – a useful function to poll multiple sensors at the same time. Dynamic C is also flexible enough so that we can add assembly code directly to the program body.
The construction of probability map of the environment will be similar to the scheme proposed in the previous semester. This scheme was borrowed largely from a paper Efficient Learning of Variable-Resolution Cognitive Maps for Autonomous Indoor Navigation, written in 1998 by Angelo Arleo, Jose Millan and Dario Floreano. The scheme will involve dividing the environment into discrete cells, where each cell will contain a probability value based on the amount of information that is available about that cell. As the robot moves around its environment, the information obtained from its sensors will be plugged into the neural network to obtain a probability value between 0 and 1, based on how probable it is that an object exists at a given distance. The map resolution, which will involve determining the size of individual cell, is still to be determined. The decision will be based on the overall size of the environment, and on how much memory will be available to store the map matrix.
Part Name |
Part Number |
Manufacturer |
Unit Cost |
Units |
Total |
Tactile Switch |
SWPBMT100 |
Mekatronix |
$0.95 |
8 |
$7.60 |
Sharp Ranger |
GP2D12 |
Sharp |
$19.95 |
4 |
$79.80 |
Ultrasonic Sensor |
MUST00a |
Mekatronix |
$65.95 |
2 |
$131.90 |
Photoreflector |
R64-P5587 |
Hamamatsu |
$3.25 |
2 |
$6.50 |
Analog Compass |
1525 |
Images Co. |
$38.00 |
1 |
$38.00 |
R/C Servo |
MS492 |
NovaSoft |
$13.95 |
2 |
$27.90 |
2.75 in. rubber wheels |
W275T |
NovaSoft |
$2.29 |
2 |
$4.58 |
Robot Body |
TJ-Body-pop |
NovaSoft |
$19.95 |
1 |
$19.95 |
Rabbit 2000 |
101-0359 |
Z-World |
$143.65 |
1 |
$143.65 |
1525 Documentation |
1525-doc |
Images Co. |
$2.00 |
1 |
$2.00 |
Misc. circuitry, glue, screws, etc. |
- |
Various |
$50.00 |
- |
$50.00 |
Parts Total |
$510.98 |
||||
Shipping & Handling |
$38.28 |
||||
Total Materials |
$549.26 |
||||
|
|
|||||
Direct Labor |
Number |
Rate |
Total |
||
Project Leader |
1 |
$35.00/hr |
$5,040.00 |
||
Team Member |
3 |
$30.00/hr |
$12,960.00 |
||
Labor Sub-Total |
$18,000.00 |
||||
Fringe Benefit (30% of direct labor) |
$5400.00 |
||||
Overhead (65% of direct labor) |
$11,700.00 |
||||
Labor Total |
$35,100.00 |
||||
Grand Total |
$35,649.26 |
||||
The actual costs for the robot is only slightly above what was estimated last semester. There was a misprint on the price of the ultrasonic sensors on the final design reports. If we correct this misprint than the total for materials should have been estimated at $503.98 not including shipping and miscellaneous parts. The difference is then $510.98 - $503.98 = $7.00 which is insignificant considering shipping wasn’t even budgeted.
Table 2: Gantt Chart - Click for full size
The project seems to be on track for completion by the scheduled date. Many factors will affect whether or not the project is successful. The biggest problem encountered was the limitations of the Matlab compiler, which still needs to be confirmed, and the lateness of the ultrasonic sensors. This unfortunately pushed back testing of sensors past the interim dates. Other tasks were moved up to compensate for this. Hopefully this will offset any lost time. As for the Matlab compiler, further testing needs to be conducted on it to see if it will provide us with stand-alone C code. If it does not, then code will have to be written by hand to simulate the C code. This isn’t that bad as the training and testing of the network can still be done by Matlab, however it will require a little more time. All the other tasks are proceeding smoothly and no other problems are anticipated. At this point the performance of the robot will most likely be determined by how well we utilize the potential of the various parts of the robot.