Skip to content

Printing from a TI to a modern printer

TI-99/4A So, obviously, the TI-99/4A doesn't support printing to USB printers, nor can it print to network printers.

With a little help, though, it can print to modern printers via a helper device running UNIX/FreeBSD/etc. This leverages the BeagleBone Black-based cassette emulator I described in an earlier web log entry.

Here's how it's done:

Step 1: Decide if you're going to use the TI's parallel port or the serial port. I recommend the parallel port for the sake of speed -- the serial port lacks any sort of handshaking, so you will drop characters if you choose serial.

Step 1a (parallel): obtain a parallel-to-serial converter. They're about fifteen bucks on eBay. Pretty much any unit will do, so long as it has a Centronics port on the input and a DB25/DB9 on the output. Configure it to output as fast as it can (typically 38400, which we'll refer to as ${SPEED} for the rest of this procedure), 8N1.

Step 1a (serial): obtain a straight-through DB25 <-> DB9 cable. DB25 will be male, DB9 will be female.

Step 2: obtain and connect a USB serial adapter to the BeagleBone Black. You will probably need a small USB hub if you're also using it as a cassette deck emulator -- passive hubs are fine. Run "dmesg" on the BBB's console until you see it detect the serial adapter and assign a device name (typically "ttyUSB0"). Note the device name; we'll refer to it as ${DEVICE} for the rest of this procedure.

Step 3: connect the TI to the BBB. If you went with step 1a, verify that you can successfully send characters through your parallel converter -- i.e., print a file while running minicom on ${DEVICE} at ${SPEED}. If you went with step 1b, no further actions are necessary for this step.

Step 4: download my TI utilities from GitHub here ... you care about everything in the printer_listener subdirectory.

Step 5: on the BBB, make an incoming printer spool directory wherever convenient. We will refer to it as ${SPOOL_DIRECTORY} for the rest of this procedure.

Step 6: inside the printer_listener subdirectory is an "epsonps" directory. Enter it, and execute "make; sudo make install". The Epson-to-PostScript converter (and its PostScript preamble) should be installed to /usr/local/bin.

Step 7: on the BBB, as root, ensure that the python2-pyserial package is installed.

Step 8: on the BBB, copy the printer_listener.py script from the printer_listener subdirectory to someplace convenient in your path. You can also leave it in-place, but you'll need to explicitly specify its location when started.

Step 8a: on the BBB, look at the sample filter scripts and optionally choose one to use. One will send the printed output to a networked printer as HP PCL, the other will leave a PDF in /tmp. If you choose to use a filter, copy it to someplace convenient in
your path (hereafter referred to as ${PATH_TO_FILTER})

Step 9: on the BBB, execute "printer_listener.py -d ${DEVICE} -s ${SPEED} -f ${PATH_TO_FILTER} -n ${SPOOL_DIRECTORY} (with the "-f" and "-n" options being, well, optional). You will see "printer listener listening" after the serial port is initialized.

At this point, anything you print will appear either in the directory that you ran printer_listener.py from, or the ${SPOOL_DIRECTORY} if you specified that option. If you specified a filter with "-f", the output will be processed per the directives in the filter file.

That's about it. You'll probably want to wire this into a startup script; I despise systemd, so I'm leaving that as an exercise for the student.

Enjoy.

Trackbacks

No Trackbacks

Comments

Display comments as Linear | Threaded

No comments

Add Comment

Enclosing asterisks marks text as bold (*word*), underscore are made via _word_.
Standard emoticons like :-) and ;-) are converted to images.
E-Mail addresses will not be displayed and will only be used for E-Mail notifications.
To leave a comment you must approve it via e-mail, which will be sent to your address after submission.
BBCode format allowed
Form options

Submitted comments will be subject to moderation before being displayed.