1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

Use spaces for indention of .conf files

Signed-off-by: Steffen Vogel <post@steffenvogel.de>
This commit is contained in:
Steffen Vogel 2024-02-29 21:36:38 +01:00
parent bc670254e2
commit 1b1643834c
121 changed files with 2972 additions and 2972 deletions

View file

@ -23,9 +23,9 @@ indent_style = space
indent_size = 4 indent_size = 4
[*.conf] [*.conf]
indent_style = tab indent_style = space
indent_size = 8 indent_size = 4
[*.nix] [*.{nix,json}]
indent_style = space indent_style = space
indent_size = 2 indent_size = 2

View file

@ -2,60 +2,60 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "info" level = "info"
} }
http = { http = {
enabled = false enabled = false
} }
nodes = { nodes = {
opal = { opal = {
type = "socket" type = "socket"
in = { in = {
address = "*:13000" address = "*:13000"
hooks = ( hooks = (
{ type = "stats" } { type = "stats" }
), ),
signals = ( signals = (
{ type = "float", name = "f0" }, { type = "float", name = "f0" },
{ type = "float", name = "f1" }, { type = "float", name = "f1" },
{ type = "float", name = "f2" }, { type = "float", name = "f2" },
{ type = "float", name = "f3" }, { type = "float", name = "f3" },
{ type = "float", name = "cnt" } { type = "float", name = "cnt" }
) )
} }
out = { out = {
address = "134.130.169.81:13000" address = "134.130.169.81:13000"
netem = { netem = {
enabled = true, enabled = true,
delay = 10000, // 10 ms delay = 10000, // 10 ms
jitter = 5000, // 5 ms jitter = 5000, // 5 ms
distribution = "normal", distribution = "normal",
loss = 10 loss = 10
} }
} }
} }
} }
paths = ( paths = (
{ {
in = "opal", in = "opal",
out = "opal", out = "opal",
hooks = ( hooks = (
{ {
type = "average", type = "average",
offset = 0, offset = 0,
signals = ["f0", "f1", "f2", "f3"] signals = ["f0", "f1", "f2", "f3"]
} }
# { # {
# type = "print" # type = "print"
# } # }
) )
} }
) )

View file

@ -13,61 +13,61 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
name = "villas-acs" # The name of this VILLASnode. Might by used by node-types name = "villas-acs" # The name of this VILLASnode. Might by used by node-types
# to identify themselves (default is the hostname). # to identify themselves (default is the hostname).
logging = { logging = {
level = "debug" level = "debug"
} }
http = { http = {
port = 80 # Port for HTTP connections port = 80 # Port for HTTP connections
} }
## Dictionary of nodes ## Dictionary of nodes
nodes = { nodes = {
ws = { ws = {
type = "websocket" type = "websocket"
unit = "MVa" unit = "MVa"
units = [ "V", "A", "Var" ] units = [ "V", "A", "Var" ]
description = "Demo Channel" description = "Demo Channel"
series = ( series = (
{ label = "Random walk" }, { label = "Random walk" },
{ label = "Sine" }, { label = "Sine" },
{ label = "Rect" }, { label = "Rect" },
{ label = "Ramp" } { label = "Ramp" }
) )
} }
socket1 = { socket1 = {
type = "socket" type = "socket"
layper = "udp" layper = "udp"
in = {
address = "*:12000"
}
out = {
address = "127.0.0.1:12001"
}
}
socket2 = {
type = "socket"
layer = "udp"
in = { in = {
address = "*:12001" address = "*:12000"
} }
out = { out = {
address = "127.0.0.1:1200" address = "127.0.0.1:12001"
} }
} }
socket2 = {
type = "socket"
layer = "udp"
in = {
address = "*:12001"
}
out = {
address = "127.0.0.1:1200"
}
}
} }
## List of paths ## List of paths
paths = ( paths = (
{ {
in = "socket2", in = "socket2",
out = "ws" out = "ws"
} }
) )

View file

@ -2,104 +2,104 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
http = { http = {
port = 8080 port = 8080
} }
nodes = { nodes = {
api_node = { api_node = {
type = "api" type = "api"
in = { in = {
signals = ( signals = (
{ {
name = "sig1_in", name = "sig1_in",
type = "float", type = "float",
unit = "V", unit = "V",
description = "Signal 1", description = "Signal 1",
rate = 100, rate = 100,
readable = true, readable = true,
writable = false, writable = false,
payload = "samples" payload = "samples"
}, },
{ {
name = "sig2_in", name = "sig2_in",
type = "float", type = "float",
unit = "A", unit = "A",
description = "Signal 1", description = "Signal 1",
rate = 100, rate = 100,
readable = true, readable = true,
writable = false, writable = false,
payload = "samples" payload = "samples"
}, },
{ {
name = "sig3_in", name = "sig3_in",
type = "float", type = "float",
unit = "A", unit = "A",
description = "Signal 1", description = "Signal 1",
rate = 100, rate = 100,
readable = true, readable = true,
writable = false, writable = false,
payload = "samples" payload = "samples"
} }
) )
} }
out = { out = {
signals = ( signals = (
# Output signals have no name, type and unit settings as those are implicitly # Output signals have no name, type and unit settings as those are implicitly
# derived from the signals which are routed to this node # derived from the signals which are routed to this node
{ {
description = "Signal 1", description = "Signal 1",
rate = 100, rate = 100,
readable = true, readable = true,
writable = false, writable = false,
payload = "samples" payload = "samples"
}, },
{ {
description = "Signal 1", description = "Signal 1",
rate = 100, rate = 100,
readable = true, readable = true,
writable = false, writable = false,
payload = "samples" payload = "samples"
}, },
{ {
description = "Signal 1", description = "Signal 1",
rate = 100, rate = 100,
readable = true, readable = true,
writable = false, writable = false,
payload = "samples" payload = "samples"
} }
) )
} }
} }
signal_node = { signal_node = {
type = "signal" type = "signal"
signal = "mixed" signal = "mixed"
values = 5 values = 5
rate = 1.0 rate = 1.0
} }
} }
paths = ( paths = (
{ {
in = [ in = [
"api_node" "api_node"
], ],
hooks = ( hooks = (
"print" "print"
) )
}, },
{ {
in = [ in = [
"signal_node" "signal_node"
] ]
out = [ out = [
"api_node" "api_node"
] ]
hooks = ( hooks = (
"print" "print"
) )
} }
) )

View file

@ -2,17 +2,17 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "csv" type = "csv"
separator = "," separator = ","
delimiter = "\n" delimiter = "\n"
skip_first_line = false skip_first_line = false
header = true header = true
} }
} }
} }

View file

@ -2,16 +2,16 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "gtnet" type = "gtnet"
bits = 32 bits = 32
endianess = "little" endianess = "little"
fake = false fake = false
} }
} }
} }

View file

@ -2,10 +2,10 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = "iotagent_ul" format = "iotagent_ul"
} }
} }

View file

@ -2,18 +2,18 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "json.edgeflex" type = "json.edgeflex"
indent = 4 indent = 4
compact = true compact = true
ensure_ascii = true ensure_ascii = true
escape_slash = false escape_slash = false
sort_keys = true sort_keys = true
} }
} }
} }

View file

@ -2,18 +2,18 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "json.kafka" type = "json.kafka"
indent = 2 indent = 2
schema = { schema = {
type = "struct" type = "struct"
name = "villas-node.Value" name = "villas-node.Value"
} }
} }
} }
} }

View file

@ -2,18 +2,18 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "json.reserve" type = "json.reserve"
indent = 4 indent = 4
compact = true compact = true
ensure_ascii = true ensure_ascii = true
escape_slash = false escape_slash = false
sort_keys = true sort_keys = true
} }
} }
} }

View file

@ -2,18 +2,18 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "json" type = "json"
indent = 4 indent = 4
compact = true compact = true
ensure_ascii = true ensure_ascii = true
escape_slash = false escape_slash = false
sort_keys = true sort_keys = true
} }
} }
} }

View file

@ -2,31 +2,31 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "socket" type = "socket"
layer = "udp" layer = "udp"
format = { format = {
type = "opal.asyncip" type = "opal.asyncip"
dev_id = 99 dev_id = 99
} }
in = { in = {
# Port number specified in Asynchronous Process block of RTlab project # Port number specified in Asynchronous Process block of RTlab project
address = ":12000" address = ":12000"
signals = { signals = {
count = 64 count = 64
# The Asynchronous Process block only supports floating point values! # The Asynchronous Process block only supports floating point values!
type = "float" type = "float"
} }
} }
out = { out = {
# IP address and port of OPAL-RT Target # IP address and port of OPAL-RT Target
address = "192.168.0.44:12000" address = "192.168.0.44:12000"
} }
} }
} }

View file

@ -2,10 +2,10 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = "protobuf" format = "protobuf"
} }
} }

View file

@ -2,16 +2,16 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "raw" type = "raw"
bits = 32 bits = 32
endianess = "little" endianess = "little"
fake = false fake = false
} }
} }
} }

View file

@ -2,17 +2,17 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "tsv" type = "tsv"
separator = "\t" separator = "\t"
delimiter = "\n" delimiter = "\n"
skip_first_line = false skip_first_line = false
header = true header = true
} }
} }
} }

View file

@ -2,14 +2,14 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "value" type = "value"
real_precision = 5 real_precision = 5
} }
} }
} }

View file

@ -2,14 +2,14 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "villas.binary" type = "villas.binary"
source_index = 99 source_index = 99
} }
} }
} }

View file

@ -2,15 +2,15 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = { format = {
type = "villas.human" type = "villas.human"
comment_prefix = "#" comment_prefix = "#"
header = false header = false
} }
} }
} }

View file

@ -2,10 +2,10 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
node = { node = {
type = "file" type = "file"
uri = "/dev/null" uri = "/dev/null"
format = "villas.web" format = "villas.web"
} }
} }

View file

@ -11,31 +11,31 @@
## Global Options ## Global Options
affinity = 0x01 # Mask of cores the server should run on affinity = 0x01 # Mask of cores the server should run on
# This also maps the NIC interrupts to those cores! # This also maps the NIC interrupts to those cores!
#priority = 50 # Priority for the server tasks. #priority = 50 # Priority for the server tasks.
# Usually the server is using a real-time FIFO # Usually the server is using a real-time FIFO
# scheduling algorithm # scheduling algorithm
# See: https://github.com/docker/docker/issues/22380 # See: https://github.com/docker/docker/issues/22380
# on why we cant use real-time scheduling in Docker # on why we cant use real-time scheduling in Docker
name = "villas-acs" # The name of this VILLASnode. Might by used by node-types name = "villas-acs" # The name of this VILLASnode. Might by used by node-types
# to identify themselves (default is the hostname). # to identify themselves (default is the hostname).
logging = { logging = {
level = "debug" # The level of verbosity for debug messages level = "debug" # The level of verbosity for debug messages
# One of: "warn", "info", "error", "off", "info" # One of: "warn", "info", "error", "off", "info"
file = "/tmp/villas-node.log" # File for logs file = "/tmp/villas-node.log" # File for logs
syslog = true # Log to syslogd syslog = true # Log to syslogd
} }
http = { http = {
enabled = true, # Do not listen on port if true enabled = true, # Do not listen on port if true
port = 80 # Port for HTTP connections port = 80 # Port for HTTP connections
} }

View file

@ -4,17 +4,17 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "average" type = "average"
signals = [ "sine", "square" ] signals = [ "sine", "square" ]
offset = 0 offset = 0
} }
) )
} }
) )

View file

@ -4,20 +4,20 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "cast" type = "cast"
signal = "random" signal = "random"
new_name = "int_random" new_name = "int_random"
new_unit = "pts" new_unit = "pts"
new_type = "integer" new_type = "integer"
} }
) )
} }
) )

View file

@ -4,16 +4,16 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "decimate" type = "decimate"
ratio = 10 ratio = 10
} }
) )
} }
) )

View file

@ -4,20 +4,20 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
# Use a frame hook to generate NEW_FRAME annotations. # Use a frame hook to generate NEW_FRAME annotations.
"frame", "frame",
{ {
type = "digest" type = "digest"
# The algorithm used for digest calculation # The algorithm used for digest calculation
algorithm = "sha256" algorithm = "sha256"
# The output file for digests # The output file for digests
uri = "sequence.digest" uri = "sequence.digest"
} }
) )
} }
) )

View file

@ -4,24 +4,24 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "dp" type = "dp"
signal = "sine" signal = "sine"
f0 = 50 # Hz f0 = 50 # Hz
dt = 0.1 # seconds dt = 0.1 # seconds
# Alternative to dt
# rate = 10 Hz
harmonics = [ 0, 1, 3, 5, 7 ] # Alternative to dt
inverse = false # rate = 10 Hz
}
) harmonics = [ 0, 1, 3, 5, 7 ]
} inverse = false
}
)
}
) )

