The Story of My Life so Far - Part 56 - Creating a Computer Game on the Corvette Georges Leygues: Coding

This is the story of my life so far: 68 years and counting.
Prequel: A Brief History of my Family in France



The story starts here
Previous episode: Part 55


Programming my Computer Game

There was no support for me to program the computers of the Georges Leygues.

Programs were usually written in a high level programming language such as FORTRAN, that I had been using at the École Navale. Programs written in a high level language are converted to the language understood by the computer, its machine language, with a compiler. There was no compiler available to me.

The lowest level of programming language on any computer is call the assembly language. An assembler is used to translate assembly to machine code. One instruction in assembly code is translated to one instruction in machine code.


Machine+vs+Assembly+Code.jpg
The instruction in assembly "move,w # 0x5a1e,0x0120" is converted into one instruction of machine code on 3 words of 16bits.
source

I had no assembler available to me either. All I had were the manuals for the assembly languages of the two computers, the P2MS and the Mitra 15.

So this is what I did: I wrote the code of my game in assembly code and I translated it manually on paper.

It took me weeks and months to do that, but I was determined to have a game that worked successfully.

Inputing and saving the program of the game

Another problem that I had to solved was that there were very few ways to enter the program in the computers or to save it on some medium so that it could be loaded again later.

The program was to be run on the Mitra 15, the visualization computer, that was directly connected to the consoles on the CIC. There were no possibility of input or output for the program on this computer.

The only way to load a program on the Mitra 15 was to send it from the P2MS.

There was a way to input instructions on the P2MS using a row of 32 switches and pressing a button for each word of 32 bits. It was very slow, but this was the only way I found to enter the program.

Fortunately, when I started to enter the program on the P2MS, the computer was already installed and there was no tests that needed to run on it. So, I was able to keep the program in the non-volatile magnetic-core memory of the P2MS for several weeks.

However, at some point I had to save the program on a medium that I could use later to load it again.

The only device available for this was a teletype with a tape puncher and reader using a five-hole punched tape.


paper-punched-tapes.jpg
Five-hole and eight-hole punched paper tapes
source

So, this is what I used: I wrote a small program on the P2MS to write the game program on a punched tape on the teletype.

Then, to load the program and run it from scratch, this is what needed to be done:

  • input, using the switches on the P2MS, a "pre-loader" program that had only 23 instructions.
  • with this pre-loader, input a small program that I called the "loader" from a small punched tape.
  • using the loader, input the game program from a larger punched tape on the teletype. This operation was taking around 45 minutes.
  • finally, start the program on the P2MS manually

The program on the P2MS was very simple:

  • send the real game program to the Mitra 15 and instructed it to start the program.

After months of trials and errors, the game was finally running and we were able to play tennis in the CIC of the Georges Leygues when we were not at sea.

Continue to Part 57


If you like this story, please consider to follow me

Summary
Part 1 - Part 2 - Part 3 - Part 4 - Part 5 - Part 6 - Part 7 - Part 8
Part 9 - Part 10 - Part 11 - Part 12 - Part 13 - Part 14 - Part 15 - Part 16
Part 17 - Part 18 - Part 19 - Part 20 - Part 21 - Part 22 - Part 23 - Part 24
Part 25 - Part 26 - Part 27 - Part 28 - Part 29 - Part 30 - Part 31 - Part 32
Part 33 - Part 34 - Part 35 - Part 36 - Part 37 - Part 38 - Part 39 - Part 40
Part 41 - Part 42 - Part 43 - Part 44 - Part 45 - Part 46 - Part 47 - Part 48
Part 49 - Part 50 - Part 51 - Part 52 - Part 53 - Part 54 - Part 55



H2
H3
H4
3 columns
2 columns
1 column
28 Comments