Connecting a Thermal Printer to a Commodore 64 via a Custom Arduino Board Blends Modernity and Retro

Clever use of multiple channels allows the C64 to pick from two different fonts without a custom driver.

Gareth Halfacree
4 years agoRetro Tech

Sjaak at SMD Prutser has taken a break from their current project to restore a Commodore SX64 eight-bit portable in order to combine the new and the old: Interfacing a cheap thermal printer with the machine via an Arduino Pro Mini-inspired interface board.

"I’m in the process restoring and pimping a Commodore SX64 and realized I didn't have a printer for it," Sjaak explains. "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."

"I designed a small 5×5 PCB which is basically 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 built in, 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."

To make the printer capable of multiple fonts without having to write any special drivers for the Commodore 64, Sjaak opted for a multi-channel system: Printing to the default channel gives the default font, while printing to the secondary channel switches to the Commodore 64's own font — and offers additional formatting, using the cursor-up and -down control characters to switch between regular and shifted font and the inverse-on and -off characters to do exactly what their names suggest.

More information is available on SMD Prutser, while the code is available on GitHub under the GNU General Public License Version 3.

Gareth Halfacree
Freelance journalist, technical author, hacker, tinkerer, erstwhile sysadmin. For hire: freelance@halfacree.co.uk.
Latest articles
Sponsored articles
Related articles
Latest articles
Read more
Related articles