📜 ⬆️ ⬇️

Margaret Hamilton: "Guys, I'll send you to the moon"

“When I first started working in this area, it was all for us like the Wild West - we were the pioneers of uncharted land. Nobody taught us anything. ” Margaret Hamilton.



This is Margaret . She writes code well. Do as Margaret.
')
And also:

Under the guidance of Margaret Hamilton, programs were written for the Apollo spacecraft onboard computer. At one of the most crucial moments of the Apollo 11 mission, it was the work of Margaret and her team that prevented a possible disruption of the landing on the moon . Three minutes before the landing, several alarm devices worked. The computer was overloaded with incoming data — an involuntary update of the counter occurred in the docking radar system, which led to a request for the computer to perform more operations than it was able to process. Thanks to the robust architecture, the computer continued its work: an asynchronous executive approach was used in the development of onboard software. High priority processes (critical for pruning) could interrupt low-priority processes.

“After disconnecting the command-and-service and lunar modules, the docking radar switch was put in the wrong position due to an error in the instructions for the astronauts, the radar sent erroneous signals to the on-board computer. The processing of false signals took 15% of the machine time. The on-board computer (more precisely, the software embedded in it) turned out to be reasonable enough to recognize that more operations are requested for execution than it should. Then he sent an alert, which meant for the astronaut the following: “I am overloaded with a large number of tasks at a time, which is stipulated, and I will continue to perform only the most important, that is, those necessary for landing ...” In fact, the computer was programmed for more than just recognizing error conditions. The software provided a complete set of recovery programs. In this particular case, the response of the software was to suspend the work of low-priority tasks and re-establish the most important ones. If the computer did not recognize this problem and did not take recovery measures, I am not sure that Apollo 11 would have made a successful landing on the moon. ” Margaret Hamilton

"Girl hammer!
But I wouldn’t want such a wife for myself, for it would have been a pity against her background, even though the programmer ... LOL »
Comments from GeekTimes


Iron


image
Lunar module

image
Navigation system diagram

image
Well, you yourself know what it is

image
Phases of moon landing

image
Interfaces Among PGNS, ATCA and the Rendezvous Radar

There is a little more interesting here:
[ TALES FROM THE LUNAR MODULE GUIDANCE COMPUTER ]

Apollo spacecraft control computer


image
The Apollo Guidance Computer (AGC) on-board control computer of the spacecraft carried out calculations and controlled movement, navigation, and controlled the command and lunar modules during flights using the Apollo program.

AGC was developed for the Apollo program in the early 1960s at the MIT instrumentation laboratory. A distinctive feature of the design of the computer was the use of chips, which was done for the first time.

Also during the flight to the moon two additional computers were used:



Firmware


The programming process itself was no less laborious than writing code. The Apollo on-board computer used a magnetic core memory system that stored data in a binary system. If the wires passed through ferrite cores in the form of a ring, it meant a unit; if they went outside, it was zero.

Thus, the programs were physically created by hand, in factories where mostly women worked. Among engineers, the memory on magnetic cores even got the nickname LOL-memory, where LOL stands for little old lady, “little old lady”.

Margaret talks about her work:


image
Core rope memory

How is the "firmware" in the literal sense of the word. We look at the 21st minute



AGC dual 3-input NOR gate


Memory

image

image
The interface of the Apollo spacecraft's onboard control computer installed in the command module. Above the interface, the FDAI indicator is visible.

image
Cheat Sheet with Codes

Source code



image


www.ibiblio.org/apollo/listings/Comanche055/REENTRY_CONTROL.agc.html

Emulator


Apollo 11


image



Description of landing Apollo 11
On July 20, Neil Armstrong and Edwin Aldrin switched to the lunar module, activated and checked all of its systems, brought the folded supports of the landing stage to the working position. Michael Collins in the on-board telescope of the command module at the 12th orbit conducted observation of landmarks on the approach to the main landing area to clarify the data in the navigation system and the start time of the controlled descent of the lunar module. After that, the Apollo 11 received a go-ahead for uncoupling the command and service and lunar modules. At the beginning of the 13th orbit, when Apollo 11 was above the far side of the moon, Columbia and Eagle undid. Armstrong, using the engines of the orientation system, made a complete rotation of the lunar module around the vertical axis; Collins visually inspected it and reported that the supports of the landing stage had opened normally. When the connection with Earth was restored, Armstrong reported to the MCC in Houston about the disconnection. Answering the question about sensations, he said: “The Eagle has wings.” Collins noted that the Eagle looks great, only flying upside down. To which Armstrong replied: "Some of us are flying upside down." Collins took “Columbia” to a distance of about 1,300 meters. At the end of the 13th orbit, over the back side of the Moon, the landing module of the lunar module was switched on for 29.8 seconds, the “Eagle” switched to a descent orbit with an apowelling 105.9 km and moving 15.7 km. He flew forward with landing pillars and portholes down so that astronauts could track landmarks on the surface. Armstrong remarked that one of the landmarks, Maskeline W Crater, they flew about 3 seconds earlier than expected. This meant that they would sit further than the calculated point. At 102 hours 33 minutes 05 seconds of flight time near the descent of the orbit of descent (approximately 400 km east of the planned landing area), the engine of the landing module of the lunar module was turned on, and the stage of deceleration began. Approximately 4 minutes after this, the Eagle was turned in a roll of 180 °, with the portholes up, Armstrong and Aldrin saw the Earth almost in front of them. Such a turn was necessary for two reasons: so that the landing radar could capture the surface and so that at the final stage of landing, when the ship turns into a vertical position, the astronauts can see the area where they are landing. Almost immediately after this, the on-board computer alarm went off, as Armstrong reported to the MCC. The lunar module at this moment was at an altitude of 10,200 m. From Houston they answered that everything looks normal. Such an emergency situation was not handled by astronauts on Earth. As Armstrong explained at the post-flight press conference, many problems were simulated during trainings, and the crew was always “charged” for the mission’s emergency interruption, but in real flight the astronauts were “charged” for landing. The alarm was triggered by the onboard computer overload, which, in addition to the navigation data, received unnecessary information from the radar of a meeting with the command and service module at that moment (the radar switch was set by Armstrong about 3 minutes before the first alarm). In total, during the landing, the alarm went off 5 times, which distracted astronauts' attention. The decisive factor in the decision of the MCC on the continuation of the landing was the word of the specialist in navigation systems of the lunar module Steve Beils (English) Russian, who considered that computer overload would not put the landing at risk (later he would receive the Presidential Medal of Freedom together with the astronauts).

Eight and a half minutes after the start of braking, at a height of just under 2 km, the stage of approaching the landing point began, the on-board computer started to execute the program, according to which the landing stage engine and the orientation system engines are automatically controlled, and the astronauts can manually only adjust orientation. The Eagle began to slowly turn into a vertical position. At an altitude of 1.5 km with a descent rate of 30.5 m / s, Armstrong turned off the automatic mode for a while to make a trial orientation adjustment, everything worked fine. Armstrong should have done this test a little earlier, so that in those moments he would be engaged exclusively in the visual search for a suitable landing site. Experts believe this delay is a consequence of computer alarms that distract the attention of the commander. The upheaval of the lunar module to a vertical position gave the commander not only an overview of the landing area, but also the ability to change the point of landing. Scales were applied to the inner and outer glasses of the commander's window. The pilot of the lunar module dictated to the commander the angular values ​​that the computer display showed, and the commander looked out the window so that both scales were combined. Then he saw the place where the autopilot leads the ship. This place could be changed by moving the handle of the controller. Moving the controller one step forward moved the landing site 1/2 ° further along the course, one movement to the side - 2 ° to the left or right, respectively.

