1972 Star Trek in Python


STTR1 and trek on cool-retro-term.

The first computer I used was a DEC PDP-11/70 running the RSTS/E operating system. It was 1978, I was in 10th grade. From our high school, we dialed up nearby University of Delaware, connected to Project Delta and our computing experience centered around a 300 baud DECwriter. Quaint by today's standards, yet it opened a new world to me! Even on a paper terminal, when taking a break from learning to program you play games. My favorite was trek, a slightly watered down version of the original STTR1. But it's the first version I played, so I wanted to revive it. You can read some trek history here. And of course there is a Wikipedia page on STTR1.

I converted STTR1 as well and it's a more complete game, though user input (numbers) and short range scan (lack of grid) are not as convenient. I wonder if there was a time constraint on the Project Delta porting that prevented all STTR1 features from being incorporated. I notice small differences in the games and there are likely more:

Click a link below if you'd like to download the game. You have four versions to choose from, two on each page: linux (or any major OS) and HP Prime python versions of:

Why python?

Star Trek programs have long ago been ported to other languages, so why bother with yet another port? I wanted to run the programs on my calculator! Most modern, high end calculators support python and any effort to port a program to python pays off in making it useful in these tiny handheld computers. Programming a calculator in the 2020s is not very different from programming a PC in the 1980s, making this the perfect time to revive aging but great examples of programming creativity.

My phone has trouble focusing on the screen, so you must trust me that they look much better and easier to read in real life. You can see my app screen and a game of STTR1 just underway:

The tml library

Piotr Kowalewski created a terminal (tml) emulator that provides fixed width font and related niceties. The HP Prime provides only a variable width font and these old text based programs assume and require fixed width printing. The versatile and easily used tml makes it possible to bring these programs to life on the Prime. Thank you, Piotr!

Bugs

Please report any bugs. The programs are straightforward, but I more than likely made a conversion error here and there!

Mike Markowski
mike.ab3ap@gmail.com