Skip to content

BMCLI bench

Reference version: BMCLI 1.6.3. Command names, parameters and machine-readable fields retain their source spelling.

connections.<network>.firmware is a saved observation, labelled firmware_source: "bench_record"; bench show and bench validate do not refresh it. Use channel enumerate for the current firmware version. Hardware validation uses daemon-coordinated inventory when available and local BMAPI discovery when no daemon is running. An IPC or response failure is reported as unavailable inventory, not as a missing device.

bench is the first-party configuration layer shared by users, AI harnesses, shell scripts, and Python automation. One .bmcli directory is one target and one bench; that bench may contain multiple logical networks and physical channels. It separates portable target/network/node intent from machine-local analyzer identity, wiring, and paths:

  • .bmcli/target.json may be versioned with the project.
  • .bmcli/bench.local.json is local and is ignored by the generated .bmcli/.gitignore.
Terminal window
bmcli bench init --target=vehicle-a --kind=vehicle \
--network=vehicle-can --node=gateway --nbitrate=500 --dbitrate=2M
bmcli channel enumerate
bmcli bench init --network=sensor-private-can --node=sensor-controller \
--channel=10356/1 --nbitrate=500 --dbitrate=2M --termination=120 \
--request-id=0x791 --response-id=0x799 --database=network/body.dbc \
--validated-by=enumerate+autoset+uds-discover
bmcli bench show --format=json
bmcli bench validate --format=json
bmcli bench validate --hardware --format=json

bench init updates the selected network, node, and local connection while preserving all other entries. The first network and node become defaults. It accepts repeatable, protocol-neutral --database references for DBC, LDF, A2L, or future supported database types; --database=none clears the list. --dbc is a mutually exclusive single-DBC convenience form. It rejects order-dependent numeric channel indices. It does not enumerate, AutoSet, transmit a functional UDS request, or stop/start the daemon; perform those separately with the applicable authorization, then persist confirmed results. --force is required to replace malformed existing JSON. Use --global only to create or update the per-user fallback.

Without an explicit --project, BMCLI searches from the current directory to the nearest parent .bmcli; when none exists it reads the per-user default. That implicit fallback emits a WARNING which names the selected Target and global configuration directory. JSON sets implicit_global_fallback=true and adds the warning to issues. Explicit --global sets the field to false and does not emit this warning. If no usable global profile exists, implicit fallback returns a structured nonzero error. Use --project=<directory> or run bmcli bench init in the intended project to make the scope explicit. Project and global profiles are not merged. An explicit physical channel always works as before. A configured logical name is also accepted wherever the existing --channel option is accepted:

Terminal window
bmcli message recv --channel=vehicle-can --duration=10 --format=jsonl
bmcli message recv --channel=10356/0 --duration=10 --format=jsonl

The client resolves logical names to local physical bindings before BMAPI access or daemon slot selection. Resolution is exact: an unknown logical network fails instead of falling back to slot 0 or an enumeration index. Node definitions are returned by bench show; automatic selection of one diagnostic node among several is not performed.

bench validate checks network/node/connection references, required timing, database and local paths, and stable persisted channels. With --hardware, it also enumerates every configured binding and verifies that channel capabilities match the declared bus. Its state is READY, DEGRADED (for example, no DBC but raw CAN remains possible), or NEEDS_INPUT; required-value, stale-path, JSON, capability, and hardware mismatch failures return nonzero.

The complete schema, ownership, lookup, and acceptance contract is recorded in bench_configuration_plan.md.



Source of truth: BMCLI 1.6.3 repository documentation. Run bmcli help <category> <action> --format=json for the exact contract of the installed version.