Author Topic: Apollo moon landing  (Read 1100 times)

0 Members and 1 Guest are viewing this topic.

Offline andy3055Topic starter

  • Super Contributor
  • ***
  • Posts: 1109
  • Country: us
Apollo moon landing
« on: April 15, 2021, 06:06:04 am »
For those who are interested in the Apollo moon landing, this is a fantastic talk/presentation about the guidance computer. Rightfully, it is described as "light years ahead!"


 
The following users thanked this post: Mortymore

Offline Microdoser

  • Frequent Contributor
  • **
  • Posts: 423
  • Country: gb
Re: Apollo moon landing
« Reply #1 on: April 15, 2021, 10:34:06 am »
I read Margaret talking about that image, and she said that when the press photographers were there they wanted to do that shot so they collected all the printout they could find and piled it up It is often misreported that it is just the Apollo source code.

I will play this video while I populate a test board today. Thanks for posting.

They still use some of the code she wrote in spacecraft today, it is so robust.
 

Offline TerraHertz

  • Super Contributor
  • ***
  • Posts: 3958
  • Country: au
  • Why shouldn't we question everything?
    • It's not really a Blog
Re: Apollo moon landing
« Reply #2 on: April 15, 2021, 02:47:55 pm »
I'm relieved to hear that stack is mostly random printouts, not 'all Apollo code.'

I wonder if there is any photo of just the Apollo code prinout. I'd like to see how much it really is.
Or maybe the actual source code? Is it online anywhere?
Collecting old scopes, logic analyzers, and unfinished projects. http://everist.org
 

Offline Mortymore

  • Frequent Contributor
  • **
  • Posts: 441
  • Country: pt
Re: Apollo moon landing
« Reply #3 on: April 15, 2021, 03:03:49 pm »
Just think about the amount of ROM memory that the AGC had: 36,864 words
"The AGC has a 16-bit word length, with 15 data bits and one parity bit"

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

Now think how many lines of code could be written to fill a 36,864 words size memory, and imagine that put on paper.

In the pile of paper shown in the picture, may be all the versions of code produced and all the documentation used in the project, but certainly not only the code fitted in the AGC memory.

EDIT:  May be of interest

http://apollo.josefsipek.net/links.html

« Last Edit: April 15, 2021, 03:20:58 pm by Mortymore »
 

Offline Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1668
  • Country: us
Re: Apollo moon landing
« Reply #4 on: April 15, 2021, 04:40:56 pm »
Or maybe the actual source code? Is it online anywhere?

Yep. It's up on GitHub: https://github.com/chrislgarry/Apollo-11

The "Luminary" code is what flew on Apollo 11.
Complexity is the number-one enemy of high-quality code.
 

Offline floobydust

  • Super Contributor
  • ***
  • Posts: 6958
  • Country: ca
Re: Apollo moon landing
« Reply #5 on: April 15, 2021, 06:53:40 pm »


Tidbit about the Apollo S/W I found in an old interview with Edsger Dijkstra 13:54
He was a Dutch computer scientist legend, winner of the Turing Award, U of Texas at Austin. A true legend for his contributions to computing science.
One of his many software philosophies: "quality, correctness and elegance", rather than half-ass it with the "...you can always try to make better versions later" approach.

1969 after the first moon landing, at a NATO conference on S/W Engineering, Dijkstra ran into Joel Aron "head of IBM's Federal Systems Division responsible for the software of the moonshot".
I was duly impressed that they got so many {40,000} lines of code correct.
I asked Joel "how do you do that?"
"Do what?"
"Getting that software right."
"Right???"
He said that in one of the calculations of the orbit of the lunar module, the moon had been defined as repelling instead of attracting. They had discovered that error by accident,  five days before launch. I went white and said "Wow! Those guys have been lucky!" 'Yes', Joel Aron agreed."

https://www.cs.utexas.edu/users/EWD/video.html 300MB MPEG original
 

Offline Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1668
  • Country: us
Re: Apollo moon landing
« Reply #6 on: April 15, 2021, 07:15:25 pm »
They had discovered that error by accident,  five days before launch. I went white and said "Wow! Those guys have been lucky!" 'Yes', Joel Aron agreed."

I wonder how they fixed that? Unlike modern computers and embedded systems that store programs on easily changed media like disks and FLASH, the Apollo guidance computers stored code and read-only data on "core rope", which was a nonvolatile storage media created by threading many fine wires through ferrite cores. The work was done months in advance of a launch and could not be easily changed. I'm skeptical that anything, except perhaps parameters in writeable memory, was changed five days before launch.
Complexity is the number-one enemy of high-quality code.
 

Offline floobydust

  • Super Contributor
  • ***
  • Posts: 6958
  • Country: ca
Re: Apollo moon landing
« Reply #7 on: April 15, 2021, 09:29:21 pm »
So much testing was about the manufacturing and assembly, months ahead.
I agree it was discovered very late, but when do you pour the cement on software for a launch? They used a simulator to test the software, if it was 5 days then they were testing right to the end.

I'm not sure how difficult a firmware update would be - could you swap out a module?
They could flip a sign bit, say if the constant for the moon's gravity was the wrong polarity. Or change an add/subtract operation if that was the error.
 

Offline Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1668
  • Country: us
Re: Apollo moon landing
« Reply #8 on: April 15, 2021, 10:11:29 pm »
I'm not sure how difficult a firmware update would be - could you swap out a module?

Very difficult. As I mentioned in my previous post, the firmware was stored on core ropes and these took months to manufacture. Even if the ropes could have been swapped out on the launch pad, there's absolutely no way they could have fabricated a new rope in only five days.

This video (starting at 20:45) describes the process of manufacturing core rope: https://youtu.be/ndvmFlg1WmE
Complexity is the number-one enemy of high-quality code.
 

Offline floobydust

  • Super Contributor
  • ***
  • Posts: 6958
  • Country: ca
Re: Apollo moon landing
« Reply #9 on: April 16, 2021, 01:55:54 am »
I checked and IBM did the Saturn V Instrument Guide. Guidance for the booster rocket and the 7 minute ride up and the trans-lunar injection.
It used erasable core memory, a read is destructive so you have to do a refresh after but the software was changeable without changing hardware.
Not sure how much of an error being out by 2x moon's gravity would affect the moon injection portion.
 

Offline Sal Ammoniac

  • Super Contributor
  • ***
  • Posts: 1668
  • Country: us
Re: Apollo moon landing
« Reply #10 on: April 16, 2021, 04:09:37 pm »
Yes, IBM wrote the code for the Saturn V instrument unit (and not the Apollo guidance computers used in the command and lunar modules), but the quote in Reply #5 references the "orbit of the lunar module", which has nothing to do with any calculations made by the Saturn instrument unit.
Complexity is the number-one enemy of high-quality code.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf