Skip to content

Command line

All mechatronics commands live under embeddyn mechatronics (or python -m embeddyn mechatronics). This page is generated from the command definitions by tools/docs/make_cli_reference.py; --help on any command shows the same.

Command Purpose
compile Compile a project into a run directory with its manifest and lock file, without running it.
run Run a co-simulation; write telemetry, a manifest and optionally a CSV, and print final values and metrics.
metrics Compute the project's declared metrics from an exported run CSV.
tune Tune project parameters by repeated co-simulation (bounded Nelder-Mead or CMA-ES).
verify Verify a model: energy balance, step-size convergence, golden waveforms, scenario matrix. Exits with status 1 when a check fails.
estimate Estimate physical parameters from bench measurements (Levenberg-Marquardt, 95 % confidence intervals).
tolerance Monte Carlo yield and Sobol sensitivity over component tolerances.
validate Parse and validate a project file without starting any simulator.
runs-list List recorded runs from the metadata database.
runs-inspect Show one recorded run: manifest, parameters, artifacts.
runs-export Export a recorded run's signals.
artifacts-verify Verify the content hashes of every artifact in the content-addressed store.
replay Check that a recorded run directory replays consistently.
gui Embeddyn Lab: schematic editor, virtual instruments and 3-D view in the browser.
fmu-export Export a python plant as an FMI 3.0 co-simulation FMU (PythonFMU3), with state save/restore.
fmu-check Validate an FMU (FMPy model-description checks) and run a short co-simulation.
bindings-from-pinplan Generate Renode GPIO/PWM/ADC bindings from a CodeLayer Forge pin plan.
curtain-run Run a light-curtain scan algorithm against a scene (no Webots needed).
curtain-sweep Sweep LED angle, intensity, algorithm, ... and tabulate the bench metrics.
curtain-webots Write a Webots world (IrLightCurtain PROTOs + light_curtain supervisor) for a bench file.
doctor Report which external tools (Renode, ngspice, Webots, KiCad, LTspice) are found.
kicad-export Export a KiCad schematic to a SPICE netlist with kicad-cli.
kicad-plugin Create a KiCad IPC plugin skeleton that talks to the local Studio API.
integration-validate Check a project's integrations: model files, bindings, FMU variables, tool availability.
catalog-list List the component definitions found under a catalog root.
kicad-inspect Summarise a SPICE netlist (sources, models, subcircuits) without KiCad.
worker-register Register a worker with the distributed coordinator.
workers-list List registered workers.
job-submit Submit a simulation job to the distributed queue.
jobs-list List queued and finished jobs.
job-cancel Cancel a queued job.
experiment-expand Expand an experiment file into its individual runs (sweeps, matrices).
experiment-submit Submit every run of an experiment to the queue.
experiment-status Show the progress of a submitted experiment.
hil-validate Validate a hardware-in-the-loop safety policy (watchdog, emergency stop, outputs, deadline trips).
worker-run Run a worker agent that executes queued jobs.
twin-state Create a digital-twin state snapshot.
twin-compare Compare simulated and measured signal files.
twin-calibrate Fit digital-twin parameters to measured data.
uncertainty-run Run an uncertainty propagation from a specification file.
requirements-verify Check requirements against computed metrics.
evidence-report Render a Markdown evidence report from verification results.

compile

Compile a project into a run directory with its manifest and lock file, without running it.

embeddyn mechatronics compile PROJECT_FILE [OPTIONS]
Option Default Description
--output-root .embeddyn/runs

run

Run a co-simulation; write telemetry, a manifest and optionally a CSV, and print final values and metrics.

embeddyn mechatronics run PROJECT_FILE [OPTIONS]
Option Default Description
--output, -o Optional CSV export path.
--output-root .embeddyn/runs
--mock, --no-mock False Use deterministic built-in simulators for all domains.
--isolate-adapters False Run supported adapters in supervised child processes.
--checkpoint-interval Checkpoint interval in seconds.
--resume-from
--parameter-overrides JSON object of resolved parameter overrides.
--fault Inject a fault, as in the project's faults: list, written as a YAML/JSON mapping, e.g. '{signal: servo.feedback_voltage, type: stuck, start: 1.2 s}'. Repeatable.

metrics

Compute the project's declared metrics from an exported run CSV.

embeddyn mechatronics metrics PROJECT_FILE RUN_CSV [OPTIONS]

tune

Tune project parameters by repeated co-simulation (bounded Nelder-Mead or CMA-ES).

embeddyn mechatronics tune SPEC_FILE [OPTIONS]
Option Default Description
--output, -o .embeddyn/tuning/result.json
--max-evaluations
--workers Parallel evaluations (overrides the spec).
--method nelder-mead or cmaes (overrides the spec).

verify

Verify a model: energy balance, step-size convergence, golden waveforms, scenario matrix. Exits with status 1 when a check fails.

