Author Topic: Code for Apollo 11 AGC  (Read 8850 times)

0 Members and 1 Guest are viewing this topic.

Offline madiresTopic starter

  • Super Contributor
  • ***
  • Posts: 7695
  • Country: de
  • A qualified hobbyist ;)
Code for Apollo 11 AGC
« on: July 11, 2016, 11:54:56 am »
In case you got an Apollo 11 AGC and need the source code, please check https://github.com/chrislgarry/Apollo-11  ;D
 
The following users thanked this post: MK14, SimonR

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #1 on: July 11, 2016, 12:04:57 pm »
Here's mine. I MUST upgrade the firmware. I might use it to go to Mars, later this week.
EDIT:
For clarity. I was joking. The picture is a REPLICA one, which I DON'T currently have. (It is an INTERNET picture).

« Last Edit: July 11, 2016, 03:54:36 pm by MK14 »
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #2 on: July 11, 2016, 01:20:16 pm »
This has more information about it, including descriptions/details of the instruction set used in it. Which you need to better understanding the listings.

https://en.wikipedia.org/wiki/Apollo_Guidance_Computer
 

Online Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1663
  • Country: us
Re: Code for Apollo 11 AGC
« Reply #3 on: July 11, 2016, 03:38:10 pm »
Here's mine. I MUST upgrade the firmware. I might use it to go to Mars, later this week.

Is that an original DSKY or a replica?
Complexity is the number-one enemy of high-quality code.
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #4 on: July 11, 2016, 03:52:42 pm »
Here's mine. I MUST upgrade the firmware. I might use it to go to Mars, later this week.

Is that an original DSKY or a replica?

It is a REPLICA. But I liked the picture so much, I put it in.

It is NOT mine (which I hoped was obvious), as I'm NOT really going to Mars this week (the week after, maybe ?).

But on seeing it, I now WANT ONE !.

