November 2, 2013

Run Docketport 467 Scanner under Linux

The Problem

I always wanted to get rid of my flatbed scanner and bought a DocketPORT 467, a tiny sheet fed scanner for small money on ebay.
But it didn't work out of the box under Linux (Ubuntu 12.04).
 Using the sane software tools, i was able to see that the scanner at least is detected:

found USB scanner (vendor=0x1dcc [Document Capture Technologies Inc.], product=0x4812 [DocketPORT 467], chip=GL842?) at libusb:001:003
  # Your USB scanner was (probably) detected. It may or may not be supported by
  # SANE. Try scanimage -L and read the backend's manpage.

When i try

 scanimage -L

i get

 No scanners were identified. If you were expecting something different,
check that the scanner is plugged in, turned on and detected by the
sane-find-scanner tool (if appropriate). Please read the documentation
which came with this software (README, FAQ, manpages)

basically the same happens when i start xsane (a graphical scanning programm).

What is wrong: it is the permissions! When i tried

sudo  xsane

the scanner was found and worked fine.
Because the permission situation, one is not allowed to use all usb devices available. 


1. lazy bum version 

just use "sudo xsane" to access the scanner. When you save the images, maybe you have to adjust the file user and group of scanned images afterwards.

2. make a udev rule

the permissions for usb devices can be adjusted writing rules for the udev (device daemon). You can place them in the folder /etc/udev/rules.d.

The file name must have the ending .rules and can be for example 90scanner.rules. It can be important that the number at the beginning is higher that the number of the other filenames, because the system reads the files according to the alphanumeric ordering.

Our file contains the following:

#usb scanner readable by me#
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1dcc", ATTRS{idProduct}=="4812", OWNER="THISisYOU"

(you have to change the owner (here THISisYOU) to your own username). Hint: Everything from "Subsystem" up to the end has to be put in one single line.

Now i was able to access and scan without sudo.


another variation of udev rules is described on the bottom of this page (paragraph "Permission problem"):