Page 27 - Designing Autonomous Mobile Robots : Inside the Mindo f an Intellegent Machine
P. 27
Chapter 1
A proper architecture will have an inherent elegance, just as an efficient airplane is usually
aesthetically pleasing to look at. When this elegance is not evident, it is probably not an
optimal architecture.
Defining an open architecture
Having spent only a short while with our state-driven model, it quickly became
evident that we were going to need to continue to add to the architecture as we
tested it against real or hypothetical challenges. It is therefore obvious that our
architecture needs to be flexible and modular in nature.
The first rule of creating such an architecture should, therefore, be to think in general terms
rather than specific terms. We should think of each element of the structure as a specific case
of a generic element, and consider how the element can be made as flexible as possible.
For example, if we are considering elements that control the speed and the rate of
turning of the robot in response to sonar data, we should also consider how our
system might be expanded to use another and as yet undetermined sensor. We need
to consider how this similar module might be used at the same time or in lieu of the
sonar sensor interface without disrupting other elements of the control architecture.
And we should push the thought further to consider an interface that doesn’t report
range, such as a bumper contact. How is such an event going to get processed into
our robot’s behavior?
Both the real sonar module and our hypothetical sensor will need to calculate
deceleration and turning, so we would want to break out the functions that calculate
these parameters and make them called subroutines (functions).
We might also add a structure that tests all available collision avoidance data to
merge the readings into a single assessment of the situation. In the end we would
then create a sonar module that plugged into a general framework. If we take the
time to do this, even though we can’t envision needing another type of sensor, we
will be well on our way to developing a living design instead of a rigid, inflexible
monument to our lack of foresight.
In the final analysis, an architecture is like a living organism operating under the laws of
natural selection. As it is subjected to challenges, it will either grow stronger or be destroyed.
In many cases, the architecture itself will not survive, but it will give birth to an offspring
that does.
10