EDIT:
Sorry if I caused any confusion. I should have been clearer that I was joking. At the time of posting (maybe a bit before, I'm NOT sure), I DID NOT KNOW it was a replica. But found out later. I was amazed their display technology was so good for 1969. But of course it is a replica.

I tried to find REAL pictures, but the REPLICA looks much NICER, so I left it in, SORRY!

The REAL one (I believe) . . .

« Last Edit: July 11, 2016, 04:00:43 pm by MK14 »
 

Online Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1663
  • Country: us
Re: Code for Apollo 11 AGC
« Reply #5 on: July 11, 2016, 04:00:51 pm »
Anyone know where one can buy a replica DSKY? I'd love to have one as a novelty display in my office.
Complexity is the number-one enemy of high-quality code.
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #6 on: July 11, 2016, 04:07:19 pm »
Anyone know where one can buy a replica DSKY? I'd love to have one as a novelty display in my office.

EDIT:
Actually it seems to be a PAPER MODEL!!!!!!

I'm NOT sure if you can get "electronic" light up ones ?
Or maybe you have to make them yourself ?

***********************************************************

They seem to be on ebay for around $49.99

There may be other/better sellers and sources (e.g. Amazon). This is just ONE example I quickly found...

http://www.ebay.co.uk/itm/DSKY-DISPLAY-KEYBOARD-APOLLO-GUIDANCE-COMPUTER-AGC-MODEL-CRAFT-KIT-of-LM-5s-/230953345011?hash=item35c5e45ff3:g:P9AAAMXQlUNRUWeY

« Last Edit: July 11, 2016, 04:13:58 pm by MK14 »
 

Offline Len

  • Frequent Contributor
  • **
  • Posts: 547
  • Country: ca
Re: Code for Apollo 11 AGC
« Reply #7 on: July 11, 2016, 04:10:51 pm »
In case you got an Apollo 11 AGC and need the source code, please check https://github.com/chrislgarry/Apollo-11  ;D

Be sure to check out the bug list first.

https://github.com/chrislgarry/Apollo-11/issues/3
DIY Eurorack Synth: https://lenp.net/synth/
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #8 on: July 11, 2016, 04:10:58 pm »
The one I just showed, seems to be a FIXED, non-working replica.

Maybe there are proper light up, "working" ones you can get ?
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #9 on: July 11, 2016, 04:18:32 pm »
Anyone know where one can buy a replica DSKY? I'd love to have one as a novelty display in my office.

I'm NOT sure if you can buy "Functional"/Light-up ones ?

Here are some details on how to make them.

http://hackaday.com/2015/02/03/reproducing-a-dsky/
 

Offline SimonR

  • Regular Contributor
  • *
  • Posts: 122
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #10 on: July 11, 2016, 07:35:27 pm »
In case you got an Apollo 11 AGC and need the source code, please check https://github.com/chrislgarry/Apollo-11  ;D

A very interesing find, Now all I need to do is nip down to Tandy and order an AGC to run it on.

I considerd getting one of the paper DSKYs but the shipping to the UK was more that the cost of the item at the time.
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #11 on: July 11, 2016, 07:40:38 pm »
In case you got an Apollo 11 AGC and need the source code, please check https://github.com/chrislgarry/Apollo-11  ;D

A very interesing find, Now all I need to do is nip down to Tandy and order an AGC to run it on.

I considerd getting one of the paper DSKYs but the shipping to the UK was more that the cost of the item at the time.

You probably CAN buy them in Tandy's.

Since as you enter the Tandy shop (in the UK), you must already be dreaming (or something, as I think they closed a very long time ago), so it may well sell them. (In the fantasy world).

I bet if someone made a REPLICA available, with the working/flashing Led displays and lights, they would sell like hot cakes.
 

Offline SimonR

  • Regular Contributor
  • *
  • Posts: 122
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #12 on: July 11, 2016, 08:05:03 pm »
I'd buy one. I always fancied a DSKY as an office clock
 

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8240
Re: Code for Apollo 11 AGC
« Reply #13 on: July 13, 2016, 11:37:16 am »
...and if you feel like building the actual CPU hardware, there's schematics here:
http://klabs.org/history/ech/agc_schematics/
 
The following users thanked this post: MK14

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #14 on: July 13, 2016, 11:55:56 am »
...and if you feel like building the actual CPU hardware, there's schematics here:
http://klabs.org/history/ech/agc_schematics/

Thanks for that link, it looks VERY interesting. The schematics are nice and very clean, they have been well preserved. (Presumably stored on microfilm, maybe).

A quick glance, seems to show it is built exclusively out of Nor gates, which themselves are made out of three transistors, in a resistor transistor logic configuration (i.e. probably RTL). I think they are then made out of early, simple integrated circuits.

It is a bit like the Cray1 supercomputer, which was also made out of simple, single function logic gates (mostly), ECL.

The memory (probably core for the Apollo 11), and other stuff are done differently.
« Last Edit: July 13, 2016, 11:58:03 am by MK14 »
 

Online Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1663
  • Country: us
Re: Code for Apollo 11 AGC
« Reply #15 on: July 13, 2016, 04:01:02 pm »
A quick glance, seems to show it is built exclusively out of Nor gates, which themselves are made out of three transistors, in a resistor transistor logic configuration (i.e. probably RTL). I think they are then made out of early, simple integrated circuits.

Yep, the entire computer is built from thousands of three input NOR gates. The chips themselves were built by Fairchild and each one had two gates. Yes, they were RTL logic. The Apollo AGC was one of the first to use integrated circuits rather than discrete transistors. The word length was 16 bits, with one bit acting as an overflow bit and one as a sign bit. Numbers were represented in ones complement.

The AGC did use core. Core rope for the read-only program store and planar core for the writable memory.
Complexity is the number-one enemy of high-quality code.
 

Online nfmax

  • Super Contributor
  • ***
  • Posts: 1556
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #16 on: July 13, 2016, 04:11:20 pm »
Not only did the AGC use these ICs, the ground test equipment used the same parts. Approximately 80% of US IC production at the time went to the Apollo programme. They wanted to ensure the parts would stay in production long enough to get to the moon & back
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #17 on: July 13, 2016, 05:50:23 pm »
A quick glance, seems to show it is built exclusively out of Nor gates, which themselves are made out of three transistors, in a resistor transistor logic configuration (i.e. probably RTL). I think they are then made out of early, simple integrated circuits.

Yep, the entire computer is built from thousands of three input NOR gates. The chips themselves were built by Fairchild and each one had two gates. Yes, they were RTL logic. The Apollo AGC was one of the first to use integrated circuits rather than discrete transistors. The word length was 16 bits, with one bit acting as an overflow bit and one as a sign bit. Numbers were represented in ones complement.

The AGC did use core. Core rope for the read-only program store and planar core for the writable memory.

Not only did the AGC use these ICs, the ground test equipment used the same parts. Approximately 80% of US IC production at the time went to the Apollo programme. They wanted to ensure the parts would stay in production long enough to get to the moon & back

Replying to both of you at the same time.

(from a quick glance at it), I think they did a really good job, of designing that computer (I'm especially surprised at the drawing quality of the schematics. I'm use to hand drawn stuff in that era. Maybe they used stencils/protractors/shapes etc to do it, or some kind of crazily early CAD/EDA software). Except maybe they should have considered 8 bits, which could have drastically reduced the hardware size, in theory. But maybe 16 bits was the right choice.

Also from a quick look at the instruction set (the other day), it seems to be a very early RISC like architecture, although maybe that is a matter of opinion. Certainly it seems to have very few instructions, but they seem to have crammed all the sort of functionality that one would need, into them.

Taking the time when they did this into consideration (pre-1969, obviously), they did quite an amazing job. Even the first microprocessors had not been invented (as regards available on the open market), yet. Although some people (me included) argue that some of the pre-microprocessor cpu chips, were actually almost processors in their own right.
E.g. TTL 74181 4 bit ALU. It is almost a TTL based, 4 bit arithmetic Logic "microprocessor", in its own right. Technically it is not a processor and is missing many of the units in a single chip microprocessor. But on the other hand, it is a sort of 4 bit-sliced (partial) processor.

Ignoring the political/philosophical ramifications. This Apollo AGC, was probably an early version of the TTL based, computers, used for the Nuclear weapon deterrent systems, of that era. Some sources say that the ballistic missile program, effectively paved/paid the way for the development of TTL, and hence the start of the computer revolution.

Early (especially hand built) Germanium transistors, were rumored to be terribly unreliable (by today's standards). So these three (or 6) transistor IC's, should be especially reliable, surviving the huge G forces, and safety/reliability requirements of space.
But I can believe by then, reliable transistor production and/or Silicon transistors, could be mass produced, and were fairly reliable.
Although 1960's electronics had a tendency to be unreliable, anyway. Reliable construction techniques were in their infancy, especially for space environments.

I'm a bit surprised that core memory (with potentially weak/flimsy wires and fragile magnetizable cores and stuff) can take the huge G forces, and harsh environment, strict reliability and safety requirements for a space mission. Also the fact that you have to "write" to it, in order to "read" from it, would worry me, as well. As it makes it sound intrinsically unreliable/delicate.
I guess the "ROM" version, may have used a technique so that it is not writable. I.e. non-destructive reads. I.e. permanent magnets as cores, if that even works technically and/or is practicable to put in the individual 0's and 1 bits in by hand. I vaguely remember reading somewhere or a Youtube program, mentioning something like that. Where women would patiently assemble the cores and it would take months to make each one.

I can imagine in 10 years time, putting on a VR helmet, and then getting into a life like virtual simulation of the Apollo 11 space craft, then flying and landing on the Moon.
« Last Edit: July 13, 2016, 05:54:14 pm by MK14 »
 

Offline SimonR

  • Regular Contributor
  • *
  • Posts: 122
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #18 on: July 13, 2016, 07:53:10 pm »
As mentioned elsewhere on this forum a really good read if your interested in this is
 "The Apollo guidance computer, architecture and operation" from Frank O'Brian at Springer.

It tells you exactly how the memory was used, although not how it worked.
I suspect that magnetic core was the most reliable and robust memory available at the time, 1960/61 when the project started. Think about it, the alternative was mercury delay line or nickel delay line memory. Mercury weighed more than a Saturn 5 and external vibration in nickel wires would have destroyed the data.
 

Online Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1663
  • Country: us
Re: Code for Apollo 11 AGC
« Reply #19 on: July 13, 2016, 08:26:50 pm »
I'm especially surprised at the drawing quality of the schematics. I'm use to hand drawn stuff in that era.

I'm not. Remember that this was a government-funded project with a nearly unlimited budget. No expense was spared in anything, including the documentation. The size of the team developing the computer and writing the software was around 600 at its max size.

What does surprise me is that these schematics survived until now. A lot of the Apollo documentation was destroyed due to lack of space in government warehouses.

Quote
I'm a bit surprised that core memory (with potentially weak/flimsy wires and fragile magnetizable cores and stuff) can take the huge G forces, and harsh environment, strict reliability and safety requirements for a space mission. Also the fact that you have to "write" to it, in order to "read" from it, would worry me, as well. As it makes it sound intrinsically unreliable/delicate.

The memory, along with most of the rest of the computer, was potted in epoxy resin. There were no "huge" G forces involved -- remember that this computer was used on a manned spacecraft, and men can't withstand huge G forces. Max G was probably in the 7-9 G range.
« Last Edit: August 27, 2019, 07:47:07 pm by Sal Ammoniac »
Complexity is the number-one enemy of high-quality code.
 

Offline SimonR

  • Regular Contributor
  • *
  • Posts: 122
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #20 on: July 13, 2016, 08:33:28 pm »
I'd forgotten that they potted everything, that would make it even more resilient.
The same memory wqs used in the shuttle for half its life, I believe, right up until they refitted it with al glass instruments.

 

Offline rrinker

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Code for Apollo 11 AGC
« Reply #21 on: July 13, 2016, 08:57:41 pm »

I can imagine in 10 years time, putting on a VR helmet, and then getting into a life like virtual simulation of the Apollo 11 space craft, then flying and landing on the Moon.

 I for one, would hope it comes sooner than 10 years, just to be sure I'm still around - but I would most definitely buy something like that. Recordings of the Apollo 11 touchdown trigger memories I can't otherwise readily recall - I was 3 years old when that happened, but I most definitely was watching and there's like a deja vu moment when I hear the radio chatter.



 

Offline smgvbest

  • Supporter
  • ****
  • Posts: 630
  • Country: us
    • Kilbourne Astronomics
Re: Code for Apollo 11 AGC
« Reply #22 on: July 17, 2016, 05:34:17 am »
This is something on my TODO list.   I really want to recreate the DSKY   Been collecting information for some time on it

here's two nice ones
http://www.ibiblio.org/apollo/Pultorak.html
Here'sa FPGA implementation of the AGC
https://github.com/donnaware/AGC

My Favorite
http://nassp.sourceforge.net/wiki/Main_Page
get the orbiter simulator from here
http://orbitersimulator.com/

You can also find various youtube video's
search for DSKY AGC

Sandra
(Yes, I am a Woman :p )
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #23 on: July 17, 2016, 09:30:06 am »

I can imagine in 10 years time, putting on a VR helmet, and then getting into a life like virtual simulation of the Apollo 11 space craft, then flying and landing on the Moon.

 I for one, would hope it comes sooner than 10 years, just to be sure I'm still around - but I would most definitely buy something like that. Recordings of the Apollo 11 touchdown trigger memories I can't otherwise readily recall - I was 3 years old when that happened, but I most definitely was watching and there's like a deja vu moment when I hear the radio chatter.

VR should be coming somewhat soon (ignoring very early stuff), maybe later this year (if it's on time), or next year. But that will probably be mainly for early VR gaming and stuff.
How long it takes before we have the first Apollo 11 AGC (and similar) stuff, I'm much less certain about.

Before I stray too off-topic. I'll just say that I'm not sure how VR is going to progress, because some people would prefer to just sit down and watch movies/TV and/or games. Yet some VR thingies, involve standing up and moving about in "safe"/empty (relatively) rooms. Which I imagine would get too exhausting, after an hour or two, depending on ones fitness.

I would imagine that the Apollo 11 AGC is a fairly obvious target for future VR systems. So it makes sense that the VR people, will go for it at some point.

At this point in time, it is not obvious, how successful VR will be, either.
 

Offline newbrain

  • Super Contributor
  • ***
  • Posts: 1714
  • Country: se
Re: Code for Apollo 11 AGC
« Reply #24 on: July 17, 2016, 04:00:33 pm »
Not strictly related to the AGC, but I think still in topic:
The well known (at least in Italy) blogger and debunker Paolo Attivissimo has collected a vast amount of audio and video documentation, and created an extremely interesting and high quality documentary video on the Apollo 11 landing:

Quote
Moonscape is a free and freely shareable high-definition documentary about the first manned Moon landing. Funded and produced by space enthusiasts from all over the world, it shows the full Apollo 11 landing and moonwalk, using only the original audio, TV and film footage and the original photographs, rescanned and restored from the best available sources, with full English subtitles (other languages will follow).

You can find it here:
https://moonscapemovie.blogspot.it/

Apart for appreciating his effort and dedication, and a small contribution, I'm not affiliated with the project.
Nandemo wa shiranai wa yo, shitteru koto dake.
 
The following users thanked this post: albert22, SimonR

Offline SimonR

  • Regular Contributor
  • *
  • Posts: 122
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #25 on: July 23, 2016, 06:21:26 pm »
Not strictly AGC related but here is a complete 3D scan of the inside of the Apollo 11 CM

http://3d.si.edu/apollo11cm/boxes/play-cm-ext-rc6-int-rc5/cm-interior.html
 
The following users thanked this post: albert22, MK14

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4527
  • Country: gb
Re: Code for Apollo 11 AGC
« Reply #26 on: July 23, 2016, 10:54:32 pm »
Not strictly AGC related but here is a complete 3D scan of the inside of the Apollo 11 CM

http://3d.si.edu/apollo11cm/boxes/play-cm-ext-rc6-int-rc5/cm-interior.html

Thanks, that is fun, interesting and educational to play with.

I did not realize that the flight computer, had buttons, labeled, 'Noun' and 'Verb'. They are to initiate and something, 2 digit commands. I guess since it was a very early computer, even knowing how to label up the keyboard was new to everyone. Since embedded computers were fairly rare, then, I would think.
 

Online Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1663
  • Country: us
Re: Code for Apollo 11 AGC
« Reply #27 on: July 24, 2016, 12:39:18 am »
I liked the hand-written message by Michael Collins in the lower equipment bay.
Complexity is the number-one enemy of high-quality code.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf