From owner-freebsd-doc@FreeBSD.ORG Wed Oct 30 21:11:56 2013 Return-Path: Delivered-To: freebsd-doc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 04466AE5 for ; Wed, 30 Oct 2013 21:11:56 +0000 (UTC) (envelope-from juris.kaminskis@gmail.com) Received: from mail-wg0-x234.google.com (mail-wg0-x234.google.com [IPv6:2a00:1450:400c:c00::234]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8273823FB for ; Wed, 30 Oct 2013 21:11:55 +0000 (UTC) Received: by mail-wg0-f52.google.com with SMTP id k14so1920113wgh.7 for ; Wed, 30 Oct 2013 14:11:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=ANCCFgPlacXCsSTZHufwD47c1ZcbANNvdGTi2XaFwNo=; b=CGZqsIxYa4nMHeMih3gCgdrFSxaAgNVSQyn0aryWyYtzOW+wlXW17Bu+vDt1rohB80 VzU8PCCX7jQmaR4RSGtJp3QntGY2c/UlYu0J3ZVv8U3h1KjKtV8rRlZzfZsjdh2aepl3 JPUo5gz8i3A2PbDsT/ArEdi8s6bbtdGXTTPpXkgEK4POgfghYtwk1ZaFAeEfqh0XqdAq PUa0vnTerG2CcM286HqxkWZXEH7Q6d/SqbAqgp42X32IDKHckv+ssp7sC2OAEA62WiM8 KrfzMkMGCvgqEL180Qp9TS1SrVxPrjJyR25VuvsSGP03XUPa4mzx0uUMDrhege+LsQTK Cb9Q== MIME-Version: 1.0 X-Received: by 10.194.94.167 with SMTP id dd7mr4561724wjb.43.1383167513801; Wed, 30 Oct 2013 14:11:53 -0700 (PDT) Received: by 10.194.185.101 with HTTP; Wed, 30 Oct 2013 14:11:53 -0700 (PDT) Date: Wed, 30 Oct 2013 23:11:53 +0200 Message-ID: Subject: TODO item: Add info on USB printers From: Juris Kaminskis To: freebsd-doc@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 30 Oct 2013 21:11:56 -0000 Hi, 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=AE or other printer language, then se= nd 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=AE. To tes= t communication create a file first in a format printer understands. Many variants exist use Ghostscript and/or foo2zjs to convert PostScript=AE file= s. Example: HP Laserjet M1120 uses XQX protocol http://foo2xqx.rkkda.com/ Install foo2zjs port (includes foo2xqx) Create a test PostScript=AE file (any decent program will print a PostScrip= t=AE file). Foo2xqx converts pbmraw file into xqx format, thus first convert PostScript=AE file to pbmraw format: gs -sDEVICE=3Dpbmraw -sOutputFile=3DYourFileName.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. thanks Juris