Loving tikz-timing for preparing timing diagrams for my teaching. One thing I've not been able to find, though, is how I might add a numbered time axis to a timing diagram. This is useful when showing the basics of testbench design, and wanting to indicate the correspondence in the diagram with a line in the Verilog source. I imagine a TikZ overlay could work, but I'm not that much of a pro, and would prefer something where the numbers are added automatically. I am using the vertical help lines, so somehow adding numbers above or below those would be great.
There is no dedicated macro provided by
The number of rows is given by
If you need this more often you could define an own macro:
Here is another possible way, using
... using this MWE:
Note that one needs to do a bit of arithmetic, so as to scale the units of the