Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>Arduino to Codespaces BridgeNew to Visual Studio Code? Get it now.
Arduino to Codespaces Bridge

Arduino to Codespaces Bridge

Ben Jones

|
2 installs
| (0) | Free
Compile and upload Arduino sketches from GitHub Codespaces to physical boards via Web Serial
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Arduino to Codespaces Bridge

Develop on the Cloud, Deploy to the Edge.

Arduino to Codespaces Bridge enables a seamless workflow for developing Arduino projects inside GitHub Codespaces while interacting with physical hardware connected to your local computer.


🚀 Features

🌉 Cloud-to-Local Bridge (Main Feature)

The missing link for cloud development. This extension solves the primary challenge of using GitHub Codespaces for embedded development: connecting to local hardware.

  • Remote Compilation: Code is compiled in the high-performance cloud environment.
  • Local Flashing: The compiled binary is streamed securely to your local browser and flashed to the USB-connected Arduino via the Web Serial API.
  • Zero Local Setup: You do not need to install Arduino IDE, drivers, or CLI tools on your local machine.

🤝 Collaborative Environment Sync

Perfect for teams and classrooms. The extension maintains a consistent development environment using arduino-requirements.txt.

  • State Management: Defines exactly which libraries and board cores are required.
  • Auto-Install: When a collaborator opens the Codespace, the bridge automatically installs the correct dependencies.
  • Reproducibility: Eliminates "missing library" errors and version conflicts.

🎨 Optimized C/C++ Formatting

Includes a pre-configured Clang-Format style optimized for Arduino sketches.

  • Auto-Formatting: Automatically formats your .ino and .cpp files on save.
  • Standard Style: Enforces the official Arduino coding style guide for clean, readable code.

📝 Professional Serial Monitor

A full-featured terminal for viewing serial output. Supports:

  • ANSI color codes
  • Auto-scrolling
  • Timestamping
  • Multiple baud rates
  • Line ending configuration (CR, LF, CRLF)

📊 Real-time Serial Plotter

Visualize sensor data instantly. Compatible with the standard Arduino Serial Plotter format.

  • Multi-variable plotting
  • Auto-scaling axes
  • Freeze/Resume support
  • CSV export

📋 Requirements

  1. GitHub Codespaces: This extension is designed to run in a remote Codespace environment.
  2. Web Browser: A browser that supports the Web Serial API (Chrome, Edge, Opera). Firefox and Safari are not currently supported.
  3. Physical Hardware: An Arduino or compatible microcontroller connected via USB to your local machine.

🏃‍♂️ Quick Start

  1. Open in Codespaces: Open your Arduino project repository in GitHub Codespaces.
  2. Connect Hardware: Plug your Arduino into your local computer.
  3. Open Bridge: Click the "Arduino to Codespaces Bridge" icon in the Activity Bar or Status Bar.
  4. Connect Port: In the browser window that opens, click "Connect Port" and select your device.
  5. Compile & Upload: Select your sketch and click "Compile & Upload".

⚙️ Configuration

arduino-requirements.txt

Create this file in your workspace root to define your environment. The extension will automatically install these dependencies.

# Board Platforms
platform arduino:avr 1.8.6
platform esp32:esp32 2.0.11

# Libraries
library ArduinoJson 6.21.3
library "Adafruit NeoPixel" 1.11.0

Extension Settings

Setting Default Description
arduinoBridge.serverPort 3000 Local port for the bridge server.
arduinoBridge.autoStartServer true Start server automatically when opening .ino files.
arduinoBridge.defaultBoard arduino:avr:uno Default FQBN to use if none selected.
arduinoBridge.showStatusBar true Toggle the status bar item.

🧩 Supported Hardware

The extension leverages arduino-cli, making it compatible with virtually any Arduino-compatible board that supports the Arduino framework.

Tested & Verified Boards

These boards have been explicitly tested with the Web Serial upload workflow:

  • Arduino AVR Boards
    • Arduino Uno (R3)
    • Arduino Nano
    • Arduino Mega 2560
    • Arduino Leonardo
    • Arduino Micro
  • Arduino Renesas Boards
    • Arduino Uno R4 WiFi
    • Arduino Uno R4 Minima
  • Espressif
    • ESP32 Dev Module
    • ESP8266 NodeMCU (v1.0)
  • Raspberry Pi
    • Raspberry Pi Pico
    • Raspberry Pi Pico W
  • Teensy
    • Teensy 4.0 / 4.1 (Requires Teensy Loader)
  • Seeed Studio
    • Seeed XIAO SAMD21
    • Seeed XIAO RP2040
  • Generic / Clones
    • Unofficial boards using CH340/CH341 USB-to-Serial chips (Ensure drivers are installed on your local machine)

Note: While most boards work out-of-the-box, some specialized boards may require entering bootloader mode manually before uploading.


❓ Troubleshooting

"Browser doesn't show my device"

  • Ensure you are using Chrome or Edge.
  • Check your USB cable (some are power-only).
  • On Linux, ensure your user has permission to access serial ports (dialout group).

"Compilation failed"

  • Check the Output panel in VS Code for detailed error logs.
  • Ensure your arduino-requirements.txt includes all necessary libraries.

"Bridge is offline"

  • Run the command Arduino: Restart Bridge Server from the Command Palette.
  • Check if port 3000 is being used by another process.

📄 License

GNU General Public License v3.0. See LICENSE for more information.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft