table of contents
- NAME
- SYNOPSIS
- SUPPORTED HARDWARE
- EXTRA ARGUMENTS
- UPS COMMANDS
- BATTERY CHARGE GUESSTIMATION
- NOTES FOR THE PREVIOUS USER OF MEGATEC DRIVERS
- NOTES FOR THE PREVIOUS USER OF BLAZER DRIVERS
- NOTES FOR THE PREVIOUS USER OF BESTUPS DRIVER
- NOTES FOR THE PREVIOUS USER OF VOLTRONIC DRIVERS
- KNOWN PROBLEMS
- UPS WARNINGS (VOLTRONIC PROTOCOL)
- AUTHORS
- SEE ALSO
NUTDRV_QX(8) | NUT Manual | NUTDRV_QX(8) |
NAME¶
nutdrv_qx - Driver for Q* protocol serial and USB based UPS equipment
SYNOPSIS¶
nutdrv_qx -h
nutdrv_qx -a UPS_NAME [OPTIONS]
Note
This man page only documents the hardware-specific features of the nutdrv_qx driver. For information about the core driver, see nutupsdrv(8).
SUPPORTED HARDWARE¶
The nutdrv_qx driver is known to work with various UPSes from Armac, Blazer, Energy Sistem, Fenton Technologies, General Electric, Hunnox, Masterguard, Mustek, Powercool, Voltronic Power, SKE (rebranded by many, many - have I said many? - others...
Long story short: if your UPS came with a software called Viewpower, chances are high that it works with this driver with one of the voltronic* protocols or with the mecer one), and many others.
The NUT compatibility table lists all the known supported models. Keep in mind, however, that other models not listed there may also be supported, but haven’t been tested or reported back.
All devices with a serial interface and many with a USB interface are supported.
EXTRA ARGUMENTS¶
You may need to override or provide defaults for some values, depending on the make and model of your UPS.
The following are the ones that most likely will need changing (see ups.conf(5)):
ondelay = value
Note that a value below 3 minutes, may cause earlier firmware versions to not switch on automatically, so it defaults to 3 minutes (i.e. 180 seconds).
This option provides a default value for ups.delay.start that will then be used by the driver in the automatic shutdown sequence (i.e. calling the driver with the -k option, calling upsdrvctl(8) with the shutdown option or when the FSD flag is set and upsmon(8) enters its shutdown sequence): however you can change this value ‘on the fly’ for the actual session, only for the use with instant commands, setting ups.delay.start with upsrw(8).
offdelay = value
This option provides a default value for ups.delay.shutdown that will then be used by the driver in the automatic shutdown sequence (i.e. calling the driver with the -k option, calling upsdrvctl(8) with the shutdown option or when the FSD flag is set and upsmon(8) enters its shutdown sequence): however you can change this value ‘on the fly’ for the actual session, only for the use with instant commands, setting ups.delay.shutdown with upsrw(8).
stayoff
protocol = string
Run the driver program with the --help option to see the exact list of protocol values it would currently recognize.
Note that if you end up using the q1 protocol, you may want to give a try to the mecer, megatec and zinto ones setting the novendor/norating flags (only one, or both).
pollfreq = num
If your UPS doesn’t report either battery.charge or battery.runtime you may want to add the following ones in order to have guesstimated values:
default.battery.voltage.high = value
default.battery.voltage.low = value
default.battery.voltage.nominal = value, override.battery.voltage.nominal = value
override.battery.packs = value
For instance, if battery.voltage.nominal is 24 V, but it reports a battery.voltage of around 2 V, the number of battery.packs to correct this reading would be 12.
The driver will attempt to detect this number automatically, but if this fails somehow, you may want to override this value.
Note that this is primarily useful for "guesstimation" of battery.charge and/or battery.runtime (with runtimecal setting), if those readings are not provided by the device directly.
battery_voltage_reports_one_pack
If this flag is set, most of the subdrivers (except those which know about more complicated device-specific nuances, currently: ablerex, masterguard and voltronic-qs-hex) adjust their ultimately reported battery.voltage value as a multiple of battery.packs and "native" battery.voltage).
Note this is primarily useful for consistent diagnostics and graphing of the numbers, and should not impact the "guesstimation" of battery.charge and/or battery.runtime - so rather a cosmetic adjustment, than critical.
runtimecal = value,value,value,value
runtimecal = 240,100,720,50
The first load should always be higher than the second. If you have values available for loads other than 100 and 50 % respectively, you can use those too, but keep them spaced apart as far as reasonably possible. Just don’t get too close to no load (prediction of runtime depends more on idle load for the battery then).
chargetime = value
idleload = value
BESTUPS, MECER, MEGATAEC, MEGATEC/OLD, MUSTEK, Q1, VOLTRONIC-QS, VOLTRONIC-QS-HEX, ZINTO PROTOCOLS¶
ignoresab
MECER, MEGATAEC, MEGATEC/OLD, MUSTEK, ZINTO PROTOCOLS¶
ondelay
offdelay
norating
novendor
BESTUPS PROTOCOL¶
ondelay
offdelay
pins_shutdown_mode = value
MASTERGUARD PROTOCOL¶
slave_addr = value
Q1 PROTOCOL¶
ondelay
offdelay
VOLTRONIC-QS, VOLTRONIC-QS-HEX PROTOCOLS¶
ondelay
offdelay
VOLTRONIC PROTOCOL¶
The following options are supported only by the voltronic protocol. Not all of them are available on all the UPSes supported by this protocol.
ondelay
offdelay
battery_number = value
output_phase_angle = value
UPS CAPABILITY SETTINGS
reset_to_default
Note that setting this option will reset also ups.start.auto, battery.protection, battery.energysave, ups.start.battery, outlet.0.switchable, input.transfer.high, input.transfer.low, input.frequency.high and input.frequency.low.
These UPSes can be fine-tuned to suit your needs enabling or disabling the following options (the driver should tell you which one the UPS is capable of on startup: the settable ones will be reported either are enabled or disabled in the logs):
alarm_control = string
bypass_alarm = string
battery_alarm = string
bypass_when_off = string
bypass_forbidding = string
converter_mode = string
eco_mode = string
advanced_eco_mode = string
battery_open_status_check = string
site_fault_detection = string
constant_phase_angle = string
limited_runtime_on_battery = string
BYPASS MODE VOLTAGE/FREQUENCY LIMITS
Variables to fine-tune voltage and frequency limits for Bypass mode. These limits are reset to safe default values by reset_to_default.
If AC voltage and frequency are within acceptable range, Bypass mode will be used (If the UPS is capable of and it’s enabled).
Since these values are device-specific, if your UPS support them, you will get their settable limits printed in the logs on startup.
max_bypass_volt = value
min_bypass_volt = value
max_bypass_freq = value
min_bypass_freq = value
OPTIONS SPECIFIC FOR P31 UPSES
The following options are available only on P31 UPSes.
work_range_type = string
TESTING
This protocol comes with a couple of functions that are not enabled by default because of the lack of knowledge of some part of the communication protocol used by these UPSes by your friendly neighborhood developer. Since these functions are supposed to be queries to the UPS for some kind of information, they should not make your UPS go boom. So if you are brave enough to risk your UPS and attached devices' life to help the developers, this will be very appreciated.. Do it at your own risk.
testing
SERIAL INTERFACE ONLY¶
cablepower = string
USB INTERFACE ONLY¶
port = string
Note
This could be a device filesystem path like /dev/usb/hiddev0 but current use of libusb API precludes knowing and matching by such identifiers. They may also be inherently unreliable (dependent on re-plugging and enumeration order). At this time the actual value is ignored, but syntactically some port configuration must still be there.
It is possible to control multiple UPS units simultaneously by running several instances of this driver, provided they can be uniquely distinguished by setting some combination of the vendor, product, vendorid, productid, serial, bus and/or device options detailed below. For devices or operating systems that do not provide sufficient information, the allow_duplicates option can be of use (limited and risky!)
vendorid = regex, productid = regex, vendor = regex, product = regex, serial = regex
Try lsusb(8) or running this NUT driver with -DD command-line argument for finding out the strings to match.
Examples:
bus = regex
device = regex
Note
device numbers are not guaranteed by the OS to be stable across re-boots or device re-plugging.
busport = regex
Note
this option is not practically supported by some NUT builds (it should be ignored with a warning then), and not by all systems that NUT can run on.
allow_duplicates
Normally the driver initialization would abort at this point claiming "Resource busy" or similar error, assuming that the otherwise properly matched device is unique — and some other process already handles it.
Warning
This feature is inherently non-deterministic! The association of driver instance name to actual device may vary between runs!
If you only care to know that at least one of your no-name UPSes is online, this option can help.
If you must really know which one, it will not!
usb_set_altinterface = bAlternateSetting
usb_config_index, usb_hid_rep_index, usb_hid_desc_index, usb_hid_ep_in, usb_hid_ep_out
As a rule of thumb for usb_hid_desc_index discovery, you can see larger wDescriptorLength values (roughly 600+ bytes) in reports of lsusb or similar tools.
subdriver = string
Run the driver program with the --help option to see the exact list of subdriver values it would currently recognize.
Note
When using this option, it is mandatory to also specify the vendorid and productid matching parameters.
langid_fix = value
noscanlangid
IMPLEMENTATION NOTES
armac subdriver
fabula subdriver
hunnox subdriver
fuji subdriver
krauler subdriver
snr subdriver
UPS COMMANDS¶
This driver supports some instant commands (see upscmd(8)):
beeper.toggle
load.on
load.off
shutdown.return
shutdown.stayoff
shutdown.stop
test.battery.start.deep
test.battery.start.quick
test.battery.stop
BESTUPS, MECER, MEGATEC, MEGATEC/OLD, MUSTEK, Q1, ZINTO PROTOCOLS¶
test.battery.start value
MASTERGUARD PROTOCOL¶
beeper.enable
beeper.disable
test.battery.start value
bypass.start
bypass.stop
VOLTRONIC POWER P98 UNITS (WITH MECER PROTOCOL)
test.battery.start value
VOLTRONIC PROTOCOL¶
The following instant commands are available for the voltronic protocol. Not all of them are available on all the UPSes supported by this protocol.
beeper.enable
beeper.disable
test.battery.start value
outlet.1.load.off
outlet.1.load.on
outlet.2.load.off
outlet.2.load.on
outlet.3.load.off
outlet.3.load.on
outlet.4.load.off
outlet.4.load.on
bypass.start
bypass.stop
BATTERY CHARGE GUESSTIMATION¶
Due to popular demand, this driver will report a guesstimated battery.charge and optionally battery.runtime, provided you specified a couple of the EXTRA ARGUMENTS listed above.
If you specify both battery.voltage.high and battery.voltage.low in ups.conf(5), but don’t enter runtimecal, it will guesstimate the state of charge by looking at the battery voltage alone. This is not reliable under load, as this only gives reasonably accurate readings if you disconnect the load, let the battery rest for a couple of minutes and then measure the open cell voltage. This just isn’t practical if the power went out and the UPS is providing power for your systems.
battery.voltage - battery.voltage.low battery.charge = ------------------------------------------ x 100 %
battery.voltage.high - battery.voltage.low
There is a way to get better readings without disconnecting the load but this requires one to keep track on how much (and how fast) current is going in and out of the battery. If you specified the runtimecal, the driver will attempt to do this. Note however, that this heavily relies on the values you enter and that the UPS must be able to report the load as well. There are quite a couple of devices that report 0 % (or any other fixed value) at all times, in which case this obviously doesn’t work.
The driver also has no way of determining the degradation of the battery capacity over time, so you’ll have to deal with this yourself (by adjusting the values in runtimecal). Also note that the driver guesses the initial state of charge based on the battery voltage, so this may be less than 100 %, even when you are certain that they are full. There is just no way to reliably measure this between 0 and 100 % full charge.
This is better than nothing (but not by much). If any of the above calculations is giving you incorrect readings, you are the one that put in the values in ups.conf(5), so don’t complain with the author. If you need something better, buy a UPS that reports battery.charge and battery.runtime all by itself without the help of a NUT driver.
NOTES FOR THE PREVIOUS USER OF MEGATEC DRIVERS¶
The nutdrv_qx driver having replaced the megatec ones, some configuration changes may be required by users switching to nutdrv_qx.
Part of this, the following megatec options, in ups.conf(5), have to be changed:
battvolts
dtr and rts
ignoreoff
NOTES FOR THE PREVIOUS USER OF BLAZER DRIVERS¶
The nutdrv_qx driver having replaced the blazer ones, some configuration changes may be required by users switching to nutdrv_qx.
Part of this, the following blazer options, in ups.conf(5), have to be changed:
ondelay
The following instant command has also been changed:
test.battery.start value
NOTES FOR THE PREVIOUS USER OF BESTUPS DRIVER¶
The nutdrv_qx driver having replaced the bestups one, some configuration changes may be required by users switching to nutdrv_qx.
Part of this, the following bestups options, in ups.conf(5), are no longer supported by this driver:
nombattvolt, battvoltmult
ID
NOTES FOR THE PREVIOUS USER OF VOLTRONIC DRIVERS¶
The nutdrv_qx driver having replaced the voltronic ones, some configuration changes may be required by users switching to nutdrv_qx.
Part of this, the following voltronic options, in ups.conf(5), have to be changed:
ondelay
battnumb
The following options are no longer supported by this driver, you can now change them more conveniently ‘on the fly’ calling upsrw(8) with the appropriate NUT variable - provided that your UPS supports them.
battpacks | → battery.packs Set number of battery packs in parallel [1..99]. This setting will change the charge and runtime estimation reported by the UPS. |
battlow | → battery.voltage.low Set minimum battery voltage just before the UPS automatically shuts down. This setting will change the charge and runtime estimation reported by the UPS. |
auto_reboot | → ups.start.auto Enable or disable auto reboot [enabled/disabled]. If enabled, the UPS will auto recover when AC power returns. |
battery_protection | → battery.protection Enable or disable battery deep discharge protection [enabled/disabled]. |
energy_saving | → battery.energysave Enable or disable Green power function [enabled/disabled]. If enabled, for energy saving, the UPS will auto off when there is no load. |
cold_start | → ups.start.battery Enable or disable Cold Start [enabled/disabled]. If enabled, the UPS can be turned on also if AC is not connected to the UPS. |
outlet_control | → outlet.0.switchable Enable or disable programmable outlets control at battery mode [enabled/disabled]. If enabled, the UPS will cut off programmable outlets after backup time (set through outlet.{1,2,3,4}.delay.shutdown) arrives. If disabled, the UPS will provide continuous power to programmable outlets until the battery is running out. |
max_eco_volt | → input.transfer.high Maximum voltage for ECO Mode (V). If AC voltage is within acceptable range, ECO mode will be used (If the UPS is capable of and it’s enabled). |
min_eco_volt | → input.transfer.low Minimum voltage for ECO Mode (V). If AC voltage is within acceptable range, ECO mode will be used (If the UPS is capable of and it’s enabled). |
max_eco_freq | → input.frequency.high Maximum frequency for ECO Mode (Hz). If AC frequency is within acceptable range, ECO mode will be used (If the UPS is capable of and it’s enabled). |
min_eco_freq | → input.frequency.low Minimum frequency for ECO Mode (Hz). If AC frequency is within acceptable range, ECO mode will be used (If the UPS is capable of and it’s enabled). |
outlet1_delay | → outlet.1.delay.shutdown Delay time before programmable outlet 1 shuts down the load when on battery mode [0..59940] (seconds). |
outlet2_delay | → outlet.2.delay.shutdown Delay time before programmable outlet 2 shuts down the load when on battery mode [0..59940] (seconds). |
outlet3_delay | → outlet.3.delay.shutdown Delay time before programmable outlet 3 shuts down the load when on battery mode [0..59940] (seconds). |
outlet4_delay | → outlet.4.delay.shutdown Delay time before programmable outlet 4 shuts down the load when on battery mode [0..59940] (seconds). |
batt_type | → battery.type Battery type (for P31 UPSes only) [Li/Flooded/AGM]. |
KNOWN PROBLEMS¶
Some UPS commands aren’t supported by all models. In most cases, the driver will send a message to the system log when the user tries to execute an unsupported command. Unfortunately, some models don’t even provide a way for the driver to check for this, so the unsupported commands will silently fail.
Both the load.off and shutdown.stayoff instant commands are meant to turn the load off indefinitely. However, some UPS models don’t allow this.
Some models report a bogus value for the beeper status (will always be enabled or disabled). So, the beeper.toggle command may appear to have no effect in the status reported by the driver when, in fact, it is working fine.
The temperature and load value is known to be bogus in some models.
MASTERGUARD UNITS¶
The driver is supposed to support both "new" A series (A700/1000/2000/3000 and their -19 cousins) and E series (E60/100/200) but was tested only on A due to lack of E hardware.
VOLTRONIC-QS UNITS¶
Both load.off and shutdown.stayoff instant commands are known to work as expected (i.e. turn the load off indefinitely) only if mains is present, otherwise, as soon as mains returns the load will be powered.
After issuing a shutdown.return instant command, the UPS won’t wait ondelay before powering on the load, provided the following conditions are met:
In this case, as soon as mains returns the load will be powered.
VOLTRONIC-QS-HEX UNITS¶
shutdown.return, load.off, and shutdown.stayoff instant commands are known to work as expected only if mains is present, otherwise, as soon as mains returns the load will be powered.
UPS WARNINGS (VOLTRONIC PROTOCOL)¶
The UPSes supported by voltronic protocol report warnings through a 64bit flag (bit1bit2...bit63bit64) where 1 means that a warning arose, while 0 means no warning. Since more than one warning at a time can be signaled, and because of the limited space in the ups.alarm variable, if the length of the warnings exceeds that of ups.alarms variable, they will be reported as bits. If you want to know the explanation of that bit you can either watch the log or see the next table (unlisted bits equal to unknown warnings).
Table 1. UPS Warnings for voltronic UPSes
# | Corresponding Warning |
1 | Battery disconnected |
2 | Neutral not connected |
3 | Site fault |
4 | Phase sequence incorrect |
5 | Phase sequence incorrect in bypass |
6 | Input frequency unstable in bypass |
7 | Battery overcharged |
8 | Low battery |
9 | Overload alarm |
10 | Fan alarm |
11 | EPO enabled |
12 | Unable to turn on UPS |
13 | Over temperature alarm |
14 | Charger alarm |
15 | Remote auto shutdown |
16 | L1 input fuse not working |
17 | L2 input fuse not working |
18 | L3 input fuse not working |
19 | Positive PFC abnormal in L1 |
20 | Negative PFC abnormal in L1 |
21 | Positive PFC abnormal in L2 |
22 | Negative PFC abnormal in L2 |
23 | Positive PFC abnormal in L3 |
24 | Negative PFC abnormal in L3 |
25 | Abnormal in CAN-bus communication |
26 | Abnormal in synchronous signal circuit |
27 | Abnormal in synchronous pulse signal circuit |
28 | Abnormal in host signal circuit |
29 | Male connector of parallel cable not connected well |
30 | Female connector of parallel cable not connected well |
31 | Parallel cable not connected well |
32 | Battery connection not consistent in parallel systems |
33 | AC connection not consistent in parallel systems |
34 | Bypass connection not consistent in parallel systems |
35 | UPS model types not consistent in parallel systems |
36 | Capacity of UPSs not consistent in parallel systems |
37 | Auto restart setting not consistent in parallel systems |
38 | Battery cell over charge |
39 | Battery protection setting not consistent in parallel systems |
40 | Battery detection setting not consistent in parallel systems |
41 | Bypass not allowed setting not consistent in parallel systems |
42 | Converter setting not consistent in parallel systems |
43 | High loss point for frequency in bypass mode not consistent in parallel systems |
44 | Low loss point for frequency in bypass mode not consistent in parallel systems |
45 | High loss point for voltage in bypass mode not consistent in parallel systems |
46 | Low loss point for voltage in bypass mode not consistent in parallel systems |
47 | High loss point for frequency in AC mode not consistent in parallel systems |
48 | Low loss point for frequency in AC mode not consistent in parallel systems |
49 | High loss point for voltage in AC mode not consistent in parallel systems |
50 | Low loss point for voltage in AC mode not consistent in parallel systems |
51 | Warning for locking in bypass mode after 3 consecutive overloads within 30 min |
52 | Warning for three-phase AC input current unbalance |
53 | Warning for a three-phase input current unbalance detected in battery mode |
54 | Warning for Inverter inter-current unbalance |
55 | Programmable outlets cut off pre-alarm |
56 | Warning for Battery replace |
57 | Abnormal warning on input phase angle |
58 | Warning!! Cover of maintain switch is open |
62 | EEPROM operation error |
AUTHORS¶
Daniele Pezzini <hyouko@gmail.com>
SEE ALSO¶
blazer_ser(8), blazer_usb(8), nutupsdrv(8), ups.conf(5), upsc(8), upscmd(8), upsdrvctl(8), upsmon(8), upsrw(8)
Internet Resources:¶
09/29/2024 | Network UPS Tools 2.8.2 |