Let Claude Desktop control an ESP32 smart lamp through the DCP-to-MCP Bridge
Author a YAML intent manifest for a new sensor and flash a matching ESP32 firmware skeleton
Run the pydcp simulator to dry-run agent commands before pointing them at real hardware
Add CBOR-based agent control to an existing Arduino project under 14KB extra footprint
Full loop needs an ESP32 or ESP8266 board flashed with the DCP firmware plus the Python Bridge running with the right transport extra (serial, MQTT, or BLE).
DCP, short for Device Context Protocol, is a draft protocol that lets large language model agents send commands to physical devices like microcontrollers. The project is at draft v0.3 as of May 2026 and has been measured on an ESP32-WROOM-32 dev board. The author positions it as a companion to MCP, the Model Context Protocol used by Claude Desktop and other assistant tools. A reference Bridge converts between DCP and MCP, so any MCP-compatible assistant can drive a device with no extra setup. The problem the README describes: MCP works well for SaaS tools, but it expects JSON-RPC over WebSocket and runtime tool discovery, which is too heavy for a chip with only 32 KB of RAM. DCP keeps the same idea of a manifest plus tool calls, then compiles them into a compact CBOR wire format with a fixed intent table. A typical brightness command is about 19 bytes on the wire, versus around 180 bytes for the MCP equivalent. Safety lives in the Bridge process, not on the device. The Bridge issues capability tokens, checks parameter ranges, types, and units against the manifest, and supports dry-run as a first-class wire feature. Devices stay simple and trust the Bridge. The author argues this catches several classes of model hallucination or adversarial calls before any byte hits hardware. A manifest declares intents in YAML, for example a smart lamp with set_brightness, read_brightness, and a motion_detected event. Every parameter declares a unit and a range. The intent ID is a CRC-16 of the name, so manifests and firmware stay aligned without coordination. The firmware footprint is around 14 KB on top of an empty Arduino sketch, and the protocol layer compiles for every current ESP32 variant and ESP8266 without SoC-specific code paths. Installation for a user is pip install pydcp with optional MCP, serial, MQTT, and BLE transport extras. There is a CLI for inspecting a manifest and serving a simulator, recipes for ready-to-flash device skeletons, and a five-step guide for adding a new feature. The license is MIT.
Generated 2026-05-22 · Model: sonnet-4-6 · Verify against the repo before relying on details.