Network UPS Tools

My UPS have a serial port to report operating data. I read in the manual that it uses Upsilon 2000 software to get data. It uses Megatec Protocol which is supported by Network UPS Tool’s blazer_ser driver.

I learned this by running nut-scanner --eaton_serial /dev/ttyUSB0 which tries different protocols to the serial connection.

root@jco-tc-pm01:~# nut-scanner --eaton_serial /dev/ttyUSB0
SNMP library not found. SNMP search disabled.
Neon library not found. XML search disabled.
IPMI library not found. IPMI search disabled.
Scanning serial bus for Eaton devices.
        driver = "blazer_ser"
        port = "/dev/ttyUSB0"

Plug-in USB to RS232 connector. dmesg should yield something like

[257226.785044] usb 1-2: new full-speed USB device number 2 using xhci_hcd
[257226.933739] usb 1-2: New USB device found, idVendor=0557, idProduct=2008, bcdDevice= 3.00
[257226.933743] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[257226.933745] usb 1-2: Product: USB-Serial Controller D
[257226.933746] usb 1-2: Manufacturer: Prolific Technology Inc. 
[257226.940963] usbcore: registered new interface driver usbserial_generic
[257226.940968] usbserial: USB Serial support registered for generic
[257226.941833] usbcore: registered new interface driver pl2303
[257226.941840] usbserial: USB Serial support registered for pl2303
[257226.941848] pl2303 1-2:1.0: pl2303 converter detected
[257226.942410] usb 1-2: pl2303 converter now attached to ttyUSB0

Access raw data

# Add current user to dialout group
usermod -a -G dialout <user>

# Connect to serial using screen
screen /dev/ttyUSB0 2400

# Status query using Q1

# It would write back
(230.1 241.7 230.2 027 60.4 2.28 34.0 00000000

# 230.1 - Input voltage
# 241.1 - Fault voltage
# 230.2 - Output voltage
# 60.4 - Input Frequency
# 2.28 - Battery voltage
# 34 - Temperature



vim /etc/nut/nut.conf


vim /etc/nut/ups.conf

Add output of nut-scanner

root@jco-tc-pm01:~# upsdrvctl start
Network UPS Tools - UPS driver controller 2.7.4
Network UPS Tools - Megatec/Q1 protocol serial driver 1.57 (2.7.4)
Supported UPS detected with megatec protocol
Vendor information read in 1 tries
No values provided for battery high/low voltages in ups.conf

Using 'guestimation' (low: 20.800000, high: 26.000000)!
Battery runtime will not be calculated (runtimecal not set)

upsc nutdev1

battery.charge: 100
battery.voltage: 27.24
battery.voltage.high: 26.00
battery.voltage.low: 20.80
battery.voltage.nominal: 24.0
device.type: ups blazer_ser
driver.parameter.pollinterval: 2
driver.parameter.port: /dev/ttyUSB0
driver.parameter.synchronous: no
driver.version: 2.7.4
driver.version.internal: 1.57
input.current.nominal: 4.0
input.frequency: 60.4
input.frequency.nominal: 60
input.voltage: 230.4
input.voltage.fault: 241.7
input.voltage.nominal: 220
output.voltage: 230.1
ups.beeper.status: disabled
ups.delay.shutdown: 30
ups.delay.start: 180
ups.firmware: V022B000D0
ups.load: 30
ups.status: OL
ups.temperature: 34.0
ups.type: online


Leave a Reply

Your email address will not be published. Required fields are marked *