Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
premultiply authored and andig committed Sep 14, 2023
1 parent 4c02929 commit 48b85bb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions util/templates/documentation_modbus.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Attached to local serial interface (Modbus RTU)
modbus: rtu
id: {{ .id }}
device: {{ .device }} # Geräteadresse, typische Werte sind /dev/ttyUSB0, /dev/ttyAMA0, /dev/ttyS0 oder COM3
device: {{ .device }} # Schnittstellenname, typische Werte sind /dev/ttyUSB0, /dev/ttyAMA0, /dev/ttyS0 oder COM3
baudrate: {{ .baudrate }} # Baudrate, typische Werte sind 9600, 19200, 38400, 57600, 115200
comset: {{ .comset }} # Parität, Datenbits, Stoppbits, typische Werte sind 8N1, 8E1, 8O1
{{- end }}
Expand All @@ -12,15 +12,15 @@ comset: {{ .comset }} # Parität, Datenbits, Stoppbits, typische Werte sind 8N1,
# Attached to transparent serial device server (Modbus RTU over TCP/IP)
modbus: rtu-over-tcpip
id: {{ .id }}
host: {{ .host }} # Hostname
host: {{ .host }} # Hostname / IP-Adresse
port: {{ .port }} # Port
{{- end }}
{{- if .asciiserial }}

# Attached to local serial interface (Modbus ASCII)
modbus: ascii
id: {{ .id }}
device: {{ .device }} # Geräteadresse, typische Werte sind /dev/ttyUSB0, /dev/ttyAMA0, /dev/ttyS0 oder COM3
device: {{ .device }} # Schnittstellenname, typische Werte sind /dev/ttyUSB0, /dev/ttyAMA0, /dev/ttyS0 oder COM3
baudrate: {{ .baudrate }} # Baudrate, typische Werte sind 9600, 19200, 38400, 57600, 115200
comset: {{ .comset }} # Parität, Datenbits, Stoppbits, typische Werte sind 8N1, 8E1, 8O1
{{- end }}
Expand All @@ -29,14 +29,14 @@ comset: {{ .comset }} # Parität, Datenbits, Stoppbits, typische Werte sind 8N1,
# Attached to transparent serial device server (Modbus ASCII over TCP/IP)
modbus: ascii-over-tcpip
id: {{ .id }}
host: {{ .host }} # Hostname
host: {{ .host }} # Hostname / IP-Adresse
port: {{ .port }} # Port
{{- end }}
{{- if .tcp }}

# Modbus TCP
modbus: tcp
id: {{ .id }}
host: {{ .host }} # Hostname
host: {{ .host }} # Hostname / IP-Adresse
port: {{ .port }} # Port
{{- end -}}
2 changes: 1 addition & 1 deletion util/templates/modbus.tpl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{{- define "modbus" }}
id: {{ .id }}
{{- if or (eq .modbus "rs485serial") (eq .modbus "rtu") (eq .modbus "ascii") }}
# Serial interface (Modbus RTU/ASCII)
# Local serial interface (Modbus RTU/ASCII)
device: {{ .device }}
baudrate: {{ .baudrate }}
comset: "{{ .comset }}"
Expand Down

0 comments on commit 48b85bb

Please sign in to comment.