Basis#
The scenario file describes the hardware, how it is connected to the world, how to configure it, and how to run a test suite.
A board can be connected to the external world by three type of connections:
pcie
, jtag
and ftdi
.
For example, the PCIe400 board is connected by one pcie
,
one jtag
and three ftdi
connections.
Therefore, a component can be access by one or more than one connections
as shown in the
peripheral tree
The scenario is an YAML file containing parameters for connection, to configure components and to run the test suites.
File naming convention#
Naming convention for scenario files are described in the table below.
Values between {}
are mandatory while those between []
are optional.
setup |
grammar |
exemple |
comment |
---|---|---|---|
p400 card |
{part_number}.yml |
|
|
devkit |
{part_number}.yml |
|
Path to the scenario via the CLI option#
The path to the scenario is mandatory for the CLI
p4x_collect
,p4x_console
,p4x_dcdc
andp4x_functional
.Use the option
--scenario
or the shortcut-S
Scenario file is located either in the invocation directory of the CLI or in the package
p400scnr
. The file is search in the invocation directory and then in the package. It can be abbreviated to the file name without extension, e.g.p400x101x
.
Path to scenario files in python code#
The path to
p400scnr
is stored in the variablePATH_SCNRS
:from p400scnr import PATH_SCNRS pscnr = PATH_SCNRS.joinpath("p400x101x.yml") print(pscnr.exists())
Alternative (preferred one):
from p400uc import PATH_SCNRS pmap = PATH_SCNRS.join("p400x101x.csv") print(pscnr.exists())
The scenario defined the defaults values for all parameters. They can be supersed using command line options.