Archive for the 'Programming' Category

Preparing a source code release

Our source code has been available to the public on github since we started a new repository last summer. However, we haven’t had a stable master worthy of releasing to the public until the RoboCup in Graz.

Now we’ve decided to do a real ’source-release’ with the code we played in the Finals which has relatively stable versions of all the major modules necessary for soccer play. In addition, we’ve added pages of documentation to the motion and vision systems, and are revamping our online documentation at our wiki. Once we finished some more documentation and get a good draft of our Team Report done, we’ll add a tag to our github account, and make an official announcement here.

Our hope is that by setting the example of sharing our code, we can convince other teams to share their code as well, and help out teams who don’t want to develop all their modules on their own. If you’re interested in providing feedback on our documentation in advance of the code release, please take a look at our GettingStarted page, and reply to this post, or email me directly (jstrom bowdoin edu).

Below is a graph from github.com of our the git commits leading up to RoboCup 2009.

NBites Dev History

NBites Dev History

SLOC counts, oh my

For those of you interested in how sprawling this project has become:

TOOL branch statistics:

man branch statistics:

That’s a lot of lines of code.

More Architecture Changes

Relativity.cc -> VerticalScan.cc and SubVision.cc , split up for the two different vision systems, the old vertican scanning style and the newer relativity, subvision technique.  Theoretically, the subvision still uses vertical scanning, but whatever.  Both files are still within the Vision class and are not their own classes.

#ifdef Switches, Sensors

Yo–I moved NotifyImage (and thus all the calls to the vision processing, brain functioning) and NotifySensors methods into Vision.cc for simplicity.  It just got annoying going into Interobject.cc all the time.

Also, because we keep switching between the two vision systems, between color table thresholding and our old vision.cfg thresholding, between using localization and not, using python and not, using the brain and not, etc–I’ve implemented a bunch of #ifdef and #ifndef preprocessors to make this toggling easier.  Basically: no more commenting out methods or large swathes of code in NotifyImage–just comment/uncomment the #define switches at the top of the file. This should make things a lot easier.

Lastly,  I’ve begun to make the sensors more useful.  Initially, it’s just the touch sensors but I’m going to give some people the job of using distance sensors and acceleration estimators to some kind of advantage.  Hopefully some dead reckoning and some extra distance estimation will work out.

openr site gone

Sad day! The home of the OPEN-R SDK is gone as is the soon departure of the Aibo.

Two Module, One Module

I’m in here late on a Saturday, cursing the OPEN-R SDK and its inter-objectivity, and trying to make life for our team a lot simple: One object. One object to rule them all. It’s a risk in one way: things could run slower, compilation time could take longer, and I might not even be able to make it work. I’ve gotten one module into the one-module framework. Now it’s time for the second.

UPDATE::Brought in the Chlaos, our motion module. Boots up, and even stands up. AiboConnect works, but not for motions yet. Promising…

UPDATEx2::Motions are wickedly choppy. Bleak.

UPDATEx3::Motions work fine if I don’t initialize sensors/image. Time to work it out. —Works when initializing Sensors, now

UPDATEx4::Seems like a Memory Management issue. Turning off some of the initializing malloc’s–big image arrays–speed things up considerably.

EchoServer

I’ve fulfilled my life-long dream to make a really smart message parser for AiboConnect’s server side. W00t!! Also, fixed the ‘timed’ head motions so that they, you know, work. Anyone know how timer functions work on Aperios?

Windows, Conquered

We’ve conquered windows. With george’s excellent post, I was able to get:
-cygwin (and subversion) installed
-open-r SDK installed
-get our code from the repository
-install the memory card reader driver
-and with editing only one file (makefile.config), get our code onto a working memory stick.

This means: check out the new makefile.config on the repository. If you want to use Win, uncomment the win part. If you want to use Mac, uncomment the make part.

The greatest thing about windows: we don’t have to script the unmounting process. It doesn’t yell at you when you take the stick out.

Windows, consider yourself 0wned.

Pointers Tutorial

Want to know what all the * and & do in all our C Code? Read this really good introduction (or refresher) to C and C++ pointers.

OPEN-R r5

Upgraded, finally, all of the machines to the OPEN_R_SDK-1.1.5-r5 pack.