At an altitude of about 460 m, Armstrong saw that the autopilot was driving the ship to a point on the near edge of a large crater surrounded by a field of boulders up to 2–3 meters across (it was later found to be West Crater, 165 m in diameter). On the post-flight survey, he said that at first he thought this place was good, since from a scientific point of view, landing next to a large crater would be very valuable. However, Armstrong quickly realized that it would not be possible to land the “Eagle” in a fairly safe place without reaching the crater. He decided to fly it. At an altitude of about 140 meters, the commander transferred the computer to a semi-automatic mode, in which the engine of the landing stage is controlled automatically and maintains a constant vertical speed of 1 m / s, and the engines of the orientation system are controlled completely manually. Armstrong reduced the tilt of the lunar module from 18 ° to 5 ° from the vertical. This increased the speed of horizontal forward movement to 64 km / h. When the lunar module flew over the crater, the commander began to look for a place suitable for landing, and chose a relatively flat area between the small craters and the field of boulders. At an altitude of about 80 meters, the vertical descent rate was about 0.5 m / s. Aldrin reported that 8% of the fuel remained. After a few seconds, he added that he saw the shadow of the "Eagle" on the surface of the moon. At the final stage of the landing approach, the lunar module was rotated about 13 ° to the left of the course, and the shadow was out of sight of Armstrong. At that moment, a warning came up that the computer was not receiving data from the landing radar. This went on for a few seconds. At an altitude of 30 meters, Aldrin reported that fuel remained 5% and that a warning had been lit. A 94-second countdown began, at the end of which Armstrong will have only 20 seconds to land the ship or urgently interrupt the landing and take off. After 33 seconds, the telecom operator at MCC in Houston, Charles Duke, warned that there are 60 seconds remaining. At this point, the landing radar again "lost" the surface for a few seconds. Armstrong's pulse rate at the final landing stage reached 150 beats per minute. At an altitude of 12 meters, Aldrin reported that moon dust was rising. But he rarely looked out the window. Armstrong, on the post-flight survey, said that he first noticed rising dust at a height of slightly less than 30 m. At first, it looked like a transparent sheet of flying dust, which slightly impaired visibility. As the ship went down, visibility got worse. According to Armstrong, this didn’t interfere with the visual determination of the height, but in a thick sheet of moving flying dust it was very difficult to keep track of static stones and, accordingly, determine the vertical and horizontal speeds.

Landing the "Eagle", shot on a 16-mm camera through the porthole of the pilot of the lunar module
As Armstrong recalled, at an altitude of about 9 meters, the Eagle, for some unknown reason, began to move left and back. It was possible to cope with the movement back, but the movement to the left did not work out completely. It was impossible to slow down the decline even more or to hang because the fuel was very short and the acceptable time limit before landing was almost exhausted (in one of his interviews in 2001, Armstrong remembered that he wanted this first landing to go as smoothly as possible , but at the same time, he knew that if you quench the horizontal speed and level the ship, you could fall from about a height of 12 meters and even more, in conditions of weak lunar gravity, the supports of the landing stage had to withstand the impact). Soon after Aldrin reported that the height was 6 m, the vertical speed was 0.15 m / s, and the horizontal movement speed was 1.2 m / s, Duke from Houston warned that 30 seconds remained. 9 seconds after this warning, Aldrin shouted: “Contact signal!” This happened at 20:17:39 UTC on July 20 (102 h 45 min 39.9 per flight time). The blue contact signal meant that at least one of the probes 1.73 meters long, which were attached to three of the four pillars (except for the one where the staircase) had touched the lunar surface. 1.5 seconds after that, Armstrong stopped the engine. On the post-flight survey, he said that he could not accurately determine the time of landing. According to him, Buzz shouted: “Contact!”, But he himself didn’t even see the signal that went on fire, the engine worked until the landing itself, because it was so soft that the moment when the ship went to the ground was difficult to determine. After the moon landing, Armstrong conveyed to Earth: “Houston, the Tranquility Base says. The Eagle has sat down. Charles Duke replied, with excitement, making a reservation: “I understood you,“ Candy ... ”,“ Calmness ”. You limp. We were all turned blue here. Now we breathe again. Thank you very much!"

