circuit-muse

agent
Security Audit
Fail
Health Warn
  • License — License: MIT
  • Description — Repository has a description
  • Active repo — Last push 0 days ago
  • Low visibility — Only 7 GitHub stars
Code Fail
  • network request — Outbound network request in app/package.json
  • new Function() — Dynamic code execution via Function constructor in app/scripts/generate-sitemap.mjs
  • exec() — Shell command execution in app/scripts/generate-sitemap.mjs
  • network request — Outbound network request in app/scripts/generate-sitemap.mjs
  • network request — Outbound network request in app/scripts/generate-sitemap.ts
  • exec() — Shell command execution in app/scripts/translate-i18n.mjs
  • process.env — Environment variable access in app/scripts/translate-i18n.mjs
  • network request — Outbound network request in app/scripts/translate-i18n.mjs
Permissions Pass
  • Permissions — No dangerous permissions requested

No AI report is available for this listing yet.

SUMMARY

AI-powered circuit simulator and embedded board emulator for desktop.

README.md

CircuitMuse

CircuitMuse

Design. Simulate. Code. Create.

Release License Build Status Platforms Version

AI-powered circuit simulator and embedded board emulator for desktop. Write Arduino C++ or MicroPython, compile it, simulate it with real CPU emulation and 150+ interactive electronic components — and chat with an AI to design circuits, debug code, and wire components.


What CircuitMuse Does

CircuitMuse is a desktop application that lets you:

  • Write code for microcontrollers (Arduino C++, MicroPython, ESP-IDF C)
  • Compile it automatically using bundled toolchains
  • Simulate it with real CPU emulation (not mocked — actual AVR, RP2040, ESP32, STM32, Raspberry Pi silicon)
  • Build circuits with 150+ electronic components on a drag-and-drop canvas
  • Chat with AI to design circuits, place components, wire them up, and debug code

Simulation and project data run locally on your machine. The desktop release includes the app, Python API engine, and Arduino CLI. Arduino board cores are fetched when first needed, and optional QEMU runtimes are downloaded when you first use those boards; AI providers that use cloud models also need internet.


Supported Boards

Board CPU Simulation Engine
Arduino Uno / Nano / Mega 2560 ATmega328p / ATmega2560 avr8js (in-browser)
ATtiny85 ATtiny85 avr8js (in-browser)
Raspberry Pi Pico / Pico W RP2040 rp2040js (in-browser)
ESP32 DevKit / CAM / Lolin32 Xtensa LX6 QEMU (bundled)
ESP32-S3 / XIAO ESP32-S3 Xtensa LX7 QEMU (bundled)
ESP32-C3 / SuperMini RISC-V RV32IMC QEMU (bundled)
STM32 Blue Pill / Nucleo ARM Cortex-M3 QEMU (bundled)
Raspberry Pi 3B / 4B / 5 ARM Cortex-A QEMU + Linux (bundled)

Supported platforms: Windows (x64), macOS (Apple Silicon), and Linux (x64: Debian/Ubuntu, Fedora, Arch, or AppImage).


Installation

Download

Get the latest release for your platform from GitHub Releases:

Platform Format Notes
Windows .msi or .exe Installer with start menu shortcut
macOS .dmg Drag to Applications folder
Linux (Ubuntu/Debian) .deb sudo dpkg -i circuit-muse_*.deb
Linux (Arch) .pkg.tar.zst sudo pacman -U circuit-muse-*.pkg.tar.zst
Linux (Fedora) .rpm Install the release RPM with Software or sudo dnf install ./circuit-muse-*.rpm
Linux (Universal) .AppImage chmod +x CircuitMuse_*.AppImage && ./CircuitMuse_*.AppImage

Linux graphics: CircuitMuse detects systems without a GPU render device and enables software rendering automatically. If your graphics driver still causes a white screen, launch with CIRCUIT_MUSE_SOFTWARE_RENDERING=1 ./CircuitMuse_*.AppImage. Set CIRCUIT_MUSE_HARDWARE_RENDERING=1 to override the automatic software fallback.

Linux runtime: The AppImage needs WebKit2GTK 4.1 and GTK 3 from the host system. The .deb and .rpm installers declare these system dependencies for the package manager.

First Launch

  1. Double-click the installer or AppImage
  2. You'll see the CircuitMuse splash screen with loading status
  3. The editor workspace opens directly — no landing page
  4. The setup wizard runs automatically on first launch, showing what's installed and what needs downloading

System Requirements

Component Required Auto-installed
Node.js 20+ Build only No
Python 3.12+ Source builds only Bundled engine in releases
arduino-cli 1.5+ Compilation Yes, bundled
ESP-IDF (optional) ESP32 advanced builds No
Ollama (optional) Local AI agent No

Building from Source

Prerequisites

  • Node.js 20+
  • Python 3.12+
  • Rust (stable)
  • Platform-specific dependencies (see below)

Linux (Ubuntu/Debian)

sudo apt install -y \
  libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev \
  patchelf libssl-dev libgtk-3-dev libsoup-3.0-dev \
  libjavascriptcoregtk-4.1-dev libudev-dev

Linux (Arch)

sudo pacman -S webkit2gtk-4.1 appmenu-gtk-module libappindicator-gtk3 \
  librsvg patchelf openssl gtk3 libsoup3

Linux (Fedora)

sudo dnf install -y gcc webkit2gtk4.1-devel gtk3-devel libsoup3-devel \
  patchelf openssl-devel

macOS

xcode-select --install

Windows

