VILLASframework
Modular co-simulation framework
Custom VILLAS Human Readable

This is a simple human-readable format commonly used for logging or debugging: The format is similiar to a conventional CSV (comma seperated values) file. Every line in a file correspondents to a message / sample of simulation data. The columns of a line are seperated by whitespaces (tabs or spaces). The columns are defined as follows:

seconds.nanoseconds+offset(sequenceno)      value0 value1 ... valueN
  1. The first column contains a timestamp which is composed of up to 4 parts:

    • Number of seconds after 1970-01-01 00:00:00 UTC
    • A dot: '.'
    • Number of nano seconds of the current second (optional)
    • An offset between the point in time when a message was sent and received (optional)
    • The sequence number of the message (optional)

    A valid timestamp can be generated by the following Unix command: date +s.N. Important: The second field is not the fractional part of the second!!!

  2. Maximum MSG_VALUES floating point values per sample. The values are seperated by whitespaces as well.

Implementation

The source code of the format-type is available here: https://git.rwth-aachen.de/acs/public/villas/node/-/blob/master/lib/formats/villas_human.cpp

Configuration

The Custom VILLAS Human Readable format-type supports the options documented on the following pages:

Example Configuration

nodes = {
node = {
type = "file"
uri = "/dev/null"
format = {
type = "villas.human"
comment_prefix = "#"
header = false
}
}
}

Example Payload

This example shows a dump with three values per sample:

# seconds.nanoseconds(sequence) signal0 signal1 signal2
1438959964.162102394(6) 3.489760 -1.882725 0.860070