table of contents
DRAWTIMING(1) | General Commands Manual | DRAWTIMING(1) |
NAME¶
drawtiming
—
generate timing diagram from signal description
SYNOPSIS¶
drawtiming |
[--verbose --scale
factor--pagesize
WxH--aspect --cell-height
H--cell-width
W--font-size
pts--line-width
W--output
target file
... |
DESCRIPTION¶
This application provides a command line tool for documenting hardware and software designs through ideal timing diagrams. It reads signal descriptions from a text file with an intuitive syntax, and outputs an ideal timing diagram to an image file. Notation typical of timing diagrams found in the Electrical Engineering discipline is used, including arrows indicating causal relationships between signal transitions. The options are as follows:--help
- Show usage reminder.
--verbose
- Increase diagnostic output.
--scale
factor- Scale the diagram by the given factor. The default scaling factor is 1.0.
--pagesize
WidthxHeight- Scale the diagram to fit given image size.
--aspect
- Maintain fixed aspect ratio if --pagesize given.
--cell-height
H- Height of the each signal in pixels. Default is 32.
--cell-width
W- Width for the time unit in pixels. Defaults is 64.
--font-size
pts- Font size in pts. Default is 18.
--line-width
W- Line width for drawings in pixels. Default is 1.
--output
target- The name and format of the output image is determined by target.
- file ...
- The input files describe the signals to be diagrammed. See the FILES and EXAMPLES sections for a description of their format.
FILES¶
The following is a technical description of the input file syntax and semantics. If you are reading this for the first time, you may want to skip ahead to the EXAMPLES section. The input file consists of a series of statements describing the signal transitions during each clock period of the timing diagram. Whitespace and comments following a ‘#
’ are ignored.
- 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 words consisting of alphanumerics and
underscores joined by periods,
‘
signal.name
’, for example. The signal value format is described further on. - SIGNAL
- This statement adds a signal to the list of dependencies without changing its value.
- ,
- The comma separator is used to separate statements without affecting the dependency list or clock (ie: the next statement will add to the dependency list).
- ;
- The semicolon separator resets the list of dependencies without incrementing the clock
- .
- The period separator resets the list of dependencies and increments the clock.
- =>
- The "causes" separator renders dependency arrows based on the current list of dependencies and then resets the dependency list.
- -tD>
- The "delay" separator renders a delay arrow from the last dependency with the annotation tD.
- 0, 1, true, false
- A binary high/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. For example,
‘
“1”
’, is rendered as a state, whereas, ‘1
’, is rendered as a high signal.
EXAMPLES¶
Let's look at an example input file, and parse its meaning.POWER=0, FIRE=0, ARMED=0, LED=OFF, COUNT=N. POWER=1 => LED=GREEN. FIRE=1. FIRE => ARMED=1. FIRE=0. FIRE=1. FIRE, ARMED => LED=RED; FIRE => COUNT="N+1".
FIRE
’ became true during a clock cycle:
FIRE=1.
POWER=0, FIRE=0, ARMED=0, LED=OFF,
COUNT=N.
FIRE
’ causes a change in
the ‘ARMED
’ signal.
FIRE => ARMED=1.
POWER=1 => LED=GREEN.
FIRE, ARMED =>
LED=RED.
FIRE
’ also causes
‘COUNT
’ to increment yields:
FIRE, ARMED =>
LED=RED;
FIRE =>
COUNT="N+1".
drawtiming
at
‘http://drawtiming.sourceforge.net
’.
DIAGNOSTICS¶
Exit status is 0 on success, and 2 if the command fails.COMPATIBILITY¶
Thedrawtiming
command has been tested on
FreeBSD, Linux, and Cygwin.
AUTHORS¶
This software package was written by Edward Counce ⟨ecounce@users.sourceforge.net⟩ Additional modifications bySalvador E. Tropea ⟨set@users.sourceforge.net⟩
Daniel Beer
BUGS¶
None reported.April 13, 2005 | Debian |