# Mobile printing?



## GullibleJones (Feb 10, 2012)

I was having much trouble getting LPD to work right, so I decided to try CUPS instead. But the instructions in the online documentation tell me to make devd change the permissions for the specific device node used by the printer (i.e. /dev/usb/X.Y.Z as opposed to /dev/usb/ulpt0 or whatever).

This is a bit of a problem, because I am using a laptop and may at times be hooked up to a different printer, in which case it looks like printing would fail with a permissions error! So is there any way to create a more generic/portable CUPS configuration, where I can add printers as needed without having to su to root to change device node permissions?

(I'm also open to options other than CUPS; anything where I can print to a PDF or Postscript file, and then pipe that through a filter to the printer device, would work. Unfortunately most of it looks much more complicated than that, except for Postscript-compatible printers such as I don't have.)


----------



## wblock@ (Feb 10, 2012)

What kind of printers will you be able to use?  Office lasers pretty much always support at least PCL.  There's a PostScript to PCL filter in my article on lpd(8): lpd Printing With FreeBSD


----------



## GullibleJones (Feb 10, 2012)

Non-office end-user-oriented inkjet printers.  The kind that require special drivers on Windows, and don't work at all on current Linux distros because CUPS and usblp don't like each other.

More specifically, my printer at home is an HP Deskjet 842C. It's generally the one I use, but there have been occasions when I've used Canon or Lexmark printers... Generally, I want printers supported by Gutenprint (and HPLIP, etc.) to just work after being added in the CUPS web interface, without requiring hacks such as changing the permissions on specific USB device nodes.

(If that's not yet possible on FreeBSD, thank you nonetheless.)


----------



## GullibleJones (Feb 10, 2012)

Thanks for the link re converting Postscript to PLC BTW. Unfortunately that does not work for me at all; Ghostscript appears to produce some kind of runtime error, fragments of which are then printed.


----------



## wblock@ (Feb 10, 2012)

Many inkjets need proprietary, or at least weird, drivers that only CUPS provides.  However, devfs.rules(5) should let you set ulpt0 permissions automatically.  If not, devd.conf(5) certainly can do it.

Many average inkjets can't handle PCL, but gs(1) shouldn't die producing it.

http://www.openprinting.org/printers is a good source for finding what drivers support a given printer.


----------



## GullibleJones (Feb 10, 2012)

Thanks again...

I tried the CUPS setup earlier with only ulpt0 permissions altered, and got a permission denied error when trying to print. It looks like the usb/X.Y.Z node associated with the printer must in fact be altered. I will try again though, I might have done something wrong.


----------



## GullibleJones (Feb 10, 2012)

I tried again and it worked perfectly! I must have selected the wrong device last time. This time I just had devd change the permissions of lpt0, ulpt0, and unlpt0, and it printed.

Looks like my Linux days are over!


----------