View file

@ -4,14 +4,14 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "dump" type = "dump"
} }
) )
} }
) )

View file

@ -4,20 +4,20 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "ebm" type = "ebm"
phases = ( phases = (
[ 0, 1 ], [ 0, 1 ],
[ 2, 3 ], [ 2, 3 ],
[ 4, 5 ] [ 4, 5 ]
) )
} }
) )
} }
) )

View file

@ -4,18 +4,18 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "frame" type = "frame"
trigger = "timestamp" trigger = "timestamp"
unit = "seconds" unit = "seconds"
interval = 10 interval = 10
} }
) )
} }
) )

View file

@ -4,22 +4,22 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "gate" type = "gate"
signal = "square" signal = "square"
mode = "above" mode = "above"
threshold = 0.5 threshold = 0.5
# Once triggered, keep active for: # Once triggered, keep active for:
duration = 5 # in seconds duration = 5 # in seconds
samples = 100 # in number of samples samples = 100 # in number of samples
} }
) )
} }
) )

View file

@ -6,13 +6,13 @@
# of different hooks # of different hooks
nodes = { nodes = {
signal_node = { signal_node = {
type = "signal" type = "signal"
values = 5 values = 5
signal = "mixed" signal = "mixed"
} }
file_node = { file_node = {
type = "file" type = "file"
uri = "hook_output.log" uri = "hook_output.log"
} }
} }

View file

@ -4,27 +4,27 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "pmu", type = "pmu",
signals = ( signals = (
"sine" "sine"
) )
sample_rate = 1000, # sample rate of the input signal sample_rate = 1000, # sample rate of the input signal
dft_rate = 10, # number of phasors calculated per second dft_rate = 10, # number of phasors calculated per second
estimation_range = 10, # the range around the nominal_freq in with the estimation is done estimation_range = 10, # the range around the nominal_freq in with the estimation is done
nominal_freq = 50, # the nominal grid frequnecy nominal_freq = 50, # the nominal grid frequnecy
number_plc = 10., # the number of power line cylces stored in the buffer number_plc = 10., # the number of power line cylces stored in the buffer
angle_unit = "rad" # one of: rad, degree angle_unit = "rad" # one of: rad, degree
} }
) )
} }
) )

View file

@ -4,14 +4,14 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "jitter_calc" type = "jitter_calc"
} }
) )
} }
) )

View file

@ -4,16 +4,16 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "limit_rate" type = "limit_rate"
rate = 5.5 rate = 5.5
} }
) )
} }
) )

View file

@ -4,19 +4,19 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "limit_value" type = "limit_value"
min = -0.5 min = -0.5
max = 0.5 max = 0.5
signals = [ "sine" ] signals = [ "sine" ]
} }
) )
} }
) )

View file

@ -6,81 +6,81 @@
stats = 1 stats = 1
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "lua" type = "lua"
# Enables or disables the use of signal names in the process() function # Enables or disables the use of signal names in the process() function
# of the Lua script. If disabled, numeric indices will be used. # of the Lua script. If disabled, numeric indices will be used.
use_names = true use_names = true
# The Lua hook will pass the complete hook configuration to the prepare() # The Lua hook will pass the complete hook configuration to the prepare()
# function. So you can add arbitrary settings here which are then # function. So you can add arbitrary settings here which are then
# consumed by the Lua script. # consumed by the Lua script.
some_setting = "Hello World" some_setting = "Hello World"
this = { this = {
is = { is = {
nested = 1234 nested = 1234
bool_val = true bool_val = true
} }
} }
# Script mode: we provide a Lua script containing functions # Script mode: we provide a Lua script containing functions
# for the individual hook points # for the individual hook points
# Define some or all of the following functions in your Lua script: # Define some or all of the following functions in your Lua script:
# #
# prepare(cfg) Called during initialization with a Lua table which contains # prepare(cfg) Called during initialization with a Lua table which contains
# the full hook configuration # the full hook configuration
# start() Called when the node/path is started # start() Called when the node/path is started
# #
# stop() Called when the node/path is stopped # stop() Called when the node/path is stopped
# #
# restart() Called when the node/path is restarted. # restart() Called when the node/path is restarted.
# Falls back to stop() + start() if absent. # Falls back to stop() + start() if absent.
# #
# process(smp) Called for each sample which is being processed. # process(smp) Called for each sample which is being processed.
# The sample is passed as a Lua table with the following # The sample is passed as a Lua table with the following
# fields: # fields:
# - sequence The sequence number of the sample. # - sequence The sequence number of the sample.
# - flags The flags field of the sample. # - flags The flags field of the sample.
# - ts_origin The origin timestamp as a Lua table containing # - ts_origin The origin timestamp as a Lua table containing
# the following keys: # the following keys:
# 0: seconds # 0: seconds
# 1: nanoseconds # 1: nanoseconds
# - ts_received The receive timestamp a Lua table containing # - ts_received The receive timestamp a Lua table containing
# the following keys: # the following keys:
# 0: seconds # 0: seconds
# 1: nanoseconds # 1: nanoseconds
# - data The sample data as a Lua table container either # - data The sample data as a Lua table container either
# numeric indices or the signal names depending # numeric indices or the signal names depending
# on the 'use_names' option of the hook. # on the 'use_names' option of the hook.
# #
# periodic() Called periodically with the rate of the global 'stats' option. # periodic() Called periodically with the rate of the global 'stats' option.
script = "../lua/hooks/test.lua" script = "../lua/hooks/test.lua"
# Expression mode: We provide a mangled signal list including Lua expressions # Expression mode: We provide a mangled signal list including Lua expressions
signals = ( signals = (
{ name = "sum", type="float", unit = "V", expression = "smp.data.square * 10" }, { name = "sum", type="float", unit = "V", expression = "smp.data.square * 10" },
# You can access any global variable set by the script # You can access any global variable set by the script
{ name = "sequence", type="float", unit = "V", expression = "global_var" }, { name = "sequence", type="float", unit = "V", expression = "global_var" },
# Here we set a global variable from the periodic handler # Here we set a global variable from the periodic handler
{ name = "temp_aachen", type="float", unit = "°C", expression = "temp_aachen" }, { name = "temp_aachen", type="float", unit = "°C", expression = "temp_aachen" },
# We can refer to the current time the global Lua variable 't' # We can refer to the current time the global Lua variable 't'
{ name = "sum", type="float", unit = "V", expression = "math.sin(2 * math.pi * f * t)" }, { name = "sum", type="float", unit = "V", expression = "math.sin(2 * math.pi * f * t)" },
{ name = "random", expression = "smp.data.random" } { name = "random", expression = "smp.data.random" }
) )
}, },
{ {
type = "print" type = "print"
} }
) )
} }
) )

View file

@ -4,20 +4,20 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "ma", type = "ma",
window_size = 1000 window_size = 1000
signals = [ signals = [
"sine" "sine"
] ]
} }
) )
} }
) )

View file

@ -4,26 +4,26 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "pmu", type = "pmu",
signals = ( signals = (
"sine" "sine"
) )
sample_rate = 1000, # sample rate of the input signal sample_rate = 1000, # sample rate of the input signal
dft_rate = 10, # number of phasors calculated per second dft_rate = 10, # number of phasors calculated per second
nominal_freq = 50, # the nominal grid frequnecy nominal_freq = 50, # the nominal grid frequnecy
number_plc = 10., # the number of power line cylces stored in the buffer number_plc = 10., # the number of power line cylces stored in the buffer
angle_unit = "rad" # one of: rad, degree angle_unit = "rad" # one of: rad, degree
} }
) )
} }
) )

View file

@ -4,34 +4,34 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "pmu_dft", type = "pmu_dft",
signals = ( signals = (
"sine" "sine"
) )
sample_rate = 1000, # sample rate of the input signal sample_rate = 1000, # sample rate of the input signal
dft_rate = 10, # number of phasors calculated per second dft_rate = 10, # number of phasors calculated per second
start_frequency = 49.7, # lowest frequency bin start_frequency = 49.7, # lowest frequency bin
end_frequency = 50.3, # highest frequency bin end_frequency = 50.3, # highest frequency bin
frequency_resolution = 0.1, # frequency bin resolution frequency_resolution = 0.1, # frequency bin resolution
window_size_factor = 1, # a factor with which the window will be increased window_size_factor = 1, # a factor with which the window will be increased
window_type = "hamming", # one of: flattop, hamming, hann window_type = "hamming", # one of: flattop, hamming, hann
padding_type = "zero", # one of: signal_repeat, zero padding_type = "zero", # one of: signal_repeat, zero
frequency_estimate_type = "quadratic", # one of: quadratic frequency_estimate_type = "quadratic", # one of: quadratic
pps_index = 0, # signal index of the PPS signal pps_index = 0, # signal index of the PPS signal
angle_unit = "rad" # one of: rad, degree angle_unit = "rad" # one of: rad, degree
} }
) )
} }
) )

View file

@ -4,28 +4,28 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "power", type = "power",
angle_unit = "degree" angle_unit = "degree"
window_size = 1000 window_size = 1000
timestamp_align = "center" timestamp_align = "center"
pairings = ( pairings = (
{voltage = "voltage_l1", current = "current_l1"}, {voltage = "voltage_l1", current = "current_l1"},
{voltage = "voltage_l2", current = "current_l2"} {voltage = "voltage_l2", current = "current_l2"}
) )
signals = [ signals = [
"voltage_l1", "voltage_l1",
"voltage_l2", "voltage_l2",
"current_l1", "current_l1",
"current_l2" "current_l2"
] ]
} }
) )
} }
) )

View file

@ -4,22 +4,22 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "pps_ts" type = "pps_ts"
signal = "pps" signal = "pps"
mode = "simple" # Oneof: simple, horizon mode = "simple" # Oneof: simple, horizon
threshold = 0.5 threshold = 0.5
expected_smp_rate = 5e3 expected_smp_rate = 5e3
horizon_estimation = 10 horizon_estimation = 10
horizon_compensation = 10 horizon_compensation = 10
} }
) )
} }
) )

View file

@ -4,18 +4,18 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "print", type = "print",
output = "print_output_file.log" output = "print_output_file.log"
format = "villas.human" format = "villas.human"
# prefix = "[file_node] " # prefix and output are exclusive settings! # prefix = "[file_node] " # prefix and output are exclusive settings!
} }
) )
} }
) )

View file

@ -4,16 +4,16 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "reorder_ts" type = "reorder_ts"
window_size = 10 window_size = 10
} }
) )
} }
) )

View file

@ -4,20 +4,20 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "rms", type = "rms",
window_size = 1000 window_size = 1000
signals = [ signals = [
"sine" "sine"
] ]
} }
) )
} }
) )

View file

@ -4,17 +4,17 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "round" type = "round"
signal = "sine" signal = "sine"
precision = 4 precision = 4
} }
) )
} }
) )

View file

@ -4,19 +4,19 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "scale" type = "scale"
signal = "sine" signal = "sine"
offset = 100.0 offset = 100.0
scale = 55.0 scale = 55.0
} }
) )
} }
) )

View file

@ -4,16 +4,16 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "shift_seq" type = "shift_seq"
offset = 10 offset = 10
} }
) )
} }
) )

View file

@ -4,17 +4,17 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "shift_ts" type = "shift_ts"
mode = "origin" mode = "origin"
offset = 5.5 offset = 5.5
} }
) )
} }
) )

View file

@ -4,17 +4,17 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "skip_first" type = "skip_first"
seconds = 10 seconds = 10
# sequence = 10 # sequence = 10
} }
) )
} }
) )

View file

@ -2,27 +2,27 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
udp_node = { udp_node = {
type = "socket" type = "socket"
in = { in = {
address = "*:12000" address = "*:12000"
hooks = ( hooks = (
{ {
type = "stats" type = "stats"
verbose = true verbose = true
warmup = 100 warmup = 100
buckets = 25 buckets = 25
output = "stats.log" output = "stats.log"
format = "json" format = "json"
} }
) )
} }
out = { out = {
address = "127.0.0.1:12000" address = "127.0.0.1:12000"
} }
} }
} }

View file

@ -4,14 +4,14 @@
@include "hook-nodes.conf" @include "hook-nodes.conf"
paths = ( paths = (
{ {
in = "signal_node" in = "signal_node"
out = "file_node" out = "file_node"
hooks = ( hooks = (
{ {
type = "ts" type = "ts"
} }
) )
} }
) )

View file

