Pong Wars on the Commodore 64
A couple of years ago, I saw a graphics demo in JavaScript that I just had to recreate on the C64. Having never written a real C64 program before, it s been quite a journey, and it s all documented here.
Articles on emulation and software development, with the occasional bit of sci-fi thrown in.
A couple of years ago, I saw a graphics demo in JavaScript that I just had to recreate on the C64. Having never written a real C64 program before, it s been quite a journey, and it s all documented here.
Y2K-inspired science fiction in the Terminator universe: A cult tries to wait out the coming nuclear holocaust in an orbital station, but something catches them by surprise.
Another translation attempt, this time of one of Şebnem Ferah s deep cuts; the aim here is to convey meaning while retaining rhyme and meter, while not necessarily being a transliteration.
An attempt to translate Mor ve Ötesi s classic of Turkish rock while keeping to the melodic line of the song, and retaining some sense of lyrical rhyme.
While working on a long post about a Commodore 64 program, I digressed into a discussion on how to represent negative numbers in binary. The digression stands alone, so I ve decided it can be released as a separate quick hack.
I ve been slowly removing Google apps from my life, and one of the last ones left is Authenticator. In this post I look at migrating codes out of Authenticator to a command-line OTP tool, and the steps involved.
What if the reason we darkened the skies in the Matrix was much more stupid than we were told? Flash fiction, also published on DeviantArt.
A deep dive into the history of the 1541 disk drive, and a technical exploration of why it ranks as possibly the slowest commercially released floppy drive. Originally a series of 100 posts on Mastodon and Bluesky, for Threadapalooza 2024.
Learning of the passing of Ward Christensen who created the BBS and XMODEM, I decided was as good a time as any to relate the tale of the time I used XMODEM as a protocol of last resort to fix a Windows machine, so here is that tale.
In the concluding part of the series on implementing ActivityPub for this blog, I look at the events that may arrive at the blog after a user follows the blog on Mastodon, and how we can keep track of them.
Continuing a previous article on implementing ActivityPub support in PHP, this post looks at how to handle the most common types of message that might be expected to pass through a simple AP implementation.
First written for the DeviantArt Community group journal, Jun 2024. A short exploration of the connection between Piet Mondrian s abstract art and esoteric programming languages.
Tooltips are the leading cause of hair loss for frontend developers: many hours have been lost fighting JavaScript frameworks to get their positioning just so. This article looks at how simple tooltips can be achieved with CSS, and the limits of the approach.
Part of a series on implementing ActivityPub support for this blog. A core tenet of ActivityPub is the generation and verification of signatures for messages, and this article looks at how that works in PHP.
Sometimes you need to proxy an API, and you may not necessarily have the resources or wherewithal to install dedicated proxying infrastructure. Let s try to write a proxy in PHP, and see what troubles we run into.
Ever wondered if it s possible to automatically solve a game of Solitaire? It s something I got to thinking about a little while ago, and this article looks into one way you could go about it.
I ve found it very useful over the years to be able to receive email to any address at my domain. This is a quick look at how Postfix can be configured to provide routing for wildcard addresses, so it all lands in the same inbox.
A dive into the perils of running your own mailserver, when something terrible goes wrong with an upgrade.
Like many microblogging platforms, Mastodon displays posts and replies in a flat list; this can get confusing when conversations get deeply nested and branched. The Mastodon Context API offers a way to retrieve parent-child relationships between replies; this article looks at how those can be converted into a traversable tree.
A few months ago, I refreshed the design of my personal site; here s a list of a few bits of modern CSS that were used in the rebuild.
This year s Binary Golf Grand Prix recently closed for submissions, and I only just found about it. This article covers a couple of approaches for this particular code golf problem on the Commodore 64.
When hand-writing WebAssembly it can get problematic to refer to particular constants by their value instead of being able to put a name to them. I put together a simple preprocessor to allow for constants to be handled by name, and in this article I look at how the preprocessor works with the WebAssembly Text format.
A long-awaited sequel to Prime Point, in which our brave protagonist finally jumps into a hyperspace-capable ship and ends up... somewhere.
A short postmortem of the time my LUKS volume failed, what I did wrong at the time, and how I got the data back.
An update to HTCPCP (RFC 2324) to allow for the connection of networked tea-brewing devices. Published under the RFC Informational series.
Continuing a series exploring the concepts behind JPEG image compression, this part begins delving into the relationship between the image, its colour constituents and the encoded data by breaking open the Start of Frame segment.
Various levels of compression and encoding are employed in the production of a JPEG file. The first step in decompressing an image is decoding the data, which is compressed with a variant of Huffman encoding. This article looks at the data attached to a JPEG file which allows the Huffman decoding to proceed.
Aside from the concepts explored in the previous part of this series, the JPEG file format is composed of segments which encode the various portions of information needed to decode an image. This article implements a simple method of traversing the segments of a JPEG file.
This first part explores the concepts behind the compression techniques used by JPEG.
Ever run into a codebase with multiple Subversion repositories, where you just wanted to find out which branch they were all on without tediously cd ing into each working copy?
At deviantART s technology team meetup in France ( Breadlands 2012 ), I gave a short Ignite talk distilling the first three articles in the Gameboy Emulation in Javascript. The slides from that talk are now available here.
The day after the night before, a hungover flatmate notices that the wall mirror looks a bit strange. Speculative flash fiction.
There are a number of techniques for encrypting or hiding information within an image, including the concept of hiding a program within the image which itself prints the secret information. This article explores the feasibility of encoding a Brainfuck program within the bitmap data of an image, with a detailed run-through of a simple example.
Written on the theme of "thirty". On the far edge of the galaxy, a planet where only thirty stars are visible notices that one of the thirty has disappeared. Flash sci-fi.
Procedures for transmission of files over ASCII-text networks generally involve some form of encoding such as uuencode. When program executable files are being encoded for transmission, extra steps are required at the receiver before the program can be run. This article explores the concept of a program which has been encoded for an ASCII-text network, but can also be run directly without…
Concluding an introduction to the development of augmented reality software, this part looks at implementing an edge detection algorithm overlaid on an Android smartphone s camera preview, and how the process can be optimised through use of the Android Native Development Kit.
One of the major current trends in smartphone applications is augmented reality: a view of reality with information laid on top. This can be as simple as a view of what the camera is currently seeing, with calculations based on position and direction. In the first of a two-part article series on Android development, this article looks at how to set up a camera view and access a canvas for the…
Like most computer and console systems, the GameBoy offers a hardware timer for use by games, if they wish to keep time more accurately than at the rate of vertical blanking refresh. In addition to a controllable timer, the GameBoy provides a facility for directly examining a fixed divisor of the system clock; in this article, both aspects of the timer are investigated, and the use of the timer…
The tide of an interplanetary war is turned when a rogue black hole enters the solar system, and is captured by Earth forces. First published in IFWG Story Quest magazine , hard sci-fi.
Continuing a series on the implementation of a GameBoy emulator, this part looks at how the basic memory map of the GameBoy can be expanded, to accommodate games that are larger than 32kB. The GameBoy uses a system of virtual memory banking to perform this expansion; the concepts of the banking controller are looked at, and an implementation offered.
A spaceship crewman is faced with a Catch-22 while maintaining the engines. Flash sci-fi.
Game consoles, like all computers, offer the facility to break off execution of a program and handle events or triggers. The GameBoy is no exception, and most games utilise the vertical blanking interrupt as one of their primary tools for keeping time and refreshing the screen. In part 8 of the series on emulator development, I look at the concepts behind, and the implementation of interrupts.
The basis of most games is the movement of objects over a background landscape. In this part of the series on emulation development, I take a look at how the GameBoy produces movable objects, and how the process can be emulated in JavaScript.
Part six of the series examines the issue of how a player interacts with the GameBoy, taking a look at the hardware layout of the keypad, and how the layout can be implemented as part of an emulator. The particular issues thrown up by a JavaScript emulation are looked at, including basic event handling and how events can be passed to the keypad handler.
In the fifth part of the series, the graphics subsystem of the GameBoy emulator is tied to the memory handler, and a rudimentary interface provided for the activation of the emulator. This part includes a working demo of the emulator so far, as will subsequent parts.
The exploration of system emulation in JavaScript continues, with a detailed look at the GameBoy graphics system, and how graphics are rendered by the GameBoy hardware; a simulation of the process is then put in place for use by the wider graphics engine.
In the third part of a series regarding system emulation in JavaScript, the GameBoy as an example of a raster graphics system is looked at, and the timings established for passing of control between CPU and graphics. Also examined is the issue of where the emulated graphics code will be rendering its output, and the HTML5 canvas is introduced as a solution.
Continuing a series examining system emulation in JavaScript, this article examines how the GameBoy memories are mapped onto the CPU s address bus, and how such a mapping can be emulated. Also covered is the dynamic loading of program ROM images after initialisation, through asynchronous file requests.
In the first of this series of articles, I ll look at how a CPU can be emulated through JS, and start building an emulation core for the GameBoy console.
PHP provides two methods of defining constants: global-scope constants and class constants. A friend of mine, while discussing the issue with Derick Rethans, was informed that class constants are more memory efficient; this article documents my investigation into the reasons behind that assertion.