[Nut-upsuser] Unable to get NUT working
Pierluigi Frullani
pierluigi.frullani at gmail.com
Fri May 15 18:53:33 BST 2020
Hi all,
just landed here so apologize. I've googled a lot but I can't find a way
to get my UPS working with NUT.
here my ( relevant ) details:
lsusb
...
...
Bus 001 Device 027: ID 0001:0000 Fry's Electronics
...
...
lsusb -v -d 0001:0000
Bus 001 Device 027: ID 0001:0000 Fry's Electronics
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 0
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 8
idVendor 0x0001 Fry's Electronics
idProduct 0x0000
bcdDevice 0.00
iManufacturer 1 ATCL FOR UPS
iProduct 1 ATCL FOR UPS
iSerial 1 ATCL FOR UPS
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 0x0029
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xe0
Self Powered
Remote Wakeup
MaxPower 98mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 3 Human Interface Device
bInterfaceSubClass 0
bInterfaceProtocol 0
iInterface 0
HID Device Descriptor:
bLength 9
bDescriptorType 33
bcdHID 1.11
bCountryCode 0 Not supported
bNumDescriptors 1
bDescriptorType 34 Report
wDescriptorLength 32
Report Descriptor: (length is 32)
Item(Global): Usage Page, data= [ 0xa0 0xff ] 65440
(null)
Item(Local ): Usage, data= [ 0x01 ] 1
(null)
Item(Main ): Collection, data= [ 0x01 ] 1
Application
Item(Local ): Usage, data= [ 0x03 ] 3
(null)
Item(Global): Logical Minimum, data= [ 0x00 ] 0
Item(Global): Logical Maximum, data= [ 0x01 ] 1
Item(Global): Report Size, data= [ 0x08 ] 8
Item(Global): Report Count, data= [ 0x08 ] 8
Item(Main ): Input, data= [ 0x02 ] 2
Data Variable Absolute No_Wrap Linear
Preferred_State No_Null_Position Non_Volatile
Bitfield
Item(Local ): Usage, data= [ 0x04 ] 4
(null)
Item(Global): Logical Minimum, data= [ 0x00 ] 0
Item(Global): Logical Maximum, data= [ 0x01 ] 1
Item(Global): Report Size, data= [ 0x08 ] 8
Item(Global): Report Count, data= [ 0x08 ] 8
Item(Main ): Output, data= [ 0x02 ] 2
Data Variable Absolute No_Wrap Linear
Preferred_State No_Null_Position Non_Volatile
Bitfield
Item(Main ): End Collection, data=none
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
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x02 EP 2 OUT
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0008 1x 8 bytes
bInterval 10
can't get device qualifier: Resource temporarily unavailable
can't get debug descriptor: Resource temporarily unavailable
Device Status: 0x0000
(Bus Powered)
I've tried the nut-scanner:
topolinux root /usr/local/nut/bin# ./nut-scanner
Scanning USB bus.
No start IP, skipping NUT bus (old connect method)
[nutdev1]
driver = "nutdrv_atcl_usb"
port = "auto"
vendorid = "0001"
productid = "0000"
product = "ATCL FOR UPS"
serial = "ATCL FOR UPS"
vendor = "ATCL FOR UPS"
bus = "001"
So I configure ups.conf:
more ups.conf
[myups]
driver = "nutdrv_atcl_usb"
port = auto
vendorid=0001
and try to start:
root /usr/local/nut/etc# ../bin/nutdrv_atcl_usb -a myups -DDD -x vendor=0001
Network UPS Tools - 'ATCL FOR UPS' USB driver 1.1 (2.7.4)
Warning: This is an experimental driver.
Some features may not function correctly.
Fatal error: 'vendorid' is not a valid variable name for this driver.
Look in the man page or call this driver with -h for a list of
valid variable names and flags.
I then remove vendorid.
more ups.conf
[myups]
driver = "nutdrv_atcl_usb"
port = auto
#vendorid=0001
and now it somewhat works:
root /usr/local/nut/etc# ../bin/nutdrv_atcl_usb -a myups -DDDD
Network UPS Tools - 'ATCL FOR UPS' USB driver 1.1 (2.7.4)
Warning: This is an experimental driver.
Some features may not function correctly.
0.000000 debug level is '4'
0.001636 Searching for USB device...
0.007382 Checking USB device [05ac:8242] (002/003)
0.007422 Failed to open USB device, skipping: Permission denied
0.007433 Checking USB device [0424:2513] (002/002)
0.007446 Failed to open USB device, skipping: Permission denied
0.007453 Checking USB device [1d6b:0002] (002/001)
0.007463 Failed to open USB device, skipping: Permission denied
0.007470 Checking USB device [1d6b:0001] (004/001)
0.007481 Failed to open USB device, skipping: Permission denied
0.007495 Checking USB device [05ac:8509] (001/003)
0.007511 Failed to open USB device, skipping: Permission denied
0.007528 Checking USB device [0001:0000] (001/027)
0.011866 - VendorID : 0001
0.011919 - ProductID : 0000
0.011941 - Manufacturer : ATCL FOR UPS
0.011967 - Product : ATCL FOR UPS
0.011996 - Serial Number: ATCL FOR UPS
0.012007 - Bus : 001
0.012023 Matched expected vendor='ATCL FOR UPS'.
0.012428 USB device [0001:0000] opened
5.014618 status interrupt read: Connection timed out
5.014664 Communications with UPS lost: Query to UPS failed
5.014859 dstate_init: sock /var/state/ups/nutdrv_atcl_usb-myups open
on fd 10
5.014959 Checking USB device [05ac:8242] (002/003)
5.014994 Failed to open USB device, skipping: Permission denied
5.015005 Checking USB device [0424:2513] (002/002)
5.015022 Failed to open USB device, skipping: Permission denied
5.015032 Checking USB device [1d6b:0002] (002/001)
5.015047 Failed to open USB device, skipping: Permission denied
5.015069 Checking USB device [1d6b:0001] (004/001)
5.015112 Failed to open USB device, skipping: Permission denied
5.015134 Checking USB device [05ac:8509] (001/003)
5.015149 Failed to open USB device, skipping: Permission denied
5.015158 Checking USB device [0001:0000] (001/027)
5.019736 - VendorID : 0001
5.019767 - ProductID : 0000
5.019787 - Manufacturer : ATCL FOR UPS
5.019804 - Product : ATCL FOR UPS
5.019824 - Serial Number: ATCL FOR UPS
5.019851 - Bus : 001
5.019859 Matched expected vendor='ATCL FOR UPS'.
5.020208 USB device [0001:0000] opened
I have also tried with blazer_usb and nutdrv_qx.
With the former I get:
0.012149 Trying to match device
0.012194 Device matches
0.012224 nut_usb_set_altinterface: skipped
usb_set_altinterface(udev, 0)
0.012242 Trying megatec protocol...
0.012255 send: Q1
0.013044 read: Broken pipe
0.013543 Stall condition cleared
0.013564 blazer_status: short reply
0.013574 Status read 1 failed
0.013581 send: Q1
0.014632 read: Broken pipe
and with the latter:
0.007855 Trying to match device
0.007893 Device matches
0.007920 nut_usb_set_altinterface: skipped
usb_set_altinterface(udev, 0)
0.007944 command: (8 bytes) => 80 06 04 03 51 47 53 00
5.009814 send: Connection timed out (-110)
5.009856 qx_process_answer: short reply (input.voltage)
5.009884 command: (8 bytes) => 80 06 04 03 51 47 53 00
10.012265 send: Connection timed out (-110)
10.012298 qx_process_answer: short reply (input.voltage)
10.012313 command: (8 bytes) => 80 06 04 03 51 47 53 00
15.013766 send: Connection timed out (-110)
15.013804 qx_process_answer: short reply (input.voltage)
15.013815 command: (8 bytes) => 80 06 02 03 4d 00 00 00
Is there any change I get it working ?
I only need to know when the power has disconneted, nothing more.
Thanks in advance.
Pierluigi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20200515/1ccdb8b2/attachment.html>
More information about the Nut-upsuser
mailing list