@ -2,30 +2,30 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
amqp_node = { amqp_node = {
type = "amqp", type = "amqp",
format = "json", format = "json",
# Use 'amqps://' to enable SSL/TLS # Use 'amqps://' to enable SSL/TLS
uri = "amqp://username:password@example.com:1234/vhost", uri = "amqp://username:password@example.com:1234/vhost",
# Alternatively connection settings can be specified individually # Alternatively connection settings can be specified individually
username = "guest", username = "guest",
password = "guest", password = "guest",
host = "localhost", host = "localhost",
vhost = "/", vhost = "/",
port = 5672, port = 5672,
exchange = "mytestexchange", exchange = "mytestexchange",
routing_key = "abc", routing_key = "abc",
ssl = { ssl = {
verify_hostname = true, verify_hostname = true,
verify_peer = true, verify_peer = true,
ca_cert = "/path/to/ca.crt", ca_cert = "/path/to/ca.crt",
client_cert = "/path/to/client.crt", client_cert = "/path/to/client.crt",
client_key = "/path/to/client.key" client_key = "/path/to/client.key"
} }
} }
} }

View file

@ -2,32 +2,32 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
api_node = { api_node = {
type = "api" type = "api"
in = { in = {
signals = ( signals = (
{ {
name = "" # Same as 'id' in uAPI context name = "" # Same as 'id' in uAPI context
description = "Volts on Bus A" # A human readable description of the channel description = "Volts on Bus A" # A human readable description of the channel
type = "float" # Same as 'datatype' in uAPI context type = "float" # Same as 'datatype' in uAPI context
unit = "V" unit = "V"
payload = "events" # or 'samples' payload = "events" # or 'samples'
rate = 100.0 # An expected refresh/sample rate of the signal rate = 100.0 # An expected refresh/sample rate of the signal
range = { range = {
min = 20.0 min = 20.0
max = 100.0 max = 100.0
} }
readable = true readable = true
writable = false writable = false
} }
) )
} }
out = { out = {
signals = ( signals = (
# Similar to above # Similar to above
) )
} }
} }
} }

View file

@ -2,64 +2,64 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
can_node1 = { can_node1 = {
type = "can" type = "can"
interface_name = "vcan0" interface_name = "vcan0"
sample_rate = 500000 sample_rate = 500000
in = { in = {
signals = ( signals = (
{ {
name = "sigin1", name = "sigin1",
unit = "Volts", unit = "Volts",
type = "float", type = "float",
enabled = true, enabled = true,
can_id = 66, can_id = 66,
can_size = 4, can_size = 4,
can_offset = 0 can_offset = 0
}, },
{ {
name = "sigin2", name = "sigin2",
unit = "Volts", unit = "Volts",
type = "float", type = "float",
enabled = true, enabled = true,
can_id = 66, can_id = 66,
can_size = 4, can_size = 4,
can_offset = 4 can_offset = 4
}, },
{ {
name = "sigin3", name = "sigin3",
unit = "Volts", unit = "Volts",
type = "float", type = "float",
enabled = true, enabled = true,
can_id = 67, can_id = 67,
can_size = 8, can_size = 8,
can_offset = 0 can_offset = 0
} }
) )
} }
out = { out = {
signals = ( signals = (
{ {
type = "float", type = "float",
can_id = 66, can_id = 66,
can_size = 4, can_size = 4,
can_offset = 0 can_offset = 0
}, },
{ {
type = "float", type = "float",
can_id = 66, can_id = 66,
can_size = 4, can_size = 4,
can_offset = 4 can_offset = 4
}, },
{ {
type = "float", type = "float",
can_id = 67, can_id = 67,
can_size = 8, can_size = 8,
can_offset = 0 can_offset = 0
} }
) )
} }
} }
} }

View file

@ -2,84 +2,84 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
pcie6259 = { pcie6259 = {
type = "comedi", type = "comedi",
device = "/dev/comedi0", device = "/dev/comedi0",
in = { in = {
subdevice = 0, subdevice = 0,
rate = 1000, rate = 1000,
signals = (
# note: order in this array defines order in villas sample
{ channel = 0, range = 0, aref = 0, name = "temperature_int" },
{ channel = 1, range = 0, aref = 0, name = "loopback_ao0" },
{ channel = 2, range = 0, aref = 0, name = "loopback_ao1" },
{ channel = 3, range = 0, aref = 0, name = "bnc_ext" }
)
},
out = {
subdevice = 1,
# Note: buffer size and rate shouldn't be changed at the moment
# output sample rate
rate = 40000,
# comedi write buffer in kilobytes
bufsize = 24,
signals = (
# note: order in this array corresponds to order in villas sample
{ name = "ao0", channel = 0, range = 0, aref = 0 },
{ name = "ao1", channel = 1, range = 0, aref = 0 },
{ name = "ao2", channel = 2, range = 0, aref = 0 },
{ name = "ao3", channel = 3, range = 0, aref = 0 }
)
}
},
remote = { signals = (
type = "socket", # note: order in this array defines order in villas sample
layer = "udp" { channel = 0, range = 0, aref = 0, name = "temperature_int" },
format = "protobuf", { channel = 1, range = 0, aref = 0, name = "loopback_ao0" },
{ channel = 2, range = 0, aref = 0, name = "loopback_ao1" },
in = { { channel = 3, range = 0, aref = 0, name = "bnc_ext" }
address = "*:12000" )
}, },
out = { out = {
address = "134.130.169.32:12000" subdevice = 1,
} # Note: buffer size and rate shouldn't be changed at the moment
}, # output sample rate
rate = 40000,
# comedi write buffer in kilobytes
bufsize = 24,
sine1 = { signals = (
type = "signal", # note: order in this array corresponds to order in villas sample
signal = "sine", { name = "ao0", channel = 0, range = 0, aref = 0 },
values = 1, { name = "ao1", channel = 1, range = 0, aref = 0 },
frequency = 50, { name = "ao2", channel = 2, range = 0, aref = 0 },
rate = 10000, { name = "ao3", channel = 3, range = 0, aref = 0 }
}, )
}
},
sine2 = { remote = {
type = "signal", type = "socket",
signal = "sine", layer = "udp"
values = 1, format = "protobuf",
frequency = 100,
rate = 10000, in = {
} address = "*:12000"
},
out = {
address = "134.130.169.32:12000"
}
},
sine1 = {
type = "signal",
signal = "sine",
values = 1,
frequency = 50,
rate = 10000,
},
sine2 = {
type = "signal",
signal = "sine",
values = 1,
frequency = 100,
rate = 10000,
}
} }
paths = ( paths = (
# 2-ch sine # 2-ch sine
# { # {
# in = [ "sine1.data[0]", "sine2.data[0]" ] # in = [ "sine1.data[0]", "sine2.data[0]" ]
# out = "pcie6259" # out = "pcie6259"
# rate = 10000 # rate = 10000
# mask = () # mask = ()
# } # }
# Remote data via UDP # Remote data via UDP
{ {
in = "remote.data[0-3]" in = "remote.data[0-3]"
out = "pcie6259" out = "pcie6259"
rate = 40000 rate = 40000
mask = () mask = ()
} }
) )

View file

@ -2,44 +2,44 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
ethercat = { ethercat = {
coupler = { coupler = {
position = 0 position = 0
vendor_id = 0x00000002 # Backhoff vendor_id = 0x00000002 # Backhoff
product_code = 0x044c2c52 # EK1100 product_code = 0x044c2c52 # EK1100
} }
alias = 0 alias = 0
master = 0 master = 0
} }
nodes = { nodes = {
ethercat_node = { ethercat_node = {
type = "ethercat" type = "ethercat"
rate = 1000.0 # Rate of master cyclic task rate = 1000.0 # Rate of master cyclic task
# Analog Input Slave # Analog Input Slave
in = { in = {
num_channels = 8 num_channels = 8
range = 10.0 # -10.0 V to +10.0 V range = 10.0 # -10.0 V to +10.0 V
position = 2 position = 2
vendor_id = 0x00000002 # Beckhoff vendor_id = 0x00000002 # Beckhoff
product_code = 0x0bc03052 # EL3008 product_code = 0x0bc03052 # EL3008
# PDOs are currently hardcoded! # PDOs are currently hardcoded!
} }
# Analog Output Slave # Analog Output Slave
out = { out = {
num_channels = 8 num_channels = 8
range = 10.0 # -10.0 V to +10.0 V range = 10.0 # -10.0 V to +10.0 V
position = 1 position = 1
vendor_id = 0x00000002 # Beckhoff vendor_id = 0x00000002 # Beckhoff
product_code = 0x0fc63052 # EL4038 product_code = 0x0fc63052 # EL4038
# PDOs are currently hardcoded! # PDOs are currently hardcoded!
} }
} }
} }

View file

@ -2,10 +2,10 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
example_node = { example_node = {
type = "example" type = "example"
setting1 = 1 setting1 = 1
setting2 = "abc" setting2 = "abc"
} }
} }

View file

@ -2,15 +2,15 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
exec_node = { exec_node = {
type = "exec" type = "exec"
format = "villas.human" format = "villas.human"
flush = true flush = true
exec = "tee test" exec = "tee test"
shell = true shell = true
working_directory = "/tmp" working_directory = "/tmp"
environment = { environment = {
MYVAR = "TESTVAL" MYVAR = "TESTVAL"
} }
} }
} }

View file

@ -2,32 +2,32 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
file_node = { file_node = {
type = "file" type = "file"
### The following settings are specific to the file node-type!! ### ### The following settings are specific to the file node-type!! ###
uri = "logs/input.log", # These options specify the URI where the the files are stored uri = "logs/input.log", # These options specify the URI where the the files are stored
#uri = "logs/output_%F_%T.log" # The URI accepts all format tokens of (see strftime(3)) #uri = "logs/output_%F_%T.log" # The URI accepts all format tokens of (see strftime(3))
format = "csv" format = "csv"
in = { in = {
epoch_mode = "direct" # One of: direct (default), wait, relative, absolute epoch_mode = "direct" # One of: direct (default), wait, relative, absolute
epoch = 10 # The interpretation of this value depends on epoch_mode (default is 0). epoch = 10 # The interpretation of this value depends on epoch_mode (default is 0).
# Consult the documentation of a full explanation # Consult the documentation of a full explanation
rate = 2.0 # A constant rate at which the lines of the input files should be read rate = 2.0 # A constant rate at which the lines of the input files should be read
# A missing or zero value will use the timestamp in the first column # A missing or zero value will use the timestamp in the first column
# of the file to determine the pause between consecutive lines. # of the file to determine the pause between consecutive lines.
eof = "rewind" # Rewind the file and start from the beginning. eof = "rewind" # Rewind the file and start from the beginning.
buffer_size = 0 # Creates a stream buffer if value is positive buffer_size = 0 # Creates a stream buffer if value is positive
}, },
out = { out = {
flush = false # Flush or upload contents of the file every time new samples are sent. flush = false # Flush or upload contents of the file every time new samples are sent.
buffer_size = 0 # Creates a stream buffer if value is positive buffer_size = 0 # Creates a stream buffer if value is positive
} }
} }
} }

View file

@ -2,32 +2,32 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
fpgas = { fpgas = {
vc707 = { vc707 = {
interface = "pcie", interface = "pcie",
id = "10ee:7021", id = "10ee:7021",
slot = "0000:88:00.0", slot = "0000:88:00.0",
do_reset = true, do_reset = true,
ips = "../../../fpga/etc/vc707-xbar-pcie/vc707-xbar-pcie.json", ips = "../../../fpga/etc/vc707-xbar-pcie/vc707-xbar-pcie.json",
polling = false, polling = false,
} }
} }
nodes = { nodes = {
fpga_0 = { fpga_0 = {
type = "fpga", type = "fpga",
card = "vc707" card = "vc707"
connect = ["0->3", "3->dma", "0<-dma"] connect = ["0->3", "3->dma", "0<-dma"]
} }
} }
paths = ( paths = (
{ {
in = "fpga_0" in = "fpga_0"
out = "fpga_0" out = "fpga_0"
hooks = ({ type = "print"}) hooks = ({ type = "print"})
} }
) )

View file

@ -3,23 +3,23 @@
nodes = { nodes = {
iec104_node_seq = { iec104_node_seq = {
type = "iec60870-5-104" type = "iec60870-5-104"
address = "0.0.0.0" address = "0.0.0.0"
port = 2404 port = 2404
ca = 1 ca = 1
out = { out = {
# Create a sequence of 5 floats with identical IOAs # Create a sequence of 5 floats with identical IOAs
signals = { signals = {
asdu_type_id = "M_ME_NA_1" asdu_type_id = "M_ME_NA_1"
ioa = 4202852 ioa = 4202852
count = 5 count = 5
} }
# Interpret the duplicate IOAs as a sequence by incrementing the # Interpret the duplicate IOAs as a sequence by incrementing the
# IOA with each duplication. This only applies to two adjacent # IOA with each duplication. This only applies to two adjacent
# signals with the same IOA. Specifying an IOA twice with other # signals with the same IOA. Specifying an IOA twice with other
# IOAs inbetween is an error. # IOAs inbetween is an error.
duplicate_ioa_is_sequence = true duplicate_ioa_is_sequence = true
} }
} }
} }

