Project Update: Aia – 14/12/2008

Some weeks ago I announced that I was working on the development of a robot called the Artificial Intelligent Agent (Aia). Since then progress has been made. We didn’t make as much progress as I hoped for, but progress has certainly be made. For me, as a software developer, the project is nearing its end. With that in mind I thought it might be a nice idea to give a little preview of the project’s software.

The software of the Aia is split in two parts: Aia and Aia|CP. Aia is the program that is running on the robot itself. It’s main responsibility concerns the hardware. Aia|CP is the application that is running on the PC. Aia|CP analyses webcam images from the Aia, calculates pathfinding and provides a communication layer between the robot and the computer. Aia|CP can be considered as the server (or Mother Brain, as I call it) and Aia as the client.

When you start Aia|CP you’re greeted by a simple splash screen:

aia_cp_splash

Nothing complicated to see here

The splash screen of Aia|CP is not much more than eye-candy, so lets move on.

The Colour Analyser is a bit more interesting. Unfortunately Aia|CP isn’t able to retrieve images from the webcam on Linux at the moment. I’m working on a cross-platform library that will solve that problem. But you’ll hear more about that when that library will be released.
As for the Colour Analyser itself. Of every webcam image the Colour Analyser retrieves it makes a analysis. In this analysis the image is split into the colours red, green and blue. Of each colour the Colour Analyser makes a histogram which is then used to make some calculations (the maths are quite easy). Besides that the Colour Analyser also generates a 3d colour cube. But the most important feature is the ability for the end-user to manipulate the parameters of the Colour Analyser. These parameters are used internally to determine whether a colour has been detected or not.

aia_cp_colourframe

There’s no doubt… The computer recognises black

Moving on to something I finished today: the AI Control. The AI Control is the main interface point between end-user and computer when it comes to the Artificial Intelligence. With the AI Control the end-user can select start and target positions, manipulate the virtual pathfinding map and set the state of the Aia.

aia_cp_aiframe

Possible output

And last, but not least: the Lua Terminal. The Lua Terminal provides a simple interface with the Lua scripting language. It can be used to access low-level features of components of Aia|CP. Thanks to this it’s possible to send commands to the Aia directly. An example of this can be seen in screenshot. Similar functions are available for the Colour Analyser and the AI Control. Speaking of which, these functions are available in two flavours: a OOP-approach and an imperative approach. Both of the following commands give the same result:

> caSetTarget(0, 0, 0)
> ColourAnalyser:setTarget(0, 0, 0)

Also worth noting, the Lua Terminal outputs exactly what Lua outputs. So if you encounter an error you’ll see that in the terminal.

aia_cp_luaframe

A simple terminal for the Lua scripting language

Well, that’s all for now. If everything goes according to schedule the project will soon (in a few weeks) be released under the GNU General Public License (GPL)

– Michael

One Response to “Project Update: Aia – 14/12/2008”

  1. [...] package contains the source for both the program on the Arduino and Aia|CP. Besides that you can also find some documentation in the package. This documentation is currently [...]

Leave a Reply