Imported Upstream version 2.7.2

This commit is contained in:
Laurent Bigonville 2014-04-22 20:39:47 +02:00
parent 0121794af9
commit a356b56d11
263 changed files with 6039 additions and 8151 deletions

View file

@ -1,27 +1,28 @@
EXTRA_DIST = README \
avahi/nut.service.in \
HP-UX/nut-drvctl \
HP-UX/nut-drvctl.sh \
HP-UX/nut-upsd \
HP-UX/nut-upsd.sh \
HP-UX/nut-upsmon \
HP-UX/nut-upsmon.sh \
logrotate/nutlogd \
misc/nut.bash_completion \
misc/osd-notify \
perl/Nut.pm \
RedHat/halt.patch \
RedHat/README \
RedHat/ups \
RedHat/upsd \
RedHat/upsd.in \
RedHat/upsmon \
RedHat/upsmon.in \
Solaris8/S99upsmon \
subdriver/gen-usbhid-subdriver.sh \
ufw/README \
upower/95-upower-hid.rules \
Windows/halt.c \
Windows/Makefile
avahi/nut.service.in \
HP-UX/nut-drvctl \
HP-UX/nut-drvctl.sh \
HP-UX/nut-upsd \
HP-UX/nut-upsd.sh \
HP-UX/nut-upsmon \
HP-UX/nut-upsmon.sh \
logrotate/nutlogd \
misc/nut.bash_completion \
misc/osd-notify \
perl/Nut.pm \
RedHat/halt.patch \
RedHat/README \
RedHat/ups \
RedHat/upsd \
RedHat/upsd.in \
RedHat/upsmon \
RedHat/upsmon.in \
Solaris8/S99upsmon \
subdriver/gen-usbhid-subdriver.sh \
subdriver/gen-snmp-subdriver.sh \
ufw/README \
upower/95-upower-hid.rules \
Windows/halt.c \
Windows/Makefile
SUBDIRS = augeas hal hotplug python systemd udev Solaris
SUBDIRS = augeas devd hotplug python systemd udev Solaris

View file

@ -63,7 +63,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -73,10 +72,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@ -173,10 +171,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -188,8 +182,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -275,6 +267,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@
@ -317,32 +310,33 @@ top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
udevdir = @udevdir@
EXTRA_DIST = README \
avahi/nut.service.in \
HP-UX/nut-drvctl \
HP-UX/nut-drvctl.sh \
HP-UX/nut-upsd \
HP-UX/nut-upsd.sh \
HP-UX/nut-upsmon \
HP-UX/nut-upsmon.sh \
logrotate/nutlogd \
misc/nut.bash_completion \
misc/osd-notify \
perl/Nut.pm \
RedHat/halt.patch \
RedHat/README \
RedHat/ups \
RedHat/upsd \
RedHat/upsd.in \
RedHat/upsmon \
RedHat/upsmon.in \
Solaris8/S99upsmon \
subdriver/gen-usbhid-subdriver.sh \
ufw/README \
upower/95-upower-hid.rules \
Windows/halt.c \
Windows/Makefile
avahi/nut.service.in \
HP-UX/nut-drvctl \
HP-UX/nut-drvctl.sh \
HP-UX/nut-upsd \
HP-UX/nut-upsd.sh \
HP-UX/nut-upsmon \
HP-UX/nut-upsmon.sh \
logrotate/nutlogd \
misc/nut.bash_completion \
misc/osd-notify \
perl/Nut.pm \
RedHat/halt.patch \
RedHat/README \
RedHat/ups \
RedHat/upsd \
RedHat/upsd.in \
RedHat/upsmon \
RedHat/upsmon.in \
Solaris8/S99upsmon \
subdriver/gen-usbhid-subdriver.sh \
subdriver/gen-snmp-subdriver.sh \
ufw/README \
upower/95-upower-hid.rules \
Windows/halt.c \
Windows/Makefile
SUBDIRS = augeas hal hotplug python systemd udev Solaris
SUBDIRS = augeas devd hotplug python systemd udev Solaris
all: all-recursive
.SUFFIXES:

View file

@ -2,8 +2,6 @@ These directories hold various scripts:
- example startup and shutdown scripts for various operating systems and
distributions,
- hotplug and udev integration for on the fly privileges settings (Linux only),
- Hardware Abstraction Layer script, for declaring and binding NUT addons to
specific USB devices,
- UPower (previously DeviceKit-power) rules file,
- Python Client module and application,
- Perl client module,

View file

@ -65,7 +65,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -75,10 +74,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@ -135,10 +133,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -150,8 +144,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -237,6 +229,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@

View file

