agentCfg - Configure Agent
Added in version pltOS: v2.0
To facilitate SBC interaction during production, include an x86-64 PC or an additional SBC in the test fixture.
Interaction is configured based on how the agent is attached. The command
auto-detects the connection type from the attached USB device (or from the
identifier format given in id:) and configures it accordingly:
USB-CDC: Configures the UART (USB-CDC, 1,000,000 baud 8N1) for an SBC running an image based on PPC Yocto Layer, then starts a console session and optionally transfers files to its RAMDISK over USB Mass Storage.
USB-NET or Ethernet: Derives an IPv6 link-local address from the agent’s MAC address (or uses an IPv4/IPv6 address given directly) and configures a PLT agent session over the link-local network, optionally transferring files.
If <handle> has not been configured yet, the first call to agentCfg
creates it, resolving the USB device or network address described by
id:/path:/interface:. A later agentCfg on the same handle
reuses the existing agent; the UART port cannot be changed on an
already-configured handle.
Usage:
- command: agentCfg <handle> [<uartPort>]
[retry: <retryCount>]
[id: <agentID>]
[path: <usbDevicePath>]
[interface: <usbDeviceInterface>]
[extractKey: <key>]
[with:
[- <fileName>]
...]
Argument |
Description |
|---|---|
handle |
Used to refer to this agent in further commands. |
uartPort |
Optional: UART port to use, for example |
retryCount |
Optional: Number of times to retry the test step |
fileName |
Optional: Name of file to write to the SBC. |
key |
Optional: Key in which to store the UART port |
agentID |
Optional: Identifies the agent. Accepts a prefixed
form or a bare legacy form (see below). Defaults to
|
usbDevicePath |
Optional: USB device path: |
usbDeviceInterface |
Optional: USB device interface: |
Agent ID formats
id: accepts either an explicit, prefixed form or a bare legacy form that
is inferred heuristically. Prefixed forms are preferred, since the legacy
heuristics can be ambiguous:
Form |
Example / meaning |
|---|---|
|
|
|
|
|
|
|
|
|
USB-Ethernet adapter selected by VID:PID, with its MAC validated
against |
|
|
|
USB-Ethernet adapter selected by path, with its MAC validated against
|
(bare) |
|
(bare) |
heuristically detected as a MAC address |
(bare) dotted decimal |
heuristically detected as an IPv4 address |
(bare) containing |
heuristically detected as an IPv6 address |
If id: cannot be parsed by any of the above, agentCfg falls back to
treating it as a legacy raw USB device identifier.
PLT-200A / legacy id: forms
Note
These bare id: forms are the older way of identifying an agent, used
on a PLT-200A and by test plans written before the prefixed
Agent ID formats above were added.
They are still parsed heuristically (see the (bare) rows in that
table) and continue to work on a PLT-200A, but new test plans should
prefer the prefixed vid:/mac: forms, since the bare heuristics
can be ambiguous.
- command: agentCfg <handle> [<uartPort>]
[retry: <retryCount>]
[id: <usbDeviceID | macAddress>]
[path: <usbDevicePath>]
[extractKey: <key>]
[with:
[- <fileName>]
...]
Argument |
Description |
|---|---|
usbDeviceID |
Optional: USB device identifiers: |
macAddress |
Optional: Ethernet MAC address: |
Examples
Note
For Ethernet-based control, the PLT agent package should be installed on the Agent PC.
References