Debian Codegraph @

man/labgrid-device-config.5

raw
1 .\" Man page generated from reStructuredText.
2 .
3 .
4 .nr rst2man-indent-level 0
5 .
6 .de1 rstReportMargin
7 \\$1 \\n[an-margin]
8 level \\n[rst2man-indent-level]
9 level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
10 -
11 \\n[rst2man-indent0]
12 \\n[rst2man-indent1]
13 \\n[rst2man-indent2]
14 ..
15 .de1 INDENT
16 .\" .rstReportMargin pre:
17 . RS \\$1
18 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
19 . nr rst2man-indent-level +1
20 .\" .rstReportMargin post:
21 ..
22 .de UNINDENT
23 . RE
24 .\" indent \\n[an-margin]
25 .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
26 .nr rst2man-indent-level -1
27 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
28 .in \\n[rst2man-indent\\n[rst2man-indent-level]]u
29 ..
30 .TH "LABGRID-DEVICE-CONFIG" "5" "2025" "" "labgrid"
31 .SH NAME
32 labgrid-device-config \- test configuration files
33 .SH LABGRID TEST CONFIGURATION FILES
34 .SS SYNOPSIS
35 .sp
36 \fB*.yaml\fP
37 .SS DESCRIPTION
38 .sp
39 To integrate a device into a labgrid test, labgrid needs to have a description
40 of the device and how to access it.
41 .sp
42 This manual page is divided into section, each describing one top\-level yaml key.
43 .SS TARGETS
44 .sp
45 The \fBtargets:\fP top key configures a \fBtarget\fP, it\(aqs \fBdrivers\fP and \fBresources\fP\&.
46 .sp
47 The top level key is the name of the target, it needs both a \fBresources\fP and
48 \fBdrivers\fP subkey. The order of instantiated \fBresources\fP and \fBdrivers\fP is
49 important, since they are parsed as an ordered dictionary and may depend on a
50 previous driver.
51 .sp
52 For a list of available resources and drivers refer to
53 \X'tty: link https://labgrid.readthedocs.io/en/latest/configuration.html'\fI\%https://labgrid.readthedocs.io/en/latest/configuration.html\fP\X'tty: link'\&.
54 .SS OPTIONS
55 .sp
56 The \fBoptions:\fP top key configures various options such as the coordinator_address.
57 .SS OPTIONS KEYS
58 .INDENT 0.0
59 .TP
60 .B \fBcoordinator_address\fP
61 takes as parameter the coordinator \fBHOST[:PORT]\fP to connect to.
62 Defaults to \fB127.0.0.1:20408\fP\&.
63 .UNINDENT
64 .SS IMAGES
65 .sp
66 The \fBimages:\fP top key provides paths to access preconfigured images to flash
67 onto the board. The image paths can be either relative to the YAML file or
68 absolute.
69 .SS IMAGE KEYS
70 .sp
71 The subkeys consist of image names as keys and their paths as values. The
72 corresponding name can than be used with the appropriate tool found under TOOLS.
73 .SS IMAGE EXAMPLE
74 .sp
75 Two configured images, one for the root filesystem, one for the bootloader:
76 .INDENT 0.0
77 .INDENT 3.5
78 .sp
79 .EX
80 images:
81 root: \(dqplatform\-v7a/images/root.img\(dq
82 boot: \(dqplatform\-v7a/images/barebox.img\(dq
83 .EE
84 .UNINDENT
85 .UNINDENT
86 .SS TOOLS
87 .sp
88 The \fBtools:\fP top key provides paths to binaries such as fastboot.
89 .SS TOOLS KEYS
90 .INDENT 0.0
91 .TP
92 .B \fBdfu\-util\fP
93 Path to the dfu\-util binary, used by the DFUDriver.
94 See: \X'tty: link https://dfu-util.sourceforge.net/'\fI\%https://dfu\-util.sourceforge.net/\fP\X'tty: link'
95 .TP
96 .B \fBdpcmd\fP
97 Path to the dpcmd binary, used by the DediprogFlashDriver.
98 See: \X'tty: link https://github.com/DediProgSW/SF100Linux'\fI\%https://github.com/DediProgSW/SF100Linux\fP\X'tty: link'
99 .TP
100 .B \fBfastboot\fP
101 Path to the fastboot binary, used by the AndroidFastbootDriver.
102 See: \X'tty: link https://developer.android.com/studio/releases/platform-tools'\fI\%https://developer.android.com/studio/releases/platform\-tools\fP\X'tty: link'
103 .TP
104 .B \fBflashrom\fP
105 Path to the flashrom binary, used by the FlashromDriver.
106 See: \X'tty: link https://www.flashrom.org/'\fI\%https://www.flashrom.org/\fP\X'tty: link'
107 .TP
108 .B \fBimx_usb\fP
109 Path to the imx_usb binary, used by the BDIMXUSBDriver.
110 See: \X'tty: link https://github.com/boundarydevices/imx_usb_loader'\fI\%https://github.com/boundarydevices/imx_usb_loader\fP\X'tty: link'
111 .TP
112 .B \fBimx\-usb\-loader\fP
113 Path to the imx\-usb\-loader binary, used by the IMXUSBDriver.
114 See: \X'tty: link https://git.pengutronix.de/cgit/barebox/tree/scripts/imx/imx-usb-loader.c'\fI\%https://git.pengutronix.de/cgit/barebox/tree/scripts/imx/imx\-usb\-loader.c\fP\X'tty: link'
115 .TP
116 .B \fBjtagconfig\fP
117 Path to the jtagconfig binary, used by the QuartusHPSDriver.
118 See: \X'tty: link https://www.intel.com/content/www/us/en/docs/programmable/683689/current/jtagconfig.html'\fI\%https://www.intel.com/content/www/us/en/docs/programmable/683689/current/jtagconfig.html\fP\X'tty: link'
119 .TP
120 .B \fBmxs\-usb\-loader\fP
121 Path to the mxs\-usb\-loader binary, used by the MXSUSBDriver.
122 See: \X'tty: link https://git.pengutronix.de/cgit/barebox/tree/scripts/mxs-usb-loader.c?h=v2017.03.0'\fI\%https://git.pengutronix.de/cgit/barebox/tree/scripts/mxs\-usb\-loader.c?h=v2017.03.0\fP\X'tty: link'
123 .TP
124 .B \fBopenocd\fP
125 Path to the openocd binary, used by the OpenOCDDriver.
126 See: \X'tty: link https://openocd.org/'\fI\%https://openocd.org/\fP\X'tty: link'
127 .TP
128 .B \fBquartus_hps\fP
129 Path to the quartus_hps binary, used by the QuartusHPSDriver.
130 See: \X'tty: link https://www.intel.com/content/www/us/en/docs/programmable/683039/22-3/hps-flash-programmer.html'\fI\%https://www.intel.com/content/www/us/en/docs/programmable/683039/22\-3/hps\-flash\-programmer.html\fP\X'tty: link'
131 .TP
132 .B \fBrk\-usb\-loader\fP
133 Path to the rk\-usb\-loader binary, used by the RKUSBDriver.
134 See: \X'tty: link https://git.pengutronix.de/cgit/barebox/tree/scripts/rk-usb-loader.c'\fI\%https://git.pengutronix.de/cgit/barebox/tree/scripts/rk\-usb\-loader.c\fP\X'tty: link'
135 .TP
136 .B \fBrsync\fP
137 Path to the rsync binary, used by the SSHDriver.
138 See: \X'tty: link https://github.com/rsyncproject/rsync'\fI\%https://github.com/rsyncproject/rsync\fP\X'tty: link'
139 .TP
140 .B \fBscp\fP
141 Path to the scp binary, used by the SSHDriver.
142 See: \X'tty: link https://github.com/openssh/openssh-portable'\fI\%https://github.com/openssh/openssh\-portable\fP\X'tty: link'
143 .TP
144 .B \fBsd\-mux\-ctrl\fP
145 Path to the sd\-mux\-ctrl binary, used by the USBSDWireDriver.
146 See: \X'tty: link https://git.tizen.org/cgit/tools/testlab/sd-mux/'\fI\%https://git.tizen.org/cgit/tools/testlab/sd\-mux/\fP\X'tty: link'
147 .TP
148 .B \fBsispmctl\fP
149 Path to the sispmctl binary, used by the SiSPMPowerDriver.
150 See: \X'tty: link https://sispmctl.sourceforge.net/'\fI\%https://sispmctl.sourceforge.net/\fP\X'tty: link'
151 .TP
152 .B \fBssh\fP
153 Path to the ssh binary, used by the SSHDriver.
154 See: \X'tty: link https://github.com/openssh/openssh-portable'\fI\%https://github.com/openssh/openssh\-portable\fP\X'tty: link'
155 .TP
156 .B \fBsshfs\fP
157 Path to the sshfs binary, used by the SSHDriver.
158 See: \X'tty: link https://github.com/libfuse/sshfs'\fI\%https://github.com/libfuse/sshfs\fP\X'tty: link'
159 .TP
160 .B \fBuhubctl\fP
161 Path to the uhubctl binary, used by the USBPowerDriver.
162 See: \X'tty: link https://github.com/mvp/uhubctl'\fI\%https://github.com/mvp/uhubctl\fP\X'tty: link'
163 .TP
164 .B \fBusbmuxctl\fP
165 Path to the usbmuxctl tool, used by the LXAUSBMuxDriver.
166 \X'tty: link https://github.com/linux-automation/usbmuxctl'\fI\%https://github.com/linux\-automation/usbmuxctl\fP\X'tty: link'
167 .TP
168 .B \fBusbsdmux\fP
169 Path to the usbsdmux tool, used by the USBSDMuxDriver.
170 See: \X'tty: link https://github.com/linux-automation/usbsdmux'\fI\%https://github.com/linux\-automation/usbsdmux\fP\X'tty: link'
171 .TP
172 .B \fBuuu\-loader\fP
173 Path to the uuu\-loader binary, used by the UUUDriver.
174 See: \X'tty: link https://github.com/nxp-imx/mfgtools'\fI\%https://github.com/nxp\-imx/mfgtools\fP\X'tty: link'
175 .TP
176 .B \fBykushcmd\fP
177 Path to the ykushcmd binary, used by the YKUSHPowerDriver.
178 See: \X'tty: link https://github.com/Yepkit/ykush'\fI\%https://github.com/Yepkit/ykush\fP\X'tty: link'
179 .UNINDENT
180 .sp
181 The QEMUDriver expects a custom key set via its \fBqemu_bin\fP argument.
182 See \X'tty: link https://www.qemu.org/'\fI\%https://www.qemu.org/\fP\X'tty: link'
183 .SS TOOLS EXAMPLE
184 .sp
185 Configure the tool path for \fBimx\-usb\-loader\fP:
186 .INDENT 0.0
187 .INDENT 3.5
188 .sp
189 .EX
190 tools:
191 imx\-usb\-loader: \(dq/opt/labgrid\-helper/imx\-usb\-loader\(dq
192 .EE
193 .UNINDENT
194 .UNINDENT
195 .SS IMPORTS
196 .sp
197 The \fBimports\fP key is a list of files or python modules which
198 are imported by the environment after loading the configuration.
199 Paths relative to the configuration file are also supported.
200 This is useful to load drivers and strategy which are contained in your
201 testsuite, since the import is done before instantiating the targets.
202 .SS IMPORTS EXAMPLE
203 .sp
204 Import a local \fBmyfunctions.py\fP file:
205 .INDENT 0.0
206 .INDENT 3.5
207 .sp
208 .EX
209 imports:
210 \- myfunctions.py
211 .EE
212 .UNINDENT
213 .UNINDENT
214 .SS EXAMPLES
215 .sp
216 A sample configuration with one \fBmain\fP target, accessible via SerialPort
217 \fB/dev/ttyUSB0\fP, allowing usage of the ShellDriver:
218 .INDENT 0.0
219 .INDENT 3.5
220 .sp
221 .EX
222 targets:
223 main:
224 resources:
225 RawSerialPort:
226 port: \(dq/dev/ttyUSB0\(dq
227 drivers:
228 SerialDriver: {}
229 ShellDriver:
230 prompt: \(aqroot@[\ew\-]+:[^ ]+ \(aq
231 login_prompt: \(aq login: \(aq
232 username: \(aqroot\(aq
233 .EE
234 .UNINDENT
235 .UNINDENT
236 .sp
237 A sample configuration with \fBRemotePlace\fP, using the tools configuration and
238 importing the local \fBmystrategy.py\fP file. The \fBMyStrategy\fP strategy is contained
239 in the loaded local python file:
240 .INDENT 0.0
241 .INDENT 3.5
242 .sp
243 .EX
244 targets:
245 main:
246 resources:
247 RemotePlace:
248 name: test\-place
249 drivers:
250 SerialDriver: {}
251 ShellDriver:
252 prompt: \(aqroot@[\ew\-]+:[^ ]+ \(aq
253 login_prompt: \(aq login: \(aq
254 username: \(aqroot\(aq
255 IMXUSBDriver: {}
256 MyStrategy: {}
257 tools:
258 imx\-usb\-loader: \(dq/opt/lg\-tools/imx\-usb\-loader\(dq
259 imports:
260 \- mystrategy.py
261 .EE
262 .UNINDENT
263 .UNINDENT
264 .SS SEE ALSO
265 .sp
266 \fBlabgrid\-client\fP(1), \fBlabgrid\-exporter\fP(1)
267 .SH AUTHOR
268 Jan Luebbe, Rouven Czerwinski
269 .SH COPYRIGHT
270 2016-2025 Pengutronix, Jan Luebbe and Rouven Czerwinski
271 .\" Generated by docutils manpage writer.
272 .