2.8.2_1 blazer_usb, nutdrv_qx
-
@LanterIT Unfortunately there are no log entries from the nutdrv_qx process. If you are comfortable with it, could you try the following please?
First, this insures that the nut service is running:
/usr/local/etc/rc.d/nut.sh restart
This kills any driver that may be running:
killall nutdrv_qx
This starts the nutdrv_qx driver in debug mode:
/usr/local/libexec/nut/nutdrv_qx -D -a ABB
The driver will output debug information in the shell. Let it run for a few seconds, then you can kill it. Please post the output. Thanks.
-
The driver stops after a few seconds. Output with triple D:
/usr/local/libexec/nut/nutdrv_qx -DDD -a ABB Network UPS Tools - Generic Q* USB/Serial driver 0.36 (2.8.1.1) USB communication driver (libusb 1.0) 0.46 0.000000 [D3] main_arg: var='driver' val='nutdrv_qx' 0.000037 [D3] main_arg: var='port' val='auto' 0.000083 [D3] main_arg: var='pollinterval' val='10' 0.000096 [D1] testval_reloadable: setting 'pollinterval' exists and differs: new value '10' vs. '2' 0.000135 [D1] Network UPS Tools version 2.8.1.1 (release/snapshot of 2.8.1.1) built with FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152); Target: x86_64-unknown-freebsd14.0; Thread model: posix and configured with flags: --sysconfdir=/usr/local/etc/nut --program-transform-name= --localstatedir=/var/db/nut --datadir=/usr/local/etc/nut --with-devd-dir=/usr/local/etc/devd --with-drvpath=/usr/local/libexec/nut --with-statepath=/var/db/nut --with-altpidpath=/var/db/nut --with-pidpath=/var/db/nut --with-pkgconfig-dir=/usr/local/libdata/pkgconfig --with-user=nut --with-group=nut --with-python=/usr/local/bin/python3.11 --without-python2 --with-python3=/usr/local/bin/python3.11 --without-nut_monitor --with-ltdl --with-nut-scanner --with-avahi --with-cgi --with-cgipath=/usr/local/www/cgi-bin/nut --with-htmlpath=/usr/local/www/nut --with-gd-includes=-I/usr/local/include --with-gd-libs='-L/usr/local/lib -lgd' --without-dev --with-freeipmi --without-ipmi --with-doc=no --with-modbus --with-neon --without-nss --with-openssl --with-powerman --with-serial --with-snmp --with-usb=auto --prefix=/usr/local --mandir=/usr/local/man --disable-silent-rules --infodir=/usr/local/share/info/ --build=amd64-portbld-freebsd14.0 0.000156 [D1] debug level is '3' 0.000861 [D1] Succeeded to become_user(nut): now UID=316 GID=316 0.000956 [D1] upsdrv_initups... 0.001271 [D2] Checking device 1 of 1 (06DA/0005) 0.003392 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004140 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004766 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004770 [D2] - VendorID: 06da 0.004772 [D2] - ProductID: 0005 0.004774 [D2] - Manufacturer: PPC 0.004776 [D2] - Product: USB UPS 0.004778 [D2] - Serial Number: unknown 0.004780 [D2] - Bus: 000 0.004782 [D2] - Bus Port: 007 0.004784 [D2] - Device: 002 0.004786 [D2] - Device release number: 0001 0.004788 [D2] Trying to match device 0.004791 [D3] match_function_regex: matching a device... 0.004794 [D2] Device matches 0.004796 [D2] Reading configuration descriptor 1 of 1 0.004823 [D3] libusb_kernel_driver_active() returned 0: Success 0.004827 [D2] Claimed interface 0 successfully 0.004830 [D3] nut_usb_set_altinterface: skipped libusb_set_interface_alt_setting(udev, 0, 0) 0.005027 [D3] send: QGS 0.049762 [D3] read: 0.049799 [D2] qx_process_answer: short reply (input.voltage) 0.050013 [D3] send: QGS 0.089767 [D3] read: 0.089777 [D2] qx_process_answer: short reply (input.voltage) 0.089979 [D3] send: QGS 0.129766 [D3] read: 0.129778 [D2] qx_process_answer: short reply (input.voltage) 0.129981 [D3] send: M 0.153762 [D3] read: 0.153784 [D2] voltronic_qs_protocol: invalid protocol [] 0.153991 [D3] send: M 0.177763 [D3] read: 0.177774 [D2] voltronic_qs_protocol: invalid protocol [] 0.177986 [D3] send: M 0.201763 [D3] read: 0.201773 [D2] voltronic_qs_protocol: invalid protocol [] 0.201986 [D3] send: M 0.225765 [D3] read: 0.225788 [D2] voltronic_qs_hex_protocol: invalid protocol [] 0.225985 [D3] send: M 0.249776 [D3] read: 0.249791 [D2] voltronic_qs_hex_protocol: invalid protocol [] 0.249988 [D3] send: M 0.273768 [D3] read: 0.273782 [D2] voltronic_qs_hex_protocol: invalid protocol [] 0.273982 [D3] send: QS 0.313767 [D3] read: 0.313797 [D2] qx_process_answer: short reply (input.voltage) 0.314003 [D3] send: QS 0.353768 [D3] read: 0.353780 [D2] qx_process_answer: short reply (input.voltage) 0.353996 [D3] send: QS 0.393768 [D3] read: 0.393778 [D2] qx_process_answer: short reply (input.voltage) 0.393988 [D3] send: D 0.425762 [D3] read: 0.425781 [D2] qx_process_answer: short reply (input.voltage) 0.425981 [D3] send: D 0.457770 [D3] read: 0.457781 [D2] qx_process_answer: short reply (input.voltage) 0.457990 [D3] send: D 0.489781 [D3] read: 0.489802 [D2] qx_process_answer: short reply (input.voltage) 0.490024 [D3] send: Q1 0.721777 [D3] read: 0.721795 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 0.722003 [D3] send: Q1 0.953777 [D3] read: 0.953800 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 0.954010 [D3] send: Q1 1.185762 [D3] read: 1.185783 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 1.185993 [D3] send: Q1 1.417766 [D3] read: 1.417800 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 1.418004 [D3] send: Q1 1.649787 [D3] read: 1.649811 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 1.650018 [D3] send: Q1 1.881787 [D3] read: 1.881813 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 1.882028 [D3] send: Q1 2.113780 [D3] read: 2.113818 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 2.114032 [D3] send: Q1 2.345805 [D3] read: 2.345826 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 2.346033 [D3] send: Q1 2.577789 [D3] read: 2.577811 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 2.578025 [D3] send: Q1 2.809783 [D3] read: 2.809816 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 2.810032 [D3] send: Q1 3.041789 [D3] read: 3.041813 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 3.042029 [D3] send: Q1 3.273790 [D3] read: 3.273808 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 3.274022 [D3] send: WH 3.313764 [D3] read: 3.313794 [D2] qx_process_answer: short reply (experimental.series) 3.313802 [D2] claim: cannot process experimental.series 3.314007 [D3] send: WH 3.353785 [D3] read: 3.353796 [D2] qx_process_answer: short reply (experimental.series) 3.353802 [D2] claim: cannot process experimental.series 3.354023 [D3] send: WH 3.393800 [D3] read: 3.393816 [D2] qx_process_answer: short reply (experimental.series) 3.393824 [D2] claim: cannot process experimental.series 3.394039 [D3] send: Q1 3.625780 [D3] read: 3.625821 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 3.626044 [D3] send: Q1 3.857800 [D3] read: 3.857818 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 3.858031 [D3] send: Q1 4.089798 [D3] read: 4.089820 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 4.090036 [D3] send: Q1 4.321792 [D3] read: 4.321831 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 4.322044 [D3] send: Q1 4.553794 [D3] read: 4.553810 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 4.554013 [D3] send: Q1 4.785797 [D3] read: 4.785820 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 4.786030 [D3] send: Q1 5.017814 [D3] read: 5.017856 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 5.018080 [D3] send: Q1 5.249798 [D3] read: 5.249816 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 5.250031 [D3] send: Q1 5.481806 [D3] read: 5.481827 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 5.481836 Device not supported! 5.481843 Device not supported! 5.481892 upsnotify: failed to notify about state 4: no notification tech defined, will not spam more about it
-
@LanterIT said in NUT Package (2.8.1 and above):
The driver stops after a few seconds. Output with triple D:
Very useful. When you tried the nutdrv_qx driver, did you still have anything in the "Extra Arguments to driver" section?
Assuming not, can you test with this content in the "Extra Arguments to driver" section please?
vendorid=06da productid=0005 subdriver = "phoenix" protocol = "megatec"
-
Thank you for your help.
I am pleased that you have found the cause in the tripplite_usb driver.First only the pollinterval, then with all "old" arguments.
Could it also be related to the serial number?
0.003392 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004140 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004766 [D1] nut_libusb_open get iSerialNumber failed, retrying...
-
@LanterIT said in NUT Package (2.8.1 and above):
And the last entry of usbconfig dump_device_quirks | grep HID_IGNORE
correspond the vendor and product ID:VID=0x06da PID=0x0005 REVLO=0x0000 REVHI=0xffff QUIRK=UQ_HID_IGNORE
Btw, a quirk is only necessary if the device is HID compliant. The quirk prevents the OS from attaching a default HID driver. If the UPS is actually HID compliant, usbhid-ups would be the preferred driver. I assume that the usbhid-ups driver did not work, correct?
-
@LanterIT said in NUT Package (2.8.1 and above):
First only the pollinterval, then with all "old" arguments.
Just with the content above please, and the test you ran previously:
/usr/local/libexec/nut/nutdrv_qx -DDD -a ABB
Thanks
-
/usr/local/libexec/nut/nutdrv_qx -DDD -a ABB Network UPS Tools - Generic Q* USB/Serial driver 0.36 (2.8.0.1) USB communication driver (libusb 1.0) 0.46 0.000000 [D3] main_arg: var='driver' val='nutdrv_qx' 0.000033 [D3] main_arg: var='port' val='auto' 0.000050 [D3] main_arg: var='vendorid' val='06da' 0.000074 [D3] main_arg: var='productid' val='0005' 0.000092 [D3] main_arg: var='subdriver' val='phoenix' 0.000108 [D3] main_arg: var='protocol' val='megatec' 0.000144 [D1] Network UPS Tools version 2.8.0.1 (release/snapshot of 2.8.0.1) built with FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152); Target: x86_64-unknown-freebsd14.0; Thread model: posix and configured with flags: --sysconfdir=/usr/local/etc/nut --program-transform-name= --localstatedir=/var/db/nut --datadir=/usr/local/etc/nut --with-devd-dir=/usr/local/etc/devd --with-drvpath=/usr/local/libexec/nut --with-statepath=/var/db/nut --with-altpidpath=/var/db/nut --with-pidpath=/var/db/nut --with-pkgconfig-dir=/usr/local/libdata/pkgconfig --with-user=nut --with-group=nut --with-python=/usr/local/bin/python3.11 --without-python2 --with-python3=/usr/local/bin/python3.11 --with-ltdl --with-nut-scanner --with-avahi --with-cgi --with-cgipath=/usr/local/www/cgi-bin/nut --with-htmlpath=/usr/local/www/nut --with-gd-includes=-I/usr/local/include --with-gd-libs='-L/usr/local/lib -lgd' --without-dev --with-freeipmi --without-ipmi --with-doc=no --with-modbus --with-neon --without-nss --with-openssl --with-powerman --with-serial --with-snmp --with-usb=auto --prefix=/usr/local --mandir=/usr/local/man --disable-silent-rules --infodir=/usr/local/share/info/ --build=amd64-portbld-freebsd14.0 0.000163 [D1] debug level is '3' 0.000845 [D1] Succeeded to become_user(nut): now UID=316 GID=316 0.000936 [D1] upsdrv_initups... 0.001331 [D2] Checking device 1 of 1 (06DA/0005) 0.001525 [D1] nut_libusb_open: invalid libusb bus number 0 0.003757 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004506 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.005134 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.005144 [D2] - VendorID: 06da 0.005151 [D2] - ProductID: 0005 0.005157 [D2] - Manufacturer: PPC 0.005163 [D2] - Product: USB UPS 0.005169 [D2] - Serial Number: unknown 0.005175 [D2] - Bus: ▒▒▒▒▒▒▒▒002 0.005182 [D2] - Bus Port: 007 0.005187 [D2] - Device: 002 0.005193 [D2] - Device release number: 0001 0.005199 [D2] Trying to match device 0.005205 [D3] match_function_regex: matching a device... 0.005234 [D2] Device matches 0.005240 [D2] Reading first configuration descriptor 0.005304 [D3] libusb_kernel_driver_active() returned 0: Success 0.005316 [D2] Claimed interface 0 successfully 0.005325 [D3] nut_usb_set_altinterface: skipped libusb_set_interface_alt_setting(udev, 0, 0) 0.005355 [D2] Skipping protocol Voltronic 0.08 0.005362 [D2] Skipping protocol Voltronic-QS 0.09 0.005368 [D2] Skipping protocol Voltronic-QS-Hex 0.10 0.005374 [D2] Skipping protocol Mustek 0.08 0.005381 [D2] Skipping protocol Megatec/old 0.08 0.005387 [D2] Skipping protocol BestUPS 0.07 0.005393 [D2] Skipping protocol Mecer 0.08 0.062217 [D3] send: Q1 0.294022 [D3] read: (225.4 225.4 229.9 050 50.0 2.18 28.2 00000001 1.310822 [D3] flush: Timeout (-7) 1.311048 [D3] send: I 1.366114 [D3] read: 1.366148 [D2] qx_process_answer: short reply (ups.firmware) 1.430347 [D3] send: Q1 1.662015 [D3] read: (225.4 225.4 230.4 047 49.9 2.18 28.2 00000001 2.695886 [D3] flush: Timeout (-7) 2.696121 [D3] send: I 2.758125 [D3] read: 2.758151 [D2] qx_process_answer: short reply (ups.firmware) 2.822248 [D3] send: Q1 3.054034 [D3] read: (225.9 225.9 229.7 047 49.9 2.18 28.2 00000001 4.064734 [D3] flush: Timeout (-7) 4.064958 [D3] send: I 4.126133 [D3] read: 4.126151 [D2] qx_process_answer: short reply (ups.firmware) 4.126167 [D2] Skipping protocol Zinto 0.07 4.126175 [D2] Skipping protocol Masterguard 0.02 4.126181 [D2] Skipping protocol Hunnox 0.02 4.126188 [D2] Skipping protocol Ablerex 0.01 4.126194 [D2] Skipping protocol Q1 0.08 4.126200 Device not supported! 4.126206 Device not supported! 4.126247 upsnotify: failed to notify about state 4: no notification tech defined, will not spam more about it
let me upgrade to the new package...
-
... and with version 2.8.2_1:
/usr/local/libexec/nut/nutdrv_qx -DDD -a ABB Network UPS Tools - Generic Q* USB/Serial driver 0.36 (2.8.1.1) USB communication driver (libusb 1.0) 0.46 0.000000 [D3] main_arg: var='driver' val='nutdrv_qx' 0.000012 [D3] main_arg: var='port' val='auto' 0.000017 [D3] main_arg: var='vendorid' val='06da' 0.000025 [D3] main_arg: var='productid' val='0005' 0.000031 [D3] main_arg: var='subdriver' val='phoenix' 0.000036 [D3] main_arg: var='protocol' val='megatec' 0.000046 [D1] Network UPS Tools version 2.8.1.1 (release/snapshot of 2.8.1.1) built with FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152); Target: x86_64-unknown-freebsd14.0; Thread model: posix and configured with flags: --sysconfdir=/usr/local/etc/nut --program-transform-name= --localstatedir=/var/db/nut --datadir=/usr/local/etc/nut --with-devd-dir=/usr/local/etc/devd --with-drvpath=/usr/local/libexec/nut --with-statepath=/var/db/nut --with-altpidpath=/var/db/nut --with-pidpath=/var/db/nut --with-pkgconfig-dir=/usr/local/libdata/pkgconfig --with-user=nut --with-group=nut --with-python=/usr/local/bin/python3.11 --without-python2 --with-python3=/usr/local/bin/python3.11 --without-nut_monitor --with-ltdl --with-nut-scanner --with-avahi --with-cgi --with-cgipath=/usr/local/www/cgi-bin/nut --with-htmlpath=/usr/local/www/nut --with-gd-includes=-I/usr/local/include --with-gd-libs='-L/usr/local/lib -lgd' --without-dev --with-freeipmi --without-ipmi --with-doc=no --with-modbus --with-neon --without-nss --with-openssl --with-powerman --with-serial --with-snmp --with-usb=auto --prefix=/usr/local --mandir=/usr/local/man --disable-silent-rules --infodir=/usr/local/share/info/ --build=amd64-portbld-freebsd14.0 0.000053 [D1] debug level is '3' 0.000241 [D1] Succeeded to become_user(nut): now UID=316 GID=316 0.000268 [D1] upsdrv_initups... 0.000387 [D2] Checking device 1 of 1 (06DA/0005) 0.002373 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.002998 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.003622 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.003625 [D2] - VendorID: 06da 0.003627 [D2] - ProductID: 0005 0.003628 [D2] - Manufacturer: PPC 0.003630 [D2] - Product: USB UPS 0.003632 [D2] - Serial Number: unknown 0.003634 [D2] - Bus: 000 0.003636 [D2] - Bus Port: 007 0.003637 [D2] - Device: 002 0.003639 [D2] - Device release number: 0001 0.003641 [D2] Trying to match device 0.003643 [D3] match_function_regex: matching a device... 0.003652 [D2] Device matches 0.003654 [D2] Reading configuration descriptor 1 of 1 0.003671 [D3] libusb_kernel_driver_active() returned 0: Success 0.003675 [D2] Claimed interface 0 successfully 0.003677 [D3] nut_usb_set_altinterface: skipped libusb_set_interface_alt_setting(udev, 0, 0) 0.003686 [D2] Skipping protocol Voltronic 0.08 0.003688 [D2] Skipping protocol Voltronic-QS 0.09 0.003691 [D2] Skipping protocol Voltronic-QS-Hex 0.10 0.003693 [D2] Skipping protocol Mustek 0.08 0.003695 [D2] Skipping protocol Megatec/old 0.08 0.003696 [D2] Skipping protocol BestUPS 0.07 0.003698 [D2] Skipping protocol Mecer 0.08 0.066547 [D3] send: Q1 0.306233 [D3] read: (225.0 225.0 229.7 048 49.9 2.18 28.3 00000001 1.317829 [D3] flush: Timeout (-7) 1.318054 [D3] send: I 1.378224 [D3] read: 1.378268 [D2] qx_process_answer: short reply (ups.firmware) 1.442558 [D3] send: Q1 1.682233 [D3] read: (224.8 224.8 229.7 048 49.9 2.18 28.3 00000001 2.702010 [D3] flush: Timeout (-7) 2.702232 [D3] send: I 2.762328 [D3] read: 2.762343 [D2] qx_process_answer: short reply (ups.firmware) 2.826570 [D3] send: Q1 3.066243 [D3] read: (225.0 225.0 229.1 047 49.9 2.18 28.3 00000001 4.081737 [D3] flush: Timeout (-7) 4.081959 [D3] send: I 4.146236 [D3] read: 4.146251 [D2] qx_process_answer: short reply (ups.firmware) 4.146266 [D2] Skipping protocol Zinto 0.07 4.146274 [D2] Skipping protocol Masterguard 0.02 4.146281 [D2] Skipping protocol Hunnox 0.02 4.146287 [D2] Skipping protocol Ablerex 0.01 4.146294 [D2] Skipping protocol Q1 0.08 4.146299 Device not supported! 4.146305 Device not supported! 4.146346 upsnotify: failed to notify about state 4: no notification tech defined, will not spam more about it
looks pretty much the same.
-
@LanterIT How did you come to these two parameters when originally using the blazer_usb driver?
subdriver = "phoenix" protocol = "megatec"
-
The UPS was delivered with WinPower and I tried different settings with NUT and got it to work with the blazer_usb driver and these values.
-
@LanterIT said in NUT Package (2.8.1 and above):
I tried different settings with NUT and got it to work with the blazer_usb driver and these values.
And blazer_usb did not work without those two values, correct?
Also, you confirmed that usbhid did not work, correct?
-
Without these values, the UPS is connected, but the battery values displayed are incorrect, e.g:
battery.voltage 2.18 battery.voltage.high -1.08 battery.voltage.low -0.87
The usbhid did not work, no connection
-
@LanterIT Looking at the all the debug output, it appears that your UPS does not actually implement the full Megatec protocol. In particular, it does not respond to a request for Vendor Info (I).
Looking at the nutdrv_qx code, I suggest that you test these alternate settings for protocol: "q1", "zinto", "bestups", "hunnox".
My money is on the "q1" protocol.
You will probably also need to switch the subdriver setting to "cypress", or remove the subdriver setting altogether.
For reference...
The (current) valid values for 'protocol' are: voltronic, voltronic-qs, voltronic-qs-hex, mustek, megatec/old, bestups, mecer, megatec, zinto, masterguard, hunnox, ablerex, q1
The (current) valid values for 'subdriver' are: cypress, phoenixtec, phoenix, ippon, krauler, fabula, hunnox, fuji, sgs, snr, ablerex, armac
-
I briefly tested your suggestions without success.
With all combinations I get the following message and at the end device not supported.
Output for "q1" with "cypress":/usr/local/libexec/nut/nutdrv_qx -DDD -a ABB Network UPS Tools - Generic Q* USB/Serial driver 0.36 (2.8.0.1) USB communication driver (libusb 1.0) 0.46 0.000000 [D3] main_arg: var='driver' val='nutdrv_qx' 0.000036 [D3] main_arg: var='port' val='auto' 0.000058 [D3] main_arg: var='protocol' val='q1' 0.000089 [D3] main_arg: var='subdriver' val='cypress' 0.000108 [D3] main_arg: var='productid' val='0005' 0.000126 [D3] main_arg: var='vendorid' val='06da' 0.000163 [D1] Network UPS Tools version 2.8.0.1 (release/snapshot of 2.8.0.1) built with FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152); Target: x86_64-unknown-freebsd14.0; Thread model: posix and configured with flags: --sysconfdir=/usr/local/etc/nut --program-transform-name= --localstatedir=/var/db/nut --datadir=/usr/local/etc/nut --with-devd-dir=/usr/local/etc/devd --with-drvpath=/usr/local/libexec/nut --with-statepath=/var/db/nut --with-altpidpath=/var/db/nut --with-pidpath=/var/db/nut --with-pkgconfig-dir=/usr/local/libdata/pkgconfig --with-user=nut --with-group=nut --with-python=/usr/local/bin/python3.11 --without-python2 --with-python3=/usr/local/bin/python3.11 --with-ltdl --with-nut-scanner --with-avahi --with-cgi --with-cgipath=/usr/local/www/cgi-bin/nut --with-htmlpath=/usr/local/www/nut --with-gd-includes=-I/usr/local/include --with-gd-libs='-L/usr/local/lib -lgd' --without-dev --with-freeipmi --without-ipmi --with-doc=no --with-modbus --with-neon --without-nss --with-openssl --with-powerman --with-serial --with-snmp --with-usb=auto --prefix=/usr/local --mandir=/usr/local/man --disable-silent-rules --infodir=/usr/local/share/info/ --build=amd64-portbld-freebsd14.0 0.000185 [D1] debug level is '3' 0.000792 [D1] Succeeded to become_user(nut): now UID=316 GID=316 0.000897 [D1] upsdrv_initups... 0.001223 [D2] Checking device 1 of 1 (06DA/0005) 0.001400 [D1] nut_libusb_open: invalid libusb bus number 0 0.003378 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004013 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004763 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.004776 [D2] - VendorID: 06da 0.004783 [D2] - ProductID: 0005 0.004790 [D2] - Manufacturer: PPC 0.004797 [D2] - Product: USB UPS 0.004803 [D2] - Serial Number: unknown 0.004809 [D2] - Bus: ▒▒▒▒▒▒▒▒002 0.004815 [D2] - Bus Port: 007 0.004821 [D2] - Device: 002 0.004827 [D2] - Device release number: 0001 0.004833 [D2] Trying to match device 0.004839 [D3] match_function_regex: matching a device... 0.004875 [D2] Device matches 0.004882 [D2] Reading first configuration descriptor 0.004956 [D3] libusb_kernel_driver_active() returned 0: Success 0.004970 [D2] Claimed interface 0 successfully 0.004980 [D3] nut_usb_set_altinterface: skipped libusb_set_interface_alt_setting(udev, 0, 0) 0.005014 [D2] Skipping protocol Voltronic 0.08 0.005021 [D2] Skipping protocol Voltronic-QS 0.09 0.005028 [D2] Skipping protocol Voltronic-QS-Hex 0.10 0.005035 [D2] Skipping protocol Mustek 0.08 0.005041 [D2] Skipping protocol Megatec/old 0.08 0.005047 [D2] Skipping protocol BestUPS 0.07 0.005054 [D2] Skipping protocol Mecer 0.08 0.005065 [D2] Skipping protocol Megatec 0.07 0.005073 [D2] Skipping protocol Zinto 0.07 0.005079 [D2] Skipping protocol Masterguard 0.02 0.005085 [D2] Skipping protocol Hunnox 0.02 0.005091 [D2] Skipping protocol Ablerex 0.01 0.005455 [D3] send: Q1 0.238258 [D3] read: 0.238297 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 0.238509 [D3] send: Q1 0.478248 [D3] read: 0.478272 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 0.478492 [D3] send: Q1 0.718258 [D3] read: 0.718282 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 0.718291 Device not supported! 0.718297 Device not supported! 0.718338 upsnotify: failed to notify about state 4: no notification tech defined, will not spam more about it
-
@LanterIT said in NUT Package (2.8.1 and above):
I briefly tested your suggestions without success.
I'm wondering if there is a state issue as this debug output doesn't match the prior debug output for the first Q1 interaction.
Previously, the initial interaction looked list this:
0.066547 [D3] send: Q1 0.306233 [D3] read: (225.0 225.0 229.7 048 49.9 2.18 28.3 00000001 1.317829 [D3] flush: Timeout (-7) 1.318054 [D3] send: I 1.378224 [D3] read: 1.378268 [D2] qx_process_answer: short reply (ups.firmware) 1.442558 [D3] send: Q1 1.682233 [D3] read: (224.8 224.8 229.7 048 49.9 2.18 28.3 00000001 2.702010 [D3] flush: Timeout (-7) 2.702232 [D3] send: I 2.762328 [D3] read: 2.762343 [D2] qx_process_answer: short reply (ups.firmware) 2.826570 [D3] send: Q1 3.066243 [D3] read: (225.0 225.0 229.1 047 49.9 2.18 28.3 00000001 4.081737 [D3] flush: Timeout (-7)
Each time it responded to Q1. However the initial interaction in your last run looks like this:
0.005455 [D3] send: Q1 0.238258 [D3] read: 0.238297 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 0.238509 [D3] send: Q1 0.478248 [D3] read: 0.478272 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28] 0.478492 [D3] send: Q1 0.718258 [D3] read: 0.718282 [D2] qx_process_answer: input.voltage - invalid start character [00], expected [28]
The UPS is sending breaks rather than the expected open paren. I note that the same thing happened when testing with automatic detection, when the driver sends a bunch of commands to the UPS..
The reason that I suggested those protocols is because they are the ones that do not require a response to I.
There are apparently some of these UPSs that have strict ordering of commands. I'll have to research a bit more.
While I do that, please repeat the q1 test a few times to see if the UPS state clears. I.E. a correct response to Q1. If you have physical proximity to the UPS, it may be worthwhile to unplug/replug the USB connection prior to the attempt.
EDIT: Please use "protocol=q1" and "subdriver=phoenix" in the test.
-
During the last test, almost all devices were shut down after a driver incorrectly returned OnBattery.
OK, this part seems to work.
For further tests, I first have to set up an unproductive pfSense.
-
@LanterIT said in NUT Package (2.8.1 and above):
During the last test, almost all devices were shut down after a driver incorrectly returned OnBattery.
Okay. Sorry about that. Please let me know.
Edit: It might be easier to disable the NUT's shutdown behavior than to set up a separate test system.
You can temporarily suppress the local pfSense shutdown by placing
SHUTDOWNCMD "/bin/echo"
in the "Additional configuration lines for upsmon.conf" section.
If you are using the pfSense NUT instance as a server for other remote NUT clients, you would also need to temporarily disable their access.
-
That wasn't your fault. I have tried the usbhid driver again.
I have now connected the UPS to an APU2 with pfSense.
pfSense and packages are up to date and the blazer_usb works here.In a further step, I tried it again with nutdrv_qx. Now I get values with the following parameters:
protocol="q1" subdriver="phoenix" productid=0005 vendorid=06da override.battery.packs = 18 override.battery.voltage.nominal = 36 battery_voltage_reports_one_pack
They are partially correct, but the battery voltage always remains at approx. 2.18 V and battery charge is at 0%.
Any suggestions to solve this?
-
@LanterIT Do you have DDD output available?
-
here you go:
/usr/local/libexec/nut/nutdrv_qx -a ABB -DDD Network UPS Tools - Generic Q* USB/Serial driver 0.36 (2.8.1.1) USB communication driver (libusb 1.0) 0.46 0.000000 [D1] Network UPS Tools version 2.8.1.1 (release/snapshot of 2.8.1.1) built with FreeBSD clang version 16.0.6 (https://github.com/llvm/llvm-project.git llvmorg-16.0.6-0-g7cbf1a259152); Target: x86_64-unknown-freebsd14.0; Thread model: posix and configured with flags: --sysconfdir=/usr/local/etc/nut --program-transform-name= --localstatedir=/var/db/nut --datadir=/usr/local/etc/nut --with-devd-dir=/usr/local/etc/devd --with-drvpath=/usr/local/libexec/nut --with-statepath=/var/db/nut --with-altpidpath=/var/db/nut --with-pidpath=/var/db/nut --with-pkgconfig-dir=/usr/local/libdata/pkgconfig --with-user=nut --with-group=nut --with-python=/usr/local/bin/python3.11 --without-python2 --with-python3=/usr/local/bin/python3.11 --without-nut_monitor --with-ltdl --with-nut-scanner --with-avahi --with-cgi --with-cgipath=/usr/local/www/cgi-bin/nut --with-htmlpath=/usr/local/www/nut --with-gd-includes=-I/usr/local/include --with-gd-libs='-L/usr/local/lib -lgd' --without-dev --with-freeipmi --without-ipmi --with-doc=no --with-modbus --with-neon --without-nss --with-openssl --with-powerman --with-serial --with-snmp --with-usb=auto --prefix=/usr/local --mandir=/usr/local/man --disable-silent-rules --infodir=/usr/local/share/info/ --build=amd64-portbld-freebsd14.0 0.000239 [D1] debug level is '3' 0.001790 [D1] Succeeded to become_user(nut): now UID=316 GID=316 0.001959 [D1] upsdrv_initups... 0.003102 [D2] Checking device 1 of 1 (06DA/0005) 0.090800 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.119843 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.148917 [D1] nut_libusb_open get iSerialNumber failed, retrying... 0.149057 [D2] - VendorID: 06da 0.149093 [D2] - ProductID: 0005 0.149120 [D2] - Manufacturer: PPC 0.149136 [D2] - Product: USB UPS 0.149170 [D2] - Serial Number: unknown 0.149200 [D2] - Bus: 000 0.149214 [D2] - Bus Port: 003 0.149227 [D2] - Device: 002 0.149255 [D2] - Device release number: 0001 0.149279 [D2] Trying to match device 0.149312 [D3] match_function_regex: matching a device... 0.149448 [D2] Device matches 0.149486 [D2] Reading configuration descriptor 1 of 1 0.149748 [D3] libusb_kernel_driver_active() returned 0: Success 0.149806 [D2] Claimed interface 0 successfully 0.149831 [D3] nut_usb_set_altinterface: skipped libusb_set_interface_alt_setting(udev, 0, 0) 0.149962 [D2] Skipping protocol Voltronic 0.08 0.149980 [D2] Skipping protocol Voltronic-QS 0.09 0.149997 [D2] Skipping protocol Voltronic-QS-Hex 0.10 0.150014 [D2] Skipping protocol Mustek 0.08 0.150035 [D2] Skipping protocol Megatec/old 0.08 0.150051 [D2] Skipping protocol BestUPS 0.07 0.150082 [D2] Skipping protocol Mecer 0.08 0.150114 [D2] Skipping protocol Megatec 0.07 0.150130 [D2] Skipping protocol Zinto 0.07 0.150147 [D2] Skipping protocol Masterguard 0.02 0.150187 [D2] Skipping protocol Hunnox 0.02 0.150220 [D2] Skipping protocol Ablerex 0.01 1.185604 [D3] flush: Timeout (-7) 1.192724 [D3] send: Q1 1.427098 [D3] read: (227.2 227.2 229.9 046 49.9 2.18 28.0 00000001 1.427321 Using protocol: Q1 0.08 1.427385 [D1] upsdrv_initinfo... 2.515288 [D3] flush: Timeout (-7) 2.521959 [D3] send: Q1 2.755117 [D3] read: (227.2 227.2 229.9 046 49.9 2.18 28.0 00000001 2.755842 No values for battery high/low voltages 2.755891 Using 'guesstimation' (low: 31.200000, high: 39.000000)! 2.755951 Battery runtime will not be calculated (runtimecal not set) 2.756047 [D1] upsdrv_updateinfo... 2.756070 [D1] Quick update... 3.831254 [D3] flush: Timeout (-7) 3.837639 [D3] send: Q1 4.074734 [D3] read: (227.0 227.0 230.4 046 49.9 2.18 28.0 00000001 4.075893 [D2] dstate_init: sock /var/db/nut/nutdrv_qx-ABB open on fd 8 4.076108 Running as foreground process, not saving a PID file 4.076162 [D1] Driver initialization completed, beginning regular infinite loop 4.076181 upsnotify: failed to notify about state 2: no notification tech defined, will not spam more about it 4.076203 [D1] upsdrv_updateinfo... 4.076223 [D1] Quick update... 5.150175 [D3] flush: Timeout (-7) 5.156660 [D3] send: Q1 5.394689 [D3] read: (227.2 227.2 230.4 046 49.9 2.18 28.0 00000001 5.394879 sock_connect: enabling asynchronous mode (auto) 5.395089 [D3] new connection on fd 9 5.395169 [D2] send_to_one: sending SETINFO battery.charge "0" 5.395201 [D2] send_to_one: sending SETINFO battery.packs "18" 5.395259 [D2] send_to_one: sending SETFLAGS battery.packs 5.395284 [D2] send_to_one: sending SETINFO battery.voltage "2.18" 5.395340 [D2] send_to_one: sending SETINFO battery.voltage.high "39.00" 5.395364 [D2] send_to_one: sending SETINFO battery.voltage.low "31.20" 5.395389 [D2] send_to_one: sending SETINFO battery.voltage.nominal "36" 5.395444 [D2] send_to_one: sending SETFLAGS battery.voltage.nominal 5.395499 [D2] send_to_one: sending SETINFO device.type "ups" 5.395523 [D2] send_to_one: sending SETINFO driver.debug "3" 5.395580 [D2] send_to_one: sending SETFLAGS driver.debug RW NUMBER 5.395604 [D2] send_to_one: sending SETINFO driver.flag.allow_killpower "0" 5.395630 [D2] send_to_one: sending SETFLAGS driver.flag.allow_killpower RW NUMBER 5.395679 [D2] send_to_one: sending SETINFO driver.flag.battery_voltage_reports_one_pack "enabled" 5.395729 [D2] send_to_one: sending SETINFO driver.name "nutdrv_qx" 5.395753 [D2] send_to_one: sending SETINFO driver.parameter.override.battery.packs "18" 5.395778 [D2] send_to_one: sending SETINFO driver.parameter.override.battery.voltage.nominal "36" 5.395833 [D2] send_to_one: sending SETINFO driver.parameter.pollfreq "30" 5.395857 [D2] send_to_one: sending SETINFO driver.parameter.pollinterval "2" 5.395906 [D2] send_to_one: sending SETINFO driver.parameter.port "auto" 5.395930 [D2] send_to_one: sending SETINFO driver.parameter.productid "0005" 5.395954 [D2] send_to_one: sending SETINFO driver.parameter.protocol "q1" 5.395978 [D2] send_to_one: sending SETINFO driver.parameter.subdriver "phoenix" 5.396001 [D2] send_to_one: sending SETINFO driver.parameter.synchronous "auto" 5.396025 [D2] send_to_one: sending SETINFO driver.parameter.vendorid "06da" 5.396056 [D2] send_to_one: sending SETINFO driver.state "quiet" 5.396080 [D2] send_to_one: sending SETINFO driver.version "2.8.1.1" 5.396103 [D2] send_to_one: sending SETINFO driver.version.data "Q1 0.08" 5.396157 [D2] send_to_one: sending SETINFO driver.version.internal "0.36" 5.396182 [D2] send_to_one: sending SETINFO driver.version.usb "libusb-1.0.0 (API: 0x1000102)" 5.396206 [D2] send_to_one: sending SETINFO input.frequency "49.9" 5.396230 [D2] send_to_one: sending SETINFO input.voltage "227.2" 5.396254 [D2] send_to_one: sending SETINFO input.voltage.fault "227.2" 5.396277 [D2] send_to_one: sending SETINFO output.voltage "229.9" 5.396325 [D2] send_to_one: sending SETINFO ups.beeper.status "enabled" 5.396349 [D2] send_to_one: sending SETINFO ups.delay.shutdown "30" 5.396374 [D2] send_to_one: sending ADDRANGE ups.delay.shutdown 12 600 5.396400 [D2] send_to_one: sending SETFLAGS ups.delay.shutdown RW NUMBER 5.396423 [D2] send_to_one: sending SETINFO ups.delay.start "180" 5.396446 [D2] send_to_one: sending ADDRANGE ups.delay.start 0 599940 5.396496 [D2] send_to_one: sending SETFLAGS ups.delay.start RW NUMBER 5.396520 [D2] send_to_one: sending SETINFO ups.load "46" 5.396544 [D2] send_to_one: sending SETINFO ups.productid "0005" 5.396568 [D2] send_to_one: sending SETINFO ups.status "OL" 5.396591 [D2] send_to_one: sending SETINFO ups.temperature "28.0" 5.396640 [D2] send_to_one: sending SETINFO ups.type "online" 5.396688 [D2] send_to_one: sending SETINFO ups.vendorid "06da" 5.396732 [D2] send_to_one: sending ADDCMD beeper.toggle 5.396767 [D2] send_to_one: sending ADDCMD driver.killpower 5.396790 [D2] send_to_one: sending ADDCMD driver.reload 5.396829 [D2] send_to_one: sending ADDCMD driver.reload-or-error 5.396868 [D2] send_to_one: sending ADDCMD driver.reload-or-exit 5.396892 [D2] send_to_one: sending ADDCMD load.off 5.396940 [D2] send_to_one: sending ADDCMD load.on 5.396963 [D2] send_to_one: sending ADDCMD shutdown.return 5.396985 [D2] send_to_one: sending ADDCMD shutdown.stayoff 5.397008 [D2] send_to_one: sending ADDCMD shutdown.stop 5.397036 [D2] send_to_one: sending ADDCMD test.battery.start 5.397060 [D2] send_to_one: sending ADDCMD test.battery.start.deep 5.397099 [D2] send_to_one: sending ADDCMD test.battery.start.quick 5.397139 [D2] send_to_one: sending ADDCMD test.battery.stop 5.397192 [D2] send_to_one: sending DATAOK 5.397215 [D2] send_to_one: sending DUMPDONE 6.077221 [D1] upsdrv_updateinfo... 6.077350 [D1] Quick update... 7.150342 [D3] flush: Timeout (-7) 7.156732 [D3] send: Q1 7.395152 [D3] read: (227.0 227.0 230.4 048 49.9 2.18 27.9 00000001 8.092753 [D1] upsdrv_updateinfo... 8.092830 [D1] Quick update... 9.166248 [D3] flush: Timeout (-7) 9.172723 [D3] send: Q1 9.410777 [D3] read: (226.7 226.7 230.6 047 49.9 2.18 27.9 00000001 10.093141 [D1] upsdrv_updateinfo... 10.093246 [D1] Quick update... 11.166278 [D3] flush: Timeout (-7) 11.172787 [D3] send: Q1 11.410780 [D3] read: (227.2 227.2 229.7 046 49.9 2.18 28.0 00000001 12.094144 [D1] upsdrv_updateinfo... 12.094240 [D1] Quick update... 13.166398 [D3] flush: Timeout (-7) 13.172831 [D3] send: Q1 13.410816 [D3] read: (227.0 227.0 229.9 046 49.9 2.18 27.9 00000001 14.095131 [D1] upsdrv_updateinfo... 14.095203 [D1] Quick update... 15.166410 [D3] flush: Timeout (-7) 15.172846 [D3] send: Q1 15.410921 [D3] read: (227.2 227.2 230.1 046 49.9 2.18 28.0 00000001 16.109145 [D1] upsdrv_updateinfo... 16.109229 [D1] Quick update... 16.828198 [D1] set_exit_flag: raising exit flag due to signal 2 16.830334 [D3] flush: Other error (-99) 16.836886 [D3] send: Q1 17.074899 [D3] read: (226.5 226.5 230.4 045 49.9 2.18 28.0 00000001 18.110242 Signal 2: exiting
Thanks in advance