Next: , Previous: , Up: The Dezyne command-line tools   [Contents][Index]

9.9 Invoking dzn trace

The dzn trace command is a pseudo-filter to convert between different trace formats:

event trace (trail)

An event trace or trail is a list of event names observable by interacting with a Dezyne model, for example, for doc/examples/hello-world.dzn:

event trace (character separated)

Some tools, such as the simulator also read an event trace separated by a comma or a space:

"p.hello p.return"
code trace (arrow trace)

The Dezyne executable code can produce a trace showing the sender and the receiver of an event on the same line:

<external>.p.hello -> sut.p.hello
<external> <-
<external>.p.return <- sut.p.return
simulator trace (split-arrow trace)

The simulator produces a trace showing the sender and the receiver of an event both on their own line:

<external>.p.hello -> ...
... -> sut.p.hello
... <-
<external> <- ...
... <- sut.p.return
<external>.p.return <- ...

which is especially useful when the lines are prefixed with location information.

The dzn trace command reads arrow traces and converts them to a code trace (the default) or an event trace. A split-arrow trace can also be converted to an ASCII sequence diagram. Its syntax is:

dzn dzn-option… trace option… [FILE]

The options can be among the following:

-f format

Display trace in format format, one of diagram, event, json, or sexp. The default is code.

Note: The json can be processed by Dezyne-P5 to draw a trace diagram in a browser.


Display help on invoking dzn trace, and then exit.


Show communication between components in the system. When using the option --format=diagram on a system trace, the communication between components in the system is hidden by default.


Show locations in output.


When using format=event also show meta-events, such as <defer> and <illegal>.

-t trace

Use trace trace. The default is to read from standard input.

Next: Invoking dzn traces, Previous: Invoking dzn simulate, Up: The Dezyne command-line tools   [Contents][Index]