[Nut-upsuser] Problems with Unitek Alpha 1000 Ps

Jordi Moreno jmoreno at cim.es
Fri Jan 23 12:36:06 UTC 2009


Hello to all list members,

I'm trying to make my UPS work with nut-2.2.2 (using Debian Testing, but 
compiled from source code) for a week ago, with not success. It's a 
Unitek Alpha 1000Ps, and I supossed it would work with megatec_usb 
driver, as other Unitek models. It has an USB interface, and when I plug 
it into my system I've got this message:

chopito:/home/jordi# dmesg | tail -n4
input: WayTech Development(S) WayTech USB-RS232 Interface (V1.0)
Baud rate 2400bps as /class/input/input4
input: USB HID v1.00 Gamepad [WayTech Development(S) WayTech USB-RS232 
Interface (V1.0)
Baud rate 2400bps] on usb-0000:00:1d.1-2

So, apparently, it has an USB-HID interface. Output from lsusb:

chopito:/home/jordi# lsusb
Bus 005 Device 001: ID 0000:0000
Bus 002 Device 004: ID 0665:5161
Bus 002 Device 001: ID 0000:0000
Bus 004 Device 001: ID 0000:0000
Bus 003 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000

chopito:/home/jordi# lsusb -vvv -d 0665:5161

Bus 002 Device 004: ID 0665:5161
Device Descriptor:
   bLength                18
   bDescriptorType         1
   bcdUSB               1.00
   bDeviceClass            0 (Defined at Interface level)
   bDeviceSubClass         0
   bDeviceProtocol         0
   bMaxPacketSize0         8
   idVendor           0x0665
   idProduct          0x5161
   bcdDevice            0.01
   iManufacturer           1 WayTech Development(S)
   iProduct                2 WayTech USB-RS232 Interface (V1.0)
Baud rate 2400bps
   iSerial                 0
   bNumConfigurations      1
   Configuration Descriptor:
     bLength                 9
     bDescriptorType         2
     wTotalLength           34
     bNumInterfaces          1
     bConfigurationValue     1
     iConfiguration          3
     bmAttributes         0x80
       (Bus Powered)
     MaxPower              100mA
     Interface Descriptor:
       bLength                 9
       bDescriptorType         4
       bInterfaceNumber        0
       bAlternateSetting       0
       bNumEndpoints           1
       bInterfaceClass         3 Human Interface Devices
       bInterfaceSubClass      0 No Subclass
       bInterfaceProtocol      0 None
       iInterface              4
         HID Device Descriptor:
           bLength                 9
           bDescriptorType        33
           bcdHID               1.00
           bCountryCode            0 Not supported
           bNumDescriptors         1
           bDescriptorType        34 Report
           wDescriptorLength      35
          Report Descriptors:
            ** UNAVAILABLE **
       Endpoint Descriptor:
         bLength                 7
         bDescriptorType         5
         bEndpointAddress     0x81  EP 1 IN
         bmAttributes            3
           Transfer Type            Interrupt
           Synch Type               None
           Usage Type               Data
         wMaxPacketSize     0x0008  1x 8 bytes
         bInterval              10
Device Status:     0x0000
   (Bus Powered)

When I try to make it work with megatec_usb, I get the following output:

chopito:/usr/local/ups# bin/megatec_usb -DDDDD -a unitek -u root -x 
vendorid=0665 -x productid=5161
Network UPS Tools 2.2.2 - Megatec protocol driver 1.5.14 [megatec_usb]
Carlos Rodrigues (c) 2003-2008

Serial-over-USB transport layer for Megatec protocol driver [megatec_usb]
Andrey Lelikov (c) 2006, Alexander Gordeev (c) 2006-2007, Jon Gough (c) 2007

debug level is '5'
Checking device (0000/0000) (005/001)
- VendorID: 0000
- ProductID: 0000
- Manufacturer: Linux 2.6.22-2-686 ehci_hcd
- Product: EHCI Host Controller
- Serial Number: 0000:00:1d.7
- Bus: 005
Trying to match device
Device does not match - skipping
Checking device (0665/5161) (002/005)
- VendorID: 0665
- ProductID: 5161
- Manufacturer: WayTech Development(S)
- Product: WayTech USB-RS232 Interface (V1.0)
Baud rate 2400bps
- Serial Number: unknown
- Bus: 002
Trying to match device
Device matches
get_data_agiler: raw dump: (0 bytes) =>
Starting UPS detection process...
Asking for UPS status [Q1]...
get_data_agiler: raw dump: (0 bytes) =>
get_data_agiler: raw dump: (8 bytes) => 30 30 31 30 30 30 0d 00
Q1 => FAILED [short read]
Q1 detail: (6 bytes) => 30 30 31 30 30 30
Asking for UPS status [Q1]...
get_data_agiler: raw dump: (0 bytes) =>
get_data_agiler: raw dump: (8 bytes) => 30 30 31 30 30 30 0d 00
Q1 => FAILED [short read]
Q1 detail: (6 bytes) => 30 30 31 30 30 30
Asking for UPS status [Q1]...
get_data_agiler: raw dump: (0 bytes) =>
get_data_agiler: raw dump: (8 bytes) => 30 30 31 30 30 30 0d 00
Q1 => FAILED [short read]
Q1 detail: (6 bytes) => 30 30 31 30 30 30
Asking for UPS status [Q1]...
get_data_agiler: raw dump: (0 bytes) =>
get_data_agiler: raw dump: (8 bytes) => 30 30 31 30 30 30 0d 00
Q1 => FAILED [short read]
Q1 detail: (6 bytes) => 30 30 31 30 30 30
Asking for UPS status [Q1]...
get_data_agiler: raw dump: (0 bytes) =>
get_data_agiler: raw dump: (8 bytes) => 30 30 31 30 30 30 0d 00
Q1 => FAILED [short read]
Q1 detail: (6 bytes) => 30 30 31 30 30 30
5 out of 5 detection attempts failed (minimum failures: 2).
Megatec protocol UPS not detected.

Trying with usbhid-ups:

chopito:/usr/local/ups# bin/usbhid-ups -DDDDD -a unitek -u root -x 
vendorid=0665 -x productid=5161 -x explore
Network UPS Tools: 0.29 USB communication driver - core 0.33 (2.2.2)

...
Checking device (0665/5161) (002/005)
- VendorID: 0665
- ProductID: 5161
- Manufacturer: WayTech Development(S)
- Product: WayTech USB-RS232 Interface (V1.0)
Baud rate 2400bps
- Serial Number: unknown
- Bus: 002
Trying to match device
Device matches
HID descriptor, method 1: (9 bytes) => 09 21 00 01 00 01 22 23 00
i=0, extra[i]=09, extra[i+1]=21
HID descriptor, method 2: (9 bytes) => 09 21 00 01 00 01 22 23 00
HID descriptor length 35
Report Descriptor size = 35
Report Descriptor: (35 bytes) => 05 01 09 05 a1 01 05 09 19 01 29 40 15 00
  25 01 75 01 95 40 81 02 05 08 19 01 29 40 75 01 95 40 91 02 c0
Failed to parse report descriptor!: Inappropriate ioctl for device
Caller doesn't like this device
...

So, can I try a different driver? Could be this UPS supported by NUT? I 
can give strace information too, but I don't want to make my mail 
longer! Sorry, but I'm a bit desperate... I have searched the web and 
didn't found any information about this UPS.

Thanks in advance for any help...





More information about the Nut-upsuser mailing list