View file

@ -4,46 +4,46 @@
nodes = { nodes = {
iec104_node = { iec104_node = {
type = "iec60870-5-104" type = "iec60870-5-104"
# Network address and port of the server # Network address and port of the server
# 0.0.0.0 listens on all interfaces # 0.0.0.0 listens on all interfaces
address = "0.0.0.0" address = "0.0.0.0"
port = 2404 port = 2404
# Common address of this IEC104 slave
ca = 41025
# Queue sizes for this node
low_priority_queue = 100
high_priority_queue = 100
out = { # Common address of this IEC104 slave
# Map signals to information object addresses and ASDU data types ca = 41025
# one ASDU per specified asdu_type_id/asdu_type+with_timestamp is
# send for each sample. Signals of the same type are collected # Queue sizes for this node
# in a single ASDU. low_priority_queue = 100
signals = ( high_priority_queue = 100
{
# The ASDU data type out = {
asdu_type = "normalized-float" # Map signals to information object addresses and ASDU data types
# add 56 bit unix timestamp to ASDU # one ASDU per specified asdu_type_id/asdu_type+with_timestamp is
with_timestamp = false # send for each sample. Signals of the same type are collected
# the information object address of this signal # in a single ASDU.
ioa = 4202832 signals = (
}, {
{ # The ASDU data type
# Equivalent to the asdu_type above asdu_type = "normalized-float"
asdu_type_id = "M_ME_NA_1" # add 56 bit unix timestamp to ASDU
ioa = 4202852 with_timestamp = false
}, # the information object address of this signal
{ ioa = 4202832
# A boolean value },
asdu_type = "single-point" {
with_timestamp = true # Equivalent to the asdu_type above
ioa = 4206948 asdu_type_id = "M_ME_NA_1"
} ioa = 4202852
) },
} {
} # A boolean value
asdu_type = "single-point"
with_timestamp = true
ioa = 4206948
}
)
}
}
} }

View file

@ -3,145 +3,145 @@
nodes = { nodes = {
goose = { goose = {
type = "iec61850-8-1" type = "iec61850-8-1"
out = { out = {
# Ethernet interface to publish on # Ethernet interface to publish on
interface = "lo" interface = "lo"
# Array of goose publisher definitions # Array of goose publisher definitions
publishers = ( publishers = (
{ {
# Mandatory GOOSE publisher meta data # Mandatory GOOSE publisher meta data
go_id = "AA1J1Q01A3LD0/LLN0.gcbdata" go_id = "AA1J1Q01A3LD0/LLN0.gcbdata"
go_cb_ref = "AA1J1Q01A3LD0/LLN0$GO$gcbdata" go_cb_ref = "AA1J1Q01A3LD0/LLN0$GO$gcbdata"
data_set_ref = "AA1J1Q01A3LD0/LLN0$data" data_set_ref = "AA1J1Q01A3LD0/LLN0$data"
dst_address = "01:0c:cd:01:00:00" dst_address = "01:0c:cd:01:00:00"
app_id = 2 app_id = 2
conf_rev = 100 conf_rev = 100
time_allowed_to_live = 11000 time_allowed_to_live = 11000
# Payload description with either constant data or values from a signal # Payload description with either constant data or values from a signal
data = ( data = (
{ {
# Mandatory MMS type # Mandatory MMS type
mms_type = "boolean" mms_type = "boolean"
# Name of the signal in the array below # Name of the signal in the array below
signal = "ABB_cascade_state" signal = "ABB_cascade_state"
}, },
{ {
# Mandatory MMS type # Mandatory MMS type
mms_type = "bitstring" mms_type = "bitstring"
# Type meta data # Type meta data
mms_bitstring_size = 13 mms_bitstring_size = 13
# Constant value # Constant value
value = 2048 value = 2048
} }
) )
}, },
{ {
go_id = "AA1J1Q01A3LD0/LLN0.gcbDataset_1" go_id = "AA1J1Q01A3LD0/LLN0.gcbDataset_1"
go_cb_ref = "AA1J1Q01A3LD0/LLN0$GO$gcbDataset_1" go_cb_ref = "AA1J1Q01A3LD0/LLN0$GO$gcbDataset_1"
data_set_ref = "AA1J1Q01A3LD0/LLN0$Dataset_1" data_set_ref = "AA1J1Q01A3LD0/LLN0$Dataset_1"
dst_address = "01:0c:cd:01:00:01" dst_address = "01:0c:cd:01:00:01"
app_id = 1 app_id = 1
conf_rev = 300 conf_rev = 300
time_allowed_to_live = 22000 time_allowed_to_live = 22000
data = ( data = (
{ {
mms_type = "boolean" mms_type = "boolean"
signal = "ABB_cascade_state" signal = "ABB_cascade_state"
}, },
{ {
mms_type = "bitstring" mms_type = "bitstring"
mms_bitstring_size = 13 mms_bitstring_size = 13
value = 2048 value = 2048
}, },
{ {
mms_type = "bitstring" mms_type = "bitstring"
mms_bitstring_size = 2 mms_bitstring_size = 2
value = 0 value = 0
}, },
{ {
mms_type = "bitstring" mms_type = "bitstring"
mms_bitstring_size = 13 mms_bitstring_size = 13
value = 2048 value = 2048
}, },
{ {
mms_type = "bitstring" mms_type = "bitstring"
mms_bitstring_size = 13 mms_bitstring_size = 13
value = 2048 value = 2048
}, },
{ {
mms_type = "bitstring" mms_type = "bitstring"
mms_bitstring_size = 2 mms_bitstring_size = 2
value = 0 value = 0
} }
) )
} }
) )
signals = ( signals = (
{ {
# The signal name used to identify the signal in a publishers data field # The signal name used to identify the signal in a publishers data field
name = "ABB_cascade_state" name = "ABB_cascade_state"
type = "boolean" type = "boolean"
} }
) )
} }
in = { in = {
# Ethernet interface to listen on # Ethernet interface to listen on
interface = "lo" interface = "lo"
# Use the goose timestamp for a sample # Use the goose timestamp for a sample
with_timestamp = true with_timestamp = true
# List of named subscriber definitions # List of named subscriber definitions
subscribers = { subscribers = {
relay = { relay = {
# Mandatory GoCbRef # Mandatory GoCbRef
go_cb_ref = "AA1J1Q01A3LD0/LLN0$GO$gcbdata" go_cb_ref = "AA1J1Q01A3LD0/LLN0$GO$gcbdata"
# Optional filter by packet destination MAC address # Optional filter by packet destination MAC address
dst_address = "01:0c:cd:01:00:00" dst_address = "01:0c:cd:01:00:00"
# Optional filter by AppID # Optional filter by AppID
app_id = 2 app_id = 2
# Optional trigger specification (either "always" or "change") # Optional trigger specification (either "always" or "change")
# #
# "always" = emit an updated sample for each incoming GOOSE message # "always" = emit an updated sample for each incoming GOOSE message
# "change" = only emit an updated sample when SqNum is 0 # "change" = only emit an updated sample when SqNum is 0
trigger = "change" trigger = "change"
} }
} }
signals = ( signals = (
{ {
name = "ABB_relay_state" name = "ABB_relay_state"
type = "boolean" type = "boolean"
# Mandatory MmsType specification # Mandatory MmsType specification
mms_type = "boolean" mms_type = "boolean"
# Mandatory subscriber name # Mandatory subscriber name
subscriber = "relay" subscriber = "relay"
# Mandatory index within the received vector of GOOSE values # Mandatory index within the received vector of GOOSE values
index = 0 index = 0
}, },
{ {
name = "ABB_relay_state_meta_bitset" name = "ABB_relay_state_meta_bitset"
type = "integer" type = "integer"
mms_type = "bitstring" mms_type = "bitstring"
subscriber = "relay" subscriber = "relay"
index = 1 index = 1
} }
) )
} }
} }
} }

View file

@ -2,31 +2,31 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
sampled_values_node = { sampled_values_node = {
type = "iec61850-9-2", type = "iec61850-9-2",
interface = "lo", interface = "lo",
dst_address = "01:0c:cd:01:00:01", dst_address = "01:0c:cd:01:00:01",
out = { out = {
signals = ( signals = (
{ iec_type = "float32" }, { iec_type = "float32" },
{ iec_type = "float64" }, { iec_type = "float64" },
{ iec_type = "int8" }, { iec_type = "int8" },
{ iec_type = "int32" } { iec_type = "int32" }
) )
svid = "test1234", svid = "test1234",
smpmod = "samples_per_second", smpmod = "samples_per_second",
confrev = 55 confrev = 55
}, },
in = { in = {
signals = ( signals = (
{ iec_type = "float32" }, { iec_type = "float32" },
{ iec_type = "float64" }, { iec_type = "float64" },
{ iec_type = "int8" }, { iec_type = "int8" },
{ iec_type = "int32" } { iec_type = "int32" }
) )
} }
} }
} }

View file

@ -2,73 +2,73 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
results = { results = {
type = "file", type = "file",
uri = "logs/ib_results-%Y%m%d_%H-%M-%S.log", uri = "logs/ib_results-%Y%m%d_%H-%M-%S.log",
}, },
siggen = { siggen = {
type = "signal", type = "signal",
signal = "mixed", signal = "mixed",
values = 3, values = 3,
frequency = 3.0, frequency = 3.0,
rate = 100000.0, rate = 100000.0,
limit = 100000, limit = 100000,
}, },
ib_node_source = { ib_node_source = {
type = "infiniband", type = "infiniband",
rdma_port_space = "RC", rdma_port_space = "RC",
in = {
address = "10.0.0.2:1337",
max_wrs = 8192, in = {
cq_size = 8192, address = "10.0.0.2:1337",
vectorize = 1, max_wrs = 8192,
cq_size = 8192,
buffer_subtraction = 128, vectorize = 1,
},
out = { buffer_subtraction = 128,
address = "10.0.0.1:1337", },
resolution_timeout = 1000,
max_wrs = 8192,
cq_size = 256,
vectorize = 1, out = {
address = "10.0.0.1:1337",
resolution_timeout = 1000,
send_inline = true, max_wrs = 8192,
max_inline_data = 60, cq_size = 256,
use_fallback = true, vectorize = 1,
}
}
ib_node_target = { send_inline = true,
type = "infiniband", max_inline_data = 60,
rdma_port_space = "RC", use_fallback = true,
}
}
in = { ib_node_target = {
address = "10.0.0.1:1337", type = "infiniband",
max_wrs = 8192, rdma_port_space = "RC",
cq_size = 8192,
vectorize = 1, in = {
address = "10.0.0.1:1337",
buffer_subtraction = 128, max_wrs = 8192,
cq_size = 8192,
hooks = ( vectorize = 1,
{ type = "stats", verbose = true }
) buffer_subtraction = 128,
}
} hooks = (
{ type = "stats", verbose = true }
)
}
}
} }

View file

@ -2,10 +2,10 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
influxdb_node = { influxdb_node = {
type = "influxdb", type = "influxdb",
server = "localhost:8089", server = "localhost:8089",
key = "villas" key = "villas"
} }
} }

View file

@ -2,30 +2,30 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
kafka_node = { kafka_node = {
type = "kafka", type = "kafka",
format = "json.kafka",
server = "localhost:9094", format = "json.kafka",
protocol = "SASL_SSL",
client_id = "villas-node",
in = { server = "localhost:9094",
consume = "test-topic", protocol = "SASL_SSL",
group_id = "villas-node" client_id = "villas-node",
},
out = {
produce = "test-topic"
},
ssl = { in = {
ca = "/etc/ssl/certs/ca.pem", consume = "test-topic",
}, group_id = "villas-node"
sasl = { },
mechanisms = "SCRAM-SHA-512", out = {
username = "scram-sha-512-usr", produce = "test-topic"
password = "scram-sha-512-pwd" },
}
} ssl = {
ca = "/etc/ssl/certs/ca.pem",
},
sasl = {
mechanisms = "SCRAM-SHA-512",
username = "scram-sha-512-usr",
password = "scram-sha-512-pwd"
}
}
} }

View file

@ -2,10 +2,10 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
loopback_node = { loopback_node = {
type = "loopback", # A loopback node will receive exactly the same data which has been sent to it. type = "loopback", # A loopback node will receive exactly the same data which has been sent to it.
# The internal implementation is based on queue. # The internal implementation is based on queue.
queuelen = 1024, # The queue length of the internal queue which buffers the samples. queuelen = 1024, # The queue length of the internal queue which buffers the samples.
mode = "polling" # Use busy polling for synchronization of the read and write side of the queue mode = "polling" # Use busy polling for synchronization of the read and write side of the queue
} }
} }

View file

@ -2,167 +2,167 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
modbus_node = { modbus_node = {
type = "modbus" type = "modbus"
# Required transport type. Can be either "rtu" or "tcp" # Required transport type. Can be either "rtu" or "tcp"
transport = "tcp" transport = "tcp"
# Optional timeout in seconds when waiting for responses from a modbus server. # Optional timeout in seconds when waiting for responses from a modbus server.
# Default is 1.0. # Default is 1.0.
response_timeout = 1.0 response_timeout = 1.0
# #
# Settings for transport = "tcp". # Settings for transport = "tcp".
# #
# Required remote IP address. # Required remote IP address.
remote = "127.0.0.1" remote = "127.0.0.1"
# Optional remote port. # Optional remote port.
# Default is 502. # Default is 502.
port = 502 port = 502
# #
# Settings for transport = "rtu" # Settings for transport = "rtu"
# #
# Required device file. # Required device file.
device = "/dev/ttyS0" device = "/dev/ttyS0"
# Required baudrate. # Required baudrate.
baudrate = 9600 baudrate = 9600
# Required parity. One of "none", "even" and "odd" # Required parity. One of "none", "even" and "odd"
parity = "none" parity = "none"
# Required data bits. One of 5, 6, 7, 8 # Required data bits. One of 5, 6, 7, 8
data_bits = 5 data_bits = 5
# Required stop bits. One of 1, 2 # Required stop bits. One of 1, 2
stop_bits = 1 stop_bits = 1
# The modbus unit ID. # The modbus unit ID.
# Required for transport = "rtu". # Required for transport = "rtu".
# Optional for transport = "tcp". # Optional for transport = "tcp".
unit = 1 unit = 1
# Optional polling rate for the modbus remote reads. # Optional polling rate for the modbus remote reads.
# Defaults to 10. # Defaults to 10.
rate = 10 rate = 10
in = { in = {
signals = ( signals = (
# A 32-bit IEEE 754 floating point value. # A 32-bit IEEE 754 floating point value.
# This spans 2 registers. # This spans 2 registers.
{ {
# Required type = "float". # Required type = "float".
type = "float" type = "float"
# Required address of the lowest register. # Required address of the lowest register.
address = 0x50 address = 0x50
# Optional endianess for joining the 2 16-bit registers into a 32-bit value. # Optional endianess for joining the 2 16-bit registers into a 32-bit value.
# Defaults to "big". # Defaults to "big".
word_endianess = "big" word_endianess = "big"
# Optional endianess for the 2 bytes within a register. # Optional endianess for the 2 bytes within a register.
# Defaults to "big". # Defaults to "big".
byte_endianess = "big" byte_endianess = "big"
# Optional scale that should be applied to the integer value. # Optional scale that should be applied to the integer value.
# Defaults to 1. # Defaults to 1.
scale = 10 scale = 10
# Optional offset that should be applied to the integer value after scaling. # Optional offset that should be applied to the integer value after scaling.
# Defaults to 0. # Defaults to 0.
offset = 2 offset = 2
}, },
# A single bit within a register as a boolean value. # A single bit within a register as a boolean value.
{ {
# Required type = "boolean". # Required type = "boolean".
type = "boolean" type = "boolean"
# Required address of the register. # Required address of the register.
address = 0x54 address = 0x54
# Required bit within the register. # Required bit within the register.
# Starting at 0. # Starting at 0.
bit = 0 bit = 0
}, },
# An integer value. # An integer value.
# This may span multiple registers. # This may span multiple registers.
{ {
# Required type = "integer". # Required type = "integer".
type = "integer" type = "integer"
# Required address of the lowest register. # Required address of the lowest register.
address = 0x52 address = 0x52
# Optional number of registers that should be joined to form the value. # Optional number of registers that should be joined to form the value.
# Defaults to 1. # Defaults to 1.
integer_registers = 1 integer_registers = 1
# Optional endianess for joining the 16-bit registers into a 32-bit value. # Optional endianess for joining the 16-bit registers into a 32-bit value.
# Defaults to "big". # Defaults to "big".
word_endianess = "big" word_endianess = "big"
# Optional endianess for the 2 bytes within a register. # Optional endianess for the 2 bytes within a register.
# Defaults to "big". # Defaults to "big".
byte_endianess = "big" byte_endianess = "big"
}, },
# An float value created by reading an integer and applying an optional offset and scale. # An float value created by reading an integer and applying an optional offset and scale.
# This may span multiple registers. # This may span multiple registers.
{ {
# Required type = "float". # Required type = "float".
type = "float" type = "float"
# Required address of the lowest register. # Required address of the lowest register.
address = 0x52 address = 0x52
# Required number of registers that should be joined to form the value. # Required number of registers that should be joined to form the value.
# A "float" value without the "integer_registers" settings is considered an IEEE 754 float, spanning 2 registers. # A "float" value without the "integer_registers" settings is considered an IEEE 754 float, spanning 2 registers.
integer_registers = 1 integer_registers = 1
# Optional endianess for joining the 16-bit registers into a 32-bit value. # Optional endianess for joining the 16-bit registers into a 32-bit value.
# Defaults to "big". # Defaults to "big".
word_endianess = "big" word_endianess = "big"
# Optional endianess for the 2 bytes within a register. # Optional endianess for the 2 bytes within a register.
# Defaults to "big". # Defaults to "big".
byte_endianess = "big" byte_endianess = "big"
# Optional scale that should be applied to the integer value. # Optional scale that should be applied to the integer value.
# Defaults to 1. # Defaults to 1.
scale = 10 scale = 10
# Optional offset that should be applied to the integer value after scaling. # Optional offset that should be applied to the integer value after scaling.
# Defaults to 0. # Defaults to 0.
offset = 2 offset = 2
} }
) )
} }
out = { out = {
signals = ( signals = (
# All register mappings described for "in" except for "boolean" are supported in the "out" signals. # All register mappings described for "in" except for "boolean" are supported in the "out" signals.
{ {
type = "float" type = "float"
address = 0x50 address = 0x50
# Scale and offset a applied as attributes of the register that is written to. # Scale and offset a applied as attributes of the register that is written to.
# This means the value written to "register" for a "signal" with "offset" and "scale" will be: # This means the value written to "register" for a "signal" with "offset" and "scale" will be:
# #
# register = (signal - offset) / scale # register = (signal - offset) / scale
# #
# It is fairly common to specify a scale and offset for modbus registers in a device manual. # It is fairly common to specify a scale and offset for modbus registers in a device manual.
# You should be able to plug those values into this configuration without conversion. # You should be able to plug those values into this configuration without conversion.
scale = 10 scale = 10
offset = 2 offset = 2
}, },
) )
} }
} }
} }

View file

@ -2,32 +2,32 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
mqtt_node = { mqtt_node = {
type = "mqtt", type = "mqtt",
format = "protobuf",
username = "guest",
password = "guest",
host = "localhost",
port = 1883,
keepalive = 5, # Send ping every 5 seconds to keep connection alive
retain = false,
qos = 0,
out = { format = "protobuf",
publish = "test-topic"
}, username = "guest",
in = { password = "guest",
subscribe = "test-topic" host = "localhost",
}, port = 1883,
ssl = {
enabled = false, keepalive = 5, # Send ping every 5 seconds to keep connection alive
insecure = true, retain = false,
cafile = "/etc/ssl/certs/ca-bundle.crt", qos = 0,
certfile = "/etc/ssl/certs/my.crt",
keyfile = "/etc/ssl/keys/my.key" out = {
} publish = "test-topic"
} },
in = {
subscribe = "test-topic"
},
ssl = {
enabled = false,
insecure = true,
cafile = "/etc/ssl/certs/ca-bundle.crt",
certfile = "/etc/ssl/certs/my.crt",
keyfile = "/etc/ssl/keys/my.key"
}
}
} }

View file

@ -2,22 +2,22 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
nanomsg_node = { nanomsg_node = {
type = "nanomsg", type = "nanomsg",
out = { out = {
endpoints = [ endpoints = [
"tcp://*:12000", # TCP socket "tcp://*:12000", # TCP socket
"ipc:///tmp/test.ipc", # Interprocess communication "ipc:///tmp/test.ipc", # Interprocess communication
"inproc://test" # Inprocess communication "inproc://test" # Inprocess communication
], ],
} }
in = { in = {
endpoints = [ endpoints = [
"tcp://127.0.0.1:12000", "tcp://127.0.0.1:12000",
"ipc:///tmp/test.ipc", "ipc:///tmp/test.ipc",
"inproc://test" "inproc://test"
] ]
} }
} }
} }

View file

@ -2,29 +2,29 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
udp_node = { # The dictionary is indexed by the name of the node. udp_node = { # The dictionary is indexed by the name of the node.
type = "socket", # For a list of available node-types run: 'villas-node -h' type = "socket", # For a list of available node-types run: 'villas-node -h'
### The following settings are specific to the socket node-type!! ### ### The following settings are specific to the socket node-type!! ###
format = "gtnet", # For a list of available node-types run: 'villas-node -h' format = "gtnet", # For a list of available node-types run: 'villas-node -h'
in = { in = {
address = "127.0.0.1:12001" # This node only received messages on this IP:Port pair address = "127.0.0.1:12001" # This node only received messages on this IP:Port pair
}, },
out = { out = {
address = "127.0.0.1:12000", # This node sends outgoing messages to this IP:Port pair address = "127.0.0.1:12000", # This node sends outgoing messages to this IP:Port pair
netem = { # Network emulation settings netem = { # Network emulation settings
enabled = true, enabled = true,
# Those settings can be specified for each node individually! # Those settings can be specified for each node individually!
delay = 100000, # Additional latency in microseconds delay = 100000, # Additional latency in microseconds
jitter = 30000, # Jitter in uS jitter = 30000, # Jitter in uS
distribution = "normal", # Distribution of delay: uniform, normal, pareto, paretonormal distribution = "normal", # Distribution of delay: uniform, normal, pareto, paretonormal
loss = 10 # Packet loss in percent loss = 10 # Packet loss in percent
duplicate = 10, # Duplication in percent duplicate = 10, # Duplication in percent
corrupt = 10 # Corruption in percent corrupt = 10 # Corruption in percent
} }
} }
} }
} }

View file

@ -2,43 +2,43 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
ngsi_node = { ngsi_node = {
type = "ngsi", type = "ngsi",
### The following settings are specific to the ngsi node-type!! ### ### The following settings are specific to the ngsi node-type!! ###
# The HTTP REST API endpoint of the FIRWARE context broker # The HTTP REST API endpoint of the FIRWARE context broker
endpoint = "http://46.101.131.212:1026", endpoint = "http://46.101.131.212:1026",
access_token: "aig1aaQuohsh5pee9uiC2Bae3loSh9wu" # Add an 'Auth-Token' token header to each request access_token: "aig1aaQuohsh5pee9uiC2Bae3loSh9wu" # Add an 'Auth-Token' token header to each request
entity_id = "S3_ElectricalGrid", entity_id = "S3_ElectricalGrid",
entity_type = "ElectricalGridMonitoring", entity_type = "ElectricalGridMonitoring",
create = true # Create the NGSI entities during startup create = true # Create the NGSI entities during startup
rate = 0.1 # Rate at which we poll the broker for updates rate = 0.1 # Rate at which we poll the broker for updates
timeout = 1, # Timeout of HTTP request in seconds (default is 1, must be smaller than 1 / rate) timeout = 1, # Timeout of HTTP request in seconds (default is 1, must be smaller than 1 / rate)
verify_ssl = false, # Verification of SSL server certificates (default is true) verify_ssl = false, # Verification of SSL server certificates (default is true)
in = { in = {
signals = ( signals = (
{ {
name = "attr1", name = "attr1",
ngsi_attribute_name = "attr1", # defaults to signal 'name' ngsi_attribute_name = "attr1", # defaults to signal 'name'
ngsi_attribute_type = "Volts", # default to signal 'unit' ngsi_attribute_type = "Volts", # default to signal 'unit'
ngsi_attribute_metadatas = ( ngsi_attribute_metadatas = (
{ name="accuracy", type="percent", value="5" } { name="accuracy", type="percent", value="5" }
) )
} }
) )
} }
out = { out = {
signals = ( signals = (
{ name="PTotalLosses", unit="MW" }, { name="PTotalLosses", unit="MW" },
{ name="QTotalLosses", unit="Mvar" } { name="QTotalLosses", unit="Mvar" }
) )
} }
} }
} }

View file

