[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: usb issues in sarge: scanner, multicard



Hi Antonio,

AR> ls -l /etc/hotplug.d/usb
AR> -rwxr-xr-x  1 root root 535 2005-04-20 10:28 libsane.hotplug

That's the same as mine..

AR> and

AR> ls -lR /proc/bus/usb/
AR> /proc/bus/usb/002:
AR> total 0
AR> -rw-r--r--  1 root root 43 2005-08-13 07:27 001
AR> -rw-r--r--  1 root root 57 2005-08-13 07:27 002
AR> -rw-r--r--  1 root root 50 2005-08-13 07:27 003         <=

AR> My /proc/bus/usb/devices file shows the following (interesting that it
AR> is length 0, seems to be generated on the spot upon cat request):

It's not really a file "as we know it Jim", but a symbolic one, created by
the kernel. It looks like a file, though..

AR> T:  Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=12  MxCh= 0
AR> D:  Ver= 1.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1
AR> P:  Vendor=03f0 ProdID=0401 Rev= 1.00
AR> S:  Manufacturer=Hewlett-Packard
AR> S:  Product=HP ScanJet 5200C
AR> S:  SerialNumber=SG02CPEgina
AR> C:* #Ifs= 1 Cfg#= 1 Atr=60 MxPwr=  0mA
AR> I:  If#= 0 Alt= 0 #EPs= 3 Cls=00(>ifc ) Sub=00 Prot=00 Driver=(none)
AR> E:  Ad=81(I) Atr=02(Bulk) MxPS=  64 Ivl=0ms
AR> E:  Ad=02(O) Atr=02(Bulk) MxPS=  16 Ivl=0ms
AR> E:  Ad=83(I) Atr=03(Int.) MxPS=   1 Ivl=250ms

That't it alright :) It looks like it should be accessible through 
"/proc/bus/usb/002/003".

What counts here are "Vendor=03f0 ProdID=0401", with which the hotplug system
should try to find the right info. However, is the hotplug system active on
your system?
Assuming there is, do the following: check if the file following file exists:
"/etc/sane.d/hotplug/libsane.db". 
If it does, it should contain the line "0x03f0 0x0401 root:scanner 0660"
(the fields are tab-separated). 
If it doesn't, add it and try reconnecting your scanner. 
Note the field "root:scanner", that's the field describing the ownership of
the device. "0660" defines the access on it.

=> the file "/etc/sane.d/hotplug/libsane.db" comes with the "libsane" package.

If that doesn't help, we'll have to check if hotplug support is set up
properly:

1. check if "/proc/sys/kernel/hotplug" exists. Two options:
   a) it exists: continue;
   b) it doesn't: your kernel doesn't suport hotplugging. Do you use
      the stock 2.4/2.6 kernel?
2. check if ".../hotplug" contains "/sbin/hotplug":
   a) it does: continue;
   b) it does't: "echo "/sbin/hotplug > /proc/sys/kernel/hotplug";
3. Check if the file "/etc/hotplug/usb.rc" exists: 
   a) it does: continue;
   b) it doesn't: euh, I don't know. Did you install all the relevant
      packages?
4. Check the file "/etc/default/hotplug". There should *NOT* be a line
   saying: "HOTPLUG_RC_usb=no": 
   a) If there is: comment it out (place a "#" in front of the line) and
      execute the commands "/etc/init.d/hotplug stop" and 
      "/usr/init.d/hotplug start". This should do it? 
   b) continue :)

Hmm. Normally, the file "/etc/hotplug/usb.rc" will be called to perform
some actions to get your devices configured as desired. You can find out
more doing the next:

5. edit the file "/sbin/hotplug" and add, on the second line:
   "export DEBUG=1". Dis- and reconnect your scanner;
6) examine "/var/log/messages". It *should* say something :-)) Send in the
   relevant output (lines are marked with "default.hotplug")..

Regards,

  Bob



Reply to: