[Nut-upsdev] HAL and NUT feedback

Arnaud Quette aquette.dev at gmail.com
Fri Jun 1 12:26:33 UTC 2007


[was: svn commit r915 - in trunk: . drivers]

Hi Kjell,

sorry, I'm still much late in emptying my mail stack...

2007/5/25, Kjell Claesson <kjell.claesson at epost.tidanet.se>:
> Den Friday 25 May 2007 08.52.20 skrev Arnaud Quette:
> >
> > I would be interested in some more info:
> > - lshal -u <your device's UDI>
> > the UDI can be obtained for ex. through hal-device-manager
>
> lshal -lu /org/freedesktop/Hal/devices/usb_device_592_2_noserial
> udi = '/org/freedesktop/Hal/devices/usb_device_592_2_noserial'
>   ac_adaptor.present = true  (bool)
>   battery.charge_level.design = 100  (0x64)  (int)
>   battery.charge_level.last_full = 100  (0x64)  (int)
>   battery.charge_level.unit = 'percent'  (string)
>   battery.is_rechargeable = true  (bool)
>   battery.model = 'POWERWARE UPS    500VA'  (string)
>   battery.present = true  (bool)
>   battery.rechargeable.is_charging = true  (bool)
>   battery.rechargeable.is_discharging = false  (bool)
>   battery.reporting.design = 100  (0x64)  (int)
>   battery.reporting.last_full = 100  (0x64)  (int)
>   battery.reporting.unit = 'percent'  (string)
>   battery.serial = ''  (string)
>   battery.type = 'ups'  (string)
>   battery.voltage.unit = 'V'  (string)
>   info.addons = {'hald-addon-bcmxcp_usb'} (string list)
>   info.bus = 'usb_device'  (string)
>   info.capabilities = {'battery', 'ac_adaptor'} (string list)
>   info.category = 'battery'  (string)
>   info.is_recalled = false  (bool)
>   info.linux.driver = 'usb'  (string)
>   info.parent = '/org/freedesktop/Hal/devices/usb_device_0_0_0000_00_07_2'
> (string)
>   info.product = 'Powerware UPS'  (string)
>   info.subsystem = 'usb_device'  (string)
>   info.udi = '/org/freedesktop/Hal/devices/usb_device_592_2_noserial'
> (string)
>   info.vendor = 'Powerware Corp.'  (string)
>   linux.hotplug_type = 2  (0x2)  (int)
>   linux.subsystem = 'usb'  (string)
>   linux.sysfs_path = '/sys/devices/pci0000:00/0000:00:07.2/usb1/1-1'  (string)
>   usb_device.bus_number = 1  (0x1)  (int)
>   usb_device.can_wake_up = true  (bool)
>   usb_device.configuration_value = 1  (0x1)  (int)
>   usb_device.device_class = 0  (0x0)  (int)
>   usb_device.device_protocol = 0  (0x0)  (int)
>   usb_device.device_revision_bcd = 128  (0x80)  (int)
>   usb_device.device_subclass = 0  (0x0)  (int)
>   usb_device.is_self_powered = true  (bool)
>   usb_device.linux.device_number = 2  (0x2)  (int)
>   usb_device.linux.sysfs_path
> = '/sys/devices/pci0000:00/0000:00:07.2/usb1/1-1'  (string)
>   usb_device.max_power = 2  (0x2)  (int)
>   usb_device.num_configurations = 1  (0x1)  (int)
>   usb_device.num_interfaces = 1  (0x1)  (int)
>   usb_device.num_ports = 0  (0x0)  (int)
>   usb_device.product = 'Powerware UPS'  (string)
>   usb_device.product_id = 2  (0x2)  (int)
>   usb_device.speed = 1.5 (1.5) (double)
>   usb_device.speed_bcd = 336  (0x150)  (int)
>   usb_device.vendor = 'Powerware Corp.'  (string)
>   usb_device.vendor_id = 1426  (0x592)  (int)
>   usb_device.version = 2.0 (2) (double)
>   usb_device.version_bcd = 512  (0x200)  (int)
>
> usb2 device but run on a usb1.1 port.
>
> > - an upsc output of your device.
> > - some details about your device capabilities in therm of delayed
> > shutdown, and status reporting (ie, is it reporting only ups.status?)
> >
> upsc pw3105 at localhost
> driver.name: bcmxcp_usb
> driver.parameter.pollinterval: 2
> driver.parameter.port: auto
> driver.parameter.shutdown_delay: 60
> driver.version: 2.1.0
> driver.version.internal: 0.11
> output.phases: 1
> ups.alarm:
> ups.firmware: Cont:00.80 Inve:00.60
> ups.model: POWERWARE UPS    500VA
> ups.power.nominal: 500
> ups.serial:
> ups.status: OL
> ups.voltage.nominal: 230
>
> Alarms supported:
> 0000    BATTERY_LOW     Yes
> 0001    UTILITY_FAIL    Yes
> 0002    UPS_ON_BATTERY  Yes
>
> Shutdow delay (runtime after OB LB) seems to be locked to 60 sec.
> This may be set to another value, but this and load-block switching
> is on my TODO list. I need another ups to do the testing.

oh, a dumb USB unit! interesting. Though I'm not sure of the exact
support level we'll have with HAL. But it gives me more visibility,
and that's a good point. thanks.

> > I lack much visibility on our supported devices capabilities to make
> > some implementation decisions...
> >
> The output from a PW5115 would show more data.

I'm interested in...

> > One more note: I'm convinced that the nut future lies in such approach.
> > This combined with some legacy support (discussed with D. Zeuthen, the
> > HAL PL, to configure manually the support for serial devices) and some
> > avahi servicing should give a great deal of user experience.
> Yes, I think this is the right move. One more thing to make Linux a user
> friendly system.

even more friendly than its competitors I would say ;-)
and not only linux, but also our *bsd and solaris cousins too...

> > You (and others) are very welcome to give me a hand on this.
> > There are areas (such as avahi, the network servicing, the common
> > power management namespace, ...). I haven't yet had time to give much
> > love.
> >
>
> The problem is time. Children, house, garden, work..... my own TODO list, so
> hard to say how much i can contribute to this.

testing and reporting is a good contrib for me, since I only own MGE
(and maybe soon APC?!)

thanks again,
Arnaud
-- 
Linux / Unix Expert - MGE UPS SYSTEMS - R&D Dpt
Network UPS Tools (NUT) Project Leader - http://www.networkupstools.org/
Debian Developer - http://people.debian.org/~aquette/
OpenSource Developer - http://arnaud.quette.free.fr/



More information about the Nut-upsdev mailing list