Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I have an old piece of a hardware that does diagnostics on medical equipment. It prints out results over a parallel port. Is there any way to have CUPS accept jobs from a parallel port and redirect them to the default printer?

Essentially I want CUPS to listen to /dev/lp0 for incoming jobs.

Reading about this problem a bit, would it be possible for me to capture the PCL data via the parallel port (cat /dev/lp0 > out.pcl) and then convert it to Postscript using pspc16 or somehow send the PCL to Ghostscript to interpret the PCL and dispatch to CUPS?

share|improve this question
    
Not clear on the question, are you saying the hardware has a parallel port, normally you would connect directly to a printer, but you would like to connect to a different machines parallel port and use the CUPS service on that machine? –  Tim May 24 '12 at 18:10
    
yes, exactly. I want to service station -> lp -> linux box w/ CUPS -> spool to non-lp printer –  Evan Carroll May 24 '12 at 18:13
    
I don't think this is possible with cups. You would have to write a software listening on the parallel port and sending jobs to cups –  Ulrich Dangel May 24 '12 at 18:22
2  
I think you need a special cable, parallel ports aren't wired symmetrically (I'm not sure a crossover cable would be enough: some pins aren't wired inside the computer). There are two parts to your problem: getting the data from the diagnostics equipment to your computer's parallel port, for which you'll find more expertise on Super User, and routing the data from the parallel port to CUPS, which this site should address best. –  Gilles May 24 '12 at 23:47

1 Answer 1

This is not possible with a PC alone the parallel port is not designed to act as a printer.

You will need some sort of hardware that emulates a printer and then relays the data to the computer.

This page describes the sort of product you need. I don't know anything about that specific company.

Another option option might be a parallel to serial converter and then connect that to your PC.

share|improve this answer
    
Why can't the PC do this in software? There has to be some kind of project that tackled this, the technology is like 40 years old. I mean, you're telling me if I want to turn a Linux box into an LPT printer, I'm SOL? This sounds like a popular request. –  Evan Carroll May 24 '12 at 19:47
    
Very specific need. Legacy hardware support. –  Tim May 24 '12 at 19:50
    
I am pretty sure you could do it manually yourself. Just write a software reading the data from the parallel port and process it. –  Ulrich Dangel May 24 '12 at 19:55
2  
An adequate cable and some userspace software to read the data from the parallel port should be all you need. You might need to hack your own software, though. –  Renan Jun 24 '12 at 3:09
2  
For the cable, see Laplink (null-printer) cable. For the software... I don't know but you will probably be operating on /dev/parport* (the raw parallel port device) instead of /dev/lp* (specifically made for talking to a printer, not pretending to be one) –  Alan Curry Aug 23 '12 at 4:37

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.