🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@labwired/mcp

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@labwired/mcp

Model Context Protocol server exposing the LabWired deterministic firmware simulator as agent tools.

latest
npmnpm
Version
0.7.0
Version published
Maintainers
1
Created
Source

@labwired/mcp

Model Context Protocol server exposing the LabWired deterministic firmware simulator as tools your AI coding agent can call.

One-line install (Claude Code)

claude mcp add labwired -- npx -y @labwired/mcp

That's it. Restart Claude Code if the tools don't appear, then ask: "List LabWired boards and run my ELF on stm32f103-blinky."

Cursor / other MCP clients: see Other clients below.

LabWired runs ARM Cortex-M / RISC-V / Xtensa firmware against a silicon-validated, deterministic simulator. This MCP server lets your agent (Claude Code, Cursor, Continue, etc.) verify firmware behaviour without lying to itself — same inputs always produce the same outputs, so the agent can iterate against a real oracle.

What it gives your agent

Core workflow:

ToolWhat it does
labwired_list_boardsHigh-level: list pre-wired boards (chip + peripherals + demo firmware). Start here.
labwired_run_labHigh-level: run an ELF on a board by id. Synthesizes the test script, returns cycles + serial + a snapshot_id.
labwired_fuzzCoverage-guided fuzz a firmware ELF and return the crashing inputs. Silicon-validated sim → crashes are replayable on real hardware (HIL-confirm), not emulation false positives. Deterministic for a fixed seed.
labwired_inspect_runFetch detail from a prior snapshot_idsummary, serial, gpio, raw. 10-min TTL.
labwired_catalogLow-level: list raw chip descriptors.
labwired_simulateLow-level: run firmware against a custom System Manifest + test script YAML. Full control.
labwired_validate_systemValidate a System Manifest YAML before simulating. Fast schema check.
labwired_validate_diagramStructurally validate a wired diagram (parts + wires) before running. Returns machine-readable diagnostics (PIN_NOT_ON_CHIP, PIN_LACKS_I2C, BOARDIO_NOT_TO_MCU, NO_MCU, COMPONENT_DANGLING, …) with suggested fixes.
labwired_compile_diagramCompile a validated diagram to a runnable board manifest (ERC-gated; net-derived I2C bus binding). Persists the manifest to .labwired/boards/<name>.yaml and returns board_path + system_yaml. Errors abort with diagnostics; warnings are included in the response.
labwired_define_componentDefine a new off-chip device from a declarative IR spec; validated, persisted, ready to wire into a manifest.

Live agent → browser bridge (optional — for showing humans what the agent is doing):

ToolWhat it does
labwired_create_sessionOpen a watch session; returns a watch_url like https://app.labwired.com/?watch=<id>. Subsequent runs mirror to it automatically over WebSocket.
labwired_set_diagramPush the current circuit (parts + wires) to the watch session.
labwired_set_sourcePush the current source code to the watch session.
labwired_end_sessionClose the watch session.

Prerequisites

You need the labwired CLI on your PATH. Install via:

curl -fsSL https://labwired.com/install.sh | sh

Verify with labwired --help.

Install in Cursor

Add to ~/.cursor/mcp.json:

{
  "mcpServers": {
    "labwired": {
      "command": "npx",
      "args": ["-y", "@labwired/mcp"]
    }
  }
}

Install globally (any MCP client)

npm install -g @labwired/mcp
labwired-mcp   # speaks MCP over stdio

Example agent prompts

Once installed, ask your agent things like:

"My STM32F1 blinky firmware hangs after about 100k cycles. Here's the ELF (base64-encoded) and my system.yaml. Use LabWired to simulate it with a 200k cycle budget and tell me where it stops."

"Generate a System Manifest for the Nucleo-F401RE with UART2 routed to PA2/PA3 at 115200 baud, then validate it with labwired_validate_system before I commit."

"Here are two versions of my ADC interrupt handler. Run each through labwired_simulate against my regression script and tell me which one passes all assertions."

Environment variables

  • LABWIRED_CLI — override the CLI binary path. Defaults to labwired on PATH.
  • LABWIRED_REPO_ROOT — absolute path to your labwired checkout. The high-level labwired_run_lab tool resolves board YAMLs from core/configs/. Auto-detected when the MCP server is run from inside the repo; required when running globally.

Why deterministic matters for agents

Agents that propose firmware fixes hit a fundamental problem: there's no fast, reliable oracle to verify whether a fix actually works. Physical HIL benches are slow and flaky. Best-effort simulators give different results on different runs. LLMs hallucinate "yes I think that fixes it."

LabWired is bit-accurate and reproducible by design: the same firmware + same system config + same test script produce the same result.json every time. The agent can propose, verify, iterate, and trust the answer.

Status

v0.7 — sixteen tools (fifteen plus the labwired_search_tools meta-tool), stdio transport, no auth required for local use (the simulator runs on your machine).

Shipped:

  • v0.1labwired_catalog / labwired_simulate / labwired_validate_system (raw chip + YAML workflow).
  • v0.2 — high-level board-centric workflow: labwired_list_boards / labwired_run_lab / labwired_inspect_run. ELF-in only — agents compile locally.
  • v0.3 — live agent → browser bridge: labwired_create_session / labwired_set_diagram / labwired_set_source / labwired_end_session. Runs stream over WebSocket to https://app.labwired.com/?watch=<id>.
  • v0.4labwired_validate_diagram with machine-readable diagnostics (pin/wire/bus errors + suggested fixes).
  • v0.5labwired_fuzz: coverage-guided firmware fuzzing in the silicon-validated sim; crashes are HIL-replayable, not emulation false positives.
  • v0.6labwired_define_component: agent-authored declarative IR specs for off-chip I2C devices; type: ir manifest integration; PCA9685 and TMP102 reference specs gated by byte-equivalence tests.
  • v0.7 — Wiring kernel: named nets, electrical rule checks (ERC), and ERC-gated diagram compilation on both MCP surfaces. labwired_validate_diagram upgraded with full kernel ERC (I2C bus rules, driver conflicts, voltage mismatches, IRQ ordinal validation). New labwired_compile_diagram compiles a diagram to a runnable board manifest with net-derived I2C bus binding.

Next:

  • v0.8 — Worker-side metering for hosted runs.

Issues / requests: https://github.com/w1ne/labwired/issues.

License

MIT.

FAQs

Package last updated on 05 Jul 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts