Back in the last century, the US Department of Defense declared that Ada was going to be used everywhere and for everything. Books were published, schools build curriculum. Working programmers, however, filled out waivers to continue working in their languages of choice. As a result, only a little bit of safety-critical software really used Ada. However, we’ve noticed a bit of a resurgence lately. Case in point: an RC car using Ada for the brains. You can watch it tool around in the video below.
This isn’t the first time we’ve heard about Ada in the past few months. Partially, this could be because of the availability of the GNU compiler, although that’s been around since 1995, so maybe there’s another explanation. Ada’s strong typing does tend to plug holes that hackers exploit, so while we would hate to say it is hack proof, it certainly is hack resistant compared to many popular languages.
The car looks like a fun project. They started with the Lego NXT but replaced the controller. Using the HiTechnic design gives you a motion base that has Ackerman steering and a differential on the drive wheels. The original design used an IR receiver to talk to a Lego remote, but the Ada version adds a Bluetooth connection, as well.
For the replacement CPU, a $15 Discovery board puts a Cortex M4 running at 168 MHz onboard. A smattering of 3rd party modules and some parts in an Altoid tin completed the electronics portion of the car.
In case you miss all the Arduino-provided libraries, the Ada Drivers Library provides interfaces for timers, communications, and the like. Not everything the car needed was in the library, but some of the abstractions made creating and integrating the custom pieces easier.
If you have ever been interested in Ada, this is a fun project to learn from and would not be too hard to replicate. If you make things that could be unsafe — a large robot, a drone, or a control system for something that could do bad things — you ought to consider Ada as a way to cut down on the potential for mishaps.
[Maya Posch] made the case for Ada last year. You can even target the RISC-V if you like.
As someone who works with Ada I find this disgusting lol
May I ask why?
It’d be really nice if AdaCore would release some of the embedded programming parts of the IDE in the free version.
I like a lot of things about the Ada language–if only it weren’t so darned wordy.