“Now Go Bang!” is named after a source comment in Spacewar!, the first digital video game. It marks the very instance, when a spaceship which has been dragged into the gravitational star starts to explode. What follows, is impressionist pixel-dust floating along the ship’s former trajectory in a sparkling bloom of phosphor activation.
A Software Archeological Approach to the First Video Game.
Over the years, before I started this blog, some rather blog-like formats have accumulated on my website, each dedicated to a certain topic or project. Maybe, as many of us are expected to stay at home on their own, this is also an opportunity to point these series of write-ups out and to include them here as links, over the next few days.
For a beginning, there’s a walk through the code of Spacewar!, which is generally considered the first digital video game. We’ll have a look at every single line of code — no instruction is left behind —, learn about the DEC PDP-1 computer, learn how this game was achieved on this early 1960s machine by some ingenious tricks in software. (There are actually some things to be admired, like early object oriented approaches and a JIT compiler.) We’ll even learn about some of the fundamental intrinsics of digital computing, e.g., how basic operations like multiplications and divisions, or integer square roots were solved on this particular machine. Moreover, we’ll have a look at some of the more arcane versions of the game, including a somewhat first person multiplayer version from 1963. — Already intrigued? Then, have a closer look and follow the link, or, maybe, save it for later…
Veering off of our usual topics for a bit of political economy.
Since everything is a bit out of the ordinary recently, here’s a somewhat different post, diverging from our usual path. Yes it’s about the current “Corona” situation, but also about a somewhat broader perspective. Since my educational background is in such things like philosophy, sociology and even a couple of semesters of political science, I can’t help including this perspective. On the other hand, I’m clearly not a medic nor do I have any relations to that honorable profession. So I’m entirely without expertice in this field and relying on what is to be learned from public appearances of epidemiologist who speak on the matter. (In other words, anything regarding the current situation and its epidemiological perspectives is just hearsay and lacking any further foundations. Any inferences and/or conclusions drawn from this kind of awareness are not any better than the foundations on which they are built.)
Trigger Warning I’m sorry to say, this will not be another pep talk on the subject. If you feel apprehensive about this or do not feel like in the right mood for this, better skip this post.
Proudly announcing version 1.0 of the PET 2001 online emulator.
Recently, I’ve been posting on Commodore BASIC and more specifically about the PET 2001 quite a bit. While not the sole reason, this was partly because I was adding a few features to the PET 2001 online emulator behind the scenes. I even endeavored into a major reorganization of some of the source code in order to facilitate this and future work. And, last but not least, there’s now even a suitable help file / documentation. — Reason enough to promote the emulator from its previous beta state to version 1.0!
A closer look at the logic behind Commodore ASCII, AKA “PETSCII”, and the PET 2001.
The flavor of ASCII used by the Commodore 8 bit computers, commonly known as PETSCII, is asking for a bit of an explanation. PETSCII is a peculiar beast, close to ASCII, but not quite, somewhat compatible, but not really, there are duplicate ranges of characters all over the place, and the special characters are lacking any recognizable order… — But look at all these these funny graphics characters!
In order to make sense of this and how the character set is organized, it may be helpful to have a closer look at it with a particular focus on the PET 2001. At least, this is the very machine, this character set originated on and for which it was designed for, with no idea yet that this may become the ancestor of a succesful line of home computers. Here, we may discover logic, in what must remain a puzzling enigma on the more popular and better known machines that followed, like the C64.
Learning from history: How to keep calm while panicking and carry on with face masks
Influenza and influencers, and a friendly customer information from 1918. Apparently, it’s not the first time, we’re facing an epidemic. Some prefer doing so while wearing a face mask, others may prefer desinfectants. Arguably, masks make the better photographs.
String exploits and a reasonably paced video game in just 10 lines of Commodore BASIC.
In continuation of and as a finale to our mini series on the internal representations of Commodore BASIC, we’ll now put some of our findings to use, especially some possible exploits of string variables.
What we’re going to do, is a classic cañon run game, where a single player rides/flies/drives/navigates a procedurally generated cañon down from the top, trying to progress as far and deeply into the winding depths as possible while avoiding the walls of the cañon. And we’re going to implement it in just 10 lines of BASIC, which puts some serious constraints on our solution. As do some of the intricacies of the PET 2001. Especially, we’ll have to avoid any direct access to the video memory (as in PEEKs and POKEs), meaning, we’ll do it all by print statements. So we’ll have to consult our bag of tricks — and come up with some exploits of the string mechanism.
Spoiler alert: It will be about fast partial strings and fast FIFO queues, while avoiding garbage collection.
How to thoroughly renumber Commodore BASIC programs (PET 2001, VIC-20, C64)
Renumbering a is popular beginner’s sport for those who dare to venture into the mythical realms of intricacy, which the BASIC interpreter and its storage formats provide. Since it is also a useful utility, there are numerous programs for this, especially it’s a favorite example in the intructory sections of machine language guides. However, as always, there’s an easy way and a thorough one. And we’ll see soon, why this may be.