Skip to content

Commit 3e34c92

Browse files
committed
docs/man/apc_modbus.txt, docs/nut.dict: update manpage with instructions for USB-capable builds [networkupstools#2063]
Signed-off-by: Jim Klimov <[email protected]>
1 parent 9ef8727 commit 3e34c92

File tree

2 files changed

+43
-1
lines changed

2 files changed

+43
-1
lines changed

docs/man/apc_modbus.txt

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,46 @@ Set the Modbus slave id. The default slave id is 1.
8383
Set the Modbus response timeout. The default timeout is set by libmodbus. It can
8484
be good to set a higher timeout on TCP connections with high latency.
8585

86+
BUGS
87+
----
88+
89+
This driver relies on advanced features of `libmodbus` to talk Modbus protocol
90+
over USB specifically (Serial and TCP are part of common library codebase).
91+
At the time of this writing, the common library project is just expecting a
92+
merge of the pull request with this ability.
93+
94+
For the time being, if your OS distribution does not ship the required feature
95+
set, you may have to build your own `libmodbus` and subsequently (re-)build NUT
96+
against this library, as detailed in the NUT GitHub Wiki at
97+
https://github.com/networkupstools/nut/wiki/APC-UPS-with-Modbus-protocol
98+
99+
The short sequence may be like follows:
100+
------
101+
cd ~/
102+
git clone -b rtu_usb https://github.com/networkupstools/libmodbus
103+
cd libmodbus
104+
./autogen.sh
105+
./configure --with-libusb --prefix=/path/to/prefix
106+
make install
107+
108+
cd ~/
109+
git clone https://github.com/networkupstools/nut
110+
cd nut
111+
./autogen.sh
112+
./configure --with-drivers=apc_modbus --with-usb --with-modbus \
113+
--with-modbus-includes=-I/path/to/prefix/include/modbus \
114+
--with-modbus-libs="-L/path/to/prefix/lib -lmodbus"
115+
make
116+
------
117+
118+
NOTE: Other `configure` options may be needed for proper behavior, such as
119+
`--prefix`, `--with-sysconfdir`, `--with-user` and `--with-group` to match
120+
your packaged or otherwise preceding NUT installation.
121+
122+
The `./configure --enable-inplace-runtime` may be a good start to inherit
123+
build configuration from an existing NUT deployment, as further detailed at
124+
https://github.com/networkupstools/nut/wiki/Building-NUT-for-in%E2%80%90place-upgrades-or-non%E2%80%90disruptive-tests
125+
86126
AUTHORS
87127
-------
88128

docs/nut.dict

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
personal_ws-1.1 en 3478 utf-8
1+
personal_ws-1.1 en 3480 utf-8
22
AAC
33
AAS
44
ABI
@@ -2431,6 +2431,7 @@ lk
24312431
lldb
24322432
llvm
24332433
lm
2434+
lmodbus
24342435
ln
24352436
lnetsnmp
24362437
loadPercentage
@@ -2940,6 +2941,7 @@ rqt
29402941
rsa
29412942
rsync
29422943
rts
2944+
rtu
29432945
ru
29442946
rubygem
29452947
runlevel

0 commit comments

Comments
 (0)