Skip to content

Commit c7189cd

Browse files
authored
Merge pull request #3228 from DarkMike-ru/must_ep2000
MUST EP2000Pro driver (modbus)
2 parents 783d2fa + 6554202 commit c7189cd

File tree

7 files changed

+706
-1
lines changed

7 files changed

+706
-1
lines changed

NEWS.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,10 @@ https://github.com/networkupstools/nut/milestone/12
9898
- Introduced a new NUT driver named `meanwell_ntu` which provides support for
9999
the Mean Well NTU series hybrid inverter and UPS units. [PR #3206]
100100

101+
- Introduced a new NUT driver named `must_ep2000pro` which provides support
102+
for the MUST EP2000Pro compatible, line-interactive UPS models which talk
103+
serial-protocol modbus protocol. [PR #3228]
104+
101105
- `nhs_ser` driver updates:
102106
* Driver source code includes a table to map baud rates (defined by the OS
103107
as C macros) to numbers and strings more useful to the driver program.

data/driver.list.in

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -963,6 +963,8 @@
963963

964964
"Minibox" "ups" "5" "openUPS Intelligent UPS" "USB port" "usbhid-ups"
965965

966+
"Must" "ups" "4" "EP2000Pro" "" "must_ep2000pro"
967+
966968
"Mustek" "ups" "2" "Powermust" "400VA Plus" "blazer_ser"
967969
"Mustek" "ups" "2" "Powermust" "600VA Plus" "blazer_ser"
968970
"Mustek" "ups" "2" "Powermust" "800VA Pro" "blazer_ser"

docs/man/Makefile.am

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1342,6 +1342,7 @@ SRC_MODBUS_PAGES = \
13421342
generic_modbus.txt \
13431343
huawei-ups2000.txt \
13441344
socomec_jbus.txt \
1345+
must_ep2000pro.txt \
13451346
adelsystem_cbi.txt \
13461347
apc_modbus.txt
13471348

@@ -1350,6 +1351,7 @@ INST_MAN_MODBUS_PAGES = \
13501351
generic_modbus.$(MAN_SECTION_CMD_SYS) \
13511352
huawei-ups2000.$(MAN_SECTION_CMD_SYS) \
13521353
socomec_jbus.$(MAN_SECTION_CMD_SYS) \
1354+
must_ep2000pro.$(MAN_SECTION_CMD_SYS) \
13531355
adelsystem_cbi.$(MAN_SECTION_CMD_SYS) \
13541356
apc_modbus.$(MAN_SECTION_CMD_SYS)
13551357

@@ -1370,6 +1372,7 @@ INST_HTML_MODBUS_MANS = \
13701372
generic_modbus.html \
13711373
huawei-ups2000.html \
13721374
socomec_jbus.html \
1375+
must_ep2000pro.html \
13731376
adelsystem_cbi.html \
13741377
apc_modbus.html
13751378
DIST_ALL_HTML_PAGES += $(INST_HTML_MODBUS_MANS)

docs/man/must_ep2000pro.txt

Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
MUST_EP2000Pro(8)
2+
=================
3+
4+
NAME
5+
----
6+
7+
must_ep2000pro - Driver for MUST EP2000Pro UPS with
8+
RS-232 serial Modbus connection.
9+
10+
SYNOPSIS
11+
--------
12+
13+
*must_ep2000pro* -h
14+
15+
*must_ep2000pro* -a 'DEVICE_NAME' ['OPTIONS']
16+
17+
NOTE: This man page only documents the hardware-specific features of the
18+
'must_ep2000pro' driver. For information about the core driver, see
19+
linkman:nutupsdrv[8].
20+
21+
SUPPORTED HARDWARE
22+
------------------
23+
24+
This driver supports MUST EP2000Pro compatible, line-interactive
25+
UPS with the following characteristics:
26+
27+
1. 12V or 24V external battery
28+
29+
2. Connection: RS-232 or USB (via RS232-to-USB converter dongle)
30+
31+
Some models that may be covered by this driver:
32+
33+
* Original EP200Pro
34+
* Energy Smart.2
35+
* Luxeon UPS-500ZR
36+
* Bineos EP20-1000 PRO
37+
* any other work with original program from MUST
38+
39+
Currently, it has only been tested on the following model:
40+
41+
* Energy Smart.2 600W
42+
43+
Generally, these device do not serve any identification data, so
44+
autodetection is not possible. Only one documented piece of info is
45+
"software version" with unknown meaning.
46+
47+
The `must_ep2000pro` driver uses the libmodbus project, for Modbus
48+
implementation.
49+
50+
INSTALLATION
51+
------------
52+
53+
This driver should be built by default if libmodbus and development headers
54+
are available. You can force the `configure` script to build it with the
55+
following arguments:
56+
57+
:; ./configure --with-serial=yes --with-modbus=yes
58+
59+
You also need to give proper (R/W) permissions on the local serial device
60+
file to allow the NUT driver run-time user to access it. This may need
61+
additional setup for start-up scripting, udev or upower rules, to apply
62+
the rights on every boot -- especially if your device nodes are tracked
63+
by a virtual filesystem.
64+
65+
For example, a USB-to-serial converter can be identified as `/dev/ttyACM0`
66+
or `/dev/ttyUSB0` on Linux, or `/dev/ttyU0` on FreeBSD (note the capital "U").
67+
A built-in serial port can be identified as `/dev/ttyS0` on Linux or one of
68+
`/dev/cua*` names on FreeBSD.
69+
70+
EXTRA ARGUMENTS
71+
---------------
72+
73+
This driver also supports the following optional settings:
74+
75+
*lowbatt*='num'::
76+
Set the value of `battery.charge.low` to 'num'. Device itself has only switch-off
77+
on low battery voltage.
78+
79+
INSTANT COMMANDS
80+
----------------
81+
82+
This driver supports some instant commands (see linkman:upscmd[8]):
83+
84+
*beeper.enable*::
85+
Enable the UPS beeper
86+
87+
*beeper.disable*::
88+
Disable the UPS beeper
89+
90+
*shutdown.return*::
91+
Turn off the load and wait for the power to return
92+
93+
KNOWN PROBLEMS
94+
--------------
95+
96+
If you run the *shutdown.return* command with mains present it does nothing.
97+
98+
If you run the *shutdown.return* command without mains present it immediately
99+
powers off the device.
100+
101+
There is no setting in device documentation to specify a shutdown delay.
102+
103+
AUTHOR
104+
------
105+
106+
Mikhail Mironov <[email protected]>
107+
108+
SEE ALSO
109+
--------
110+
111+
The core driver:
112+
~~~~~~~~~~~~~~~~
113+
114+
linkman:nutupsdrv[8]
115+
116+
Internet resources:
117+
~~~~~~~~~~~~~~~~~~~
118+
119+
* The NUT (Network UPS Tools) home page: https://www.networkupstools.org/
120+
* libmodbus home page: http://libmodbus.org
121+
* Simple data reader for similar device: https://github.com/reverieline/ep2000pro

docs/nut.dict

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@ Berge
132132
Berzonis
133133
Bieringer
134134
BigServers
135+
Bineos
135136
BlaXwan
136137
BlackOut
137138
BladeUPS
@@ -687,6 +688,7 @@ LogMin
687688
LowBatt
688689
Loyer
689690
Luca
691+
Luxeon
690692
Lygre
691693
Lynge
692694
MANPATH
@@ -761,6 +763,7 @@ MinGW
761763
MiniCOL
762764
MiniGuard
763765
Minislot
766+
Mironov
764767
Moar
765768
Modbus
766769
ModemManager

drivers/Makefile.am

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ SERIAL_USB_DRIVERLIST = \
9090
nutdrv_qx
9191
NEONXML_DRIVERLIST = netxml-ups
9292
MACOSX_DRIVERLIST = macosx-ups
93-
MODBUS_DRIVERLIST = phoenixcontact_modbus generic_modbus huawei-ups2000 socomec_jbus adelsystem_cbi apc_modbus
93+
MODBUS_DRIVERLIST = phoenixcontact_modbus generic_modbus huawei-ups2000 socomec_jbus adelsystem_cbi apc_modbus must_ep2000pro
9494
LINUX_I2C_DRIVERLIST = asem pijuice hwmon_ina219
9595
POWERMAN_DRIVERLIST = powerman-pdu
9696
IPMI_DRIVERLIST = nut-ipmipsu
@@ -385,6 +385,11 @@ huawei_ups2000_LDADD = $(LDADD_DRIVERS_SERIAL) $(LIBMODBUS_LIBS)
385385
socomec_jbus_SOURCES = socomec_jbus.c
386386
socomec_jbus_LDADD = $(LDADD_DRIVERS_SERIAL) $(LIBMODBUS_LIBS)
387387

388+
# MUST EP2000Pro driver
389+
# (this is a Modbus driver)
390+
must_ep2000pro_SOURCES = must_ep2000pro.c
391+
must_ep2000pro_LDADD = $(LDADD_DRIVERS_SERIAL) $(LIBMODBUS_LIBS)
392+
388393
# Linux I2C drivers
389394
asem_LDADD = $(LDADD_DRIVERS) $(LIBI2C_LIBS)
390395
asem_SOURCES = asem.c

0 commit comments

Comments
 (0)