[Nut-upsdev] ORVALDI 650/750/900SP.
Paweł Sikora
pluto at agmk.net
Mon Oct 25 18:53:14 UTC 2010
hi,
i've bought a 750VA orvaldi ups http://en.orvaldi.com/index.php/en/product_catalog/product_view/11/162
which holds my hardware (wifi router, cable modem, quad-core with raid and lcd monitor) for ~15 minutes.
pretty nice result for a cheap (~57 euro) home ups.
in fact, the vendor software for linux is very old (e.g. requires ancient redhat with qt2),
requires db9 port while shipped product has serial-over-usb converter,
so the nut package is my only hope in this area.
afaics in other orvaldi's data sheets they use megatec protocol, so i've tested followinf scenario:
1). connect usb cable to ups.
/* on fresh 2.6.36 kernel from git */
Oct 25 20:00:09 localhost kernel: [33773.726642] usb 7-2: new low speed USB device using uhci_hcd and address 3
Oct 25 20:00:09 localhost kernel: [33773.922008] usb 7-2: New USB device found, idVendor=0665, idProduct=5161
Oct 25 20:00:09 localhost kernel: [33773.922011] usb 7-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
Oct 25 20:00:09 localhost kernel: [33773.922014] usb 7-2: Product: WayTech USB-RS232 Interface (V1.0)
Oct 25 20:00:09 localhost kernel: [33773.922015] Baud rate 2400bps
Oct 25 20:00:09 localhost kernel: [33773.993071] input: WayTech USB-RS232 Interface (V1.0)
Oct 25 20:00:09 localhost kernel: [33773.993073] Baud rate 2400bps as /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input9
Oct 25 20:00:09 localhost kernel: [33773.993218] generic-usb 0003:0665:5161.0005: input,hidraw3: USB HID v1.10 Gamepad [WayTech USB-RS232 Interface (V1.0)
Oct 25 20:00:09 localhost kernel: [33773.993219] Baud rate 2400bps] on usb-0000:00:1d.1-2/input0
2). add [orvaldi] entry to /etc/ups/ups.conf:
[orvaldi]
driver = megatec_usb
port = /dev/input/by-id/usb-0665_WayTech_USB-RS232_Interface__V1.0__Baud_rate_2400bps-event-if00
^^^^ this is a udev-maintained symlink to proper /dev/input/eventX.
desc = "Orvaldi"
3). test the driver:
# /lib/nut/upsdrvctl -u root -D start orvaldi
Network UPS Tools - UPS driver controller 2.4.3
0.000000 Starting UPS: orvaldi
Network UPS Tools - Megatec protocol driver 1.6 (2.4.3)
Serial-over-USB transport layer 0.10
45.000128 Startup timer elapsed, continuing...
ser_get_line: Device detached? (error -1: Connection timed out)
Successfully reconnected
ser_get_line: Device detached? (error -1: Connection timed out)
Successfully reconnected
ser_get_line: Device detached? (error -1: Connection timed out)
Successfully reconnected
Megatec protocol UPS not detected.
in dmesg i see only:
(...)
[33932.034568] usb 7-2: usbfs: process 7697 (megatec_usb) did not claim interface 0 before use
(...)
lsusb -v reports cypress converter:
Bus 007 Device 003: ID 0665:5161 Cypress Semiconductor USB to Serial
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 1.10
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 8
idVendor 0x0665 Cypress Semiconductor
idProduct 0x5161 USB to Serial
bcdDevice 0.00
iManufacturer 1
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 Device
bInterfaceSubClass 0 No Subclass
bInterfaceProtocol 0 None
iInterface 4
HID Device Descriptor:
bLength 9
bDescriptorType 33
bcdHID 1.10
bCountryCode 0 Not supported
bNumDescriptors 1
bDescriptorType 34 Report
wDescriptorLength 35
Report Descriptor: (length is 35)
Item(Global): Usage Page, data= [ 0x01 ] 1
Generic Desktop Controls
Item(Local ): Usage, data= [ 0x05 ] 5
Gamepad
Item(Main ): Collection, data= [ 0x01 ] 1
Application
Item(Global): Usage Page, data= [ 0x09 ] 9
Buttons
Item(Local ): Usage Minimum, data= [ 0x01 ] 1
Button 1 (Primary)
Item(Local ): Usage Maximum, data= [ 0x40 ] 64
(null)
Item(Global): Logical Minimum, data= [ 0x00 ] 0
Item(Global): Logical Maximum, data= [ 0x01 ] 1
Item(Global): Report Size, data= [ 0x01 ] 1
Item(Global): Report Count, data= [ 0x40 ] 64
Item(Main ): Input, data= [ 0x02 ] 2
Data Variable Absolute No_Wrap Linear
Preferred_State No_Null_Position Non_Volatile Bitfield
Item(Global): Usage Page, data= [ 0x08 ] 8
LEDs
Item(Local ): Usage Minimum, data= [ 0x01 ] 1
NumLock
Item(Local ): Usage Maximum, data= [ 0x40 ] 64
Indicator Fast Blink
Item(Global): Report Size, data= [ 0x01 ] 1
Item(Global): Report Count, data= [ 0x40 ] 64
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
Device Status: 0x0000
(Bus Powered)
from the other side, there's a working windows software installed on my laptop.
i can sniff it with your help to provide required info for further nut development.
BR,
Pawel.
More information about the Nut-upsdev
mailing list