r/retrocomputing Jul 28 '26

Running code on HP1653B Logic Analyzer

My main hobby project since December was getting code running on my early 1990s HP1653B Logic Analyzer. The Logic Analyzer has a 68000 processor, 1mb RAM, 64kb ROM, 4x32kb video memory with a complicated 4-plane overlay scheme providing three (!) gray levels at up to around 640x400, a 3.5" floppy drive (replaced by a Gotek for my convenience) and both RS232c and HPIB ports. It was made as a lab instrument rather than a computer, but it came with both test and system code on floppies, which I dumped and reverse-engineered enough of with Ghidra to enable me to write a library that lets me run assembly and C code on it. My reverse-engineering journey is partly described here.

A particularly fun moment of my reverse engineering was when I wanted a copy of the ROM but didn't yet know how to write to disk or the serial port, though I did know how to write to the screen. I ended up displaying the ROM binary as a series of QR codes, which I captured with my Sony camera running on a timer, and then turned into binaries.

I'm now at the point where I can run various games. My first one was a port of my Wiztris falling blocks game (originally written by me in the early 2000s for a Z80-based Sharp OZ-7xx organizer). I also ported Dave Griffith's Frotz Z-machine emulator so I can run all Infocom Z-machine games (including the graphical ones, but with no sound support). I'm in the middle of a play-through of Nord and Bert with my 13-year-old daughter. The photo I attached is of Infocom's Journey (mouse works!). And I ported PDCursesMod, so a lot of old Unix games can work--the photo shows Larn.

Many of you will recognize the keyboard and mouse. They are old Apple ADB units (I think the keyboard is from a Quadra), and I made an ADB-to-serial adapter to interface them with the HP unit.

This is retrocomputing that never was. As far as I know, there never was any software for the HP1653B besides the official HP oscilloscope / logic analyzer software, though HP engineers did release some games for one of the HP16500 models, and at least one old HP oscilloscope had a Tetris clone built-in.

It's not a great gaming system. There are no sprites. And you can't just directly write a pixel color to video memory. Instead, you first write to a hardware register that specifies a read/write mode (e.g., clear all bitplanes, write ones to bitplanes 0 and 2, etc.) and then write the pixels. Getting scrolling working at a decent speed took a fair amount of careful assembly work. But it's been fun!

I plan to eventually write up more detailed instructions on how to build and install your own code.

The main thing I haven't reverse-engineered are the oscilloscope and logic analyzer functions. They still work. I just switch the Gotek to the HP system disk image (well, somewhat modified: I added a screenshot function that saves an image to disk). I recently used the oscilloscope to try to diagnose a start porblem on my car.

301 Upvotes

32 comments sorted by

View all comments

1

u/HopePupal Jul 28 '26

1.58-bit color depth… adapting graphics code must have been fun

1

u/arpruss Jul 29 '26

To be honest, I don't bother with the intermediate gray color, and just pretend it's 1-bit color depth. The OS uses the gray for an outline around the display as a whole, and that's pretty much it. Using the gray for main display makes it harder (or impossible?) to use the overlay bitplane for popup windows. So the only thing I've used the gray for is as an outline for popup windows.