-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Friday, 2021-04-16 at 22:22 +0200, Roger Price wrote:
On Fri, 16 Apr 2021, Carlos E. R. wrote:
El 2021-04-16 a las 21:29 +0200, Roger Price escribió:
On Fri, 16 Apr 2021, Carlos E. R. wrote:
Isengard:~ # upsc Salicru battery.charge: 100 battery.voltage: 13.60 battery.voltage.high: 13.00 battery.voltage.low: 10.40 battery.voltage.nominal: 12.0 ...
I don't see variable battery.charge.low which specifies the charge below which the LB (Low Battery) status is raised, signalling that the time has come to shutdown.
Does the command "upsrw Salicru" list the variable battery.charge.low ?
Isengard:~ # upsrw Salicru Isengard:~ #
Nope...
If you are using the blazer_usb driver there is a workaround using extra arguments to the driver:
* default.battery.voltage.high = value
Maximum battery voltage that is reached after about 12 to 24 hours charging. If you want the driver to report a guesstimated battery.charge, you need to specify this (see BATTERY CHARGE).
Well, that voltage is the same for every battery of the same chemicals :-)
* default.battery.voltage.low = value
Minimum battery voltage just before the UPS automatically shuts down. If you want the driver to report a guesstimated battery.charge, you need to specify this (see BATTERY CHARGE).
I don't like the idea of stressing the battery to exhaustion in order to find out that value. Doesn't the hardware communicate the battery percent itself? It has an LCD display with a graph display of charge. I have this: Isengard:~ # upsc Salicru battery.charge: 100 battery.voltage: 13.60 battery.voltage.high: 13.00 battery.voltage.low: 10.40 battery.voltage.nominal: 12.0 Aren't those the values told by the UPS itself? It prints battery charge.
See man blazer_usb
"Salicru" is not even listed at https://networkupstools.org/stable-hcl.html There is only a user report for the "SPS One 700VA": https://networkupstools.org/ddl/Salicru/index.html Anyway... I changed the configuration a bit: [salicru] driver = blazer_usb #port = /dev/usb/hiddev0 port = auto desc = "Salicru SPS SOHO+ 800VA" default.battery.voltage.high = 13.60 default.battery.voltage.low = 10.40 The utility reports the same values as before: Isengard:/etc/ups # upsc Salicru battery.charge: 100 battery.voltage: 13.60 battery.voltage.high: 13.00 battery.voltage.low: 10.40 battery.voltage.nominal: 12.0 device.type: ups driver.name: blazer_usb I switched off the mains for a few seconds: sengard:/etc/ups # upsc Salicru battery.charge: 92 <============= battery.voltage: 12.80 battery.voltage.high: 13.00 battery.voltage.low: 10.40 battery.voltage.nominal: 12.0 device.type: ups driver.name: blazer_usb driver.parameter.pollinterval: 2 driver.parameter.port: auto driver.parameter.synchronous: no driver.version: 2.7.4 driver.version.internal: 0.12 input.current.nominal: 3.0 input.frequency: 50.0 input.frequency.nominal: 50 input.voltage: 3.9 <=========== input.voltage.fault: 3.9 input.voltage.nominal: 230 output.voltage: 227.7 ups.beeper.status: enabled ups.delay.shutdown: 30 ups.delay.start: 180 ups.load: 6 ups.productid: 5161 ups.status: OB ups.temperature: 25.0 ups.type: offline / line interactive ups.vendorid: 0665 Isengard:/etc/ups # And with mains back on: Isengard:/etc/ups # upsc Salicru battery.charge: 100 battery.voltage: 13.60 battery.voltage.high: 13.00 battery.voltage.low: 10.40 battery.voltage.nominal: 12.0 device.type: ups driver.name: blazer_usb driver.parameter.pollinterval: 2 driver.parameter.port: auto driver.parameter.synchronous: no driver.version: 2.7.4 driver.version.internal: 0.12 input.current.nominal: 3.0 input.frequency: 50.0 input.frequency.nominal: 50 input.voltage: 228.9 input.voltage.fault: 228.9 input.voltage.nominal: 230 output.voltage: 228.9 ups.beeper.status: enabled ups.delay.shutdown: 30 ups.delay.start: 180 ups.load: 7 ups.productid: 5161 ups.status: OL ups.temperature: 25.0 ups.type: offline / line interactive ups.vendorid: 0665 Isengard:/etc/ups # - -- Cheers, Carlos E. R. (from openSUSE 15.2 x86_64 at Telcontar) -----BEGIN PGP SIGNATURE----- iHoEARECADoWIQQZEb51mJKK1KpcU/W1MxgcbY1H1QUCYHn3xBwccm9iaW4ubGlz dGFzQHRlbGVmb25pY2EubmV0AAoJELUzGBxtjUfVqR0AnAyIGssvXhAt6NsrtiRi LghqlteTAJ4qT4htx32MSZZhda7R2II4OY6cqw== =UIlv -----END PGP SIGNATURE-----