Apollo 11号登月飞船制导计算机源代码(待续)

今年是人类登月50周年,最近github上出现了Apollo 11号源代码,荣登排行榜第一。

这些指令可以理解为特制的汇编语言,说汇编,是因为它不是机器码,也不是高级解释性语言,而是介于两者之间。之所以说特制,是因为这些代码是用在特定的“计算机”上的,那个年代,说计算机其实不太合适,更像是个计算器。

                                                         

  在1960年代末和1970年代早期用于月球任务的阿波罗号太空船实际上是两种不同的航天器,命令模块Command Module (CM)和月球模块 Lunar Module (LM)。CM被用来让三名宇航员登上月球,然后再回来。LM用于登陆月球上的两名宇航员,而第三名宇航员则留在CM中,绕月球轨道运行。

                                                         

                                                               Apollo 15 CSM (Command and Service Modules)命令模块  

                                                            

                                                                                    Apollo 16 LM月球模块

程序指令是逻辑的符号化。

这些符号化的逻辑是如何改变世界的?

扫描二维码关注公众号,回复: 11783484 查看本文章

http://www.ibiblio.org/apollo/ScansForConversion/Luminary099/0026.jpg

上面是阿波罗11号制导计算(AGC)中指令模块(Comanche055)和登月模块(Luminary099)原始代码的一部分。

源代码采用了动词——名词结构来编程,下面是给动词和名词的汇编语言代码,有兴趣可以去github上搜索源代码,看看是怎么对应起来的。

http://www.ibiblio.org/apollo/A17_VN_Checklist.png

这些指令最大的目的是利用IMU(惯性测量单元)数据求解求解飞船姿态,根据当前姿态才有可能调整飞船的航行。这保证了飞船能够以预定轨道路线完成使命。

              

                                                                                   指令、导航和控制系统


A giant leap for technology

   When in 1962 MIT's Instrumentation Laboratory began, under the direction of the legendary Dr. Charles Stark Draper (a pioneer of inertial navigation systems), the development of a computer to bring people from the Earth to the Moon, computers where in their childhood. They were giant electronic-tubes devices, big as rooms or even building floors, controlled by means of of perforated tapes or cards, with insignificant memory capacity compared to the personal computers that would be born at the end of the 1970's. With an engineering courage that has few precedents, designers (historical characters like Hal Laning Jr, Eldon Hall, Ramon Alonso, Albert Hopkins and many others) elected to use for the first time in history a newly born electronic component: the integrated circuit. Still far away from the microprocessor or microcontrollers of the 1980's, the only functions available were simple logic ones. Using thousands of these logic gates, it was possible to implement what would be called today the central processing unit of the computer and all support circuitry. For memory, since it was still impractical to build it with integrated circuits, the ferrite core technology (where small rings were used to store single bits) was adopted. being reasonable easy to miniaturize. Using the same technology, the program memory was made of tens of thousands of ferrite cores, hand woven with thin copper wire to represent the 1's and 0's of the computer software. These wire were to be woven by specialized workers at least one month before the launch of a mission.

  These critical decisions, taken in the era of the "dinosaur computers", were found to be winners in the following years, just seven, that saw men land on the Moon. The onboard computer developed for the Apollo program (and installed into both the Command Module and the Lunar Module, but with different software for each vehicle) was an outstanding technological success and established rules for the development of future computers both for aerospace and other applications. It also opened the way to new applications of integrated circuits (it has been the first big user on an industrial scale) and being at the time the smallest computer in the world, helped push computers into other sectors of technology.

引自http://www.ibiblio.org/apollo/ForDummies.html


重点解读:设计师(如Hal Laning Jr,Eldon Hall,Ramon Alonso,Albert Hopkins等众多历史人物)选择在历史上第一次使用新生的电子元件:集成电路。距离1980年代的微处理器或微控制器还很远,唯一可用的功能是简单的逻辑功能。使用数千个这些逻辑门,可以实现今天所谓的计算机中央处理单元和所有支持电路。对于存储器,由于使用集成电路构建它仍然是不切实际的,因此采用了铁氧体磁芯技术(其中小环用于存储单个位)。合理容易小型化。使用相同的技术,程序存储器由数万个铁氧体磁芯组成,用细铜线手工编织,代表计算机软件的1和0。

这里也可以看到,那个时代还没有所谓单片机一说,就连集成电路都没有。设计师创造性的提出了把电子元件放在同一块介质上。 

猜你喜欢

转载自blog.csdn.net/sinat_39416814/article/details/96903723