embeddyn mechatronics verify PROJECT_FILE [OPTIONS]
Option Default Description
--check Run only these checks: energy, convergence, golden, scenarios.
--mock, --no-mock False Use the built-in simulators for the core domains.
--update-golden False Rewrite the golden waveform file.
--output, -o Write the JSON report here.

estimate

Estimate physical parameters from bench measurements (Levenberg-Marquardt, 95 % confidence intervals).

embeddyn mechatronics estimate SPEC_FILE [OPTIONS]
Option Default Description
--output, -o .embeddyn/estimation/result.json

tolerance

Monte Carlo yield and Sobol sensitivity over component tolerances.

embeddyn mechatronics tolerance SPEC_FILE [OPTIONS]
Option Default Description
--output, -o .embeddyn/tolerance/result.json
--workers Parallel processes (overrides the spec).
--samples Monte Carlo samples (overrides the spec).

validate

Parse and validate a project file without starting any simulator.

embeddyn mechatronics validate PROJECT_FILE [OPTIONS]

runs-list

List recorded runs from the metadata database.

embeddyn mechatronics runs-list [OPTIONS]
Option Default Description
--database .embeddyn/database/metadata.sqlite3
--limit 50

runs-inspect

Show one recorded run: manifest, parameters, artifacts.

embeddyn mechatronics runs-inspect RUN_ID [OPTIONS]
Option Default Description
--database .embeddyn/database/metadata.sqlite3

runs-export

Export a recorded run's signals.

embeddyn mechatronics runs-export RUN_ID [OPTIONS]
Option Default Description
--output, -o
--database .embeddyn/database/metadata.sqlite3

artifacts-verify

Verify the content hashes of every artifact in the content-addressed store.

embeddyn mechatronics artifacts-verify [OPTIONS]
Option Default Description
--root .embeddyn/artifacts

replay

Check that a recorded run directory replays consistently.

embeddyn mechatronics replay RUN_DIRECTORY [OPTIONS]

gui

Embeddyn Lab: schematic editor, virtual instruments and 3-D view in the browser.

embeddyn mechatronics gui PROJECT_FILE [OPTIONS]
Option Default Description
--host 127.0.0.1 Interface to bind (keep it local: the API runs simulators).
--port 8710
--open False Open the Lab in the default browser.

fmu-export

Export a python plant as an FMI 3.0 co-simulation FMU (PythonFMU3), with state save/restore.

embeddyn mechatronics fmu-export PLANT [OPTIONS]
Option Default Description
--output, -o . Directory for .fmu.
--name Model name (default: the class name).
--param, -p Parameter default, name=value (repeat).
--input-start Input start value, name=value.
--max-step 0.0001 RK4 sub-step inside each doStep [s].
--check, --no-check True Validate and simulate the result with FMPy.

fmu-check

Validate an FMU (FMPy model-description checks) and run a short co-simulation.

embeddyn mechatronics fmu-check FMU [OPTIONS]
Option Default Description
--stop-time 0.01

bindings-from-pinplan

Generate Renode GPIO/PWM/ADC bindings from a CodeLayer Forge pin plan.

embeddyn mechatronics bindings-from-pinplan PLAN_FILE [OPTIONS]
Option Default Description
--device Device with renode pin data.
--output, -o Bindings YAML to write (default: stdout).
--merge Existing bindings whose non-pin entries (sysbus...) are kept.
--machine

curtain-run

Run a light-curtain scan algorithm against a scene (no Webots needed).

embeddyn mechatronics curtain-run BENCH_FILE [OPTIONS]
Option Default Description
--scenario static, approach, rod or orbit
--algorithm sequential, crossed, group or module:Class
--set, -p dotted.key=value, e.g. emitter.half_angle='20 deg'
--output, -o CSV of per-frame rows

curtain-sweep

Sweep LED angle, intensity, algorithm, ... and tabulate the bench metrics.

