A Commodore 128 Tracks Ships with AIS4CBM
Ioannis Anagnostopoulos built AIS4CBM so a Commodore 128 can map ships from a 38,400 bps stream.
Most people first heard of AIS, the Automatic Identification System ships use, in 2021, when the Ever Given wedged itself in the Suez Canal and the tracking sites filled up. Ioannis Anagnostopoulos, who posts as Greek Geek, came to it from the other direction: he actually likes following ships. He also likes the Commodore 128. After several years of work, AIS4CBM is a fairly complete ship tracker for that 8-bit machine.
A stock C128 cannot keep up. AIS runs at 38,400 bps. A 1980s serial port can do that rate, but the port on the C128 cannot. His first approach was an Arduino that buffered the stream and fed the Commodore a little at a time. He later moved to a SwiftLink or Turbo-232 style cartridge serial card, which gives the machine a fast serial read that still belongs to the period.
To parse the stream quickly enough, he taught himself 6502 assembly. The rest of AIS4CBM is written in BASIC, though not Commodore’s stock BASIC. It uses BASIC 8, the extension Walrusoft released in the 1980s. That is not the BASIC-8 DEC shipped for the PDP-8. BASIC 8 includes fast drawing routines for the C128’s video chip and can use up to 64 kB of VDC memory. His machine is not a 128D, so expanding the video RAM to 64 kB is the upgrade that takes it past the factory setup. The warranty was already long gone.
The map needs that video RAM
The extra VDC memory is what makes a map of ship positions possible. Without it, the 6502 is already busy parsing, and BASIC 8 can only offer an 80-column text screen. Text can still list position, heading, and speed for ships in the area. A map is much easier to read.
The project write-up is on Hackaday.io, and the code is on GitLab. If you live near a coast, AIS is not hard to receive. Hackaday covered picking it up with a software-defined radio years ago.
Comments
0 comments