RespCode Documentation
Multi-model AI code generation with real hardware verification.
RespCode orchestrates multiple AI models (Claude, GPT, DeepSeek, Gemini, and more) to generate, compile, and verify code across multiple architectures β x86, ARM64, and ARM32 baremetal β using Daytona sandboxes and Firecracker microVMs.
Hardware Agent
CLI tool that generates code, compiles in the cloud, and deploys to real hardware β MCUs, SBCs, or your local machine.
Web Platform
Browser-based multi-model code generation with real-time streaming and sandbox execution. Free & unlimited.
VS Code Extension
Generate and compare multi-model code directly from your editor. Coming Soon
MCP Server
Connect RespCode to Claude Desktop, Cursor, and other MCP-compatible clients. Coming Soon
Quick Start
Hardware Agent (recommended for embedded development)
Web Platform
Visit respcode.com, sign up, and start generating code immediately in your browser. The web platform is free with unlimited generations.
Hardware Agent
Generate code in the cloud. Deploy and verify on real hardware.
The RespCode Hardware Agent is a CLI tool that connects your physical development boards to the RespCode cloud. It generates code using AI models, compiles in sandboxes, then deploys the binary to your actual hardware β STM32, NXP, Nordic, Pico, TI, Microchip and other ARM development boards via pyOCD/UF2, Linux Single Board computer via SSH, test Cloud instances or your local machine directly.
You type a prompt β cloud generates + compiles β agent downloads binary β flashes/deploys to your board β reads UART/stdout output β shows pass/fail. All from one command.
Installation
One-line install (Linux & macOS)
This will:
- Detect your OS and CPU architecture (x86 or ARM64)
- Download the correct binary to
~/.local/bin/ - Add it to your
PATH - Create a default config at
~/.config/respcode/boards.yaml - Linux only: install udev rules for USB debug probes (ST-Link, CMSIS-DAP, J-Link, NXP)
- Linux only: add your user to
dialoutandplugdevgroups - Scan USB for connected development boards (Linux via sysfs, macOS via system_profiler)
- Auto-detect STM32, NXP, Nordic, Pico, TI, Microchip, and J-Link debug probes
- Install pyOCD target packs for detected MCUs
Supported platforms
| OS | Architecture | Binary |
|---|---|---|
| Linux | x86_64 | respcode-agent-linux-amd64 |
| Linux | ARM64 | respcode-agent-linux-arm64 |
| macOS | Apple Silicon | respcode-agent-darwin-arm64 |
| macOS | Intel | respcode-agent-darwin-amd64 |
Manual install
Verify installation
First Run & API Key
When you first run the agent, it will show the board picker and prompt for your API key:
The agent runs without a key β you can browse boards, check hardware, run /boards for examples. You only need the key when generating code.
Get your API key at: respcode.com/settings/api-keys
Configuration
The agent reads its configuration from boards.yaml. It searches these locations in order:
- Explicit
--config path/to/boards.yamlflag - Current working directory:
./boards.yaml - XDG config:
~/.config/respcode/boards.yaml - Same directory as the binary
The install script creates the default config at ~/.config/respcode/boards.yaml:
respcode: api_url: "https://respcode.com/api" api_key: "${RESPCODE_API_KEY}" # set via /key command or env var agent: max_retries: 3 # retry attempts on failure uart_timeout_seconds: 10 flash_timeout_seconds: 30 output_dir: "respcode-output" # where artifacts are saved boards: - id: "local" type: "sbc" board_name: "Local Machine" architecture: "x86" # auto-detected during install connection: "localhost" verify: timeout: 30
Adding Boards
Add boards by editing boards.yaml or using the /boards commands inside the agent. The agent supports three board types and auto-detects USB boards on every startup.
Baremetal MCU (Flash + UART)
For microcontrollers like STM32, NXP and other ARM baremetal MCU using pyOCD. The agent first compiles the binary in cloud, verifies there are no errors and later uses pyOCD to flash firmware and reads UART output for verification.
- id: "nucleo-f767zi" type: "bare-metal" mcu: "STM32F767ZI" board_name: "NUCLEO-F767ZI" architecture: "arm32-baremetal" flash: tool: "pyocd" target: "stm32f767zi" # pyocd target name address: "0x08000000" # flash start address interface: "stlink" # stlink, cmsis-dap, jlink speed_khz: 4000 uart: port: "/dev/ttyACM0" # ls /dev/ttyACM* to find yours baud: 115200 board_info: led_pin: "PB0" led_active: "high" uart_pins: "PD8 (TX) / PD9 (RX) on USART3" clock: "216MHz HSE" ram: "512KB @ 0x20000000" flash_size: "2MB"
Linux: Run ls /dev/ttyACM* or ls /dev/ttyUSB*. macOS: Run ls /dev/cu.usbmodem*. Or use the ports command inside the agent.
Required fields for baremetal:
| Field | Description | Example |
|---|---|---|
type | Must be "bare-metal" | bare-metal |
mcu | MCU part number (used in prompt enrichment) | STM32F767ZI |
architecture | arm32-baremetal | arm32-baremetal |
flash.tool | pyocd, uf2, or openocd | pyocd |
flash.target | pyOCD target ID | stm32f767zi |
uart.port | Serial port path | /dev/ttyACM0 |
board_info.led_pin | LED pin name (for prompts) | PB0 |
board_info.uart_pins | UART pin description (for prompts) | PD8/PD9 on USART3 |
SBC via SSH
For single-board computers like Raspberry Pi, Jetson, BeagleBone, or any Linux machine reachable via SSH. Code is first compiled and executed in the cloud sandbox, then SCP'd to the target and executed via SSH. Use /boards ssh in the agent for an interactive setup wizard with presets for common boards.
- id: "rpi4" type: "sbc" board_name: "Raspberry Pi 4" architecture: "arm64" # or "arm32" for 32-bit OS ssh: host: "192.168.1.50" user: "pi" key: "~/.ssh/id_rsa" # path to private key port: 22 verify: timeout: 10 # execution timeout in seconds expect: "" # optional: expected output pattern
Localhost
Run code directly on your local machine without SSH. Code is compiled in the cloud, downloaded, and executed locally. Great for quick testing.
- id: "local" type: "sbc" board_name: "Local Machine" architecture: "x86" # or "arm64" on Apple Silicon / ARM Linux connection: "localhost" verify: timeout: 30
Set architecture to match your machine. Use "x86" for Intel/AMD, "arm64" for Apple Silicon or ARM Linux. The install script auto-detects this.
Raspberry Pi Pico (UF2)
For RP2040-based boards that flash via UF2 mass storage. Hold BOOTSEL while plugging in β the board mounts as a USB drive, and the agent copies the UF2 binary directly.
- id: "rpi-pico" type: "bare-metal" mcu: "RP2040" board_name: "Raspberry Pi Pico" architecture: "arm32" flash: tool: "uf2" mount: "/Volumes/RPI-RP2" # macOS β use /mnt/rpi-rp2 on Linux uart: port: "/dev/cu.usbmodem1101" # CDC USB serial baud: 115200 board_info: led_pin: "GPIO25" led_active: "high" uart_pins: "UART0 on GP0 (TX) / GP1 (RX)" clock: "125MHz from XOSC 12MHz + PLL" ram: "264KB @ 0x20000000" flash_size: "2MB @ 0x10000000"
Nordic nRF (pyOCD)
For Nordic nRF52/nRF53 development kits with on-board J-Link or CMSIS-DAP debug probe.
- id: "nrf52840" type: "bare-metal" mcu: "NRF52840" board_name: "nRF52840-DK" architecture: "arm32-baremetal" flash: tool: "pyocd" target: "nrf52840" address: "0x00000000" interface: "cmsis-dap" uart: port: "/dev/ttyACM0" baud: 115200
Auto-Detection
The agent automatically detects new USB boards every time it starts. If you plug in a board after installation, just restart the agent β it will find the board, add it to boards.yaml, and install the required pyOCD target pack.
Supported debug probes (auto-detected on Linux & macOS)
| Board Family | USB Vendor ID | Flash Tool | Examples |
|---|---|---|---|
| STM32 | 0x0483 | pyOCD (ST-Link) | Nucleo-F767ZI, Discovery, Nucleo-F411RE |
| NXP LPC | 0x1fc9 | pyOCD (CMSIS-DAP) | LPC55S69-EVK, LPCXpresso |
| CMSIS-DAP | 0x0d28 | pyOCD | mbed-enabled boards |
| Raspberry Pi Pico | 0x2e8a | UF2 copy | Pico, Pico W, Pico 2 |
| Nordic nRF | 0x1915 | pyOCD | nRF52840-DK, nRF5340-DK |
| TI | 0x0451 | OpenOCD | MSP432, CC3220, TM4C |
| SEGGER J-Link | 0x1366 | J-Link | Any J-Link connected target |
| Microchip / Atmel | 0x03eb | OpenOCD | SAM, PIC32 |
On macOS, serial ports appear as /dev/cu.usbmodemXXXX instead of /dev/ttyACM0 on Linux. The agent detects this automatically. Use the ports command inside the agent to list available ports.
Adding SBC targets interactively
For SSH-based boards (Raspberry Pi, Jetson, BeagleBone, cloud instances), use the built-in wizard:
The wizard prefills board name, architecture, and SSH username from the preset. You only need to enter the IP address and SSH key path. It also tests the connection and auto-detects the remote architecture via uname -m.
Modes & Tiers
After connecting, select your mode and tier at the prompt. Use shortcodes like C1, S2, C4:
| Shortcode | Mode | Tier | Credits | Models |
|---|---|---|---|---|
C1 | Compete | Flagship | 29 | Claude Opus, GPT-5, Gemini 3 Pro, DeepSeek Coder |
C2 | Compete | Mid | 17 | Claude Sonnet, GPT-4o, Gemini Flash, DeepSeek V3 |
C3 | Compete | Budget | 6 | Claude Haiku, GPT-4o Mini, Gemini Flash |
C4 | Compete | Open Source | 8 | Llama 4, Qwen 3, DeepSeek, Mistral |
S1 | Single | Flagship | varies | Pick one model from flagship tier |
Change mode anytime with /mode.
Commands Reference
| Command | Description |
|---|---|
<any prompt> | Generate code, compile, and deploy |
rerun | Re-run the last prompt (new generation) |
| Hardware | |
flash <path> | Flash a local .bin file and verify via UART |
reflash | Re-download and flash the last successful generation |
uart | Listen on UART (no flash) |
probe | Check if target is connected |
ports | List available serial ports |
| Cloud | |
download <gen_id> | Download all artifacts for a generation |
status | Show board + cloud status |
| Session | |
/key | Set or change your API key |
/mode | Change mode (compete/single) and tier |
/board | Switch to a different board |
/boards | List configured boards and management commands |
/boards ssh | Interactive wizard to add SBC targets (Pi, Jetson, BeagleBone...) |
/boards add | Add a board interactively |
/boards probe | Auto-detect MCU via pyOCD and update config |
/boards remove N | Remove board #N from config |
results | Show compile results from last generation |
history | Show last prompt and generation info |
help | Show all commands |
quit | Exit the agent |
Workflow
Here's what happens when you type a prompt:
The 3-attempt retry system:
- Attempt 1: Normal compete/single generation
- Attempt 2: If all models fail β Claude Sonnet reviews the errors and generates a fix
- Attempt 3: If still failing β Claude Opus escalation with full error context
Deploy & Verify
Baremetal flow
For type: "bare-metal" boards:
- Code compiles in cloud sandbox (Docker + QEMU verification)
- Binary downloads to agent
- pyOCD flashes to board memory
- UART monitored for output
- Output compared against expected pattern
SBC / SSH flow
For type: "sbc" boards with SSH:
- Code compiles + runs in cloud sandbox
- If sandbox passes β binary SCP'd to target
- SSH executes binary on target
- stdout captured for verification
Localhost flow
For connection: "localhost":
- Code compiles + runs in cloud sandbox
- Binary downloaded to
~/respcode-deploy/ - Executed directly on local machine
- stdout captured for verification
The agent auto-detects the file type and uses the right interpreter: .py β python3, .js β node, .rb β ruby, ELF β direct execution.
Auto-Update
On every startup, the agent checks https://respcode.com/agent/version.json for new versions. If a newer version is available, it downloads, verifies the SHA-256 checksum, replaces itself, and exits with a "please restart" message.
To manually update:
Troubleshooting
pyOCD not detecting my board
- Run
probein the agent to check connection - Run
portsto list serial ports - Ensure udev rules are installed (Linux):
ls /etc/udev/rules.d/99-respcode.rules - Check group membership (Linux):
groupsβ should includedialoutandplugdev - Unplug and replug your board
SSH connection fails
- Verify SSH manually:
ssh -i ~/.ssh/key user@host echo ok - Check that
ssh.keypath is correct and readable - Ensure the target is on the same network
Compilation fails in sandbox
- Check
resultsfor detailed error output - The agent retries up to 3 times with escalating model intelligence
- Try rephrasing your prompt with more specific requirements
macOS Gatekeeper warning
"Permission denied" on serial port (Linux)
macOS: pyOCD not found after install
On macOS, pip install places binaries in ~/Library/Python/3.XX/bin/ which may not be in your PATH. The agent searches common locations automatically, but if you need to run pyOCD manually:
macOS: boards.yaml not created during install
If the install script fails to create the config file, the agent will auto-create a default one on first run with a localhost target. To add boards afterwards, use /boards ssh or /boards add inside the agent.
macOS: Board not detected during install
Ensure your board is plugged in before running the install script. The installer uses system_profiler SPUSBDataType to detect debug probes on macOS. If you plug in the board after installing, just restart the agent β it auto-detects new boards on every startup.
Agent shows "Plan: β" (empty)
This happens when the plan field hasn't been set for your user account on the server. Contact support or check that the server migration has been applied. The agent still works normally β this is a display-only issue.
Uninstall the agent
Full troubleshooting guide and FAQs: respcode.com/docs#agent-troubleshooting
Examples
Example 1: Bare-metal Ethernet UDP on STM32F767ZI
Flagship Compete mode generating bare-metal Ethernet firmware. 4 models attempt to write a UDP sender using the LAN8742A PHY over RMII β direct register access, no HAL. Claude Opus compiles and sends real UDP packets on the wire.
This is a hard prompt β bare-metal Ethernet with RMII PHY initialization, MAC DMA descriptors, ARP handling, and UDP packet construction, all without any SDK. Only Claude Opus and Gemini compiled. Claude's firmware sent real UDP packets on the wire at 192.168.0.175:9000 and responded to ARP requests β verified via UART output on the Nucleo-F767ZI board.
Example 2: Memory bandwidth test on ARM64 cloud instance
Running 4 open-source models in Compete mode on a remote ARM64 instance via SSH. Each model generates a C program that measures memcpy bandwidth on a 64MB buffer.
All 4 open-source models compiled successfully in the cloud sandbox. After deploying to real ARM64 hardware, the results diverged β Llama had a timer bug (negative bandwidth), while DeepSeek produced the most detailed and accurate output. This is exactly why multi-model comparison matters.
Example 3: Baremetal LED blink and UART initialization on NXP LPC55S69-EVK
Compete mode with 4 models generating bare-metal firmware. The agent enriches the prompt with register-level SVD data (5 peripherals, 227 registers, 64 pins) for the LPC55S69 MCU β ensuring models use correct register addresses instead of guessing.
Example 4: Hello World locally on x86
The simplest test β generate a C program and run it directly on your machine. No hardware needed.
Web Platform
Browser-based multi-model code generation and verification. Free & unlimited.
The web platform at respcode.com provides the full RespCode experience in your browser β write prompts, select AI models, choose an architecture, and watch code generate in real time with sandbox verification. The web IDE is completely free with unlimited generations.
Orchestration Modes
RespCode offers three ways to orchestrate AI models:
βοΈ Compete
Run 2β5 models in parallel. Compare outputs side-by-side. Each gets independent sandbox verification. Best for: exploring different approaches.
π Collaborate
Chain models sequentially β each refines the previous output. Best for: complex projects needing iterative improvement.
β Consensus
Models vote on the best approach, then a merger model synthesizes the final solution. Best for: production and safety-critical code.
Supported Architectures
| Architecture | Toolchain | Sandbox | Use Case |
|---|---|---|---|
| x86_64 | GCC 13, Clang 17 | Daytona | Desktop, server, algorithms |
| ARM64 (AArch64) | aarch64-linux-gnu-gcc | Firecracker on Graviton | Apple Silicon, Raspberry Pi, cloud instances |
| ARM32 (ARMv7) | arm-linux-gnueabihf-gcc | Firecracker (AArch32 mode) | Embedded Linux, 32-bit SBCs |
| ARM32 Baremetal | arm-none-eabi-gcc + QEMU | Docker + QEMU emulation | STM32, NXP, Nordic nRF, RP2040, TI firmware |
| RISC-V Coming Soon | riscv64-linux-gnu-gcc | β | Open ISA development (temporarily disabled) |
| FPGA / HDL Coming Soon | Icarus Verilog, Verilator | β | Verilog, VHDL design (temporarily disabled) |
| Python | Python 3.11 | Sandboxed interpreter | Scripts, automation, ML |
AI Models
11 models available from 5 providers:
| Provider | Models |
|---|---|
| Anthropic | claude-opus-4-6, claude-sonnet-4-6, claude-haiku-4-5 |
| OpenAI | gpt-5-2, gpt-4o-mini |
| DeepSeek | deepseek-v3, deepseek-coder |
gemini-3-pro, gemini-2-flash | |
| Open Source | llama-4-maverick, qwen-3-32b |
Sandbox Execution
Every code generation is compiled and executed in an isolated sandbox. ARM code runs in Firecracker microVMs on Graviton instances; x86 code runs in Daytona containers. The sandbox provides:
- Isolation β each execution runs in its own sandbox, destroyed after completion
- Real hardware β ARM64 code runs on actual Graviton instances, not emulators
- Exit code + stdout β pass/fail verification with full output capture
- Time limits β 30-second default timeout prevents infinite loops
- Artifact storage β compiled binaries (.elf, .bin) stored for agent download and deployment
VS Code Extension
Multi-model code generation directly in your editor. Coming Soon
The VS Code extension is currently in development. It will allow you to select models, generate code, compare outputs, and run sandbox verification β all from within VS Code.
Planned features:
- Inline multi-model code generation
- Side-by-side diff of model outputs
- Sandbox verification results in the editor
- Board selection and deployment from VS Code
MCP Server
Connect RespCode to Claude Desktop, Cursor, and MCP clients. Coming Soon
The MCP (Model Context Protocol) server will expose RespCode's multi-model generation and sandbox verification as tools that Claude Desktop, Cursor, and other MCP-compatible AI clients can invoke.
Planned tools:
generate_codeβ trigger multi-model generation with architecture targetingrun_sandboxβ compile and execute code in Firecracker microVMslist_modelsβ query available models and presetsdeploy_to_boardβ flash firmware to connected hardware
API Reference
The RespCode API powers all clients (web, agent, VS Code, MCP). Base URL: https://respcode.com/api
| Endpoint | Method | Description |
|---|---|---|
/user | GET | Get user info, plan, credits |
/generate | POST (SSE) | Stream multi-model code generation |
/artifacts/{gen_id} | GET | List compiled artifacts |
/artifacts/{gen_id}/{art_id}/download | GET | Download binary artifact |
/agent/version.json | GET | Check for agent updates |
All endpoints require Authorization: Bearer <api_key> header (except version check).
Credits & Pricing
| Tier | Credits per generation | Models included |
|---|---|---|
| Flagship | 29 | Claude Opus, GPT-5, Gemini 3 Pro, DeepSeek Coder |
| Mid | 17 | Claude Sonnet, GPT-4o, Gemini Flash, DeepSeek V3 |
| Open Source | 8 | Llama 4, Qwen 3, DeepSeek, Mistral |
| Budget | 6 | Claude Haiku, GPT-4o Mini, Gemini Flash |
Web platform is free with unlimited generations. Agent & API users get 500 free credits. Upgrade to Pro (29/mo) or Max ($49/mo) for more.