embeddyn mechatronics curtain-sweep BENCH_FILE [OPTIONS]
Option Default Description
--grid, -g key=v1,v2,... (replaces the file's sweep)
--workers, -j 1
--output, -o CSV with one row per variant

curtain-webots

Write a Webots world (IrLightCurtain PROTOs + light_curtain supervisor) for a bench file.

embeddyn mechatronics curtain-webots BENCH_FILE [OPTIONS]
Option Default Description
--output, -o World file, in a Webots project's worlds/ folder
--arg extra controller argument

doctor

Report which external tools (Renode, ngspice, Webots, KiCad, LTspice) are found.

embeddyn mechatronics doctor [OPTIONS]

import

embeddyn mechatronics import SOURCE [-o OUT] [--title T] [--gcc DIR] [--no-build] [--firmware NAME]...
                                    [--substitute REF=PART_ID]... [--parts FILE]... [--renode-root DIR]

Turn a board project (folder or .zip: KiCad netlist or schematic, STM32CubeMX .ioc, STM32CubeIDE or Makefile firmware) into a Renode board, the built firmware, a mechatronic project per firmware and an import report. See Import a board project.

kicad-export

Export a KiCad schematic to a SPICE netlist with kicad-cli.

embeddyn mechatronics kicad-export SCHEMATIC [OPTIONS]
Option Default Description
--output, -o artifacts/kicad/circuit.cir
--executable

kicad-plugin

Create a KiCad IPC plugin skeleton that talks to the local Studio API.

embeddyn mechatronics kicad-plugin DESTINATION [OPTIONS]

integration-validate

Check a project's integrations: model files, bindings, FMU variables, tool availability.

embeddyn mechatronics integration-validate PROJECT_FILE [OPTIONS]

catalog-list

List the component definitions found under a catalog root.

embeddyn mechatronics catalog-list [OPTIONS]
Option Default Description
--root components/mechatronics

kicad-inspect

Summarise a SPICE netlist (sources, models, subcircuits) without KiCad.

embeddyn mechatronics kicad-inspect NETLIST [OPTIONS]

worker-register

Register a worker with the distributed coordinator.

embeddyn mechatronics worker-register [OPTIONS]
Option Default Description
--name
--endpoint local://worker
--worker-id
--simulators `` Comma-separated simulator names.
--hardware `` Comma-separated hardware capabilities.
--labels `` Comma-separated scheduling labels.
--max-parallel-jobs 1
--real-time False
--database .embeddyn/database/metadata.sqlite3

workers-list

List registered workers.

embeddyn mechatronics workers-list [OPTIONS]
Option Default Description
--database .embeddyn/database/metadata.sqlite3
--stale-after

job-submit

Submit a simulation job to the distributed queue.

embeddyn mechatronics job-submit PROJECT_FILE [OPTIONS]
Option Default Description
--requirements
--priority 0
--database .embeddyn/database/metadata.sqlite3

jobs-list

List queued and finished jobs.

embeddyn mechatronics jobs-list [OPTIONS]
Option Default Description
--status
--limit 100
--database .embeddyn/database/metadata.sqlite3

job-cancel

Cancel a queued job.

embeddyn mechatronics job-cancel JOB_ID [OPTIONS]
Option Default Description
--database .embeddyn/database/metadata.sqlite3

experiment-expand

Expand an experiment file into its individual runs (sweeps, matrices).

embeddyn mechatronics experiment-expand EXPERIMENT_FILE [OPTIONS]

experiment-submit

Submit every run of an experiment to the queue.

embeddyn mechatronics experiment-submit EXPERIMENT_FILE [OPTIONS]
Option Default Description
--database .embeddyn/database/metadata.sqlite3

experiment-status

Show the progress of a submitted experiment.

embeddyn mechatronics experiment-status EXPERIMENT_ID [OPTIONS]
Option Default Description
--database .embeddyn/database/metadata.sqlite3

hil-validate

Validate a hardware-in-the-loop safety policy (watchdog, emergency stop, outputs, deadline trips).

embeddyn mechatronics hil-validate POLICY_FILE [OPTIONS]

worker-run

Run a worker agent that executes queued jobs.

embeddyn mechatronics worker-run WORKER_ID [OPTIONS]
Option Default Description
--once False
--poll-interval 1.0
--output-root .embeddyn/worker-runs
--database .embeddyn/database/metadata.sqlite3

twin-state

Create a digital-twin state snapshot.

embeddyn mechatronics twin-state MEASUREMENTS [OPTIONS]
Option Default Description
--output, -o .embeddyn/digital-twin/state.json

twin-compare

Compare simulated and measured signal files.

embeddyn mechatronics twin-compare SIMULATION MEASUREMENTS [OPTIONS]
Option Default Description
--mapping
--output, -o .embeddyn/digital-twin/comparison.json
--aligned-output

twin-calibrate

Fit digital-twin parameters to measured data.

embeddyn mechatronics twin-calibrate SIMULATION MEASUREMENTS [OPTIONS]
Option Default Description
--mapping
--output, -o .embeddyn/digital-twin/calibration.yaml
--database .embeddyn/database/metadata.sqlite3

uncertainty-run

Run an uncertainty propagation from a specification file.

embeddyn mechatronics uncertainty-run SPECIFICATION [OPTIONS]
Option Default Description
--samples 1000
--seed 1
--output, -o .embeddyn/digital-twin/uncertainty.json

requirements-verify

Check requirements against computed metrics.

embeddyn mechatronics requirements-verify REQUIREMENTS METRICS [OPTIONS]
Option Default Description
--output, -o .embeddyn/evidence/traceability.json

evidence-report

Render a Markdown evidence report from verification results.

embeddyn mechatronics evidence-report TRACEABILITY [OPTIONS]
Option Default Description
--comparison
--output, -o .embeddyn/evidence/report.md
--run-id
--database .embeddyn/database/metadata.sqlite3
--artifact-root .embeddyn/artifacts