First doc pass (no updated imgs) [ci skip]

This commit is contained in:
Abraham Gonzalez
2021-03-09 05:11:24 +00:00
parent e4ccfe1bb9
commit ade8457870
5 changed files with 120 additions and 39 deletions

View File

@@ -0,0 +1,20 @@
.. _harness-clocks:
Creating Clocks in the Test Harness
===================================
By default, all modules in the Test Harness, including those made by harness binders
use the implicit clock and reset of the Test Harness.
However, the test harness and harness binders, have the ability to generate a standalone
clock and reset signal.
This is done by the ``HarnessClockInstantiator`` which allows you to request a clock at a
particular frequency.
Take the following harness binder example:
.. literalinclude:: ../../generators/chipyard/src/main/scala/config/HarnessBinders.scala
:language: scala
:start-after: DOC include start: HarnessClockInstantiatorEx
:end-before: DOC include end: HarnessClockInstantiatorEx
While the purpose of the binder isn't necessary here, you can see that the ``p(HarnessClockInstantiatorKey).getClockBundle``
allows the binder to request a clock/reset bundle at a particular frequency.