USING DRAWTIMING



ABOUT SAMPLES DOWNLOAD INSTALL USAGE

USAGE

To generate a timing diagram, write a signal description file named, for example infile.txt, and run the application as shown:

drawtiming --output outfile.gif  infile.txt

The following options are accepted:

-o filename
--output filename
Required to produce an output image. The output format is determined from the filename. For more details on this, consult the ImageMagick documentation and the ImageMagick(1) man page. ImageMagick does additional processing on this parameter, so you should review possible security implications if you are running drawtiming from a CGI script for instance.
In addition to the formats supported by ImageMagick, postscript output can be generated using extensions of ps or eps
-x float
 --scale float
Scales the canvas size on which to render.
-p widthxheight
--pagesize widthxheight
Specify the canvas size in pixels to render on.
-a
--aspect
Force 1:1 aspect ratio when drawing on fixed size canvas. See the --pagesize option.
-v
--verbose
Increases the quantity of diagnostic output.
-c
--cell-height
Set the height of the signal in pixels.
-w
--cell-width
Set the width of the time period in pixels.
-f
--font-size
Set the font size in points.
-l
--line-width
Set the line width in pixels.

INPUT FILE

I tried to make the input syntax intuitive, but it still needs some explanation.  I suggest that you take a look at the samples before reading the description that follows. Also, at this stage in the project, I can not guarantee that the input file sentax and semantics will be completely forward compatible with future versions. In such a situation, I will provide a translation tool with the release, and note it in the release notes.

The input file consists of a series of statements seperated by seperators.  Statements are used to modify the value of a signal and to add a signal to the list of dependencies for subsequent statements. A seperator ("." "," ";" or "=>") is required after every statement. The seperators may reset the list of dependencies and/or increment the clock.  The "=>" seperator is used to draw causality arrows on the timing diagram based on the current list of dependencies.

In brief, commas and semicolons seperate simultaneous signal changes, and periods indicate the end of a clock cycle.

SIGNAL=VALUE
This statement changes the value of a signal at the beginning of the current clock, and adds it to the list of signal dependencies.  The signal name may consist of one or more alphanumeric words joined by periods.
SIGNAL
This statement adds a signal to the list of dependencies without changing its value.
,
The comma seperator is used to seperate statements without affecting the dependency list or clock (ie: the next statement will add to the dependency list).
;
The semicolon seperator resets the list of dependencies without incrementing the clock
.
The period seperator resets the list of dependencies and increments the clock.
=>
The "causes" seperator renders dependency arrows based on the current list of dependencies and then resets the dependency list.
-tD>
The "delay" seperator renders a delay arrow from the last dependency.  An optional annotation, tD in this case, can be provided.

Signal values are rendered according to the following rules:

0, 1, true, and false
binary hi/low signal.
tick
a clock pulse which repeats.
pulse
a one-shot clock pulse.
X
a don't care value.
Z
a tristate value.
"ABC"
Any other alphanumeric token, or text enclosed in quotes is rendered as a state.