IEEE1284 Device ID string for USB Printers

Naram Qashat cyberbotx at cyberbotx.com
Thu Mar 16 20:13:05 UTC 2006


Well, I don't have a Linux machine to see exactly what is needed, but
HPLIP's hpiod is looking for that IEEE1284 Device ID, which I believe starts
off with MFG: or MANUFACTURER: followed by the maker of the product.  HPLIP
tries to get the device ID by using an IOCTL on the device, specifically,
it's sending LPIOC_GET_DEVICE_ID(maxSize) [where maxSize is either the size
sent to the function or 1024, whichever is smaller, and LPIOC_GET_DEVICE_ID
is a macro that is set to _IOC(_IOC_READ, 'P', IOCNR_GET_DEVICE_ID, len)
with IOCNR_GET_DEVICE_ID #define'd to 1], and it passes a character pointer
as a buffer.  But FreeBSD doesn't let you do that on an u?lpt* device, and
trying it on the root usb device doesn't get the information that is needed.

I noticed in the ulpt.c source that the function ieee1284_print_id() is
commented out with #if 0, and earlier in the file where it's called, it says
that trying to retrieve the ID causes printing to stop working.  I don't
know enough about it to know why.

I'm not sure if there is more needed by HPLIP to get the driver to work, but
I've narrowed it down to this.

Naram Qashat
----- Original Message ----- 
From: "M. Warner Losh" <imp at bsdimp.com>
To: <cyberbotx at cyberbotx.com>
Cc: <freebsd-usb at freebsd.org>
Sent: Thursday, March 16, 2006 01:10 PM
Subject: Re: IEEE1284 Device ID string for USB Printers


> In message: <107401c6486b$773e9b10$fe02a8c0 at metroid>
>             "Naram Qashat" <cyberbotx at cyberbotx.com> writes:
> : I was wondering if there were any plans on getting the
ieee1284_print_id()
> : function in src/sys/dev/usb/ulpt.c to work properly.  I was trying to
see
> : about getting HPLIP converted to FreeBSD, but it's hpiod program
requires an
> : ioctl to access the printer andget the IEEE1284 device ID string to
identify
> : the USB printer.  Without that ioctl, HPLIP can't be ported over.
>
> What would it take to get working properly?
>
> Warner



More information about the freebsd-usb mailing list