Skip to content

Commit d107673

Browse files
Merge pull request #11 from NikolasK-source/main
Release 1.1.1
2 parents 04e98cc + 92316a1 commit d107673

File tree

4 files changed

+34
-15
lines changed

4 files changed

+34
-15
lines changed

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ cmake_minimum_required(VERSION 3.13.4 FATAL_ERROR)
44
# ======================================================================================================================
55

66
# project
7-
project(stdin-to-modbus-shm LANGUAGES CXX VERSION 1.1.0)
7+
project(stdin-to-modbus-shm LANGUAGES CXX VERSION 1.1.1)
88

99
# settings
1010
set(Target "stdin-to-modbus-shm") # Executable name (without file extension!)

README.md

Lines changed: 22 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,21 +16,35 @@ As an alternative to the ```git submodule``` commands, the ```--recursive``` opt
1616

1717
## Use
1818
```
19-
stdin_to_modbus_shm [OPTION...]
19+
stdin-to-modbus-shm [OPTION...]
2020
2121
-n, --name-prefix arg name prefix of the shared memory objects (default: modbus_)
2222
--address-base arg Numerical base (radix) that is used for the addresses (see
2323
https://en.cppreference.com/w/cpp/string/basic_string/stoul) (default: 0)
2424
--value-base arg Numerical base (radix) that is used for the values (see
2525
https://en.cppreference.com/w/cpp/string/basic_string/stoul) (default: 0)
26+
-p, --passthrough write passthrough all executed commands to stdout
27+
--bash passthrough as bash script. No effect i '--passthrough' is not set
28+
--valid-hist add only valid commands to command history
2629
-h, --help print usage
27-
28-
29-
Data input format: reg_type:address:value
30-
reg_type: modbus register type: [do|di|ao|ai]
31-
address : address of the target register: [0-65535]
32-
value : value that is written to the target register: [0-65535]
33-
For the registers do and di all numerical values different from 0 are interpreted as 1.
30+
-v, --verbose print what is written to the registers
31+
--version print version information
32+
--license show licenses
33+
--data-types show list of supported data type identifiers
34+
--constants list string constants that can be used as value
35+
36+
37+
Data input format: reg_type:address:value[:data_type]
38+
reg_type : modbus register type: [do|di|ao|ai]
39+
address : address of the target register: [0-65535]
40+
The actual maximum register depends on the size of the modbus shared memory.
41+
value : value that is written to the target register
42+
Some string constants are available. The input format depends on the type of register and data type.
43+
Type 'help constants' for more details
44+
For the registers do and di all numerical values different from 0 are interpreted as 1.
45+
data_type: an optional data type specifier
46+
If no data type is specified, exactly one register is written in host byte order.
47+
Type 'help types' to get a list of supported data type identifiers.
3448
```
3549

3650
## Libraries

docs/index.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -123,17 +123,22 @@ The following data types are possible:
123123
- u64_badcfehg, u64_little_rev, **u64lr**
124124
64-Bit unsigned integer, little endian, reversed register order
125125

126-
**Note:
127-
The endianness refers to the layout of the data in the shared memory and may differ from the Modbus master's
128-
definition of the endianness.**
126+
> **Note**:
127+
The endianness refers to the layout of the data in the shared memory and may differ from the Modbus Server's
128+
definition of the endianness.
129129

130130
### Command Passthrough
131131
By using the option ```--passthrough```, all valid inputs are written to stdout.
132132
By additionally enabling the option ```--bash```, the output is created as a bash script that reproduces the inputs
133133
(including the timing).
134134

135+
## Install
135136

136-
## Using the Flatpak package
137+
### Using the Modbus Collection Flapak Package: Shared Memory Modbus (recommended)
138+
[SHM-Modbus](https://nikolask-source.github.io/SHM_Modbus/) is a collection of the shared memory modbus tools.
139+
It is available as flatpak and published on flathub as ```network.koesling.shm-modbs```.
140+
141+
### Using the Standalone Flatpak package
137142
The flatpak package can be installed via the .flatpak file.
138143
This can be downloaded from the GitHub [projects release page](https://github.com/NikolasK-source/stdin_to_modbus_shm/releases):
139144

@@ -150,7 +155,7 @@ To enable calling with ```stdin-to-modbus-shm``` [this script](https://gist.gith
150155
In order to be executable everywhere, the path in which the script is placed must be in the ```PATH``` environment variable.
151156

152157

153-
## Build from Source
158+
### Build from Source
154159

155160
The following packages are required for building the application:
156161
- cmake

src/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ int main(int argc, char **argv) {
248248
<< std::endl;
249249
std::cout << std::endl;
250250
std::cout << "Note: The endianness refers to the layout of the data in the shared memory and may differ from "
251-
"the Modbus master's"
251+
"the definition of the Modbus Server"
252252
<< std::endl;
253253
std::cout << " definition of the endianness." << std::endl;
254254
};

0 commit comments

Comments
 (0)