mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
Merge branch 'develop' into feature-tests
This commit is contained in:
commit
292d2ecd87
15 changed files with 475 additions and 7 deletions
4
Doxyfile
4
Doxyfile
|
@ -1003,7 +1003,7 @@ VERBATIM_HEADERS = YES
|
|||
# compiled with the --with-libclang option.
|
||||
# The default value is: NO.
|
||||
|
||||
CLANG_ASSISTED_PARSING = NO
|
||||
#CLANG_ASSISTED_PARSING = NO
|
||||
|
||||
# If clang assisted parsing is enabled you can provide the compiler with command
|
||||
# line options that you would normally use when invoking the compiler. Note that
|
||||
|
@ -1011,7 +1011,7 @@ CLANG_ASSISTED_PARSING = NO
|
|||
# specified with INPUT and INCLUDE_PATH.
|
||||
# This tag requires that the tag CLANG_ASSISTED_PARSING is set to YES.
|
||||
|
||||
CLANG_OPTIONS =
|
||||
#CLANG_OPTIONS =
|
||||
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration options related to the alphabetical class index
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
# VILLASnode
|
||||
<a href="https://git.rwth-aachen.de/acs/VILLASnode/commits/develop"><img align=right alt="build status" src="https://git.rwth-aachen.de/acs/VILLASnode/badges/develop/build.svg"></img></a>
|
||||
# VILLASnode [](https://git.rwth-aachen.de/acs/VILLASnode/commits/develop) [](https://git.rwth-aachen.de/acs/VILLASnode/commits/develop)
|
||||
|
||||
|
||||
This is VILLASnode, a gateway for processing and forwardning simulation data between real-time simulators.
|
||||
|
||||
|
||||
## Documentation
|
||||
|
||||
The documentation for this software is available at [doc/Mainpage](doc/Mainpage.md).
|
||||
|
|
1
doc/Contributing.md
Symbolic link
1
doc/Contributing.md
Symbolic link
|
@ -0,0 +1 @@
|
|||
../CONTRIBUTING.md
|
1
doc/License.md
Symbolic link
1
doc/License.md
Symbolic link
|
@ -0,0 +1 @@
|
|||
../COPYING.md
|
1
doc/Readme.md
Symbolic link
1
doc/Readme.md
Symbolic link
|
@ -0,0 +1 @@
|
|||
../README.md
|
BIN
doc/pictures/villas_fpga.png
Normal file
BIN
doc/pictures/villas_fpga.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
108
doc/pictures/villas_fpga.svg
Normal file
108
doc/pictures/villas_fpga.svg
Normal file
|
@ -0,0 +1,108 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="59.79784mm"
|
||||
height="60.203037mm"
|
||||
viewBox="0 0 59.79784 60.203037"
|
||||
version="1.1"
|
||||
id="svg8"
|
||||
inkscape:version="0.91+devel r14647 custom"
|
||||
sodipodi:docname="villas_fpga.svg">
|
||||
<defs
|
||||
id="defs2" />
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="2.8258888"
|
||||
inkscape:cx="113.00379"
|
||||
inkscape:cy="113.76952"
|
||||
inkscape:document-units="mm"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
inkscape:snap-global="true"
|
||||
inkscape:window-width="1440"
|
||||
inkscape:window-height="851"
|
||||
inkscape:window-x="0"
|
||||
inkscape:window-y="23"
|
||||
inkscape:window-maximized="1"
|
||||
fit-margin-top="0"
|
||||
fit-margin-left="0"
|
||||
fit-margin-right="0"
|
||||
fit-margin-bottom="0" />
|
||||
<metadata
|
||||
id="metadata5">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="Ebene 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-47.935598,-61.580869)">
|
||||
<g
|
||||
id="g4284"
|
||||
transform="rotate(30,76.994499,93.147032)"
|
||||
style="fill:#f65d5d;fill-opacity:1">
|
||||
<path
|
||||
id="path4275"
|
||||
d="m 61.850486,65.440967 -5.16e-4,0.001 0.0016,-0.001 z"
|
||||
style="opacity:1;fill:#f65d5d;fill-opacity:1;stroke:none;stroke-width:13.98425198;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path4273"
|
||||
d="m 63.735126,65.440967 5.819283,10.078971 h 15.164967 l 5.819283,-10.078971 z"
|
||||
style="opacity:1;fill:#f65d5d;fill-opacity:1;stroke:none;stroke-width:13.98425198;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path4271"
|
||||
d="m 60.908427,67.072909 -13.401768,23.21202 h 11.63805 l 7.583,-13.133049 z"
|
||||
style="opacity:1;fill:#f65d5d;fill-opacity:1;stroke:none;stroke-width:13.98425198;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path4267"
|
||||
d="m 46.5646,91.916352 -5.19e-4,10e-4 5.19e-4,0.001 z"
|
||||
style="opacity:1;fill:#f65d5d;fill-opacity:1;stroke:none;stroke-width:13.98425198;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path4265"
|
||||
d="M 47.507178,93.550876 60.908427,116.7629 66.727709,106.68393 59.145227,93.550876 Z"
|
||||
style="opacity:1;fill:#f65d5d;fill-opacity:1;stroke:none;stroke-width:13.98425198;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path4263"
|
||||
d="m 95.12856,93.550876 -7.581966,13.132014 5.819283,10.07846 13.400213,-23.210474 z"
|
||||
style="opacity:1;fill:#f65d5d;fill-opacity:1;stroke:none;stroke-width:13.98425198;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0" />
|
||||
<path
|
||||
id="path4214"
|
||||
d="m 69.554928,108.31535 -5.819802,10.07897 H 90.538659 L 84.71886,108.31535 Z"
|
||||
style="opacity:1;fill:#f65d5d;fill-opacity:1;stroke:none;stroke-width:13.98425198;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
inkscape:connector-curvature="0" />
|
||||
</g>
|
||||
<circle
|
||||
style="opacity:1;fill:none;fill-opacity:1;stroke:none;stroke-width:0.09076402;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
|
||||
id="path4286"
|
||||
cx="77.834518"
|
||||
cy="91.776962"
|
||||
r="29.89892" />
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 4.8 KiB |
BIN
doc/pictures/villas_node.png
Normal file
BIN
doc/pictures/villas_node.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.3 KiB |
107
doc/pictures/villas_node.svg
Normal file
107
doc/pictures/villas_node.svg
Normal file
|
@ -0,0 +1,107 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="149.71165mm"
|
||||
height="149.71165mm"
|
||||
viewBox="0 0 149.71165 149.71165"
|
||||
version="1.1"
|
||||
id="svg8"
|
||||
inkscape:version="0.91+devel r14647 custom"
|
||||
sodipodi:docname="villas_node.svg">
|
||||
<defs
|
||||
id="defs2" />
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="1.0941748"
|
||||
inkscape:cx="282.57339"
|
||||
inkscape:cy="285.10587"
|
||||
inkscape:document-units="mm"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
inkscape:snap-smooth-nodes="true"
|
||||
inkscape:snap-bbox="true"
|
||||
inkscape:snap-bbox-edge-midpoints="true"
|
||||
inkscape:bbox-nodes="true"
|
||||
inkscape:object-paths="true"
|
||||
inkscape:snap-intersection-paths="false"
|
||||
inkscape:bbox-paths="false"
|
||||
inkscape:snap-midpoints="true"
|
||||
inkscape:window-width="1440"
|
||||
inkscape:window-height="851"
|
||||
inkscape:window-x="0"
|
||||
inkscape:window-y="23"
|
||||
inkscape:window-maximized="1"
|
||||
fit-margin-top="0"
|
||||
fit-margin-left="0"
|
||||
fit-margin-right="0"
|
||||
fit-margin-bottom="0"
|
||||
inkscape:measure-start="37.9039,424.38"
|
||||
inkscape:measure-end="101.386,461.031"
|
||||
inkscape:snap-global="true" />
|
||||
<metadata
|
||||
id="metadata5">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title />
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="Ebene 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(9.2667999,-9.6854979)">
|
||||
<g
|
||||
id="g5005"
|
||||
transform="matrix(0.9623191,0,0,0.9623191,2.7484651,3.9385684)">
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
id="path4216"
|
||||
d="m 63.587891,9.6855469 c 6.06e-4,7.0683591 0.0015,14.1367191 0.002,21.2050781 15.819673,9.135873 31.640734,18.269342 47.460939,27.404297 0,17.498047 0,34.996094 0,52.494138 -5.49672,3.17323 -10.99381,6.34579 -16.490236,9.51953 6.513716,4.46314 13.027976,8.92546 19.542976,13.38672 6.10534,-3.52205 12.20877,-7.04742 18.3125,-10.57226 0,-25.720706 0,-51.441409 0,-77.162112 C 109.47401,32.712977 86.530215,19.468112 63.587891,6.2207031 c 0,1.1549479 0,2.3098959 0,3.4648438 z M -1.2382812,47.113281 c 0,25.33724 -10e-8,50.674479 0,76.011719 22.2754942,12.86097 44.5512202,25.72155 66.8281252,38.58008 5.8117,-3.35395 11.623148,-6.70834 17.433594,-10.06446 0.02546,-8.23762 0.05066,-16.47525 0.07422,-24.71289 -5.83576,3.37058 -11.673247,6.73816 -17.509765,10.10743 -15.153646,-8.74805 -30.307292,-17.4961 -45.460938,-26.24414 0,-18.268885 0,-36.537765 0,-54.806645 -7.120999,-4.11327 -14.2439643,-8.223136 -21.3652342,-12.335937 -1e-7,1.154947 0,2.309895 0,3.464843 z"
|
||||
style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:#0073d9;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:17.36499977;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" />
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
id="path4234"
|
||||
d="M 60.834646,7.8107504 C 55.411432,10.941911 49.987942,14.072591 44.564895,17.20404 44.98294,28.217745 45.394994,39.23168 45.81076,50.245473 36.442386,44.40125 27.07547,38.554688 17.706182,32.71193 11.331473,36.391852 4.9568349,40.071899 -1.4174075,43.75263 20.251318,56.263922 41.921166,68.773267 63.589891,81.284557 63.589484,56.263273 63.588514,31.241988 63.588055,6.2207031 62.670238,6.7507189 61.75242,7.2807346 60.834603,7.8107504 Z"
|
||||
style="fill:#37a1ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.51856697;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
id="path4255"
|
||||
d="m 74.302734,102.83398 c 0,17.94141 0,35.88282 0,53.82422 5.235031,-3.04473 10.47151,-6.08697 15.707032,-9.13086 -0.08797,-7.21942 -0.180028,-14.43879 -0.269532,-21.6582 6.014579,3.79842 12.027266,7.59984 18.042966,11.39648 5.37572,-3.08613 10.75339,-6.16886 16.13086,-9.25195 -16.53658,-9.54909 -33.074584,-19.09572 -49.611326,-28.644529 0,1.154949 0,2.309899 0,3.464839 z"
|
||||
style="fill:#37a1ff;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.38000983;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" />
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
id="path4329"
|
||||
d="M 65.519531,7.6875 C 30.952342,7.2288821 -1.7559504,32.928216 -9.0985572,66.77029 c -8.9441948,34.36253 9.91032274,73.19316 42.4331002,87.43912 31.90533,15.5955 73.697367,4.8306 94.125297,-24.21303 C 149.0773,101.82081 146.84579,58.724642 122.42805,32.933531 108.17012,16.922072 86.915542,7.695183 65.519531,7.6875 Z"
|
||||
style="opacity:1;fill:none;fill-opacity:1;stroke:none;stroke-width:3.70000005;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" />
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
id="path4978"
|
||||
d="m 20.126956,55.984374 -21.3652354,-12.335936 -1.8e-6,12.603665 21.3652372,7.683492 z"
|
||||
style="fill:#005aa9;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.26458332px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
sodipodi:nodetypes="ccccc"
|
||||
style="fill:#005aa9;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.26458332px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
|
||||
d="m 67.039539,136.19721 7.263195,-4.14394 v 24.60493 l -2.312864,1.35308 z"
|
||||
id="path4980"
|
||||
inkscape:connector-curvature="0" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 7.1 KiB |
62
etc/gtnet_test1.conf
Normal file
62
etc/gtnet_test1.conf
Normal file
|
@ -0,0 +1,62 @@
|
|||
# This is an example for a minimal loopback configuration.
|
||||
#
|
||||
# All messages will be sent back to the origin using UDP packets.
|
||||
#
|
||||
# You can use this configuration in conjunction with the 'send', 'receive' and 'random'
|
||||
# utilities as shown below (run all three steps in parallel).
|
||||
#
|
||||
# 0. Overview:
|
||||
#
|
||||
# ./signal --PIPE--> ./pipe --UDP--> ./node --UDP--> ./pipe
|
||||
#
|
||||
# 1. Start server:
|
||||
#
|
||||
# $ ./node etc/loopback.conf
|
||||
#
|
||||
# 2. Send random data to server:
|
||||
#
|
||||
# $ ./signal random -r 10 -v 4 | ./pipe etc/loopback.conf node1
|
||||
#
|
||||
# 3. Receive data from server:
|
||||
#
|
||||
# $ ./pipe etc/loopback.conf node2
|
||||
#
|
||||
# Author: Steffen Vogel <stvogel@eonerc.rwth-aachen.de>
|
||||
# Copyright: 2016, Institute for Automation of Complex Power Systems, EONERC
|
||||
##
|
||||
|
||||
stats = 1;
|
||||
debug = 10;
|
||||
|
||||
nodes = {
|
||||
node1 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "192.168.88.128:12002", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12001",
|
||||
header = "villas", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1, # Number of samples to fetch per iteration from the socket
|
||||
netem = {
|
||||
enabled = false,
|
||||
delay = 1000000, # In micro seconds!
|
||||
jitter = 300000,
|
||||
distribution = "normal"
|
||||
}
|
||||
},
|
||||
node2 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "*:12004", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12005",
|
||||
header = "villas", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1 # Number of samples to fetch per iteration from the socket
|
||||
}
|
||||
};
|
||||
|
||||
paths = (
|
||||
{
|
||||
in = "node1", # Name of the node we listen to (see above)
|
||||
out = "node1", # And we loop back to the origin
|
||||
hook = ["print"]
|
||||
}
|
||||
);
|
62
etc/gtnet_test2.conf
Normal file
62
etc/gtnet_test2.conf
Normal file
|
@ -0,0 +1,62 @@
|
|||
# This is an example for a minimal loopback configuration.
|
||||
#
|
||||
# All messages will be sent back to the origin using UDP packets.
|
||||
#
|
||||
# You can use this configuration in conjunction with the 'send', 'receive' and 'random'
|
||||
# utilities as shown below (run all three steps in parallel).
|
||||
#
|
||||
# 0. Overview:
|
||||
#
|
||||
# ./signal --PIPE--> ./pipe --UDP--> ./node --UDP--> ./pipe
|
||||
#
|
||||
# 1. Start server:
|
||||
#
|
||||
# $ ./node etc/loopback.conf
|
||||
#
|
||||
# 2. Send random data to server:
|
||||
#
|
||||
# $ ./signal random -r 10 -v 4 | ./pipe etc/loopback.conf node1
|
||||
#
|
||||
# 3. Receive data from server:
|
||||
#
|
||||
# $ ./pipe etc/loopback.conf node2
|
||||
#
|
||||
# Author: Steffen Vogel <stvogel@eonerc.rwth-aachen.de>
|
||||
# Copyright: 2016, Institute for Automation of Complex Power Systems, EONERC
|
||||
##
|
||||
|
||||
stats = 1;
|
||||
debug = 10;
|
||||
|
||||
nodes = {
|
||||
node1 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "192.168.88.128:12002", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12001",
|
||||
header = "villas", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1, # Number of samples to fetch per iteration from the socket
|
||||
netem = {
|
||||
enabled = false,
|
||||
delay = 1000000, # In micro seconds!
|
||||
jitter = 300000,
|
||||
distribution = "normal"
|
||||
}
|
||||
},
|
||||
node2 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "192.168.88.128:12004", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12001",
|
||||
header = "villas", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1 # Number of samples to fetch per iteration from the socket
|
||||
}
|
||||
};
|
||||
|
||||
paths = (
|
||||
{
|
||||
in = "node1", # Name of the node we listen to (see above)
|
||||
out = "node2", # And we loop back to the origin
|
||||
hook = ["print"]
|
||||
}
|
||||
);
|
62
etc/gtnet_test3.conf
Normal file
62
etc/gtnet_test3.conf
Normal file
|
@ -0,0 +1,62 @@
|
|||
# This is an example for a minimal loopback configuration.
|
||||
#
|
||||
# All messages will be sent back to the origin using UDP packets.
|
||||
#
|
||||
# You can use this configuration in conjunction with the 'send', 'receive' and 'random'
|
||||
# utilities as shown below (run all three steps in parallel).
|
||||
#
|
||||
# 0. Overview:
|
||||
#
|
||||
# ./signal --PIPE--> ./pipe --UDP--> ./node --UDP--> ./pipe
|
||||
#
|
||||
# 1. Start server:
|
||||
#
|
||||
# $ ./node etc/loopback.conf
|
||||
#
|
||||
# 2. Send random data to server:
|
||||
#
|
||||
# $ ./signal random -r 10 -v 4 | ./pipe etc/loopback.conf node1
|
||||
#
|
||||
# 3. Receive data from server:
|
||||
#
|
||||
# $ ./pipe etc/loopback.conf node2
|
||||
#
|
||||
# Author: Steffen Vogel <stvogel@eonerc.rwth-aachen.de>
|
||||
# Copyright: 2016, Institute for Automation of Complex Power Systems, EONERC
|
||||
##
|
||||
|
||||
stats = 1;
|
||||
debug = 10;
|
||||
|
||||
nodes = {
|
||||
node1 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "192.168.88.128:12002", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12001",
|
||||
header = "gtnet-skt", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1, # Number of samples to fetch per iteration from the socket
|
||||
netem = {
|
||||
enabled = false,
|
||||
delay = 1000000, # In micro seconds!
|
||||
jitter = 300000,
|
||||
distribution = "normal"
|
||||
}
|
||||
},
|
||||
node2 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "192.168.88.128:12004", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12001",
|
||||
header = "gtnet-skt", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1 # Number of samples to fetch per iteration from the socket
|
||||
}
|
||||
};
|
||||
|
||||
paths = (
|
||||
{
|
||||
in = "node1", # Name of the node we listen to (see above)
|
||||
out = "node2", # And we loop back to the origin
|
||||
hook = ["print"]
|
||||
}
|
||||
);
|
62
etc/gtnet_test4.conf
Normal file
62
etc/gtnet_test4.conf
Normal file
|
@ -0,0 +1,62 @@
|
|||
# This is an example for a minimal loopback configuration.
|
||||
#
|
||||
# All messages will be sent back to the origin using UDP packets.
|
||||
#
|
||||
# You can use this configuration in conjunction with the 'send', 'receive' and 'random'
|
||||
# utilities as shown below (run all three steps in parallel).
|
||||
#
|
||||
# 0. Overview:
|
||||
#
|
||||
# ./signal --PIPE--> ./pipe --UDP--> ./node --UDP--> ./pipe
|
||||
#
|
||||
# 1. Start server:
|
||||
#
|
||||
# $ ./node etc/loopback.conf
|
||||
#
|
||||
# 2. Send random data to server:
|
||||
#
|
||||
# $ ./signal random -r 10 -v 4 | ./pipe etc/loopback.conf node1
|
||||
#
|
||||
# 3. Receive data from server:
|
||||
#
|
||||
# $ ./pipe etc/loopback.conf node2
|
||||
#
|
||||
# Author: Steffen Vogel <stvogel@eonerc.rwth-aachen.de>
|
||||
# Copyright: 2016, Institute for Automation of Complex Power Systems, EONERC
|
||||
##
|
||||
|
||||
stats = 1;
|
||||
debug = 10;
|
||||
|
||||
nodes = {
|
||||
node1 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "192.168.88.128:12002", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12001",
|
||||
header = "gtnet-skt", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1, # Number of samples to fetch per iteration from the socket
|
||||
netem = {
|
||||
enabled = false,
|
||||
delay = 1000000, # In micro seconds!
|
||||
jitter = 300000,
|
||||
distribution = "normal"
|
||||
}
|
||||
},
|
||||
node2 = {
|
||||
type = "socket",
|
||||
layer = "udp",
|
||||
local = "192.168.88.128:12004", # Local ip:port, use '*' for random port
|
||||
remote = "192.168.88.129:12001",
|
||||
header = "gtnet-skt", # 'gtnet-skt' or 'villas'. If not provided, 'villas' header will be used
|
||||
vectorize = 1 # Number of samples to fetch per iteration from the socket
|
||||
}
|
||||
};
|
||||
|
||||
paths = (
|
||||
{
|
||||
in = "node1", # Name of the node we listen to (see above)
|
||||
out = "node1", # And we loop back to the origin
|
||||
hook = ["print"]
|
||||
}
|
||||
);
|
|
@ -184,6 +184,7 @@ int kernel_irq_setaffinity(unsigned irq, uintmax_t new, uintmax_t *old)
|
|||
{
|
||||
char fn[64];
|
||||
FILE *f;
|
||||
int ret = 0;
|
||||
|
||||
snprintf(fn, sizeof(fn), "/proc/irq/%u/smp_affinity", irq);
|
||||
|
||||
|
@ -192,10 +193,10 @@ int kernel_irq_setaffinity(unsigned irq, uintmax_t new, uintmax_t *old)
|
|||
return -1; /* IRQ does not exist */
|
||||
|
||||
if (old)
|
||||
fscanf(f, "%jx", old);
|
||||
ret = fscanf(f, "%jx", old);
|
||||
|
||||
fprintf(f, "%jx", new);
|
||||
fclose(f);
|
||||
|
||||
return 0;
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -88,7 +88,7 @@ static void * path_run(void *arg)
|
|||
/* Main thread loop */
|
||||
for (;;) {
|
||||
/* Fill smps[] free sample blocks from the pool */
|
||||
ready += pool_get_many(&p->pool, (void **) smps, cnt - ready);
|
||||
ready += sample_get_many(&p->pool, smps, cnt - ready);
|
||||
if (ready != cnt)
|
||||
warn("Pool underrun for path %s", path_name(p));
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue