Skip to content

Commit

Permalink
Update the README file to reflect the change in fedsd usage
Browse files Browse the repository at this point in the history
  • Loading branch information
ChadliaJerad committed Aug 22, 2023
1 parent 2f5c3dd commit fca3a90
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions util/tracing/visualization/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
# Trace sequence diagram visualizer

`fedsd` is a utility that reports the interactions (exchanged messages)
between federates and the RTI in a sequence-diagram-like format.
between federates and the RTI in a sequence-diagram-like format.
It also reports the interactions between different encalves in an enclaved execution, where no RTI trace file is provided.


To use `fedsd`, you need to first obtain an execution trace. To do this, enable the tracing mechanism in your Lingua Franca program by setting the `tracing` target property to `true` and then compile and run the program.

Expand All @@ -10,7 +12,7 @@ internally running `trace_to_csv`. It then aggregates the data from all `.csv`
files to do the matching and draw the sequence diagram.

# Installing
`fedsd` is installed together with the rest of the tracing tools. For instructions refer to `~/util/tracing/README.md`.
`fedsd` is installed together with the rest of the tracing tools. For instructions refer to `util/tracing/README.md`.


# Running
Expand All @@ -20,20 +22,20 @@ file will be generated for each of the federates, in addition to `rti.lft`. The
contains the RTI trace.

If, however, the federation is launched manually, then running the `RTI` command should be passed the `-t` flag in order to make sure that it, too, has tracing enabled:
```
$ RTI -n <number_of_federates> -t
```bash
RTI -n <number_of_federates> -t
```

It is most convenient to launch the RTI and all federates from the same working directory so that they will all write their trace file to that directory.

Once the federation stopped executing, run `fedsd` on all generated `.lft` files:
```
$ fedsd *.lft
```
In case `trace_to_csv` executable is in a different location, other than `/usr/local/bin/`, then use the `INSTALL_PREFIX` flag, as follows:
Once the federation stopped executing, running `fedsd` will operate on all the `.lft` files in the current directory:
```bash
fedsd
```
fedsd INSTALL_PREFIX=~/.local/bin/ *.lft
It is also possible to operate on specific files. In such a case, run `fedsd` with `-r` flag to provide the RTI trace file, and `-f` flag to privide the list of federates
trace files. Bith argumenets are optional.
```bash
fedsd -r <rti.lft> -f <federate__f1.lft> <federate--f2.lft>
```

The output is an html file named `trace_svg.html` (in the current directory) that contains the sequence of interactions
between the federates and the RTI.
The output is an html file named `trace_svg.html` (in the current directory) that contains the sequence of interactions between the federates and the RTI.

0 comments on commit fca3a90

Please sign in to comment.