Printer Autodetection

brendan powers brendan0powers at gmail.com
Sun Nov 13 13:34:11 PST 2005


Hello,

I wrote some some software a little while ago that used hal to find
printers, and then determined their drivers from the foomatic driver
database. It occured to me that this would be a usefull feature for
hal to have. I looked at the hal 0.5.X spec and saw the printer
namespace. It would be very usefull to have these fields filled in by
the printers IEEE-1284 identifier. This identifier contains the
make,model, and languages this printer supports. This is very usefull
information to have when detecting printer drivers. the Foomatic
printer driver database has autodtect informatino for some printers
that maches the make/model of the IEEE-1284 string to a printer
driver. It would be trivial to conver the database into a set of FDI
files that would allow hal to show the appropriate driver, and a set
of alternate ones. Also, the languages information in the IEEE-1284
string can be used to mach a printer to a 'generic' driver on some
cases. Postscript or PCL compatible printers are a good example of
this. It is very easy to retrieve the printers IEEE-1284 string, for
parralel printers, there is a file in /sys(i think) that has the data,
for usb printers, you can use the 0x84005001 IOCTL to retrieve the
string. So i would think this would be fairly easy to implement. I
don't really know to much about hal internals, so how hard would this
be? Is it a good idea?

Thanks for you time.
Brendan Powers.
www.resara.com


More information about the hal mailing list