The lunar module turned to the ground with a slight backward slope of 4.5 ° from the vertical; it remained turned 13 ° to the left of the flight path [84]. The post-flight analysis showed that 349 kg of fuel remained in the fuel tanks of the “Eagle” landing stage. That would be enough for 25 seconds to hang up, after which there would be 20 seconds left for the engine to start the takeoff stage and interrupt the landing (the following Apollo had from 499 to 544 kg after landing). As it turned out, the warning of critically small fuel residues caught fire ahead of time, because the fuel in the tanks began to splash after Armstrong tilted the lunar module to fly over the crater West. In all subsequent models of the lunar module additional partitions were installed in the tanks. The ship came down at the coordinates of 0.67408 ° c. sh. 23.47297 ° c. , 6858 meters west of the center of landing ellipse. The reason for this was small unaccounted changes in the orientation of the Columbia and Orel in orbit due to testing the engines of the orientation system of the lunar module, which then increased during two turns before braking, as well as incomplete depressurization of the transition tunnel between the ships, because of the impulse which the “Eagle” received when undocking, turned out to be a little more than the calculated one.

[ source ]



Apollo 8



image
While the 4-year-old Loren was sleeping peacefully on the lab floor, her mother created programs that would form the basis of the Apollo main command computer.

In preparing the flight of Apollo 8, the first manned spacecraft to reach the orbit of the moon, Margaret Hamilton found a serious vulnerability, but no one believed that it was a real threat. Hamilton’s daughter, who played with the Apollo 8 computer simulator while her mother worked, helped find this vulnerability. At some point, she turned on the P01 sequence, which was launched before the launch of the spacecraft, when the simulator was already in flight. Starting P01 at an inopportune moment led to a crash; and although the astronauts have no reason to make such a mistake, Hamilton decided to add a few lines of code - to make a kind of "protection against a fool." NASA resisted, finding that well-trained astronauts could never be wrong in their lives. Then Hamilton included the line “Do not launch P01 during the flight” in the documentation, but this also seemed to the management to be an unnecessary precautionary measure.

Shortly after Christmas in 1968, when Apollo 8 was supposed to leave the moon's orbit and go to Earth, astronaut James Lovell did exactly what was not expected of him — by mistake, he launched P01. As a result, the navigation data disappeared from the Apollo computer, and it could not accurately determine its position in space. The crew had to quickly navigate the starry sky and enter the correct data into the computer, and NASA specialists, including Margaret Hamilton, spent nine hours looking for a solution on how to send other information to the Apollo from Houston. The Apollo 8 landed successfully, and Lovell a year later, with more than one, applied his skills of manually reprogramming the spacecraft’s computer during the Apollo 13 flight, of which he commanded the crew. The Apollo 13 mission ended in failure due to an accident on the way to the Moon, but the spacecraft was able to return to Earth. Lovell later admitted that he was greatly helped in the Apollo 13 emergency situation by the past experience of Apollo 8 and called that incident with the loss of navigation data "planned training." Later, the astronaut still admitted that he erased the data on his own mistake. [ source ]

Software engineering


Margaret's successes in the SAGE project opened her doors to NASA. Margaret recalls:
“In this company, it is customary to give beginners a program in which no one can figure out and even more so run. When I was an intern, I was also given such a puzzle. It was a very tricky program, and moreover, the author of the code found pleasure in writing comments on the code exclusively in Greek and Latin. So, I was given this task, and, in fact, I made it work. She even printed the result in Greek and Latin. I was the first to launch it. ”



Hamilton popularized the term “software engineering,” which Anthony Oettinger introduced. [ Proof ]

“I began to use this name to highlight our work among other types of technology. When it first appeared, everyone found him very funny and long joked about it: they say, what radical ideas I have , ”she says.

In this area, she was one of those who developed concepts such as asynchronous software, priority scheduling, end-to-end testing and human-in-the-loop decision capability, which served as the basis for the development of modern, fault-tolerant software. .

Free swimming


In 1986, she founded and became CEO of Hamilton Technologies , in Cambridge, Massachusetts, a company developing the programming language Universal Systems Language . "The language of universal systems", warning, rather than correcting crash situations, which is based on the theory of systems and is based on the lessons of the project on the development of on-board software for the Apollo ships.
List of clients
  • Abadon
  • ABB
  • Access Research
  • Adtranz signal
  • Advanced methods
  • AGS Nynex
  • Apogee Communications Technologies
  • Ariel Technologies
  • AT & T
  • Auburn university
  • BDM International Inc.
  • BMC3 Engineering
  • Boeing
  • Boston university
  • Bowe software solutions
  • CA (Ingres)
  • Cadeon Strategic Technologies, Inc.
  • Cambridge Resource Group
  • Canadian government
  • Chemical Bank
  • Citibank
  • Codemakers Pty Ltd.
  • Computer Sciences Corporation
  • Construction Information Systems
  • Cross / Z International Inc.
  • CSIRO Institute of Information Science & Engineering.
  • Descartes
  • Digital / Compaq Computer Corporation
  • DoD
  • Doe
  • Eidisys
  • Fema
  • Grumman
  • Hewlett packard
  • Honeywell
  • Hugs
  • Ibm
  • Independent engineering
  • International Billing Services
  • Lockheed martin
  • Logicon
  • Loral
  • Los Alamos National Laboratories
  • Massachusetts Institure of Technology (MIT)
  • Mcdonnell douglas
  • Miter
  • Motorola
  • MRJ, Inc.
  • NASA
  • Newbridge networks
  • NR Pty, Ltd.
  • NRI & NCC Co. Ltd.
  • NSA
  • Pacific States Marine Fisheries Commission
  • Praxis International
  • Rexham Aerospace and Defense Group
  • SAIC
  • Scott paper
  • Sdio
  • SEI, Carnegie Mellon
  • Select Computer Technologies
  • Software Productivity Consortium (SPC)
  • State of Massachusetts
  • Stratus Group, Inc.
  • Sun microsystems
  • Systems Automation Technology Ltd. (SAT)
  • Terry consulting
  • The registry
  • Toldark Pty. Limited
  • U. of Arizona
  • U. of Florida
  • U. of Minnesota
  • US Air Force
  • US Army
  • US Navy
  • WPL Laboratories




Read more:


Wiki:
Margaret_Hamilton_ (scientist)
(there is no article in Russian)

GeekTimes:
Margaret Hamilton, Lead Software Engineer, Apollo Project

Wired:
Her Code Got Humans on the Moon — And Invented Software Itself
Software - at the Heart of Lunar Triumph

Translations:
Error "Apollo 8" As a NASA programmer in 1968 found vulnerability in a spaceship
Grandma programming

PS
“Then I often imagined what headlines the newspapers would come out of if something went wrong. Everyone will blame me for failing , ”Hamilton recalls.
Remember that the tester is responsible for everything

Pps
Special thanks to Sasha for help with the translation.




Together with the company Edison we continue the spring marathon of publications.

I will try to get to the primary sources of IT-technologies, to understand how they thought and what concepts were in the minds of the pioneers, what they dreamed about, how they saw the world of the future. Why did you think “computer”, “network”, “hypertext”, “intelligence amplifiers”, “collective problem solving system”, what meaning did they put into these concepts, what tools they wanted to achieve a result.

I hope that these materials will serve as an inspiration for those who are wondering how to go “from Zero to Unit” (to create something that had never happened before). I would like IT and “programming” to stop being just “coding for the sake of dough”, and recall that they were conceived as a lever to change the methods of warfare, education, a way of working together, thinking and communication, as an attempt to solve world problems and answer facing humanity. Something like this.

0 March. Seymour papert
March 1. Xerox alto
March 2, "Call Jake." NIC and RFC history
March 3, Grace "Grandma COBOL" Hopper
March 4 Margaret Hamilton: "Guys, I'll send you to the moon"
March 5, Hedy Lamarr. And in the movie naked to play and torpedo the bullet into the enemy
March 7 Gorgeous Six: girls who had a thermonuclear explosion calculated
March 8, "Video Games, I'm your father!"

Source: https://habr.com/ru/post/278585/


All Articles