@ -12,7 +12,7 @@ fi
ups_stop () {
pkill -n upsmon
pkill -n upsd
${NUT_DIR}/bin/upsdrvctl stop > /dev/null 2>&1
${NUT_DIR}/sbin/upsdrvctl stop > /dev/null 2>&1
}
ups_start () {
@ -22,7 +22,7 @@ ups_start () {
fi
if [ ! "$MODE" = "netclient" ];then
$NUT_DIR/bin/upsdrvctl start #> /dev/null 2>&1
$NUT_DIR/sbin/upsdrvctl start #> /dev/null 2>&1
$NUT_DIR/sbin/upsd #> /dev/null 2>&1
fi
$NUT_DIR/sbin/upsmon #> /dev/null 2>&1
@ -49,7 +49,7 @@ case $1 in
$NUT_DIR/sbin/upsmon -K >/dev/null 2>&1
if [ $? = 0 ]; then
echo "Shutting down the UPS ..."
#$NUT_DIR/bin/upsdrvctl shutdown
#$NUT_DIR/sbin/upsdrvctl shutdown
fi
;;
*)

View file

@ -59,7 +59,7 @@ ln -s /etc/init.d/nut /etc/rc3.d/K100nut > /dev/null 2>&1
# Start nut services
#echo "Starting nut services"
#$NUT_DIR/bin/upsdrvctl start #> /dev/null 2>&1
#$NUT_DIR/sbin/upsdrvctl start #> /dev/null 2>&1
#$NUT_DIR/sbin/upsd #> /dev/null 2>&1
#$NUT_DIR/sbin/upsmon #> /dev/null 2>&1

View file

@ -4,5 +4,5 @@
NUT_DIR="@prefix@"
#$NUT_DIR/bin/upsdrvctl stop
#$NUT_DIR/sbin/upsdrvctl stop

View file

@ -68,7 +68,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -78,10 +77,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@ -140,10 +138,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -155,8 +149,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -242,6 +234,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@

14
scripts/devd/Makefile.am Normal file
View file

@ -0,0 +1,14 @@
if WITH_DEVD
devdconfdir = $(devddir)
devdconf_DATA =
if WITH_USB
devdconf_DATA += nut-usb.conf
endif
endif
EXTRA_DIST = README
DISTCLEANFILES = nut-usb.conf
# we should never remove this one, apart from a distclean-check
#MAINTAINERCLEANFILES = nut-usbups.rules.in

View file

@ -52,9 +52,10 @@ POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
target_triplet = @target@
subdir = scripts/hal
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
$(srcdir)/ups-nut-device.fdi.in
@WITH_DEVD_TRUE@@WITH_USB_TRUE@am__append_1 = nut-usb.conf
subdir = scripts/devd
DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
$(srcdir)/nut-usb.conf.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
@ -65,7 +66,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -75,15 +75,14 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/include/config.h
CONFIG_CLEAN_FILES = ups-nut-device.fdi
CONFIG_CLEAN_FILES = nut-usb.conf
CONFIG_CLEAN_VPATH_FILES =
SOURCES =
DIST_SOURCES =
@ -119,8 +118,8 @@ am__uninstall_files_from_dir = { \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(halfdidir)"
DATA = $(halfdi_DATA)
am__installdirs = "$(DESTDIR)$(devdconfdir)"
DATA = $(devdconf_DATA)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
A2X = @A2X@
ACLOCAL = @ACLOCAL@
@ -164,10 +163,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -179,8 +174,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -266,6 +259,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@
@ -307,13 +301,10 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
udevdir = @udevdir@
@WITH_HAL_TRUE@halfdidir = $(HAL_FDI_PATH)
@WITH_HAL_TRUE@halfdi_DATA = 20-ups-nut-device.fdi
EXTRA_DIST = ups-nut-device.fdi.in
DISTCLEANFILES = ups-nut-device.fdi
# we should never remove this one, apart from a distclean-check
#MAINTAINERCLEANFILES = ups-nut-device.fdi.in
CLEANFILES = 20-ups-nut-device.fdi
@WITH_DEVD_TRUE@devdconfdir = $(devddir)
@WITH_DEVD_TRUE@devdconf_DATA = $(am__append_1)
EXTRA_DIST = README
DISTCLEANFILES = nut-usb.conf
all: all-am
.SUFFIXES:
@ -326,9 +317,9 @@ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__confi
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu scripts/hal/Makefile'; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu scripts/devd/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu scripts/hal/Makefile
$(AUTOMAKE) --gnu scripts/devd/Makefile
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
@ -347,7 +338,7 @@ $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
ups-nut-device.fdi: $(top_builddir)/config.status $(srcdir)/ups-nut-device.fdi.in
nut-usb.conf: $(top_builddir)/config.status $(srcdir)/nut-usb.conf.in
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
mostlyclean-libtool:
@ -355,27 +346,27 @@ mostlyclean-libtool:
clean-libtool:
-rm -rf .libs _libs
install-halfdiDATA: $(halfdi_DATA)
install-devdconfDATA: $(devdconf_DATA)
@$(NORMAL_INSTALL)
@list='$(halfdi_DATA)'; test -n "$(halfdidir)" || list=; \
@list='$(devdconf_DATA)'; test -n "$(devdconfdir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(halfdidir)'"; \
$(MKDIR_P) "$(DESTDIR)$(halfdidir)" || exit 1; \
echo " $(MKDIR_P) '$(DESTDIR)$(devdconfdir)'"; \
$(MKDIR_P) "$(DESTDIR)$(devdconfdir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(halfdidir)'"; \
$(INSTALL_DATA) $$files "$(DESTDIR)$(halfdidir)" || exit $$?; \
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(devdconfdir)'"; \
$(INSTALL_DATA) $$files "$(DESTDIR)$(devdconfdir)" || exit $$?; \
done
uninstall-halfdiDATA:
uninstall-devdconfDATA:
@$(NORMAL_UNINSTALL)
@list='$(halfdi_DATA)'; test -n "$(halfdidir)" || list=; \
@list='$(devdconf_DATA)'; test -n "$(devdconfdir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(halfdidir)'; $(am__uninstall_files_from_dir)
dir='$(DESTDIR)$(devdconfdir)'; $(am__uninstall_files_from_dir)
tags: TAGS
TAGS:
@ -417,7 +408,7 @@ check-am: all-am
check: check-am
all-am: Makefile $(DATA)
installdirs:
for dir in "$(DESTDIR)$(halfdidir)"; do \
for dir in "$(DESTDIR)$(devdconfdir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
@ -442,7 +433,6 @@ install-strip:
mostlyclean-generic:
clean-generic:
-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
@ -472,7 +462,7 @@ info: info-am
info-am:
install-data-am: install-halfdiDATA
install-data-am: install-devdconfDATA
install-dvi: install-dvi-am
@ -516,26 +506,24 @@ ps: ps-am
ps-am:
uninstall-am: uninstall-halfdiDATA
uninstall-am: uninstall-devdconfDATA
.MAKE: install-am install-strip
.PHONY: all all-am check check-am clean clean-generic clean-libtool \
distclean distclean-generic distclean-libtool distdir dvi \
dvi-am html html-am info info-am install install-am \
install-data install-data-am install-dvi install-dvi-am \
install-exec install-exec-am install-halfdiDATA install-html \
install-data install-data-am install-devdconfDATA install-dvi \
install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \
install-pdf install-pdf-am install-ps install-ps-am \
install-strip installcheck installcheck-am installdirs \
maintainer-clean maintainer-clean-generic mostlyclean \
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
uninstall uninstall-am uninstall-halfdiDATA
uninstall uninstall-am uninstall-devdconfDATA
# FIXME: should be able to use $< here.
20-ups-nut-device.fdi: ups-nut-device.fdi
cp ups-nut-device.fdi $@
# we should never remove this one, apart from a distclean-check
#MAINTAINERCLEANFILES = nut-usbups.rules.in
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.

11
scripts/devd/README Normal file
View file

@ -0,0 +1,11 @@
On FreeBSD, devd has a similar role to udev on Linux. The devd.conf file
defines actions to perform when devices are plugged in.
The tools/nut-usbinfo.pl script generates nut-usb.conf.in by processing USB
macros in all of the drivers. In this case, the defined action for each
matching UPS is to change the permissions such that the NUT drivers can access
the devices without requiring root privileges. You may need to restart devd and
re-plug in the UPS to trigger the actions.
The format of this configuration file should work with devd on FreeBSD 9.0 and
9.1, at the very least.

View file

@ -0,0 +1,850 @@
# This file is generated and installed by the Network UPS Tools package.
# Homepage: http://www.networkupstools.org/
# ATCL FOR UPS - nutdrv_atcl_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0001";
match "product" "0x0000";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Hewlett Packard
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x0001";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# T500 - bcmxcp_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1f01";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# T750 - bcmxcp_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1f02";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# HP T750 INTL - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1f06";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# HP T1000 INTL - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1f08";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# HP T1500 INTL - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1f09";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# HP R/T 2200 INTL (like SMART2200RMXL2U) - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1f0a";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# HP R1500 G2 and G3 INTL - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe0";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# HP T750 G2 - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe1";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe2";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# HP T1500 G3 - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe3";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# R/T3000 - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe5";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# R/T3000 - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe6";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# various models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe7";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# various models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x03f0";
match "product" "0x1fe8";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Eaton
# various models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0463";
match "product" "0x0001";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# various models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0463";
match "product" "0xffff";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Dell
# various models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x047c";
match "product" "0xffff";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Riello (Cypress Semiconductor Corp.)
# various models - riello_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x04b4";
match "product" "0x5500";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Minibox
# openUPS Intelligent UPS (minimum required firmware 1.4) - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x04d8";
match "product" "0xd004";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Belkin
# F6H375-USB - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0375";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C550-AVR - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0551";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C1250-TW-RK - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0750";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C1500-TW-RK - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0751";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C900-UNV - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0900";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C100-UNV - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0910";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C120-UNV - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0912";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C800-UNV - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x0980";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# F6C1100-UNV, F6C1200-UNV - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x050d";
match "product" "0x1100";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# APC
# various models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x051d";
match "product" "0x0002";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# various 5G models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x051d";
match "product" "0x0003";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Powerware
# various models - bcmxcp_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0592";
match "product" "0x0002";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# PW 9140 - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0592";
match "product" "0x0004";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Agiler UPS - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x05b8";
match "product" "0x0000";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Belkin F6C1200-UNV - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0665";
match "product" "0x5161";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Phoenixtec Power Co., Ltd
# Online Yunto YQ450 - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x06da";
match "product" "0x0002";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Mustek Powermust - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x06da";
match "product" "0x0003";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Phoenixtec Innova 3/1 T - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x06da";
match "product" "0x0004";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Phoenixtec Innova RT - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x06da";
match "product" "0x0005";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Phoenixtec Innova T - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x06da";
match "product" "0x0201";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Online Zinto A - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x06da";
match "product" "0x0601";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# various models - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x06da";
match "product" "0xffff";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# iDowell
# iDowell - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x075d";
match "product" "0x0300";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Cyber Power Systems
# 900AVR/BC900D, CP1200AVR/BC1200D - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0764";
match "product" "0x0005";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Dynex DX-800U? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0764";
match "product" "0x0501";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# OR2200LCDRM2U, OR700LCDRM1U, PR6000LCDRTXL5U - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0764";
match "product" "0x0601";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Sweex 1000VA - richcomm_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0925";
match "product" "0x1234";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# TrippLite
# e.g. OMNIVS1000, SMART550USB, ... - tripplite_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x0001";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite AVR550U - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x1003";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite AVR750U - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x1007";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite ECO550UPS - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x1008";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite ECO550UPS - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x1009";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite ECO550UPS - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x1010";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite OMNI1000LCD - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2005";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite OMNI900LCD - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2007";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2008";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite Smart1000LCD - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2009";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2010";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2011";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2012";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2013";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x2014";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3008";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3009";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3010";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3011";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite smart2200RMXL2U - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3012";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3013";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3014";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3015";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite Smart1500LCD (newer unit) - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x3016";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite SmartOnline SU1500RTXL2UA (older unit?) - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4001";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite SmartOnline SU6000RT4U? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4002";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite SmartOnline SU1500RTXL2ua - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4003";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. TrippLite SmartOnline SU1000XLA - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4004";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4005";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4006";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4007";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# e.g. ? - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x09ae";
match "product" "0x4008";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# PowerCOM
# PowerCOM Vanguard and BNT-xxxAP - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0d9f";
match "product" "0x0004";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# PowerCOM IMP - IMPERIAL Series - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0d9f";
match "product" "0x00a2";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# PowerCOM SKP - Smart KING Pro (all Smart series) - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0d9f";
match "product" "0x00a3";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# PowerCOM WOW - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0d9f";
match "product" "0x00a4";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# PowerCOM VGD - Vanguard - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0d9f";
match "product" "0x00a5";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# PowerCOM BNT - Black Knight Pro - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0d9f";
match "product" "0x00a6";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Unitek Alpha 1200Sx - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x0f03";
match "product" "0x0001";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Liebert
# Liebert PowerSure PSA UPS - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x10af";
match "product" "0x0001";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Liebert PowerSure PSI 1440 - usbhid-ups
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x10af";
match "product" "0x0004";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# GE EP series - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0x14f0";
match "product" "0x00c9";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};
# Ablerex 625L USB - blazer_usb
notify 100 {
match "system" "USB";
match "subsystem" "DEVICE";
match "type" "ATTACH";
match "vendor" "0xffff";
match "product" "0x0000";
action "chgrp @RUN_AS_GROUP@ /dev/$device-name*; chmod g+rw /dev/$device-name*";
};

View file

@ -1,16 +0,0 @@
if WITH_HAL
halfdidir = $(HAL_FDI_PATH)
halfdi_DATA = 20-ups-nut-device.fdi
endif
# FIXME: should be able to use $< here.
20-ups-nut-device.fdi: ups-nut-device.fdi
cp ups-nut-device.fdi $@
EXTRA_DIST = ups-nut-device.fdi.in
DISTCLEANFILES = ups-nut-device.fdi
# we should never remove this one, apart from a distclean-check
#MAINTAINERCLEANFILES = ups-nut-device.fdi.in
CLEANFILES = 20-ups-nut-device.fdi

View file

@ -1,707 +0,0 @@
<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
<device>
<match key="@HAL_DEVICE_MATCH_KEY@" string="usb_device">
<match key="usb_device.vendor_id" int="0x0001">
<!-- Krauler UP-M500VA -->
<match key="usb_device.product_id" int="0x0000">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Hewlett Packard -->
<match key="usb_device.vendor_id" int="0x03f0">
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x0001">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- T500 -->
<match key="usb_device.product_id" int="0x1f01">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-bcmxcp_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- T750 -->
<match key="usb_device.product_id" int="0x1f02">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-bcmxcp_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- HP T750 INTL -->
<match key="usb_device.product_id" int="0x1f06">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- HP T1000 INTL -->
<match key="usb_device.product_id" int="0x1f08">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- HP T1500 INTL -->
<match key="usb_device.product_id" int="0x1f09">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- HP R/T 2200 INTL (like SMART2200RMXL2U) -->
<match key="usb_device.product_id" int="0x1f0a">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- HP R1500 G2 and G3 INTL -->
<match key="usb_device.product_id" int="0x1fe0">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- HP T750 G2 -->
<match key="usb_device.product_id" int="0x1fe1">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x1fe2">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- HP T1500 G3 -->
<match key="usb_device.product_id" int="0x1fe3">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- R/T3000 -->
<match key="usb_device.product_id" int="0x1fe5">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- R/T3000 -->
<match key="usb_device.product_id" int="0x1fe6">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- various models -->
<match key="usb_device.product_id" int="0x1fe7">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- various models -->
<match key="usb_device.product_id" int="0x1fe8">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Eaton -->
<match key="usb_device.vendor_id" int="0x0463">
<!-- various models -->
<match key="usb_device.product_id" int="0x0001">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- various models -->
<match key="usb_device.product_id" int="0xffff">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Dell -->
<match key="usb_device.vendor_id" int="0x047c">
<!-- various models -->
<match key="usb_device.product_id" int="0xffff">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Riello (Cypress Semiconductor Corp.) -->
<match key="usb_device.vendor_id" int="0x04b4">
<!-- various models -->
<match key="usb_device.product_id" int="0x5500">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-riello_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Minibox -->
<match key="usb_device.vendor_id" int="0x04d8">
<!-- openUPS Intelligent UPS (minimum required firmware 1.4) -->
<match key="usb_device.product_id" int="0xd004">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Belkin -->
<match key="usb_device.vendor_id" int="0x050d">
<!-- F6H375-USB -->
<match key="usb_device.product_id" int="0x0375">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C550-AVR -->
<match key="usb_device.product_id" int="0x0551">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C1250-TW-RK -->
<match key="usb_device.product_id" int="0x0750">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C1500-TW-RK -->
<match key="usb_device.product_id" int="0x0751">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C900-UNV -->
<match key="usb_device.product_id" int="0x0900">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C100-UNV -->
<match key="usb_device.product_id" int="0x0910">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C120-UNV -->
<match key="usb_device.product_id" int="0x0912">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C800-UNV -->
<match key="usb_device.product_id" int="0x0980">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- F6C1100-UNV, F6C1200-UNV -->
<match key="usb_device.product_id" int="0x1100">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- APC -->
<match key="usb_device.vendor_id" int="0x051d">
<!-- various models -->
<match key="usb_device.product_id" int="0x0002">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- various 5G models -->
<match key="usb_device.product_id" int="0x0003">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Powerware -->
<match key="usb_device.vendor_id" int="0x0592">
<!-- various models -->
<match key="usb_device.product_id" int="0x0002">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-bcmxcp_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- PW 9140 -->
<match key="usb_device.product_id" int="0x0004">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<match key="usb_device.vendor_id" int="0x05b8">
<!-- Agiler UPS -->
<match key="usb_device.product_id" int="0x0000">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<match key="usb_device.vendor_id" int="0x0665">
<!-- Belkin F6C1200-UNV -->
<match key="usb_device.product_id" int="0x5161">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Phoenixtec Power Co., Ltd -->
<match key="usb_device.vendor_id" int="0x06da">
<!-- Online Yunto YQ450 -->
<match key="usb_device.product_id" int="0x0002">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- Mustek Powermust -->
<match key="usb_device.product_id" int="0x0003">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- Phoenixtec Innova 3/1 T -->
<match key="usb_device.product_id" int="0x0004">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- Phoenixtec Innova RT -->
<match key="usb_device.product_id" int="0x0005">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- Phoenixtec Innova T -->
<match key="usb_device.product_id" int="0x0201">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- Online Zinto A -->
<match key="usb_device.product_id" int="0x0601">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- various models -->
<match key="usb_device.product_id" int="0xffff">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- iDowell -->
<match key="usb_device.vendor_id" int="0x075d">
<!-- iDowell -->
<match key="usb_device.product_id" int="0x0300">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Cyber Power Systems -->
<match key="usb_device.vendor_id" int="0x0764">
<!-- 900AVR/BC900D, CP1200AVR/BC1200D -->
<match key="usb_device.product_id" int="0x0005">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- Dynex DX-800U? -->
<match key="usb_device.product_id" int="0x0501">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- OR2200LCDRM2U, OR700LCDRM1U, PR6000LCDRTXL5U -->
<match key="usb_device.product_id" int="0x0601">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<match key="usb_device.vendor_id" int="0x0925">
<!-- Sweex 1000VA -->
<match key="usb_device.product_id" int="0x1234">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-richcomm_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- TrippLite -->
<match key="usb_device.vendor_id" int="0x09ae">
<!-- e.g. OMNIVS1000, SMART550USB, ... -->
<match key="usb_device.product_id" int="0x0001">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-tripplite_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite AVR550U -->
<match key="usb_device.product_id" int="0x1003">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite AVR750U -->
<match key="usb_device.product_id" int="0x1007">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite ECO550UPS -->
<match key="usb_device.product_id" int="0x1008">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite ECO550UPS -->
<match key="usb_device.product_id" int="0x1009">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite ECO550UPS -->
<match key="usb_device.product_id" int="0x1010">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite OMNI1000LCD -->
<match key="usb_device.product_id" int="0x2005">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite OMNI900LCD -->
<match key="usb_device.product_id" int="0x2007">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x2008">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite Smart1000LCD -->
<match key="usb_device.product_id" int="0x2009">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x2010">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x2011">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x2012">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x2013">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x2014">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x3008">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x3009">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x3010">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x3011">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite smart2200RMXL2U -->
<match key="usb_device.product_id" int="0x3012">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x3013">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x3014">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x3015">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite Smart1500LCD (newer unit) -->
<match key="usb_device.product_id" int="0x3016">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite SmartOnline SU1500RTXL2UA (older unit?) -->
<match key="usb_device.product_id" int="0x4001">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite SmartOnline SU6000RT4U? -->
<match key="usb_device.product_id" int="0x4002">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite SmartOnline SU1500RTXL2ua -->
<match key="usb_device.product_id" int="0x4003">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. TrippLite SmartOnline SU1000XLA -->
<match key="usb_device.product_id" int="0x4004">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x4005">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x4006">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x4007">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- e.g. ? -->
<match key="usb_device.product_id" int="0x4008">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- PowerCOM -->
<match key="usb_device.vendor_id" int="0x0d9f">
<!-- PowerCOM Vanguard and BNT-xxxAP -->
<match key="usb_device.product_id" int="0x0004">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- PowerCOM IMP - IMPERIAL Series -->
<match key="usb_device.product_id" int="0x00a2">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- PowerCOM SKP - Smart KING Pro (all Smart series) -->
<match key="usb_device.product_id" int="0x00a3">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- PowerCOM WOW -->
<match key="usb_device.product_id" int="0x00a4">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- PowerCOM VGD - Vanguard -->
<match key="usb_device.product_id" int="0x00a5">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
<!-- PowerCOM BNT - Black Knight Pro -->
<match key="usb_device.product_id" int="0x00a6">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<match key="usb_device.vendor_id" int="0x0f03">
<!-- Unitek Alpha 1200Sx -->
<match key="usb_device.product_id" int="0x0001">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<!-- Liebert -->
<match key="usb_device.vendor_id" int="0x10af">
<!-- Liebert PowerSure PSA UPS -->
<match key="usb_device.product_id" int="0x0001">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-usbhid-ups</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<match key="usb_device.vendor_id" int="0x14f0">
<!-- GE EP series -->
<match key="usb_device.product_id" int="0x00c9">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
<match key="usb_device.vendor_id" int="0xffff">
<!-- Ablerex 625L USB -->
<match key="usb_device.product_id" int="0x0000">
<append key="info.category" type="string">battery</append>
<merge key="info.capabilities" type="strlist">battery</merge>
<merge key="info.addons" type="strlist">hald-addon-blazer_usb</merge>
<merge key="battery.type" type="string">ups</merge>
</match>
</match>
</match>
</device>
</deviceinfo>

View file

@ -67,7 +67,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -77,10 +76,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@ -169,10 +167,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -184,8 +178,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -271,6 +263,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@

View file

@ -4,7 +4,7 @@
# libhidups 0x0003 0xVVVV 0xPPPP 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000
#
# usb module match_flags idVendor idProduct bcdDevice_lo bcdDevice_hi bDeviceClass bDeviceSubClass bDeviceProtocol bInterfaceClass bInterfaceSubClass bInterfaceProtocol driver_info
# Krauler UP-M500VA
# ATCL FOR UPS
libhidups 0x0003 0x0001 0x0000 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000
# Hewlett Packard
@ -208,6 +208,8 @@ libhidups 0x0003 0x0f03 0x0001 0x0000 0x0000 0x00
# Liebert
# Liebert PowerSure PSA UPS
libhidups 0x0003 0x10af 0x0001 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000
# Liebert PowerSure PSI 1440
libhidups 0x0003 0x10af 0x0004 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000
# GE EP series
libhidups 0x0003 0x14f0 0x00c9 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000
# Ablerex 625L USB

View file

@ -65,7 +65,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -75,10 +74,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@ -135,10 +133,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -150,8 +144,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -237,6 +229,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@

View file

@ -0,0 +1,348 @@
#!/bin/bash
#
# an auxiliary script to produce a "stub" snmp-ups subdriver from
# SNMP data from a real agent or from dump files
#
# Version: 0.4
#
# See also: docs/snmp-subdrivers.txt
#
# Copyright (C)
# 2011 - 2012 Arnaud Quette <arnaud.quette@free.fr>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
# TODO:
# - extend to SNMP v3 (auth.)
usage() {
echo "Usage: $0 [options] [file]"
echo "Options:"
echo " -h, --help -- show this message and quit"
echo " -n name -- subdriver name (use natural capitalization)"
echo " -M DIRLIST -- colon separated list of directories to also search for MIBs"
echo " -k -- keep temporary files (for debugging)"
echo ""
echo "mode 1: get SNMP data from a real agent"
echo " -H host_address -- SNMP host IP address or name"
echo " -c community -- SNMP v1 community name (default: public)"
echo ""
echo "mode 2: get data from files (snmpwalk dumps of 'sysOID' subtree)"
echo " -s XXXX -- SNMP OID entry point (sysOID). Ex: '.1.3.6.1.4.1.705.1'"
echo " file1 file2 -- read from files instead of an host (using Net SNMP)"
echo " file1: numeric SNMP walk (snmpwalk -On ... <sysOID>)"
echo " file2: string SNMP walk (snmpwalk -Os ... <sysOID>)"
# FIXME: EXAMPLES
}
# variables
DRIVER=""
KEEP=""
HOSTNAME=""
MIBS_DIRLIST="+."
COMMUNITY="public"
SYSOID=""
MODE=0
# constants
NAME=gen-snmp-subdriver
TMPDIR="${TEMPDIR:-/tmp}"
DEBUG=`mktemp "$TMPDIR/$NAME-DEBUG.XXXXXX"`
DFL_NUMWALKFILE=`mktemp "$TMPDIR/$NAME-NUMWALK.XXXXXX"`
DFL_STRWALKFILE=`mktemp "$TMPDIR/$NAME-STRWALK.XXXXXX"`
TMP_NUMWALKFILE=`mktemp "$TMPDIR/$NAME-TMP-NUMWALK.XXXXXX"`
TMP_STRWALKFILE=`mktemp "$TMPDIR/$NAME-TMP-STRWALK.XXXXXX"`
get_snmp_data() {
# 1) get the sysOID (points the mfr specif MIB)
SYSOID=`snmpget -v1 -c $COMMUNITY $HOSTNAME .1.3.6.1.2.1.1.2.0 41`
# 2) get the content of the mfr specif MIB
snmpwalk -On -v1 -c $COMMUNITY $HOSTNAME $SYSOID 2>/dev/null 1> $DFL_NUMWALKFILE
snmpwalk -Os -v1 -M $MIBS_DIRLIST -c $COMMUNITY $HOSTNAME $SYSOID 2>/dev/null 1> $DFL_STRWALKFILE
}
# process command line options
while [ $# -gt 0 ]; do
if [ $# -gt 1 -a "$1" = "-n" ]; then
DRIVER="$2"
shift 2
elif [ $# -gt 1 -a "$1" = "-M" ]; then
MIBS_DIRLIST="$MIBS_DIRLIST:$2"
shift 2
elif [ "$1" = "-k" ]; then
KEEP=yes
shift
elif [ $# -gt 1 -a "$1" = "-H" ]; then
HOSTNAME="$2"
shift 2
elif [ $# -gt 1 -a "$1" = "-c" ]; then
COMMUNITY="$2"
shift 2
elif [ $# -gt 1 -a "$1" = "-s" ]; then
SYSOID="$2"
shift 2
elif echo "$1" | grep -qv '^-'; then
if [ $# -gt 1 ]; then
NUMWALKFILE="$1"
shift
STRWALKFILE="$1"
shift
else
usage
exit 1
fi
elif [ "$1" = "--help" -o "$1" = "-h" ]; then
usage
exit 0
else
echo "Illegal option $1. Try --help for more info." >&2
exit 1
fi
done
# check that the needed parameters are provided, depending on the mode
if [ -z "$NUMWALKFILE" ]; then
# mode 1: directly get SNMP data from a real agent
MODE=1
NUMWALKFILE=$DFL_NUMWALKFILE
STRWALKFILE=$DFL_STRWALKFILE
# check if Net SNMP is available
if [ -z "`which snmpget`" -o -z "`which snmpwalk`" ]; then
echo "Net SNMP not found! snmpget and snmpwalk commands are required." >&2
exit 1
fi
# hostname is also mandatory
while [ -z "$HOSTNAME" ]; do
echo "
Please enter the SNMP host IP address or name."
read -p "SNMP host IP name or address: " HOSTNAME < /dev/tty
if echo $HOSTNAME | egrep -q '[^a-zA-Z0-9]'; then
echo "Please use only letters and digits"
HOSTNAME=""
fi
done
# get data from the agent
get_snmp_data
else
# mode 2: get data from files
MODE=2
# get sysOID value from command line, if needed
while [ -z "$SYSOID" ]; do
echo "
Please enter the value of sysOID, as displayed by snmp-ups. For example '.1.3.6.1.4.1.2254.2.4'.
You can get it using: snmpget -v1 -c XXX <host> .1.3.6.1.2.1.1.2.0"
read -p "Value of sysOID: " SYSOID < /dev/tty
if echo $SYSOID | egrep -q '[^0-9.]'; then
echo "Please use only the numeric form, with dots and digits"
SYSOID=""
fi
done
# check for actual files existence
if [ ! -f "$NUMWALKFILE" -o ! -f "$STRWALKFILE" ]; then
echo "SNMP walk dump files are missing on disk. Try --help for more info." >&2
exit 1
fi
fi
# delete temporary files: this is called just before exiting.
cleanup () {
rm -f "$DEBUG $DFL_NUMWALKFILE $TMP_NUMWALKFILE $DFL_STRWALKFILE $TMP_STRWALKFILE"
}
if [ -z "$KEEP" ]; then
trap cleanup EXIT
fi
# prompt use for name of driver
while [ -z "$DRIVER" ]; do
echo "
Please enter a name for this driver. Use only letters and numbers. Use
natural (upper- and lowercase) capitalization, e.g., 'Belkin', 'APC'."
read -p "Name of subdriver: " DRIVER < /dev/tty
if echo $DRIVER | egrep -q '[^a-zA-Z0-9]'; then
echo "Please use only letters and digits"
DRIVER=""
fi
done
# remove blank and "End of MIB" lines
egrep -e "^[[:space:]]?$" -e "End of MIB" -v ${NUMWALKFILE} > ${TMP_NUMWALKFILE}
egrep -e "^[[:space:]]?$" -e "End of MIB" -v ${STRWALKFILE} > ${TMP_STRWALKFILE}
NUMWALKFILE=${TMP_NUMWALKFILE}
STRWALKFILE=${TMP_STRWALKFILE}
# FIXME: sanity checks (! -z contents -a same `wc -l`)
NUM_OID_COUNT="`cat $NUMWALKFILE | wc -l`"
STR_OID_COUNT="`cat $STRWALKFILE | wc -l`"
echo "COUNT = $NUM_OID_COUNT / $NUM_OID_COUNT"
# create file names
LDRIVER=`echo $DRIVER | tr A-Z a-z`
UDRIVER=`echo $DRIVER | tr a-z A-Z`
CFILE="$LDRIVER-mib.c"
HFILE="$LDRIVER-mib.h"
# generate header file
echo "Creating $HFILE"
cat > "$HFILE" <<EOF
/* ${HFILE} - subdriver to monitor ${DRIVER} SNMP devices with NUT
*
* Copyright (C)
* 2011 - 2012 Arnaud Quette <arnaud.quette@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef ${UDRIVER}_MIB_H
#define ${UDRIVER}_MIB_H
#include "main.h"
#include "snmp-ups.h"
extern mib2nut_info_t ${LDRIVER};
#endif /* ${UDRIVER}_MIB_H */
EOF
# generate source file
# create header
echo "Creating $CFILE"
cat > "$CFILE" <<EOF
/* ${CFILE} - subdriver to monitor ${DRIVER} SNMP devices with NUT
*
* Copyright (C)
* 2011 - 2012 Arnaud Quette <arnaud.quette@free.fr>
*
* Note: this subdriver was initially generated as a "stub" by the
* gen-snmp-subdriver script. It must be customized!
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#include "${HFILE}"
#define ${UDRIVER}_MIB_VERSION "0.1"
#define ${UDRIVER}_SYSOID "${SYSOID}"
/* To create a value lookup structure (as needed on the 2nd line of the example
* below), use the following kind of declaration, outside of the present snmp_info_t[]:
* static info_lkp_t onbatt_info[] = {
* { 1, "OB" },
* { 2, "OL" },
* { 0, "NULL" }
* };
*/
/* ${UDRIVER} Snmp2NUT lookup table */
static snmp_info_t ${LDRIVER}_mib[] = {
/* Data format:
* { info_type, info_flags, info_len, OID, dfl, flags, oid2info, setvar },
*
* info_type: NUT INFO_ or CMD_ element name
* info_flags: flags to set in addinfo
* info_len: length of strings if STR
* cmd value if CMD, multiplier otherwise
* OID: SNMP OID or NULL
* dfl: default value
* flags: snmp-ups internal flags (FIXME: ...)
* oid2info: lookup table between OID and NUT values
* setvar: variable to set for SU_FLAG_SETINT
*
* Example:
* { "input.voltage", 0, 0.1, ".1.3.6.1.4.1.705.1.6.2.1.2.1", "", SU_INPUT_1, NULL },
* { "ups.status", ST_FLAG_STRING, SU_INFOSIZE, ".1.3.6.1.4.1.705.1.7.3.0", "", SU_FLAG_OK | SU_STATUS_BATT, onbatt_info },
*
* To create a value lookup structure (as needed on the 2nd line), use the
* following kind of declaration, outside of the present snmp_info_t[]:
* static info_lkp_t onbatt_info[] = {
* { 1, "OB" },
* { 2, "OL" },
* { 0, "NULL" }
* };
*/
EOF
# extract OID string paths, one by one
LINENB="0"
while IFS= read -r line; do
LINENB="`expr $LINENB + 1`"
FULL_STR_OID="$line"
STR_OID="`echo $line | cut -d'.' -f1`"
echo $line | grep STRING > /dev/null
if [ $? -eq 0 ]; then
ST_FLAG_TYPE="ST_FLAG_STRING"
SU_INFOSIZE="SU_INFOSIZE"
else
ST_FLAG_TYPE="0"
SU_INFOSIZE="1"
fi
# get the matching numeric OID
NUM_OID="`sed -n ${LINENB}p ${NUMWALKFILE} | cut -d' ' -f1`"
printf "\t/* ${FULL_STR_OID} */\n\t{ \"unmapped.${STR_OID}\", ${ST_FLAG_TYPE}, ${SU_INFOSIZE}, \"${NUM_OID}\", NULL, SU_FLAG_OK, NULL },\n"
done < ${STRWALKFILE} >> ${CFILE}
# append footer
cat >> "$CFILE" <<EOF
/* end of structure. */
{ NULL, 0, 0, NULL, NULL, 0, NULL }
};
mib2nut_info_t ${LDRIVER} = { "${LDRIVER}", ${UDRIVER}_MIB_VERSION, NULL, NULL, ${LDRIVER}_mib, ${UDRIVER}_SYSOID };
EOF
# Display the remaining tasks
cat <<EOF
Done.
Do not forget to:
* bump DRIVER_VERSION in snmp-ups.c (add "0.01")
* copy "${HFILE}" and "${CFILE}" to "../../drivers"
* add #include "${HFILE}" to snmp-ups.c
* add &${LDRIVER} to snmp-ups.c:mib2nut[] list,
* add ${LDRIVER}-mib.c to snmp_ups_SOURCES in drivers/Makefile.am
* add ${LDRIVER}-mib.h to dist_noinst_HEADERS in drivers/Makefile.am
* "./autogen.sh && ./configure && make" from the top level directory
EOF

View file

@ -166,6 +166,7 @@ cat > "$CFILE" <<EOF
* 2003 - 2012 Arnaud Quette <ArnaudQuette@Eaton.com>
* 2005 - 2006 Peter Selinger <selinger@users.sourceforge.net>
* 2008 - 2009 Arjen de Korte <adkorte-guest@alioth.debian.org>
* 2013 Charles Lepple <clepple+nut@gmail.com>
*
* Note: this subdriver was initially generated as a "stub" by the
* gen-usbhid-subdriver script. It must be customized.
@ -263,7 +264,7 @@ static const char *${LDRIVER}_format_serial(HIDDevice_t *hd) {
* the device is supported by this subdriver, else 0. */
static int ${LDRIVER}_claim(HIDDevice_t *hd)
{
int status = is_usb_device_supported(${LDRIVER}_usb_device_table, hd->VendorID, hd->ProductID);
int status = is_usb_device_supported(${LDRIVER}_usb_device_table, hd);
switch (status)
{
@ -299,8 +300,8 @@ cat <<EOF
Done.
Do not forget to:
* add #include "${HFILE}" to usbhid-ups.c,
* add &${LDRIVER}_subdriver to usbhid-ups.c:subdriver_list,
* add #include "${HFILE}" to drivers/usbhid-ups.c,
* add &${LDRIVER}_subdriver to drivers/usbhid-ups.c:subdriver_list,
* add ${LDRIVER}-hid.c to USBHID_UPS_SUBDRIVERS in drivers/Makefile.am
* add ${LDRIVER}-hid.h to dist_noinst_HEADERS in drivers/Makefile.am
* "autoreconf" from the top level directory

View file

@ -71,7 +71,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -81,10 +80,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@ -173,10 +171,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -188,8 +182,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -275,6 +267,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@

View file

@ -4,7 +4,7 @@ After=local-fs.target network.target
StopWhenUnneeded=yes
[Service]
ExecStart=@DRVPATH@/upsdrvctl start
ExecStop=@DRVPATH@/upsdrvctl stop
ExecStart=@SBINDIR@/upsdrvctl start
ExecStop=@SBINDIR@/upsdrvctl stop
Type=forking

View file

@ -1,2 +1,2 @@
#!/bin/sh
@SBINDIR@/upsmon -K >/dev/null 2>&1 && @driverexecdir@/upsdrvctl shutdown
@SBINDIR@/upsmon -K >/dev/null 2>&1 && @SBINDIR@/upsdrvctl shutdown

View file

@ -67,7 +67,6 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libavahi.m4 \
$(top_srcdir)/m4/nut_check_libfreeipmi.m4 \
$(top_srcdir)/m4/nut_check_libgd.m4 \
$(top_srcdir)/m4/nut_check_libhal.m4 \
$(top_srcdir)/m4/nut_check_libltdl.m4 \
$(top_srcdir)/m4/nut_check_libneon.m4 \
$(top_srcdir)/m4/nut_check_libnetsnmp.m4 \
@ -77,10 +76,9 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/ax_compare_version.m4 \
$(top_srcdir)/m4/nut_check_libusb.m4 \
$(top_srcdir)/m4/nut_check_libwrap.m4 \
$(top_srcdir)/m4/nut_check_os.m4 \
$(top_srcdir)/m4/nut_config_libhal.m4 \
$(top_srcdir)/m4/nut_report_feature.m4 \
$(top_srcdir)/m4/nut_type_socklen_t.m4 \
$(top_srcdir)/configure.in
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
@ -166,10 +164,6 @@ EGREP = @EGREP@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
HAL_CALLOUTS_PATH = @HAL_CALLOUTS_PATH@
HAL_DEVICE_MATCH_KEY = @HAL_DEVICE_MATCH_KEY@
HAL_FDI_PATH = @HAL_FDI_PATH@
HAL_USER = @HAL_USER@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
@ -181,8 +175,6 @@ LIBAVAHI_CFLAGS = @LIBAVAHI_CFLAGS@
LIBAVAHI_LIBS = @LIBAVAHI_LIBS@
LIBGD_CFLAGS = @LIBGD_CFLAGS@
LIBGD_LDFLAGS = @LIBGD_LDFLAGS@
LIBHAL_CFLAGS = @LIBHAL_CFLAGS@
LIBHAL_LIBS = @LIBHAL_LIBS@
LIBIPMI_CFLAGS = @LIBIPMI_CFLAGS@
LIBIPMI_LIBS = @LIBIPMI_LIBS@
LIBLTDL_CFLAGS = @LIBLTDL_CFLAGS@
@ -268,6 +260,7 @@ builddir = @builddir@
cgiexecdir = @cgiexecdir@
datadir = @datadir@
datarootdir = @datarootdir@
devddir = @devddir@
docdir = @docdir@
driverexecdir = @driverexecdir@
dvidir = @dvidir@

View file

@ -6,7 +6,7 @@ SUBSYSTEM=="usb", GOTO="nut-usbups_rules_real"
SUBSYSTEM!="usb", GOTO="nut-usbups_rules_end"
LABEL="nut-usbups_rules_real"
# Krauler UP-M500VA - blazer_usb
# ATCL FOR UPS - nutdrv_atcl_usb
ATTR{idVendor}=="0001", ATTR{idProduct}=="0000", MODE="664", GROUP="@RUN_AS_GROUP@"
# Hewlett Packard
@ -210,6 +210,8 @@ ATTR{idVendor}=="0f03", ATTR{idProduct}=="0001", MODE="664", GROUP="@RUN_AS_GROU
# Liebert
# Liebert PowerSure PSA UPS - usbhid-ups
ATTR{idVendor}=="10af", ATTR{idProduct}=="0001", MODE="664", GROUP="@RUN_AS_GROUP@"
# Liebert PowerSure PSI 1440 - usbhid-ups
ATTR{idVendor}=="10af", ATTR{idProduct}=="0004", MODE="664", GROUP="@RUN_AS_GROUP@"
# GE EP series - blazer_usb
ATTR{idVendor}=="14f0", ATTR{idProduct}=="00c9", MODE="664", GROUP="@RUN_AS_GROUP@"
# Ablerex 625L USB - blazer_usb

View file

@ -123,5 +123,6 @@ ATTRS{idVendor}=="0d9f", ATTRS{idProduct}=="00a6", ENV{UPOWER_BATTERY_TYPE}="ups
# Liebert
ATTRS{idVendor}=="10af", ATTRS{idProduct}=="0001", ENV{UPOWER_BATTERY_TYPE}="ups"
ATTRS{idVendor}=="10af", ATTRS{idProduct}=="0004", ENV{UPOWER_BATTERY_TYPE}="ups"
LABEL="up_hid_end"