TODO item: Add info on USB printers
Warren Block
wblock at wonkity.com
Wed Oct 30 23:18:57 UTC 2013
Forgot to send this to the list also...
On Wed, 30 Oct 2013, Warren Block wrote:
> On Wed, 30 Oct 2013, Juris Kaminskis wrote:
>>
>> Some first trial to create better coverage for USB printing support in
>> FreeBSD documentation. There are some more chapters to revise but this is
>> definetly one:
>>
>> 10.3.1.4.1. Checking a Parallel and USB Printer
>>
>> This section tells you how to check if FreeBSD can communicate with a
>> printer connected to a parallel or USB port.
>>
>> To test a printer on a parallel port use /dev/lptN on a USB port use
>> /dev/ulptN::
>>
>> Become root with su(1).
>>
>> Send data to the printer.
>>
>> If the printer can print plain text, then use lptest(1). Type:
>>
>> # lptest > /dev/lptN
>>
>> Where N is the number of the parallel port, starting from zero. For USB
>> port /dev/ulptN, N number identifies how many USB printers are connected,
>> if zero then one printer connected.
>>
>> If the printer understands PostScript® or other printer language, then send
>> a small program to the printer. Type:
>>
>> # cat > /dev/lptN
>>
>> Then, line by line, type the program carefully as you cannot edit a line
>> once you have pressed RETURN or ENTER. When you have finished entering the
>> program, press CONTROL+D, or whatever your end of file key is.
>>
>> Alternatively, you can put the program in a file and type:
>>
>> # cat file > /dev/lptN
>>
>> Where file is the name of the file containing the program you want to send
>> to the printer.
>>
>> 10.3.1.4.1.1. Testing printers with special wire protocols
>>
>> Many printers use different wire protocols instead of PostScript®. To test
>> communication create a file first in a format printer understands. Many
>> variants exist use Ghostscript and/or foo2zjs to convert PostScript® files.
>>
>> Example:
>>
>> HP Laserjet M1120 uses XQX protocol http://foo2xqx.rkkda.com/
>>
>> Install foo2zjs port (includes foo2xqx)
>>
>> Create a test PostScript® file (any decent program will print a PostScript®
>> file). Foo2xqx converts pbmraw file into xqx format, thus first
>> convert PostScript®
>> file to pbmraw format:
>>
>> gs -sDEVICE=pbmraw -sOutputFile=YourFileName.pbm YourFile
>>
>> And convert outputfile to xqx wire:
>>
>> foo2xqx YourFileName.pbm > YourFileName.xqx
>>
>> Last check if something prints:
>>
>> cat YourFileName.xqx > /dev/ulptN
>>
>> You should see something print. Do not worry if the text does not look
>> right; we will fix such things later.
>>
>>
>> Is there someone who can help me to review this and put into documentation?
>> After that I will take a look what else requires update to cover USB
>> printing.
>
> Thank you for working on this. The entire printing chapter really needs a
> rewrite, and I've been meaning to write an outline for what a new printing
> chapter should cover. In the meantime, please look at
> http://www.wonkity.com/~wblock/docs/html/lpdprinting.html and see if it is
> adequate in the meantime.
More information about the freebsd-doc
mailing list