Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 21 additions & 21 deletions docs/node/clients/opal_async_ip.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,33 +15,33 @@ You can start right away using this example project provided by OPAL-RT when thi

``` url="external/node/etc/examples/formats/opal-asyncip.conf" title="node/etc/examples/formats/opal-asyncip.conf"
nodes = {
node = {
type = "socket"
layer = "udp"
node = {
type = "socket"
layer = "udp"

format = {
type = "opal.asyncip"
format = {
type = "opal.asyncip"

dev_id = 99
}
dev_id = 99
}

in = {
# Port number specified in Asynchronous Process block of RTlab project
address = ":12000"
in = {
# Port number specified in Asynchronous Process block of RTlab project
address = ":12000"

signals = {
count = 64
signals = {
count = 64

# The Asynchronous Process block only supports floating point values!
type = "float"
}
}
# The Asynchronous Process block only supports floating point values!
type = "float"
}
}

out = {
# IP address and port of OPAL-RT Target
address = "192.168.0.44:12000"
}
}
out = {
# IP address and port of OPAL-RT Target
address = "192.168.0.44:12000"
}
}
}
```

Expand Down
2 changes: 1 addition & 1 deletion docs/node/clients/typhoon.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ nodes = {
paths = (
{
# A simple loopback
in = "typhoon_1",
in = "typhoon_1"
out = "typhoon_1"
}
)
Expand Down
26 changes: 13 additions & 13 deletions docs/node/formats/csv.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,19 +23,19 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/csv.conf" title="node/etc/examples/formats/csv.conf"
nodes = {
node = {
type = "file"
uri = "/dev/null"

format = {
type = "csv"

separator = ","
delimiter = "\n"
skip_first_line = false
header = true
}
}
node = {
type = "file"
uri = "/dev/null"

format = {
type = "csv"

separator = ","
delimiter = "\n"
skip_first_line = false
header = true
}
}
}
```

Expand Down
10 changes: 5 additions & 5 deletions docs/node/formats/iotagent_ul.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/iotagent_ul.conf" title="node/etc/examples/formats/iotagent_ul.conf"
nodes = {
node = {
type = "file"
uri = "/dev/null"
node = {
type = "file"
uri = "/dev/null"

format = "iotagent_ul"
}
format = "iotagent_ul"
}
}
```

Expand Down
24 changes: 12 additions & 12 deletions docs/node/formats/json.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,20 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/json.conf" title="node/etc/examples/formats/json.conf"
nodes = {
node = {
type = "file"
uri = "/dev/null"
node = {
type = "file"
uri = "/dev/null"

format = {
type = "json"
format = {
type = "json"

indent = 4
compact = true
ensure_ascii = true
escape_slash = false
sort_keys = true
}
}
indent = 4
compact = true
ensure_ascii = true
escape_slash = false
sort_keys = true
}
}
}
```

Expand Down
24 changes: 12 additions & 12 deletions docs/node/formats/json_kafka.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,20 +21,20 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/json-kafka.conf" title="node/etc/examples/formats/json-kafka.conf"
nodes = {
node = {
type = "file"
uri = "/dev/null"
node = {
type = "file"
uri = "/dev/null"

format = {
type = "json.kafka"
format = {
type = "json.kafka"

indent = 2
schema = {
type = "struct"
name = "villas-node.Value"
}
}
}
indent = 2
schema = {
type = "struct"
name = "villas-node.Value"
}
}
}
}
```

Expand Down
42 changes: 21 additions & 21 deletions docs/node/formats/opal_asyncip.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,32 +48,32 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/opal-asyncip.conf" title="node/etc/examples/formats/opal-asyncip.conf"
nodes = {
node = {
type = "socket"
layer = "udp"
node = {
type = "socket"
layer = "udp"

format = {
type = "opal.asyncip"
format = {
type = "opal.asyncip"

dev_id = 99
}
dev_id = 99
}

in = {
# Port number specified in Asynchronous Process block of RTlab project
address = ":12000"
in = {
# Port number specified in Asynchronous Process block of RTlab project
address = ":12000"

signals = {
count = 64
signals = {
count = 64

# The Asynchronous Process block only supports floating point values!
type = "float"
}
}
# The Asynchronous Process block only supports floating point values!
type = "float"
}
}

out = {
# IP address and port of OPAL-RT Target
address = "192.168.0.44:12000"
}
}
out = {
# IP address and port of OPAL-RT Target
address = "192.168.0.44:12000"
}
}
}
```
67 changes: 34 additions & 33 deletions docs/node/formats/protobuf.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,52 +13,53 @@ The `.proto` Protocol Buffers Version Language Specification of the payload used
https://github.com/VILLASframework/node/blob/master/lib/formats/villas.proto

```protobuf url="external/node/lib/formats/villas.proto" title="node/lib/formats/villas.proto"
/// Protobuf schema based on msg_format.h
///
/// @file
/// @author Steffen Vogel <post@steffenvogel.de>
/// @copyright 2014-2022, Institute for Automation of Complex Power Systems, EONERC
/// @license Apache 2.0
////////////////////////////////////////////////////////////////////////////////////
// Protobuf schema based on msg_format.h
//
// @file
// Author: Steffen Vogel <post@steffenvogel.de>
// SPDX-FileCopyrightText: 2014-2023 Institute for Automation of Complex Power Systems, RWTH Aachen University
// SPDX-License-Identifier: Apache-2.0

syntax = "proto2";

package villas.node;

message Message {
repeated Sample samples = 1;
repeated Sample samples = 1;
}

message Sample {
enum Type {
DATA = 1; // Message contains float / integer data values
START = 2; // Message marks the beginning of a new simulation case
STOP = 3; // Message marks the end of a simulation case
};

required Type type = 1 [default = DATA];
optional uint64 sequence = 2; // The sequence number is incremented by one for consecutive messages.
optional Timestamp timestamp = 4;
repeated Value values = 5;
enum Type {
DATA = 1; // Message contains float / integer data values
START = 2; // Message marks the beginning of a new simulation case
STOP = 3; // Message marks the end of a simulation case
};

required Type type = 1 [default = DATA];
optional uint64 sequence = 2; // The sequence number is incremented for consecutive samples.
optional Timestamp ts_origin = 3;
optional Timestamp ts_received = 4;
optional bool new_frame = 5;
repeated Value values = 100;
}

message Timestamp {
required uint32 sec = 1; // Seconds since 1970-01-01 00:00:00
required uint32 nsec = 2; // Nanoseconds of the current second.
required uint32 sec = 1; // Seconds since 1970-01-01 00:00:00
required uint32 nsec = 2; // Nanoseconds of the current second.
}

message Value {
oneof value {
double f = 1; // Floating point values.
int64 i = 2; // Integer values.
bool b = 3; // Boolean values.
Complex z = 4; // Complex values.
}
oneof value {
double f = 1; // Floating point values.
int64 i = 2; // Integer values.
bool b = 3; // Boolean values.
Complex z = 4; // Complex values.
}
}

message Complex {
required float real = 1; // Real component
required float imag = 2; // Imaginary component
required float real = 1; // Real component
required float imag = 2; // Imaginary component
}
```

Expand All @@ -77,11 +78,11 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/protobuf.conf" title="node/etc/examples/formats/protobuf.conf"
nodes = {
node = {
type = "file"
uri = "/dev/null"
node = {
type = "file"
uri = "/dev/null"

format = "protobuf"
}
format = "protobuf"
}
}
```
24 changes: 12 additions & 12 deletions docs/node/formats/raw.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,18 +23,18 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/raw.conf" title="node/etc/examples/formats/raw.conf"
nodes = {
node = {
type = "file"
uri = "/dev/null"

format = {
type = "raw"

bits = 32
endianess = "little"
fake = false
}
}
node = {
type = "file"
uri = "/dev/null"

format = {
type = "raw"

bits = 32
endianess = "little"
fake = false
}
}
}
```

Expand Down
26 changes: 13 additions & 13 deletions docs/node/formats/tsv.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,19 @@ import ApiSchema from '@theme/ApiSchema';

``` url="external/node/etc/examples/formats/tsv.conf" title="node/etc/examples/formats/tsv.conf"
nodes = {
node = {
type = "file"
uri = "/dev/null"

format = {
type = "tsv"

separator = "\t"
delimiter = "\n"
skip_first_line = false
header = true
}
}
node = {
type = "file"
uri = "/dev/null"

format = {
type = "tsv"

separator = "\t"
delimiter = "\n"
skip_first_line = false
header = true
}
}
}
```

Expand Down
Loading