Since a couple of months I have fascination for vintage computers like Commodore or Nintendo. I’m in the process restoring and pimping a Commodore SX64 and realized I did’t have a printer for it. After all it is an executive machine and how do I otherwise print my quotations and invoices? The solution was in a thermal printer I had lying around for years without a real purpose.
Vintage computers still get a lot of attention and love from the community. SD Cards are used to emulate old error-prone disks, modern CPLD’s and FPGA’s mimics now obsolete IC’s and fast flashchips makes massive cartridges. Also the platform don’t have much secrets after 20+ years. One of the projects around the Commodore is UNO2IEC which uses an Arduino to emulate the serial bus (to which diskdrives and printer were attached) and pass that to a regular PC or Raspberry PI to give access to its files. I realized its potential as it has the IEC bus already figured out. Halve of the project is already done.
I designed a small 5×5 PCB which is basicly an Arduino pro mini which sits between the Commodore and the thermal printer. It has a basic UI with a couple of LEDs to show its status, a reset button and a feed/offline button. A small solder jumper lets you choose which IEC address it listens to.
The thermal printer has a couple of fonts builtin, but only a limited amount of char would fit the line (about 20). To extend this I used the bitmap mode and extended this to 48 chars/line using 8×8 fonts. For extended coolness I used the Commodore 64 font instead of the boring PC Bios font floating around. Printing to secondary chan 0 give the regular font, secondary channel 7 the shifted font. If you prefer the boring PC font stick to channel 1. When using the C64 font also cursor up/down switches between regular and shifted font, inverse on/off switches to inverse or off.
All code is in Github. The IEC statemachine is mostly copied from https://github.com/Larswad/uno2iec and Lars Wadefalk has it’s copyright. I choose not to fork the original project as it is too different from that and I don’t think the code part I use will change much in the future. My code is under GPL as is the uno2iec. The other dependency is the thermal printer library from Adafruit (I’m too lazy to write the needed parts meself).
I have a couple of populated leftovers (without the printer) on Tindie for sale.