On 22/04/14 11:20, Mark Rogers wrote:
I have a potential customer with some industrial kit that currently prints to an obsolete parallel port (Centronics) printer. They need to keep the kit but ditch the printer, sending the data to a "black box" instead that logs that data.
I'd like to do this on a Linux box, any suggestions?
Off the top of my head I am thinking I'll need to do a parallel to serial conversion first, then pull the raw serial data into something that can interpret however the data is being encoded for printing. But it's turned out to be quite a hard thing to Google for (although I have found some bits that might be useful). Alternatively I wonder whether the I/O pins on a Pi or Beaglebone could be used to emulate a printer (although I might be way out of my depth there...)
Another approach might be lptcap[1] although that's intended for DOS (FreeDOS??)
[1] http://www.qi.fcen.uba.ar/materias/iqi/paralel1/home.clear.net.nz/pages/khei...
On my browser, I go to google and type "Parallel printer to" and many suggestions come up, such as to: USB, Serial, Network, WIFI etc. I'm sure you can get a parallel to Serial adaptor, and then capture the serial data directly, and also sure you can do the same thing with USB. However.... what will you do with it then? You'll have a stream of ascii and printer control codes to decipher. Perhaps doable if it's Epson control codes, but probably quite hard if it's HP's PCL, or similar.
I googled a bit and found this thread.. http://community.spiceworks.com/topic/286501-capture-parallel-printer-output which points to this http://www.pclviewer.com/resources/capture/index.html which sounds like it will do what you want and it's probably a lot simpler to get something off the shelf (assuming it's still available) from someone who can support it and specialises in it.
Alternatively try googling "Parallel Printer data capture" or "Parallel Printer Capture"
HTH. Steve