[Nut-upsuser] Problem detecting USB/HID UPS
Charles Lepple
clepple at gmail.com
Thu Aug 17 13:01:03 UTC 2006
On 8/17/06, Brian Foster <penguinator781 at gmail.com> wrote:
> Hi all,
> I guess this is more for the development side of things, rather than for
> my own benefit:
> In response to the permission problems I was experiencing, I looked at
> the udevinfo output for my Tripplite SMART1200LCD, and this is all it
> gives me:
>
> brifo at thebeast:/$ udevinfo -q all -p /class/usb_device/usbdev1.18
> P: /class/usb_device/usbdev1.18
> N: bus/usb/001/018
> E: USB_BUS=001
> E: USB_DEV=018
Try adding an '-a' after 'udevinfo'.
> man udevinfo states that these are the attributes that can be used when
> making rules for the udev .rules files.
I think this meant "the attributes *from the database*", but
apparently udev also allows rules to query sysfs itself.
This is what I get:
$ udevinfo -q all -a -p /class/usb_device/usbdev2.6
udevinfo starts with the device the node belongs to and then walks up the
device chain, to print for every device found, all possibly useful attributes
in the udev key format.
Only attributes within one device section may be used together in one rule,
to match the device for which the node will be created.
looking at device '/class/usb_device/usbdev2.6':
KERNEL=="usbdev2.6"
SUBSYSTEM=="usb_device"
SYSFS{dev}=="189:133"
looking at device '/devices/pci0001:10/0001:10:19.0/usb2/2-1/2-1.2':
ID=="2-1.2"
BUS=="usb"
DRIVER=="usb"
SYSFS{configuration}==""
SYSFS{product}=="Evolution"
SYSFS{manufacturer}=="MGE UPS SYSTEMS"
SYSFS{maxchild}=="0"
SYSFS{version}==" 1.10"
SYSFS{devnum}=="6"
SYSFS{speed}=="1.5"
SYSFS{bMaxPacketSize0}=="8"
SYSFS{bNumConfigurations}=="1"
SYSFS{bDeviceProtocol}=="00"
SYSFS{bDeviceSubClass}=="00"
SYSFS{bDeviceClass}=="00"
SYSFS{bcdDevice}=="0001"
SYSFS{idProduct}=="ffff"
SYSFS{idVendor}=="0463"
SYSFS{bMaxPower}==" 20mA"
SYSFS{bmAttributes}=="a0"
SYSFS{bConfigurationValue}=="1"
SYSFS{bNumInterfaces}==" 1"
[some information about hubs and host controllers snipped]
--
- Charles Lepple
More information about the Nut-upsuser
mailing list