Science  /  Profile

Margaret Hamilton Led the NASA Software Team That Landed Astronauts on the Moon

Apollo’s successful computing software was optimized to deal with unknown problems.

On July 20, 1969, as the lunar module, Eagle, was approaching the moon’s surface, its computers began flashing warning messages. For a moment Mission Control faced a “go / no-go” decision, but with high confidence in the software developed by computer scientist Margaret Hamilton and her team, they told the astronauts to proceed. The software, which allowed the computer to recognize error messages and ignore low-priority tasks, continued to guide astronauts Neil Armstrong and Buzz Aldrin over the crater-pocked, dusty crust of the moon to their landing.

“It quickly became clear,” she later said, “that [the] software was not only informing everyone that there was a hardware-related problem, but that the software was compensating for it.” An investigation would eventually show that the astronauts’ checklist was at fault, telling them to set the rendezvous radar hardware switch incorrectly. “Fortunately, the people at Mission Control trusted our software,” Hamilton said. And with only enough fuel for 30 more seconds of flight, Neil Armstrong reported, “The Eagle has landed.”

The achievement was a monumental task at a time when computer technology was in its infancy: The astronauts had access to only 72 kilobytes of computer memory (a 64-gigabyte cell phone today carries almost a million times more storage space). Programmers had to use paper punch cards to feed information into room-sized computers with no screen interface.

As the landing occurred, Hamilton, then 32, was hooked up to Mission Control from MIT. “I was not concentrating on the mission, per se,” Hamilton confessed. “I was concentrating on the software.” After everything worked properly, the weight of the moment hit her. “My God. Look what happened. We did it. It worked. It was exciting.”

Hamilton, who popularized the term “software engineering,” took some chiding for it. Critics said it inflated her work’s importance, but today, when software engineers represent a fervently sought-after segment of the work force, no one is laughing at Margaret Hamilton.

When the Apollo missions were planned, the process of writing code began on large sheets of paper. A keypunch operator would create holes in paper cards, keying the codes into what were called punch cards. “Not too many people know what punch cards are anymore, but that’s how you programmed it,” says Paul Ceruzzi, a curator emeritus at the Smithsonian’s National Air and Space Museum, who has known Hamilton for the past two decades.

The museum holds in its collections the Apollo Flight Guidance Computer Software Collection created by Hamilton. The archival material includes printout sheets, known as “the listings,” which show results of guidance equation calculations. When the computer’s output identified no problems, software engineers would “eyeball” the listings, verifying that no issues required attention.