Ada + Genetic Algorithms + GDB + Good Food = Fun

Last things first: During the final minutes of yesterdays open Ada-DK meeting, it was suggested that we scheduled two meetings each month, instead of the current single meeting. I think that’s a testament to how much fun people are having at these “Ada parties”. Personally I have zero objections to meeting up with these guys more than once each month, so later today I’ll shoot off an email to all the Ada-DK members suggesting a second meeting and asking the when/how/where questions.

But enough about that – lets get busy with what happened yesterday. Gathered at my offices in Farum was Kim Rostgaard Christensen, Per Dalgas Jakobsen, Søren Henssel-Rasmussen, Thomas Løcke (me) and Ulrik Hørlyk Hjort. Quite a good showing.

We started out hearing (and seeing videos) about the stuff Per is doing with his automatic/remotely controlled submarine. He’s doing some exciting (safety-related) things on a Danish oil-rig, which in itself is very interesting, but what honestly was the most fun was when he showed us some videos from a dive at around 15 meters depth. There they were, a bunch of highly paid engineers wielding equipment worth several million, when suddenly a bird of some sort “fly” past the camera, completely effortless. It was fast, smooth and elegant. So bird versus sub = win for the bird, hands down. Even at 15 meters depth. Hilarious!

Later he told us a bit about the guidance software in the sub. There’s a slew of various systems in place to make sure the expensive sub doesn’t collide with the seabed, or gets caught in other dangerous scenarios. These systems rely on various pieces of code receiving signals from a hole heap of sensors. One of these systems takes care of scanning the seabed, or more specifically how far away from it the sub is. One day, while the sub was automatically moving itself from A to B, the engineers suddenly noticed that it was climbing at a frantic pace. On closer study it turned out that the seabed was rising more or less at the same speed as the sub, though keeping its distance from the sub at about 1 meter. When the sub broke the surface, the seabed had apparently risen so far up, that the oil-rig was now officially in shallow waters. Obviously that was not possible, so Per and his colleagues started looking at data from the other sensors and from the cameras. It turned out the rising seabed was in fact just a playful seal, who’d followed its excited new playmate all the way to the surface, all the while it had completely messed with the finely tuned sensors and code of the sub.

We dubbed this the “Seal Effect” and decided that henceforth all programs should have a Seal procedure for handling of such “impossible” events.

And talking about “seals” led us to FPS Russia for some completely mad gun-fun, which in turn led us into some gaming related talks, which ended by everybody agreeing that The Humble Indie Bundle is an awesome concept. Oh, and while talking about games, Kim showed us a bunch of classics running in dosbox. Ahh, the fun of Settlers and Constructor!

We did though manage to tear ourselves away from the subject of gaming, and instead delved shortly into a tool called uppaal. Ulrik has some experience with this tool and he had suggested using it for a project we’re doing together. The tool itself…

…is an integrated tool environment for modeling, validation and verification of real-time systems modeled as networks of timed automata, extended with data types (bounded integers, arrays, etc.).

We managed to convince Ulrik to give a small presentation of the tool at the next open Ada-DK meeting and he can be sure we wont let him forget it!

We also delved into gdb, which actually was a first for me. I’d run into a nasty bug in some of my code, and I needed some assistance tracking it down. With gdb and the sharp mind of Kim, the problem was fairly quickly exposed. It originated in me doing some bad stuff in a declare block, which resulted in some objects getting lost in space. I haven’t solved the issue yet, but at least I now know what is wrong.

Søren told us a bit about some Kinect hacking he’s doing, and his plans to create an Ada binding to the C++ code. He also promised to bring his setup with him to the next meeting, so toys should be abundant come September! He also told us about a pretty interesting project he’s involved in: It includes Ada, Siemens in Switzerland and the Danish railways. If everything turned out OK, he would probably end up working with Ada for the foreseeable future. The general consensus was that he was quite a lucky bastard. 😀

Per showed us a genetic algorithm he’d done in Ada. Its purpose was to calculate the best way to construct a control system for solar-panels using only linear actuators. It was quite cool seeing the system hammer through generation after generation, ever so slowly improving itself. There’s something almost lifelike about the whole thing, and the fact that he’d written it in Ada did of course boost the excitement. Yes, we’re that geeky.

Kim and I had a rather lengthy talk about the pains of OpenLDAP, and how it would fit nicely into a joint project we’re doing. We agreed that there really should be an Ada powered LDAP server out there. OpenLDAP is a bit of a beast and ApacheDS is slow. Oh well, at least we’ve got a simple read-only LDAP client available in AWS.

The only bad thing about the evening, was that I’d forgotten to buy cookies. Yes, we were without any kind of cookie for the entire evening. It was tough, but we persevered and made it through.

I’d like to extend my thanks to all the guys, for making the August 2011 open Ada-DK meeting a fun and memorable experience!

Leave a Reply