@ -2,38 +2,38 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
opal_node = { # The server can be started as an Asynchronous process opal_node = { # The server can be started as an Asynchronous process
type = "opal", # from within an OPAL-RT model. type = "opal", # from within an OPAL-RT model.
### The following settings are specific to the opal node-type!! ### ### The following settings are specific to the opal node-type!! ###
send_id = 1, # It's possible to have multiple send / recv Icons per model send_id = 1, # It's possible to have multiple send / recv Icons per model
recv_id = 1, # Specify the ID here. recv_id = 1, # Specify the ID here.
reply = true reply = true
}, },
file_node = { file_node = {
type = "file", type = "file",
### The following settings are specific to the file node-type!! ### ### The following settings are specific to the file node-type!! ###
uri = "logs/input.log", # These options specify the path prefix where the the files are stored uri = "logs/input.log", # These options specify the path prefix where the the files are stored
in = {
epoch_mode = "direct" # One of: direct (default), wait, relative, absolute
epoch = 10 # The interpretation of this value depends on epoch_mode (default is 0).
# Consult the documentation of a full explanation
rate = 2.0 # A constant rate at which the lines of the input files should be read in = {
# A missing or zero value will use the timestamp in the first column epoch_mode = "direct" # One of: direct (default), wait, relative, absolute
# of the file to determine the pause between consecutive lines. epoch = 10 # The interpretation of this value depends on epoch_mode (default is 0).
# Consult the documentation of a full explanation
buffer_size = 1000000
eof = "rewind" # One of: rewind, exit (default) or wait rate = 2.0 # A constant rate at which the lines of the input files should be read
}, # A missing or zero value will use the timestamp in the first column
out = { # of the file to determine the pause between consecutive lines.
flush = true
buffer_size = 1000000 buffer_size = 1000000
}
} eof = "rewind" # One of: rewind, exit (default) or wait
},
out = {
flush = true
buffer_size = 1000000
}
}
} }

View file

@ -2,41 +2,41 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
redis_node = { redis_node = {
type = "redis", type = "redis",
format = "json", # only valid for mode = 'channel' and 'key' format = "json", # only valid for mode = 'channel' and 'key'
# With mode = 'hash' we will use a simple human readable format # With mode = 'hash' we will use a simple human readable format
key = "my_key" # The Redis key to be used for mode = 'key' or 'hash' (default is the node name) key = "my_key" # The Redis key to be used for mode = 'key' or 'hash' (default is the node name)
channel = "my_channel" # the Redis channel tp be used for mode = 'channel' (default is the node name) channel = "my_channel" # the Redis channel tp be used for mode = 'channel' (default is the node name)
mode = "key", # one of: mode = "key", # one of:
# - 'channel' (publish/subscribe) # - 'channel' (publish/subscribe)
# - 'key' (set/get) # - 'key' (set/get)
# - 'hash' (hmset/hgetall) # - 'hash' (hmset/hgetall)
notify = false # Whether or not to use Redis keyspace event notifications to get notified about updates notify = false # Whether or not to use Redis keyspace event notifications to get notified about updates
rate = 1.0 # The polling rate when notify = false
uri = "tcp://localhost:6379/0", # The Redis connection URI rate = 1.0 # The polling rate when notify = false
# host = "localhost" # Alternatively the connection options can be specified independently uri = "tcp://localhost:6379/0", # The Redis connection URI
# port = 6379 # Note: options here will overwrite the respective part of the URI if both are given.
# db = 0
# path = "/var/run/redis.sock" # host = "localhost" # Alternatively the connection options can be specified independently
# port = 6379 # Note: options here will overwrite the respective part of the URI if both are given.
# db = 0
# user = "guest", # path = "/var/run/redis.sock"
# password = "guest"
# ssl = { # user = "guest",
# enabled: true # password = "guest"
# cacert: "/etc/ssl/certs/ca-certificates.crt",
# cacertdir: "/etc/ssl/certs" # ssl = {
# cert: "./my_cert.crt", # enabled: true
# key, "./my_key.key" # cacert: "/etc/ssl/certs/ca-certificates.crt",
# } # cacertdir: "/etc/ssl/certs"
} # cert: "./my_cert.crt",
# key, "./my_key.key"
# }
}
} }

View file

@ -2,51 +2,51 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
rtp_node = { rtp_node = {
type = "rtp" type = "rtp"
format = { format = {
type = "raw" type = "raw"
bits = 32 bits = 32
endianess = "big" endianess = "big"
} }
rtcp = false rtcp = false
aimd = { aimd = {
a = 10, a = 10,
b = 0.5 b = 0.5
Kp = 1.0 Kp = 1.0
Ki = 0.0 Ki = 0.0
Kd = 0 Kd = 0
rate_min = 100 rate_min = 100
rate_init = 2000 rate_init = 2000
rate_source = 10000 rate_source = 10000
log = "aimd-rates-%Y_%m_%d_%s.log" log = "aimd-rates-%Y_%m_%d_%s.log"
hook_type = "limit_rate" hook_type = "limit_rate"
} }
in = { in = {
address = "0.0.0.0:12000", address = "0.0.0.0:12000",
signals = { signals = {
count = 3 count = 3
type = "float" type = "float"
} }
} }
out = { out = {
address = "127.0.0.1:12000" address = "127.0.0.1:12000"
netem = { # Network emulation settings netem = { # Network emulation settings
enabled = false, enabled = false,
delay = 100000, # Additional latency in microseconds delay = 100000, # Additional latency in microseconds
loss = 10 # Packet loss in percent loss = 10 # Packet loss in percent
} }
} }
} }
} }

View file

@ -2,22 +2,22 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
shmem_node = { shmem_node = {
type = "shmem", type = "shmem",
in = {
name = "sn1_in"
}, # Name of shared memory segment for receiving side
out = {
name = "sn1_in" # Name of shared memory segment for sending side
},
queuelen = 1024, # Length of the queues in = {
mode = "pthread", # We can busy-wait or use pthread condition variables for synchronizations name = "sn1_in"
}, # Name of shared memory segment for receiving side
# Execute an external process when starting the node which out = {
# then starts the other side of this shared memory channel name = "sn1_in" # Name of shared memory segment for sending side
# Usually we also pass the shmem names as parameters. },
exec = [ "villas-shmem", "sn1_in", "sn1_out" ]
} queuelen = 1024, # Length of the queues
mode = "pthread", # We can busy-wait or use pthread condition variables for synchronizations
# Execute an external process when starting the node which
# then starts the other side of this shared memory channel
# Usually we also pass the shmem names as parameters.
exec = [ "villas-shmem", "sn1_in", "sn1_out" ]
}
} }

View file

@ -2,32 +2,32 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
signal_node = { signal_node = {
type = "signal.v2", type = "signal.v2",
rate = 10.0 rate = 10.0
realtime = true, # Wait between emitting each sample realtime = true, # Wait between emitting each sample
limit = 1000, # Only emit 1000 samples, then stop limit = 1000, # Only emit 1000 samples, then stop
monitor_missed = true # Count and warn about missed steps monitor_missed = true # Count and warn about missed steps
in = { in = {
signals = ( signals = (
{ name = "sine1", signal = "sine", amplitude = 123.456, frequency = 10, offset = 1.0 }, { name = "sine1", signal = "sine", amplitude = 123.456, frequency = 10, offset = 1.0 },
{ name = "sine2", signal = "sine", amplitude = 12.456, frequency = 20, offset = 10.0 }, { name = "sine2", signal = "sine", amplitude = 12.456, frequency = 20, offset = 10.0 },
{ name = "sine3", signal = "sine", amplitude = 2, frequency = 1, offset = 100.0 }, { name = "sine3", signal = "sine", amplitude = 2, frequency = 1, offset = 100.0 },
{ name = "random1", signal = "random", amplitude = 2, stddev = 2, offset = 13.0 }, { name = "random1", signal = "random", amplitude = 2, stddev = 2, offset = 13.0 },
{ name = "pulse1", signal = "pulse", frequency = 1.0, pulse_width = 1, pulse_high = 100, pulse_low = 50 } { name = "pulse1", signal = "pulse", frequency = 1.0, pulse_width = 1, pulse_high = 100, pulse_low = 50 }
) )
} }
}, },
signal_node2 = { signal_node2 = {
type = "signal.v2", type = "signal.v2",
in = { in = {
signals = { signals = {
count = 8, count = 8,
signal = "mixed" signal = "mixed"
} }
} }
} }
} }

View file

@ -2,20 +2,20 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
signal_node = { signal_node = {
type = "signal", type = "signal",
# One of "sine", "square", "ramp", "triangle", "random", "mixed", "counter" # One of "sine", "square", "ramp", "triangle", "random", "mixed", "counter"
signal = [ "sine", "pulse", "square" ], signal = [ "sine", "pulse", "square" ],
values = 3, # Number of values per sample values = 3, # Number of values per sample
amplitude = [ 1.2, 0.0, 4.0 ], # Amplitude of generated signals amplitude = [ 1.2, 0.0, 4.0 ], # Amplitude of generated signals
frequency = 10, # Frequency of generated signals frequency = 10, # Frequency of generated signals
stddev = 2, # Standard deviation of random signals (normal distributed) stddev = 2, # Standard deviation of random signals (normal distributed)
rate = 10.0, # Sample rate rate = 10.0, # Sample rate
offset = 1.0, # Constant offset offset = 1.0, # Constant offset
realtime = true, # Wait between emitting each sample realtime = true, # Wait between emitting each sample
limit = 1000, # Only emit 1000 samples, then stop limit = 1000, # Only emit 1000 samples, then stop
monitor_missed = true # Count and warn about missed steps monitor_missed = true # Count and warn about missed steps
} }
} }

View file

@ -2,78 +2,78 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
udp_node = { # The dictionary is indexed by the name of the node. udp_node = { # The dictionary is indexed by the name of the node.
type = "socket", # For a list of available node-types run: 'villas-node -h' type = "socket", # For a list of available node-types run: 'villas-node -h'
vectorize = 30, # Receive and sent 30 samples per message (combining). vectorize = 30, # Receive and sent 30 samples per message (combining).
samplelen = 10 # The maximum number of samples this node can receive samplelen = 10 # The maximum number of samples this node can receive
builtin = false, # By default, all nodes will have a few builtin hooks attached to them. builtin = false, # By default, all nodes will have a few builtin hooks attached to them.
# When collecting statistics or measurements these are undesired. # When collecting statistics or measurements these are undesired.
### The following settings are specific to the socket node-type!! ### ### The following settings are specific to the socket node-type!! ###
layer = "udp", # Layer can be one of: layer = "udp", # Layer can be one of:
# - udp Send / receive L4 UDP packets # - udp Send / receive L4 UDP packets
# - ip Send / receive L3 IP packets # - ip Send / receive L3 IP packets
# - eth Send / receive L2 Ethernet frames (IEEE802.3) # - eth Send / receive L2 Ethernet frames (IEEE802.3)
format = "gtnet", # For a list of available node-types run: 'villas-node -h' format = "gtnet", # For a list of available node-types run: 'villas-node -h'
in = { in = {
address = "127.0.0.1:12001" # This node only received messages on this IP:Port pair address = "127.0.0.1:12001" # This node only received messages on this IP:Port pair
verify_source = true # Check if source address of incoming packets matches the remote address.
},
out = {
address = "127.0.0.1:12000", # This node sends outgoing messages to this IP:Port pair
}
}
ethernet_node = { verify_source = true # Check if source address of incoming packets matches the remote address.
type = "socket", # See above. },
out = {
address = "127.0.0.1:12000", # This node sends outgoing messages to this IP:Port pair
}
}
### The following settings are specific to the socket node-type!! ### ethernet_node = {
type = "socket", # See above.
layer = "eth", ### The following settings are specific to the socket node-type!! ###
in = {
address = "12:34:56:78:90:AB%lo:12002"
},
out = {
address = "12:34:56:78:90:AB%lo:12002"
}
},
unix_domain_node = { layer = "eth",
type = "socket", in = {
layer = "unix", # Datagram UNIX domain sockets require two endpoints address = "12:34:56:78:90:AB%lo:12002"
},
in = { out = {
address = "/var/run/villas-node/node.sock" address = "12:34:56:78:90:AB%lo:12002"
}, }
out = { },
address = "/var/run/villas-node/client.sock"
}
}
udp_multicast_node = { # The dictionary is indexed by the name of the node. unix_domain_node = {
type = "socket", # For a list of available node-types run: 'villas-node -h' type = "socket",
layer = "unix", # Datagram UNIX domain sockets require two endpoints
### The following settings are specific to the socket node-type!! ### in = {
address = "/var/run/villas-node/node.sock"
},
out = {
address = "/var/run/villas-node/client.sock"
}
}
in = { udp_multicast_node = { # The dictionary is indexed by the name of the node.
address = "127.0.0.1:12001" # This node only received messages on this IP:Port pair type = "socket", # For a list of available node-types run: 'villas-node -h'
multicast = { # IGMP multicast is only support for layer = (ip|udp) ### The following settings are specific to the socket node-type!! ###
enabled = true,
group = "224.1.2.3", # The multicast group. Must be within 224.0.0.0/4 in = {
interface = "1.2.3.4", # The IP address of the interface which should receive multicast packets. address = "127.0.0.1:12001" # This node only received messages on this IP:Port pair
ttl = 128, # The time to live for outgoing multicast packets.
loop = false, # Whether or not to loopback outgoing multicast packets to the local host. multicast = { # IGMP multicast is only support for layer = (ip|udp)
} enabled = true,
},
out = { group = "224.1.2.3", # The multicast group. Must be within 224.0.0.0/4
address = "127.0.0.1:12000", # This node sends outgoing messages to this IP:Port pair interface = "1.2.3.4", # The IP address of the interface which should receive multicast packets.
} ttl = 128, # The time to live for outgoing multicast packets.
} loop = false, # Whether or not to loopback outgoing multicast packets to the local host.
}
},
out = {
address = "127.0.0.1:12000", # This node sends outgoing messages to this IP:Port pair
}
}
} }

