Inspiration
Circuit design tools are built around manual interaction. You place components, connect wires, inspect the circuit, run a simulation, then write firmware separately. We wanted to explore what happens when an AI agent can operate the circuit environment itself. Circuit Co-Pilot was built around one question: What if you could describe the hardware you want, and an AI agent could build, test, and prepare it for deployment? That led us to build a circuit canvas where the agent can interact with the same live circuit state that the user sees.
What it does
Circuit Co-Pilot is an agent-ready circuit design and IoT prototyping environment. An AI agent can use WebMCP tools to:
- Place circuit components on the canvas
- Connect component pins
- Run digital logic simulations
- Export Arduino and ESP32-oriented firmware The application exposes four core tools: placeComponent connectPins runLogicSimulation exportFirmware The agent can therefore go from a natural-language hardware request to a working circuit. For example, in our demo, the agent starts from a blank canvas and builds a 1-bit half adder using DIP switches, a 7486 XOR gate, a 7408 AND gate, and two LEDs. It then runs all four possible input combinations and verifies the expected Sum and Carry outputs before exporting firmware. The application also includes live signal propagation, interactive components, circuit presets, firmware generation, Boolean equations, and an Agent Activity Console that displays WebMCP calls, latency, payloads, and results.
How we built it
We built Circuit Co-Pilot with:
- Next.js
- React
- TypeScript
- React Flow
- WebMCP
- WebMCP SDK The circuit is represented as a live graph of components, pins, connections, and signal states. The WebMCP layer exposes operations against that graph. This means the agent isn't interacting with a separate mock representation. Its actions modify the same circuit state rendered on the canvas. The logic simulator evaluates the graph and propagates HIGH, LOW, and unknown states through gates and connected components. The firmware compiler then uses that same graph to generate Arduino-style C++ with pin mappings, logic equations, sensor handling, and board-specific configuration. We also added telemetry around every WebMCP operation so agent actions can be observed directly inside the application.
Challenges we ran into
The hardest challenge was keeping the AI agent's actions synchronized with React's asynchronous state updates. When an agent places a component and immediately tries to connect it, normal React state could still contain the previous circuit state. We solved this by maintaining synchronized nodesRef and edgesRef representations alongside the React state. Tool operations update these references immediately before updating the UI state. We also encountered firmware-generation issues involving variable collisions and ultrasonic sensor alarm state. Multiple sensors could previously generate conflicting C++ identifiers. We changed the generator to create sensor-specific alarm variables and combine them correctly when multiple sensors are present. Another challenge was WebMCP compatibility. The SDK version we used has restrictions around tool naming, while the canonical tool interface uses camelCase names. We implemented the native WebMCP registration separately while maintaining SDK compatibility.
Accomplishments that we're proud of
The biggest accomplishment is that the complete agent workflow works on the deployed application. An AI agent successfully started from a blank canvas and:
- Created the required components
- Connected the circuit
- Ran the simulation
- Tested all four half-adder input combinations
- Verified the resulting outputs
- Exported the firmware The resulting truth table was: A B | Sum | Carry 0 0 | 0 | 0 0 1 | 1 | 0 1 0 | 1 | 0 1 1 | 0 | 1 The generated firmware also produced the expected equations: Sum = A ^ B; Carry = A && B; We are also proud that the circuit, simulation, agent tools, telemetry, and firmware compiler all operate on the same underlying circuit state. What we learned We learned that making an application agent-ready requires more than exposing a few functions. The tools need clear contracts, validation, predictable errors, and reliable state synchronization. We also learned that an agent needs meaningful feedback from the environment. The Agent Activity Console helped us make tool execution observable instead of treating the agent as a black box. Most importantly, we learned that circuit design can become an agent interaction problem rather than only a graphical editing problem. What's next for Circuit Co-Pilot We want to expand Circuit Co-Pilot from a digital circuit prototype into a broader AI hardware development environment.
Next steps include:
- More sensors and actuators
- PWM and analog simulation
- More microcontroller boards
- I2C, SPI, and UART components
- More complete firmware generation
- Hardware validation and pin-conflict detection
- Persistent projects
- Circuit debugging through natural language
- Agent-generated explanations of circuit behavior
- Hardware-in-the-loop testing The long-term goal is simple: You describe the hardware behavior you want. Circuit Co-Pilot helps build it, verifies it, and produces the firmware needed to run it.
Built With
- ai
- css
- iot
- javascript
- mcp
- typescript
Log in or sign up for Devpost to join the conversation.