Skip to main content

MCP server for embedded device debugging — connect, control, and debug hardware via Serial/Telnet/SSH through LLM agents

Project description

EmbPilot

Embedded device debugging via the Pilot (MCP) protocol.

EmbPilot is an MCP (Model Context Protocol) server that lets LLM agents connect to, control, and debug physical embedded devices over Serial, Telnet, or SSH.

Features

  • Connect to devices via Serial UART, Telnet, or SSH
  • Send commands and capture output with regular-expression interception (Expect)
  • Reset targets by issuing a reboot to the connected device
  • Expose active-session resources through MCP, including device://live_log and device://session_info
  • Persist sessions in SQLite (WAL mode) for RAG-backed historical search
  • Search and export recorded sessions (by session id, keyword, or full export)
  • Local vector search (fastembed + LanceDB) over Datasheets, Error Code manuals, and KB articles
  • Analyse crash logs and run hardware sanity checks with guided prompts

Quick Start

pip install embpilot        # core: Serial/Telnet/SSH MCP server
pip install embpilot[rag]   # + optional local RAG (fastembed + LanceDB)
embpilot

See embpilot --help for available options, or run embpilot doctor for environment diagnostics (Python, core/RAG deps, drivers, storage, serial ports).

Current resource direction:

  • device://live_log exposes the active session's recent log snapshot and is the resource URI used for live-log subscriptions.
  • device://session_info exposes honest session metadata for the current connection instead of pretending EmbPilot can issue one generic sysinfo probe across all targets.

Project Status

Alpha — active development.

Architecture

src/embpilot/
├── __main__.py        # Python module entry point
├── cli.py             # CLI argument parsing and startup wiring
├── mcp_app.py         # MCP app assembly and stdio server runner
├── config.py          # Configuration (XDG paths, framing timeout, retention)
├── server.py          # Compatibility wrapper over the new MCP runner
├── runtime/
│   ├── __init__.py
│   ├── models.py      # SessionInfo plus canonical log/ring exports
│   ├── pipeline.py    # Dispatcher-based log fan-out and framing
│   ├── expect.py      # Command windows and expect matching
│   ├── resources.py   # device://live_log and device://session_info payloads
│   └── session.py     # Session lifecycle and active connection state
├── core/
│   ├── engine.py      # Canonical LogLine/RingBuffer types
│   ├── database.py    # SQLite WAL layer and schema loading
│   ├── rag.py         # fastembed + LanceDB vector search
│   ├── schema_main.sql
│   └── schema_session.sql
└── drivers/
    ├── base.py        # Abstract device interface
    ├── serial_dev.py  # pyserial-asyncio
    ├── telnet_dev.py  # telnetlib3
    └── ssh_dev.py     # asyncssh
  • mcp_app.py owns MCP protocol registration and delegates runtime behavior to the runtime/ package.
  • runtime/pipeline.py now uses explicit dispatcher fan-out instead of the old implicit multi-consumer queue description.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

embpilot-0.1.0-py3-none-any.whl (34.5 kB view details)

Uploaded Python 3

File details

Details for the file embpilot-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: embpilot-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 34.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for embpilot-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 608d45042bce8d8c5f487b842325ea2ab9ec13a80db5853ee63a3748d25b31bc
MD5 920a038e7471a044c5140edc6681d172
BLAKE2b-256 49ea120e82e189a1cd21de9962c847f2e69d3116d2c40ccc6f356196c04ae5a6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page