View file

@ -2,28 +2,28 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
udp_node = { udp_node = {
type = "socket" type = "socket"
in = { in = {
address = "*:12000" address = "*:12000"
} }
out = { out = {
address = "127.0.0.1:12000" address = "127.0.0.1:12000"
} }
} }
stats_node = { stats_node = {
type = "stats" type = "stats"
node = "udp_node"
rate = 2
in = { node = "udp_node"
signals = ( rate = 2
{ name = "one_way_delay_mean", type = "float", stats = "udp_node.owd.mean" },
{ name = "one_way_delay_min", type = "float", stats = "udp_node.owd.lowest" }, in = {
{ name = "one_way_delay_max", type = "float", stats = "udp_node.owd.highest" } signals = (
) { name = "one_way_delay_mean", type = "float", stats = "udp_node.owd.mean" },
} { name = "one_way_delay_min", type = "float", stats = "udp_node.owd.lowest" },
} { name = "one_way_delay_max", type = "float", stats = "udp_node.owd.highest" }
)
}
}
} }

View file

@ -2,15 +2,15 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
temper_node = { temper_node = {
type = "temper" type = "temper"
calibration = { calibration = {
scale = 1.0 scale = 1.0
offset = 0.0 offset = 0.0
} }
bus = 0x1 bus = 0x1
port = 0x1 port = 0x1
} }
} }

View file

@ -2,44 +2,44 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
rtt_node = { # The "test_rtt" node-type runs a set of test cases for varying rtt_node = { # The "test_rtt" node-type runs a set of test cases for varying
type = "test_rtt", # sending rates, number of values and generates statistics. type = "test_rtt", # sending rates, number of values and generates statistics.
cooldown = 2, # The cooldown time between each test case in seconds cooldown = 2, # The cooldown time between each test case in seconds
prefix = "test_rtt_%y-%m-%d_%H-%M-%S", # An optional prefix in the filename
output = "./results", # The output directory for all results
# The results of each test case will be written to a separate file.
format = "villas.human", # The output format of the result files.
cases = ( # The list of test cases prefix = "test_rtt_%y-%m-%d_%H-%M-%S", # An optional prefix in the filename
# Each test case can specify a single or an array of rates and values output = "./results", # The output directory for all results
# If arrays are used, we will generate multiple test cases with all # The results of each test case will be written to a separate file.
# possible combinations format = "villas.human", # The output format of the result files.
{
rates = 55.0, # The sending rate in Hz cases = ( # The list of test cases
values = [ 5, 10, 20], # The number of values which should be send in each sample # Each test case can specify a single or an array of rates and values
limit = 100 # The number of samples which should be send during this test case # If arrays are used, we will generate multiple test cases with all
}, # possible combinations
{ {
rates = [ 5, 10, 30 ], # An array of rates in Hz rates = 55.0, # The sending rate in Hz
values = [ 2, 10, 20 ],# An array of number of values values = [ 5, 10, 20], # The number of values which should be send in each sample
duration = 5 # The duration of the test case in seconds (depending on the sending rate) limit = 100 # The number of samples which should be send during this test case
} },
) {
} rates = [ 5, 10, 30 ], # An array of rates in Hz
values = [ 2, 10, 20 ],# An array of number of values
duration = 5 # The duration of the test case in seconds (depending on the sending rate)
}
)
}
} }
paths = ( paths = (
{ {
# Simple loopback path to test the node # Simple loopback path to test the node
in = "rtt_node" in = "rtt_node"
out = "rtt_node" out = "rtt_node"
# hooks = ( # hooks = (
# { # {
# type = "print" # type = "print"
# } # }
# ) # )
} }
) )

View file

@ -2,50 +2,50 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
http = { http = {
enabled = false enabled = false
} }
nodes = { nodes = {
ul201 = { ul201 = {
type = "uldaq" type = "uldaq"
interface_type = "usb" interface_type = "usb"
in = { in = {
range = "bipolar-10", range = "bipolar-10",
input_mode = "single-ended" input_mode = "single-ended"
signals = ( signals = (
{ name = "ch0", type = "float", channel = 0 } { name = "ch0", type = "float", channel = 0 }
) )
sample_rate = 5000, sample_rate = 5000,
vectorize = 100 vectorize = 100
} }
}, },
vpmu = { vpmu = {
type = "socket", type = "socket",
layer = "udp", layer = "udp",
format = { format = {
type = "raw" type = "raw"
bits = 32 bits = 32
endianess = "big" endianess = "big"
} }
in = { in = {
address = "*:13001" address = "*:13001"
signals = () signals = ()
}, },
out = { out = {
vectorize = 100 vectorize = 100
address = "10.100.1.125:13000" address = "10.100.1.125:13000"
} }
} }
} }
paths = ( paths = (
{ {
in = "ul201", in = "ul201",
out = "vpmu" out = "vpmu"
} }
) )

View file

@ -2,16 +2,16 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
unix_domain_node = { unix_domain_node = {
type = "socket", type = "socket",
layer = "unix", layer = "unix",
format = "protobuf", format = "protobuf",
in = { in = {
address = "/var/run/villas-node.server.sock" address = "/var/run/villas-node.server.sock"
}, },
out = { out = {
address = "/var/run/villas-node.client.sock" address = "/var/run/villas-node.client.sock"
} }
} }
} }

View file

@ -2,37 +2,37 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
webrtc_node = { webrtc_node = {
type = "webrtc", type = "webrtc",
format = "json" format = "json"
# A unique session identifier which must be shared between two nodes # A unique session identifier which must be shared between two nodes
session = "my-session-name" session = "my-session-name"
# Address to the websocket signaling server # Address to the websocket signaling server
server = "https://villas.k8s.eonerc.rwth-aachen.de/ws/signaling" server = "https://villas.k8s.eonerc.rwth-aachen.de/ws/signaling"
# Limit the number of times a channel will retransmit data if not successfully delivered. # Limit the number of times a channel will retransmit data if not successfully delivered.
# This value may be clamped if it exceeds the maximum value supported. # This value may be clamped if it exceeds the maximum value supported.
max_retransmits = 0 max_retransmits = 0
# Number of seconds to wait for a WebRTC connection before proceeding the start # Number of seconds to wait for a WebRTC connection before proceeding the start
# of VILLASnode. Mainly used for testing # of VILLASnode. Mainly used for testing
wait_seconds = 10 # in seconds wait_seconds = 10 # in seconds
# Indicates if data is allowed to be delivered out of order. # Indicates if data is allowed to be delivered out of order.
# The default value of false, does not make guarantees that data will be delivered in order. # The default value of false, does not make guarantees that data will be delivered in order.
ordered = false ordered = false
# Setting for Interactive Connectivity Establishment # Setting for Interactive Connectivity Establishment
ice = { ice = {
# List of STUN/TURN servers # List of STUN/TURN servers
servers = ( servers = (
"stun:stun.0l.de:3478", "stun:stun.0l.de:3478",
"turn:villas:villas@turn.0l.de:3478?transport=udp", "turn:villas:villas@turn.0l.de:3478?transport=udp",
"turn:villas:villas@turn.0l.de:3478?transport=tcp" "turn:villas:villas@turn.0l.de:3478?transport=tcp"
) )
} }
} }
} }

View file

@ -2,17 +2,17 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
ws = { ws = {
type = "websocket" type = "websocket"
destinations = [ destinations = [
"ws://someserver:8080/somenode" "ws://someserver:8080/somenode"
] ]
} }
} }
http = { http = {
port = 8080 port = 8080
ssl_cert = "/etc/ssl/certs/mycert.pem" ssl_cert = "/etc/ssl/certs/mycert.pem"
ssl_private_key= "/etc/ssl/private/mykey.pem" ssl_private_key= "/etc/ssl/private/mykey.pem"
} }

View file

@ -2,30 +2,30 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
zeromq_node = { zeromq_node = {
type = "zeromq" type = "zeromq"
pattern = "pubsub" # The ZeroMQ pattern. One of pubsub, radiodish pattern = "pubsub" # The ZeroMQ pattern. One of pubsub, radiodish
ipv6 = false # Enable IPv6 support ipv6 = false # Enable IPv6 support
curve = { # Z85 encoded Curve25519 keys curve = { # Z85 encoded Curve25519 keys
enabled = false, enabled = false,
public_key = "Veg+Q.V-c&1k>yVh663gQ^7fL($y47gybE-nZP1L" public_key = "Veg+Q.V-c&1k>yVh663gQ^7fL($y47gybE-nZP1L"
secret_key = "HPY.+mFuB[jGs@(zZr6$IZ1H1dZ7Ji*j>oi@O?Pc" secret_key = "HPY.+mFuB[jGs@(zZr6$IZ1H1dZ7Ji*j>oi@O?Pc"
} }
in = { in = {
subscribe = "tcp://*:1234" # The subscribe endpoint. subscribe = "tcp://*:1234" # The subscribe endpoint.
# See http://api.zeromq.org/2-1:zmq-bind for details. # See http://api.zeromq.org/2-1:zmq-bind for details.
filter = "ab184" # A filter which is prefix matched for each received msg filter = "ab184" # A filter which is prefix matched for each received msg
} }
out = { out = {
publish = [ # The publish endpoints. publish = [ # The publish endpoints.
"tcp://localhost:1235", # See http://api.zeromq.org/2-1:zmq-connect for details. "tcp://localhost:1235", # See http://api.zeromq.org/2-1:zmq-connect for details.
"tcp://localhost:12444" "tcp://localhost:12444"
] ]
filter = "ab184" # A prefix which is pre-pended to each message. filter = "ab184" # A prefix which is pre-pended to each message.
} }
} }
} }

View file

@ -2,20 +2,20 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
paths = ( paths = (
{ {
enabled = true, # Enable this path (default: true) enabled = true, # Enable this path (default: true)
reverse = true, # Setup a path in the reverse direction as well (default: false) reverse = true, # Setup a path in the reverse direction as well (default: false)
in = "udp_node", # Name of the node we receive messages from (see node dictionary) in = "udp_node", # Name of the node we receive messages from (see node dictionary)
out = "ethernet_node", # Name of the node we send messages to. out = "ethernet_node", # Name of the node we send messages to.
rate = 10.0 # A rate at which this path will be triggered if no input node receives new data rate = 10.0 # A rate at which this path will be triggered if no input node receives new data
queuelen = 128, queuelen = 128,
mode = "all", # When this path should be triggered mode = "all", # When this path should be triggered
# - "all": After all masked input nodes received new data # - "all": After all masked input nodes received new data
# - "any": After any of the masked input nodes received new data # - "any": After any of the masked input nodes received new data
mask = [ "udp_node" ], # A list of input nodes which will trigger the path mask = [ "udp_node" ], # A list of input nodes which will trigger the path
} }
) )

View file

@ -2,33 +2,33 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
nodes = { nodes = {
sine = { sine = {
type = "signal" type = "signal"
signal = "mixed"
values = 5
rate = 25
frequency = 5
}
web = { signal = "mixed"
type = "websocket" values = 5
rate = 25
frequency = 5
}
destinations = [ web = {
"https://villas.k8s.eonerc.rwth-aachen.de//ws/relay/test_data_1" type = "websocket"
]
in = { destinations = [
signals = ( "https://villas.k8s.eonerc.rwth-aachen.de//ws/relay/test_data_1"
{ name = "loopback", unit = "pu", init = 13.37, type = "float" } ]
)
} in = {
} signals = (
{ name = "loopback", unit = "pu", init = 13.37, type = "float" }
)
}
}
} }
paths = ( paths = (
{ {
in = "sine" in = "sine"
out = "web" out = "web"
} }
) )

View file

@ -9,19 +9,19 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
nodes = { nodes = {
node1 = { node1 = {
type = "socket" type = "socket"
format = "gtnet" format = "gtnet"
in = { in = {
address = "*:12000" # Local ip:port, use '*' for random port address = "*:12000" # Local ip:port, use '*' for random port
} }
out = { out = {
address = "134.130.169.80:12001" address = "134.130.169.80:12001"
} }
} }
} }

