Friday, 4 April 2014

Apollo 11 code goes ‘open source’


It’s been famously remarked that the on-board systems in Apollo 11 had less computing power than a modern pocket calculator. Now we can see that the code which ran those systems was probably less complicated than the code behind the Windows Calculator.

As part of its celebration of the 40th anniversary of Apollo 11 and man’s first steps on the moon the space heads at Google have published the original code from the Apollo Guidance Computer or AGC.

The code was transcribed from scanned images of printouts for the AGC in both the Command Module (codenamed Comanche054) which reached moon orbit and was the return vehicle; and the Lunar Module (Luminary099) which took astronauts Neil Armstrong and Buzz Aldrin to the moon.

While the code itself is primarily of interest to programmers there are some amusing snippets which show that the geek sense of humour never changes.

Line 666 in the Lunar Module’s code has a comment identifying it as “NUMERO MYSTERIOSO” or the number of mystery while Lines 179 and 180 have both been commented by the programmer as “TEMPORARY I HOPE HOPE HOPE”.

If you want to load up the code and try it for yourself Google also provides links to an open-source AGC emulator.

Only impressive 1474 lines of code, including comments.. it’s amazing to say the least. At my work we have classes bigger then that - don’t start.. I am not proud of it…

Source can be found here.

No comments:

Post a Comment