Skip to content

Commit 5a3fea4

Browse files
deploy: 39b80f1 #241 (synchronize)
1 parent 94b845c commit 5a3fea4

File tree

80 files changed

+751
-336
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

80 files changed

+751
-336
lines changed

pull/241/_sources/testbenches/project_based/adrv9001/index.rst.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ The following parameters of this project can be configured:
4848
- DDS_DISABLE: By setting this parameter you can remove the dual tone DDS logic
4949
from the TX channels. This will reduce resource utilization significantly,
5050
but will lose the ability to generate a test tone:
51-
Options: 0 - Enable DDS, 1 - Disable DDS
52-
51+
Options: 0 - Enable DDS, 1 - Disable DDS
52+
5353
Configuration files
5454
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
5555

@@ -162,7 +162,7 @@ The PN test verifies the PN data.
162162

163163
.. note::
164164

165-
PN Test Skipped in 8 bits symbol mode.
165+
PN Test Skipped in 8 bits symbol mode.
166166

167167
The steps of this test are for:
168168
* NIBBLE_RAMP

pull/241/_sources/user_guide/build_tb.rst.txt

Lines changed: 120 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,14 @@ You may also do this manually (for better or worse); the following snippet is
7777
from a **.bashrc** file. Please note that unless you are an expert at manipulating
7878
these things, it is best to leave it to the tools to set up the environment.
7979

80+
For Vivado versions of 2025 and later, use the following command:
81+
82+
.. shell::
83+
84+
$export PATH=$PATH:/opt/Xilinx/202x.x/Vivado/bin:/opt/Xilinx/202x.x/Vitis/bin
85+
86+
For Vivado versions prior to 2025, use the following command:
87+
8088
.. shell::
8189

8290
$export PATH=$PATH:/opt/Xilinx/Vivado/202x.x/bin:/opt/Xilinx/Vitis/202x.x/bin
@@ -89,6 +97,14 @@ The best option on Windows is to use
8997
``make`` and ``git`` packages. You should do changes to your **.bashrc** in a
9098
similar manner to the Linux environment.
9199

100+
For Vivado versions of 2025 and later, use the following command:
101+
102+
.. shell::
103+
104+
$export PATH=$PATH:/cygdrive/d/Xilinx/202x.x/Vivado/bin:/cygdrive/d/Xilinx/202x.x/Vitis/bin
105+
106+
For Vivado versions prior to 2025, use the following command:
107+
92108
.. shell::
93109

94110
$export PATH=$PATH:/cygdrive/d/Xilinx/Vivado/202x.x/bin:/cygdrive/d/Xilinx/Vitis/202x.x/bin
@@ -97,6 +113,14 @@ A very good alternative to Cygwin is
97113
`WSL <https://learn.microsoft.com/en-us/windows/wsl/install/>`__. The
98114
manual changes to your **.bashrc** should look like:
99115

116+
For Vivado versions of 2025 and later, use the following command:
117+
118+
.. shell::
119+
120+
$export PATH=$PATH:/opt/path_to/202x.x/Vivado/bin:/opt/202x.x/Vitis/bin
121+
122+
For Vivado versions prior to 2025, use the following command:
123+
100124
.. shell::
101125

102126
$export PATH=$PATH:/opt/path_to/Vivado/202x.x/bin:/opt/Vitis/202x.x/bin
@@ -108,7 +132,8 @@ variations** installed by the tools itself.
108132

109133
Some of these may not be fully functional with our scripts and/or projects.
110134
If you are an AMD user, use the **gnuwin** installed as part of the SDK,
111-
usually at ``C:\Xilinx\Vitis\202x.x\gnuwin\bin``.
135+
usually at ``C:\Xilinx\202x.x\Vitis\gnuwin\bin`` for Vitis versions of 2025 and
136+
later, or ``C:\Xilinx\Vitis\202x.x\gnuwin\bin`` for prior versions.
112137

