Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Development Environments & Tooling

Now that you’ve decided on Arduino + OpenMRN-Lite + ESP32, you need tools to write, build, and upload code. There are three main options for Arduino development. This section compares them so you can choose what works best for you.

Three Options for Arduino Development

1. Arduino IDE

What it is: The official Arduino development environment. A simple editor with integrated build and upload tools.

Pros:

  • Official and most well-documented
  • Simplest setup for beginners
  • Latest Arduino library support (sometimes ahead of other tools)

Cons:

  • Limited editing features compared to professional IDEs
  • No advanced debugging tools
  • Library management can be tedious for complex projects
  • Slower builds for large projects
  • Limited integration with external tools (like GitHub Copilot)

Visual Studio Code is a powerful, modern code editor that supports Arduino development through extensions. Unlike the Arduino IDE, VS Code gives you professional editing features, integrations, and an extensive ecosystem of tools—all in one environment. This significantly improves your development experience.

Benefits of VS Code for Arduino Development:

  • Professional editor experience - syntax highlighting, code formatting, IntelliSense, and multi-file navigation
  • GitHub Copilot integration - AI-assisted code completion, documentation generation, and debugging suggestions
  • Extensible ecosystem - seamless access to Git, terminal, testing tools, debugging, and thousands of extensions
  • Faster development workflow - superior editing and navigation compared to Arduino IDE

There are two main extensions available for Arduino development in VS Code:

2A. Arduino Maker Workshop (VS Code Extension)

What it is: An extension that brings the Arduino CLI directly into VS Code, giving you the same capabilities as the official Arduino IDE.

Pros:

  • Full Arduino CLI capability - identical board and library support as the official Arduino IDE; no loss of functionality
  • Good library management - same library ecosystem as Arduino IDE

Cons:

  • Smaller community than PlatformIO
  • May have minor library update lag compared to official Arduino IDE (rarely an issue in practice)

2B. PlatformIO (VS Code Extension)

What it is: A professional-grade build system and IDE extension specifically designed for embedded development across multiple platforms.

Pros:

  • Fastest builds - significantly faster than Arduino IDE or Maker Workshop
  • Professional features - library version pinning, dependency resolution, build system profiling
  • Strong community - large ecosystem of libraries and examples
  • Non-Arduino platform support - extends beyond Arduino boards to ESP-IDF, FreeRTOS, STM32, and hundreds of other embedded platforms; supports phase 3 migration to full OpenMRN

Cons:

  • Latest Arduino library versions sometimes lag by 1–2 releases (minor issue in practice)
  • Slightly steeper learning curve than Arduino IDE
  • More configuration options (which is a pro for power users)

Personal Recommendation: PlatformIO + VS Code + GitHub Copilot

I personally use PlatformIO in VS Code with GitHub Copilot (paid subscription) enabled. Here’s why:

  1. Professional environment - PlatformIO’s build system is industrial-strength; you’re learning with real tools you’d use in production.
  2. GitHub Copilot - The entry-level paid subscription (~$10/month) is exceptional value. Copilot goes way beyond auto-completion; I use it to write and edit actual code. This dramatically lowers the barrier to entry and makes you far more productive:
    • Writing functions and complex logic from natural language descriptions
    • Refactoring and improving existing code
    • Generating unit tests and helper functions
    • Explaining unfamiliar code and OpenMRN APIs
  3. Fast iteration - PlatformIO’s build speed means less waiting between code changes and testing.
  4. Future flexibility - If you later migrate to full OpenMRN, PlatformIO supports it seamlessly.

The Copilot subscription is worth the investment if you’re doing this seriously. It’s not a necessity—you can learn OpenLCB without it—but it significantly improves the learning experience and accessibility for hobbyists.

Choosing Your Own Path

Each option is valid:

  • Lowest barrier to entry? → Arduino IDE
  • VS Code + Arduino CLI? → Arduino Maker Workshop
  • Professional, fastest, future-proof? → PlatformIO

This book includes detailed setup instructions for PlatformIO (Chapter 3). If you prefer a different option, the concepts apply equally; you’ll just follow that tool’s documentation for the build and upload steps.