Chapter 4: The Iris Software Environment
Iris.4 Mobile Robot Manual

by Robert T. Arrigo
The Mind Project, Illinois State University

Two overviews of the Iris Software Environment are presented below. The first version is a brief overview of the ISE, while the second, longer version is a copy of an article that appears on the Iris.4 Developer's Site; the article was written for a more technical audience, though non-techs will still find it a worthwhile read.

Short Version

Long Version

Short Version

There are three components that make up the Iris Software Environment (ISE). The first component is the Central Control Program (CCP), which you will study in detail in the next chapter. The second component is the Mind Module. The Mind Module is a computer program that processes all of the communication between Iris's other programs. The Mind Module can alter this communication, and issue orders to Iris's other programs. The third component is a set of programs called CCP-Clients (clients, for short). A client is just a program that connects to the CCP to send and receive information (instructions and data), in the form of digital messages, with other clients. Many of Iris's programs, including ProtoThinker, the Text-to-Speech Engine, and the Servo Controller Interface, are CCP-Clients.

Every client can send a message to any other client because they are all connected to the CCP, and therefore to each other:

When the CCP receives a message from a client, it checks to see if the message is addressed to the CCP itself. Besides relaying messages, the CCP performs several functions on behalf of the clients, such as disconnecting clients, shutting down the system, and checking to see if a client is online. When a message is addressed to the CCP, it will contain a request to carry out one of these functions. If the message is not addressed to the CCP, the CCP forwards the message to the Mind Module. Most of these messages are just approved by the Mind Module, returned to the CCP, and forwarded on to the original recipient. However, when the Mind Module analyzes the message, it might decide to edit or delete the message, or create new messages in response to the analyzed message.

For instance, the Mind Module may intercept a message being sent from the Speech-to-Text Engine to ProtoThinker that tells Iris to wave her left arm. If the arm were already in use (say, it's busy drawing an X on a Tic Tac Toe board), the Mind Module could block the message, then send a message to the Text-to-Speech Engine telling it to say, "Sorry, I cannot comply with your request."


Thus, Iris's clients perform specialized tasks, but must communicate and work together to get anything important accomplished. The CCP facilitates client communication, while the Mind Module watches this communication and interferes with it when necessary. These programs and their roles and responsibilities create an environment in which Iris's software modules run; this is known as the Iris Software Environment.

Long Version: From the Iris.4 Developer's Site

The Iris Software Environment: An Introduction

The Iris robot is composed of three parts: the body, various pieces of electronic hardware, and software. The body consists of the battery, wheels, main platform, support structures, and so on. The electronic hardware consists of things like the computers (CPUs, memory, motherboards, etc.), the network switch, the servo interface unit, the camera, and other components. This hardware can give feedback to the software, as when the microphone (Iris' ear) records human speech and sends it to the Voice Recognition System for processing. More importantly though, the software controls the hardware by telling the hardware what to do. Iris' software can make decisions that affect the internal state of the robot. For instance, turning the Voice Recognition System on or restarting the Vision System. Iris' software is a set of modules, each of which performs some group of related functions. For example, Iris's arm module, a software program, is in charge of the robot's arm - only the arm module has the ability to pass orders directly to the physical arm.

Of course, the robot is greater than the sum of its parts. Iris is more than just a "block-picker-upper" or a "speech recognizer". The various pieces of software that define what Iris is and what Iris can do are all tied together and placed under the control of a single piece of software called the Mind Module. The Mind Module has the power to control the various components of the robot by means of the Central Control Program (CCP, for short). The method by which this control is acheived is as follows: all software modules that are part of Iris are CCP-clients. Whenever a CCP-client (client, for short) needs to exchange information with, give orders to, or receive orders from another client, it does so via the CCP. Information, orders, and responses can all be packed up into digital messages, which are a bit like emails. In the same way that an email has a sender, receiver, subject, and body, CCP messages have fields for specifying which client is sending the message (From: field), which client is the intended recipient (To: field), and what type of message it is (Subject: field).

A (simplified) sample message might be:
		To:  	 "Arm Module"
		From: 	 "Vision Module"
		Subject: "Pick up the block at position X"
		Body: 	 "X is located at 35, 42"

A client can send a message to any other client by giving the message to the CCP, which may then pass on the message to the intended recipient. While the message is being held for delivery by the CCP, a copy of the message is sent to the Mind Module. The Mind Module can react to a message in a variety of ways such as deleting the message (so it is never delivered to the intended recipient), sending copies of the message to other clients, modifing the message before allowing it be delivered, or issuing commands to the CCP to perform tasks such as shutting down a client or even the entire CCP. Thus the Mind Module is in control of all communications going through the CCP and has a whole set of operations it can perform at any time in response to messages. The Mind Module can even create its own messages to send to clients!

One of the benefits of using this system is that the Mind Module only needs to get involved if and when it wants to. The first version of the Mind Module software simply lets all messages pass through the system untouched and provides a useful command-line interface that a human can enter commands into (such as 'Check if module X is Online', or 'Kill Module Y'). In this version, the human user has the oppurtunity to play the part of the Mind Module. More advanced Mind Modules can eliminate human interaction all together. Such versions may possess knowledge about the state of the robot and use this to determine how to process messages. For instance, if Iris is engaged in a game of Tic-Tac-Toe with a human opponent and somebody tells the robot to start "playing with her toys," the robot should at a minimum ignore the request, and ideally, ask the human opponent whether or not he or she wanted to continue playing Tic-Tac-Toe or whether the game should be canceled and Iris should instead begin playing with her toys. The Mind Module can manage this conflict by recognizing the command, "play with toys," as it is passed in message form from the module in charge of recognizing commands to the module in charge of starting the "play with toys" software. The Mind Module can intercept the command before it ever triggers the "play with toys" software, detemine that carrying out the command would prevent the robot from finishing its game of Tic-Tac-Toe, and instead, send a message to the Text-To-Speech system asking the human user what he or she would really like to do. Thus, simply managing the communications between clients allows the Mind Module to control clients.

From a client-side perspective, the CCP allows for software programs written in different computer programming languages for different operating systems, running on different platforms, to communicate seamlessly via the CCP as an intermediary. And just as the Mind Module has various commands at its disposal, clients connected to the CCP can also give orders and make queries. An example of this might be when the ProtoThinker module (ProtoThinker, or PT, is a program that can engage in conversation in plain English) needs to know if the Text-To-Speech module (TTS verbalizes text by converting English words into sounds that are played through speakers) is online so it can pass over an answer to a question the user just asked. Suppose a human user asks Iris, "How are you today?" PT is capable of formulating a response such as, "Fine, thank you." PT needs a way to get this response to the user, and because Iris is equiped with a Text-To-Speech engine, PT will send the reply to the TTS module. First, the PT client queries the CCP, "Is the TTS module online?" to which the CCP may reply, "Yes." The PT client then packs the English sentence into a message and sends that message to the TTS client via the CCP. As usual, the CCP is the intermediary and makes sure the Mind Module will let the message pass. Assuming the Mind Module okays the message, the message is passed to the TTS client. The TTS client unpacks the message, gets the sentence, and speaks it. Two other commands clients can issue are to tell the CCP they are signing off, or order the CCP to terminate other clients. Thus, clients may perform any of a limited set of operations, as well as simply exchange messages.

As the Iris mobile robot project continues to grow, so to will the needs of the clients and the capablilities of the Mind Module. The CCP can easily be expanded to service a larger number of commands for both the Mind Module and various clients, and the very modular nature of the software environment presents unlimited oppurtunity for advances. This software framework for Iris was designed with an eye to the future, and we are all very excited to see what the future holds for Iris.