113138
Repository path setup
114139
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -138,41 +163,106 @@ In this example, it is building the **AD7616** testbench.
138163
$cd ad7616
139164
$make
140165

141-
The ``make`` builds all the libraries first and then builds the testbench.
142-
This assumes that you have the tools and licenses set up correctly. If
143-
you don't get to the last line, the make failed to build one or more
144-
targets: it could be a library component or the project itself. There is
145-
nothing you can gather from the ``make`` output (other than which one
146-
failed). The actual information about the failure is in a log file inside
147-
the project directory. By default, ``make`` builds all of the available
166+
The ``make`` builds all the libraries first and then builds the testbench. The
167+
testbench build folder is in the testbench project's location under ``runs/``
168+
with the configuration's name as Vivado project name. This assumes that you have
169+
the tools and licenses set up correctly and the build finishes with no errors.
170+
If the make fails to build one or more targets, there is no useful information
171+
you can gather from the ``make`` output (other than which target failed to
172+
build). The actual information about the failure is in a log file inside
173+
the target's directory. By default, ``make`` builds all of the available
148174
configurations and runs all of the ``test programs`` that are predefined
149175
in the ``Makefile``.
150176

151-
Also, there's an option to use ``make`` using GUI, so that at the end of the
152-
build it will launch Vivado and start the simulation with the waveform viewer
153-
started as well.
177+
There are multiple ``make`` parameters that can be used to build and run a
178+
simulation.
179+
180+
**Examples**
181+
182+
The ``all`` keyword is the same as running ``make`` by itself with no additional
183+
configuration/test program parameter. Often used in combination with ``clean``
184+
parameter.
154185

155186
.. shell::
156187

157-
$make MODE=gui
188+
$make all
189+
190+
Another build option is to use the configuration file's name as a make parameter
191+
without any other input. This will build the configuration and run all test
192+
programs on it.
193+
194+
.. shell::
195+
196+
$make cfg_si
158197

159198
Some projects support adding additional ``make`` parameters to configure
160199
the project. This option gives you the ability to build only the configuration
161200
that you're interested in, without building the rest of the available
162-
configurations, as well as running the chosen test program, if it is the case.
201+
configurations, as well as running the chosen test program. ``CFG`` specifies
202+
the configuration file's name, while ``TST`` specifies the test program's name.
163203

164-
If parameters were used, the result of the build will be in a folder under
165-
``runs/``, named by the configuration used.
204+
.. shell::
205+
206+
$make CFG=cfg_si TST=test_program_si
207+
208+
.. caution::
209+
210+
Trying to run incompatible configuration and test program combinations will
211+
result in simulation error! Please refer to the projects guide to check
212+
compatibility.
213+
214+
.. note::
215+
216+
When running the ``make`` command with one of the above mentioned 3 options,
217+
please choose only 1 of them! Using multiple options may lead to building
218+
multiple designs and running multiple test programs.
219+
220+
The ``clean`` keyword removes the ``runs`` and ``results`` folders, as well as
221+
the log files created by Vivado.
222+
223+
.. shell::
224+
225+
$make clean
226+
227+
There's an option to use Vivado's XSim GUI, so that at the end of the build it
228+
will launch Vivado and start the simulation with the waveform viewer started as
229+
well. By default, ``make`` launches Vivado in batch mode, meaning that it won't
230+
provide a GUI, only a result in the terminal at the end of the simulation.
166231

167-
**Example**
232+
.. shell::
233+
234+
$make MODE=gui
168235

169-
Running the command below will create a folder named
170-
**cfg_si** for the following file combination: **cfg_si** configuration file and
171-
the **test_program_si** test program.
236+
The ``STOP_ON_ERROR`` parameter is mainly used for continuous integration
237+
purposes, which allows the user to build and run all testbenches even if one
238+
fails. The only exception to this is when a library fails to build, as this will
239+
prevent any of the testbench designs to be run. The default value is ``y``,
240+
which halts the simulation once it runs into an error. The other option to run
241+
all testbenches is ``n``. This is useful for checking which configuration and
242+
test program configurations are failing.
172243