Install Visual Studio Build Tools with "Desktop development with C++" workload.

Build Steps

git clone https://github.com/meshackbahati/circuit-muse.git
cd circuit-muse

# Install app dependencies
cd app && npm install && cd ..

# Install engine dependencies
cd engine && python -m venv venv && source venv/bin/activate
pip install -r requirements.txt && cd ..

# Download arduino-cli (for compilation)
bash scripts/download-deps.sh

# Package the API engine as the platform-specific Tauri sidecar
bash scripts/build-engine.sh

# Install Tauri CLI
cargo install tauri-cli --version "^2"

# Run the desktop app in development mode (starts Vite and the engine)
cd src-tauri && cargo tauri dev

The app opens with the editor workspace ready to use.

Building Release Packages

cd src-tauri
cargo tauri build

Output: src-tauri/target/release/bundle/ contains platform-specific installers.


AI Agent

The built-in AI agent lets you design circuits using natural language.

Setup

  1. Open the AI Agent panel from the toolbar (hamburger menu or Agent button)
  2. Click the gear icon to open settings
  3. Configure a provider:
Provider Setup
Ollama (recommended for offline) Install Ollama, run ollama pull llama3 — no API key needed
OpenAI Paste API key from platform.openai.com
Anthropic Paste API key from console.anthropic.com
Google Gemini Paste API key from aistudio.google.com
OpenRouter Paste API key from openrouter.ai
Custom Any OpenAI-compatible endpoint (LM Studio, vLLM, etc.)

What the AI Can Do

  • Add boards to the canvas
  • Add electronic components (LEDs, resistors, sensors, displays)
  • Wire components together
  • Write Arduino C++ or MicroPython code
  • Compile and run simulations
  • Debug compilation errors

Example prompts:

  • "Add an Arduino Uno and wire an LED to pin 13"
  • "Create a temperature sensor circuit with DHT22 and LCD display"
  • "Write a blink sketch for the ESP32"

Project Persistence

Auto-Save

Projects automatically save to IndexedDB every few seconds. Close and reopen the app — your work is still there.

Creating Projects

Click the Projects button in the toolbar to:

  • Create a new empty project
  • Open an existing saved project
  • Delete old projects

Import/Export

Import formats:

  • .vlx — CircuitMuse native format
  • .zip — Wokwi-compatible (diagram.json + code)
  • .fzz — Fritzing projects
  • .json — Raw project data

Export formats:

  • .vlx — Full project snapshot
  • .zip — Wokwi-compatible bundle
  • .json — Raw data
  • .html — Shareable report with boards, components, and code

Component System

150+ electronic components across categories:

  • Passive: Resistors, capacitors, inductors, potentiometers
  • Active: Transistors (NPN, PNP, MOSFET), op-amps, voltage regulators
  • Output: LEDs, NeoPixels, buzzers, servos, motors, relays
  • Input: Pushbuttons, switches, encoders, joysticks
  • Sensors: DHT22, HC-SR04, BMP280, MPU6050, photoresistors
  • Displays: LCD1602, SSD1306 OLED, ePaper, 7-segment, LED bar
  • Logic: AND, OR, NOT, NAND, NOR, XOR gates, flip-flops, shift registers
  • Communication: I2C, SPI devices (24LC256, MCP3008, DS3231)

Electrical Simulation

  • ngspice-WASM — real SPICE analog simulation in the browser
  • Mixed-mode — digital MCU + analog circuits simulated together
  • Instruments: Voltmeter, ammeter, oscilloscope, function generator
  • 44+ SPICE component models

Serial Monitor

  • Live serial output from simulated boards
  • Auto baud-rate detection
  • Send data to RX pin
  • Multi-UART support on ESP32

Project Structure

circuit-muse/
├── app/                     # Application layer (React + Vite + TypeScript)
│   ├── src/agent/           # AI agent (providers, tools, chat UI)
│   ├── src/components/      # Editor, simulator canvas, modals
│   ├── src/simulation/      # CPU emulation bridges
│   ├── src/store/           # Zustand state stores
│   ├── src/services/        # API clients, project persistence
│   └── src/desktop/         # Tauri desktop integration
├── engine/                  # Simulation engine (FastAPI + Python)
│   └── app/api/routes/      # compile, agent, libraries, simulation
├── src-tauri/               # Desktop shell (Rust + Tauri)
│   ├── src/commands/        # Serial, debug, QEMU commands
│   └── icons/               # App icons
└── scripts/                 # Build helpers

Troubleshooting

App shows white screen on Linux

The app uses software rendering for compatibility. If you still see issues:

# Force software rendering if automatic detection does not resolve the issue
CIRCUIT_MUSE_SOFTWARE_RENDERING=1 ./CircuitMuse_*.AppImage

"arduino-cli not found"

Run the setup wizard (gear icon in toolbar) or manually install:

bash scripts/download-deps.sh

Engine not starting

The Python engine auto-starts on launch. If it fails:

  1. Check Python 3.12+ is installed
  2. Run cd engine && pip install -r requirements.txt
  3. Restart the app

QEMU boards not working

ESP32/STM32/Raspberry Pi boards need QEMU runtimes. The app auto-downloads them on first use via the setup wizard.


License

MIT License


Author

Meshack Bahati Ouma


Acknowledgments

Based on Velxio by David Montero Crespo. Built on avr8js, rp2040js, wokwi-elements, ngspice-wasm, lcgamboa/qemu, Espressif QEMU, Tauri, and Monaco Editor.

Reviews (0)

No results found