View file

@ -9,51 +9,51 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
nodes = { nodes = {
node1 = { node1 = {
type = "socket" type = "socket"
format = "villas.binary" format = "villas.binary"
in = { in = {
address = "192.168.88.128:12002" # Local ip:port, use '*' for random port address = "192.168.88.128:12002" # Local ip:port, use '*' for random port
} }
out = { out = {
address = "192.168.88.129:12001" address = "192.168.88.129:12001"
} }
netem = { netem = {
enabled = false enabled = false
delay = 1000000 # In micro seconds! delay = 1000000 # In micro seconds!
jitter = 300000 jitter = 300000
distribution = "normal" distribution = "normal"
} }
} }
node2 = { node2 = {
type = "socket" type = "socket"
format = "villas.binary"
in = { format = "villas.binary"
address = "*:12004" # Local ip:port, use '*' for random port
} in = {
out = { address = "*:12004" # Local ip:port, use '*' for random port
address = "192.168.88.129:12005" }
} out = {
} address = "192.168.88.129:12005"
}
}
} }
paths = ( paths = (
{ {
in = "node1" # Name of the node we listen to (see above) in = "node1" # Name of the node we listen to (see above)
out = "node1" # And we loop back to the origin out = "node1" # And we loop back to the origin
hooks = ( hooks = (
{ {
type = "print" type = "print"
} }
) )
} }
) )

View file

@ -9,51 +9,51 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
nodes = { nodes = {
node1 = { node1 = {
type = "socket" type = "socket"
format = "villas.binary" format = "villas.binary"
in = { in = {
address = "192.168.88.128:12002" # Local ip:port, use '*' for random port address = "192.168.88.128:12002" # Local ip:port, use '*' for random port
} }
out = { out = {
address = "192.168.88.129:12001" address = "192.168.88.129:12001"
} }
netem = { netem = {
enabled = false enabled = false
delay = 1000000 # In micro seconds! delay = 1000000 # In micro seconds!
jitter = 300000 jitter = 300000
distribution = "normal" distribution = "normal"
} }
}, },
node2 = { node2 = {
type = "socket" type = "socket"
format = "villas.binary"
in = { format = "villas.binary"
address = "192.168.88.128:12004" # Local ip:port, use '*' for random port
} in = {
out = { address = "192.168.88.128:12004" # Local ip:port, use '*' for random port
address = "192.168.88.129:12001" }
} out = {
} address = "192.168.88.129:12001"
}
}
} }
paths = ( paths = (
{ {
in = "node1" # Name of the node we listen to (see above) in = "node1" # Name of the node we listen to (see above)
out = "node2" # And we loop back to the origin out = "node2" # And we loop back to the origin
hooks = ( hooks = (
{ {
type = "print" type = "print"
} }
) )
} }
) )

View file

@ -9,52 +9,52 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
nodes = { nodes = {
node1 = { node1 = {
type = "socket" type = "socket"
format = "gtnet" format = "gtnet"
in = { in = {
address = "192.168.88.128:12002" # Local ip:port, use '*' for random port address = "192.168.88.128:12002" # Local ip:port, use '*' for random port
} }
out = { out = {
address = "192.168.88.129:12001" address = "192.168.88.129:12001"
} }
netem = { netem = {
enabled = false enabled = false
delay = 1000000 # In micro seconds! delay = 1000000 # In micro seconds!
jitter = 300000 jitter = 300000
distribution = "normal" distribution = "normal"
} }
}, },
node2 = { node2 = {
type = "socket", type = "socket",
format = "gtnet"
in = { format = "gtnet"
address = "192.168.88.128:12004" # Local ip:port, use '*' for random port
} in = {
out = { address = "192.168.88.128:12004" # Local ip:port, use '*' for random port
address = "192.168.88.129:12001" }
} out = {
} address = "192.168.88.129:12001"
}
}
} }
paths = ( paths = (
{ {
in = "node1" # Name of the node we listen to (see above) in = "node1" # Name of the node we listen to (see above)
out = "node2" # And we loop back to the origin out = "node2" # And we loop back to the origin
hooks = ( hooks = (
{ {
type = "print" type = "print"
} }
) )
} }
) )

View file

@ -9,52 +9,52 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
nodes = { nodes = {
node1 = { node1 = {
type = "socket" type = "socket"
format = "gtnet"
in = { format = "gtnet"
address = "134.130.169.31:12002" # Local ip:port, use '*' for random port
}
out = {
address = "134.130.169.98:12001"
}
netem = { in = {
enabled = false address = "134.130.169.31:12002" # Local ip:port, use '*' for random port
delay = 1000000 # In micro seconds! }
jitter = 300000 out = {
distribution = "normal" address = "134.130.169.98:12001"
} }
},
node2 = {
type = "socket"
format = "gtnet"
in = { netem = {
address = "192.168.88.128:12004" # Local ip:port, use '*' for random port enabled = false
} delay = 1000000 # In micro seconds!
out = { jitter = 300000
address = "192.168.88.129:12001" distribution = "normal"
} }
} },
node2 = {
type = "socket"
format = "gtnet"
in = {
address = "192.168.88.128:12004" # Local ip:port, use '*' for random port
}
out = {
address = "192.168.88.129:12001"
}
}
} }
paths = ( paths = (
{ {
in = "node1", # Name of the node we listen to (see above) in = "node1", # Name of the node we listen to (see above)
out = "node1", # And we loop back to the origin out = "node1", # And we loop back to the origin
hooks = ( hooks = (
{ {
type = "print" type = "print"
} }
) )
} }
) )

View file

@ -9,55 +9,55 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
nodes = { nodes = {
node1 = { node1 = {
type = "socket" type = "socket"
format = {
type = "gtnet"
fake = true
}
in = { format = {
address = "134.130.169.31:12002" # Local ip:port, use '*' for random port type = "gtnet"
} fake = true
out = { }
address = "134.130.169.98:12001"
}
netem = { in = {
enabled = false address = "134.130.169.31:12002" # Local ip:port, use '*' for random port
delay = 1000000 # In micro seconds! }
jitter = 300000 out = {
distribution = "normal" address = "134.130.169.98:12001"
} }
},
node2 = {
type = "socket"
format = "gtnet" netem = {
enabled = false
delay = 1000000 # In micro seconds!
jitter = 300000
distribution = "normal"
}
},
node2 = {
type = "socket"
in = { format = "gtnet"
address = "192.168.88.128:12004" # Local ip:port, use '*' for random port
} in = {
out = { address = "192.168.88.128:12004" # Local ip:port, use '*' for random port
address = "192.168.88.129:12001" }
} out = {
} address = "192.168.88.129:12001"
}
}
} }
paths = ( paths = (
{ {
in = "node1" # Name of the node we listen to (see above) in = "node1" # Name of the node we listen to (see above)
out = "node1" # And we loop back to the origin out = "node1" # And we loop back to the origin
hooks = ( hooks = (
{ {
type = "print" type = "print"
} }
) )
} }
) )

View file

@ -26,64 +26,64 @@
# SPDX-License-Identifier: Apache-2.0 # SPDX-License-Identifier: Apache-2.0
logging = { logging = {
level = "debug" level = "debug"
} }
nodes = { nodes = {
node1 = { node1 = {
type = "socket", type = "socket",
format = { format = {
type = "gtnet" type = "gtnet"
fake = true fake = true
} }
in = {
address = "134.130.169.31:12002" # Local ip:port, use '*' for random port
}
out = {
address = "134.130.169.98:12001"
}
netem = {
enabled = false
delay = 1000000 # In micro seconds!
jitter = 300000
distribution = "normal"
}
},
node2 = {
type = "socket",
format = {
type = "gtnet"
fake = true
}
in = { in = {
address = "134.130.169.31:12004", # Local ip:port, use '*' for random port address = "134.130.169.31:12002" # Local ip:port, use '*' for random port
} }
out = { out = {
address = "134.130.169.99:12003", address = "134.130.169.98:12001"
} }
}
netem = {
enabled = false
delay = 1000000 # In micro seconds!
jitter = 300000
distribution = "normal"
}
},
node2 = {
type = "socket",
format = {
type = "gtnet"
fake = true
}
in = {
address = "134.130.169.31:12004", # Local ip:port, use '*' for random port
}
out = {
address = "134.130.169.99:12003",
}
}
} }
paths = ( paths = (
{ {
in = "node1" # Name of the node we listen to (see above) in = "node1" # Name of the node we listen to (see above)
out = "node1" # And we loop back to the origin out = "node1" # And we loop back to the origin
hooks = ( hooks = (
{ {
type = "print" type = "print"
} }
) )
}, },
{ {
in = "node2", in = "node2",
out = "node2", out = "node2",
hooks = ( hooks = (
{ {
type = "print" type = "print"
} }
) )
} }
) )

View file

@ -4,77 +4,77 @@
hugepages = 200 hugepages = 200
nodes = { nodes = {
# Node names can be any alphanumeric value # Node names can be any alphanumeric value
rpi-1 = { rpi-1 = {
type = "socket" type = "socket"
layer = "udp" layer = "udp"
format = "gtnet" # pre-built format to communicate in RTDS GTNET-SKT payload format = "gtnet" # pre-built format to communicate in RTDS GTNET-SKT payload
in = { in = {
address = "*:12005" # villas node machine IP and port number address = "*:12005" # villas node machine IP and port number
signals = { signals = {
count = 8 count = 8
type = "float" type = "float"
} }
hooks = ( hooks = (
{ {
type = "stats" type = "stats"
warmup = 3000 warmup = 3000
} }
) )
}, },
out = { out = {
address = "192.168.0.5:12005" # remote machine IP and port number address = "192.168.0.5:12005" # remote machine IP and port number
} }
}, },
rpi-2 = { rpi-2 = {
type = "socket" type = "socket"
layer = "udp" layer = "udp"
format = "gtnet" # pre-built format to communicate in RTDS GTNET-SKT payload format = "gtnet" # pre-built format to communicate in RTDS GTNET-SKT payload
in = { in = {
address = "*:12006" # villas node machine IP and port number address = "*:12006" # villas node machine IP and port number
signals = { signals = {
count = 8 count = 8
type = "float" type = "float"
} }
hooks = ( hooks = (
{ {
type = "stats" type = "stats"
warmup = 3000 warmup = 3000
} }
) )
} }
out = { out = {
address = "192.168.0.6:12006" # remote machine IP and port number address = "192.168.0.6:12006" # remote machine IP and port number
} }
}, },
rtds-1 = { rtds-1 = {
type = "socket" type = "socket"
layer = "udp" layer = "udp"
format = "gtnet" format = "gtnet"
in = { in = {
address = "*:12083" # villas node machine IP and port number address = "*:12083" # villas node machine IP and port number
signals = { signals = {
count = 8 count = 8
type = "float" type = "float"
} }
hooks = ( hooks = (
{ {
type = "stats" type = "stats"
warmup = 3000 warmup = 3000
} }
) )
} }
out = { out = {
address = "192.168.0.4:12083" # remote machine IP and port number address = "192.168.0.4:12083" # remote machine IP and port number
} }
} }
} }

View file

@ -4,22 +4,22 @@
@include "lab10_nodes.conf" @include "lab10_nodes.conf"
paths = ( paths = (
# Each path dictionary corresponds to one way communication # Each path dictionary corresponds to one way communication
{ {
in = [ "rpi-1" ], in = [ "rpi-1" ],
out = [ "rtds-1" ] out = [ "rtds-1" ]
}, },
{ {
in = [ "rtds-1" ], in = [ "rtds-1" ],
out = [ "rpi-1" ] out = [ "rpi-1" ]
} }
# Alternatively, you can use a single path specification # Alternatively, you can use a single path specification
# and set reverse = true # and set reverse = true
# Example: # Example:
# { # {
# in = [ "rpi-1" ], # in = [ "rpi-1" ],
# out = [ "rtds-1" ], # out = [ "rtds-1" ],
# reverse = true # reverse = true
# } # }
) )

View file

@ -4,12 +4,12 @@
@include "lab10_nodes.conf" @include "lab10_nodes.conf"
paths = ( paths = (
{ {
in = [ "rpi-1" ], in = [ "rpi-1" ],
out = [ "rtds-1" ], out = [ "rtds-1" ],
hooks = ( hooks = (
{ type = "print", output = "stdout" } { type = "print", output = "stdout" }
) )
} }
) )

View file

@ -4,8 +4,8 @@
@include "lab10_nodes.conf" @include "lab10_nodes.conf"
paths = ( paths = (
{ {
in = [ "rtds-1" ], in = [ "rtds-1" ],
out = [ "rpi-1", "rpi-2" ] out = [ "rpi-1", "rpi-2" ]
} }
) )

Some files were not shown because too many files have changed in this diff Show more