7.1. WaveDrom¶
WaveDrom provides digital timing diagrams based on a JSON-formatted description of the waveform. See the home page for extensive documentation on how to create these diagrams.
The Runestone extension allows authors to easily include these diagrams in a Runestone book. The code to embed a diagram closely follows the code used to embed GraphViz diagrams, and therefore supports the same options:
- .. wavedrom::¶
Directive to embed wavedrom code. The input WaveJSON code for
wavedrom
is given as the content; omit the outermost curly braces ({}
). For example:.. wavedrom:: signal: [{ name: "clk", wave: "010101" }]
produces:
options
- :align: alignment of the graph (left, center or right)¶
The horizontal alignment of the graph.
The caption of the graph.
- :name: label (text)¶
The label of the graph.
- :class: class names (a list of class names separeted by spaces)¶
The class name of the graph.
As another example:
.. wavedrom::
:caption: A basic clock waveform.
:align: right
signal: [{ name: "Alfa", wave: "01.zx=ud.23.456789" }]
You have attempted of activities on this page