173244
.. shell::
174245

175-
$make MODE=gui CFG=cfg_si TST=test_program_si
246+
$make STOP_ON_ERROR=y
247+
248+
Rerunning a simulation
249+
-------------------------------------------------------------------------------
250+
251+
If you want to rerun a simulation, you can do it in a couple of different ways,
252+
depending on what you're trying to do.
253+
254+
The most straightforward and easiest way is to rerun the ``make`` command with
255+
the parameters it was ran initially if it is the case. This will rebuild any
256+
libraries and/or the testbench block design if any of them changed and then run
257+
the simulation. If there are changes that affect the architecture of the
258+
testbench, then design is going to be rebuilt. If only the simulation files are
259+
updated, which don't affect the testbench block design, then only the simulation
260+
will be run. This is the recommended way to run the testbench to avoid any
261+
issues if the source files are modified.
262+
263+
.. attention::
264+
265+
Vivado must be closed before rerunning the ``make`` command!
176266

177267
In GUI mode, if the simulation was already run, there are a couple of options
178268
for restarting it.
@@ -188,7 +278,16 @@ for restarting it.
188278
simulation`` option from the Flow Navigator. This will recompile the project
189279
and start the simulation. This is needed when project simulation parameters
190280
are changed after the build was created or when the block design is changed
191-
manually. When the simulation seed is hard coded, this option must be used.
281+
manually. When the simulation seed is changed or randomized, and you want to
282+
rerun the simulation with an updated seed value, this is the option that must
283+
be used.
284+
285+
.. note::
286+
287+
When rerunning a simulation in GUI mode, there is a slight chance that
288+
Vivado crashes. The reason for this is unknown, and it usually happens when
289+
the restarting process is going and the user tries putting the process in the
290+
background via the pop-up window.
192291

193292
Opening a testbench
194293
-------------------------------------------------------------------------------

pull/241/_static/app.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pull/241/_static/app.min.css.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pull/241/_static/app.umd.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pull/241/_static/app.umd.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pull/241/_static/extra.min.css.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pull/241/_static/extra.umd.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pull/241/_static/extra.umd.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pull/241/common/more_information.html

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
<title>More information &#8212; Testbenches documentation</title>
1010
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=8e8a900e" />
11-
<link rel="stylesheet" type="text/css" href="../_static/app.min.css?v=8d0b0339" />
11+
<link rel="stylesheet" type="text/css" href="../_static/app.min.css?v=85dade36" />
1212
<link rel="stylesheet" type="text/css" href="../_static/custom.css" />
13-
<script async="async" src="../_static/app.umd.js?v=2f9373fc"></script>
13+
<script async="async" src="../_static/app.umd.js?v=3a4867e9"></script>
1414
<link rel="icon" href="../_static/icon.svg"/>
1515
<link rel="index" title="Index" href="../genindex.html" />
1616
<link rel="search" title="Search" href="../search.html" />
@@ -41,7 +41,10 @@
4141
}
4242
}
4343
</style>
44-
</head><body>
44+
</head>
45+
46+
<body>
47+
4548
<input type="checkbox" id="input-show-toc">
4649
<input type="checkbox" id="input-show-localtoc">
4750
<input type="checkbox" id="input-show-repotoc">
@@ -244,7 +247,7 @@ <h1>More information<a class="headerlink" href="#more-information" title="Link t
244247
<label id="cancel-area-show-toc" for="input-show-toc"></label>
245248
<label id="cancel-area-show-localtoc" for="input-show-localtoc"></label>
246249
<footer>
247-
&#169;2024, Analog Devices, Inc.
250+
&#169;2024-2025, Analog Devices, Inc.
248251

249252
|
250253
Made with <a href="https://www.sphinx-doc.org/">Sphinx</a>

0 commit comments

Comments
 (0)