R2P2ESP32
PicoRuby × ESP32

Run Ruby directly on your ESP32

R2P2-ESP32 brings R2P2 — a PicoRuby shell — to ESP32 microcontrollers. Flash it from your browser and start writing Ruby on real hardware in minutes.

picoruby-shell
$> irb
irb> words = ["Hello", "PicoRuby", "!"]
=> ["Hello", "PicoRuby", "!"]
irb> words.join(" ")
=> "Hello PicoRuby !"
irb> ▏

From zero to Ruby in three steps

You don't need to install anything to try it out.

  1. 1

    Flash

    Pick your chip in the Web Installer and write the prebuilt firmware over USB.

    Open the installer →
  2. 2

    Connect

    Open a serial console and you land in the R2P2 shell on your board.

    Monitoring guide →
  3. 3

    Code

    Run irb, transfer scripts, and configure WiFi — all in Ruby, on the device.

    Quick start →

Flash from your browser

No toolchain required to get started — flash prebuilt firmware straight from the Web Installer.

A full Ruby REPL

Drop into irb on-device and explore the picoruby-shell interactively, right over the wire.

Multiple ESP32 targets

Supports ESP32, ESP32-C3, ESP32-C6, ESP32-H2, ESP32-P4 and ESP32-S3 boards.

Open source

Built on PicoRuby, the smallest Ruby implementation for one-chip microcontrollers.

Works across the ESP32 family

Prebuilt images are published for these chips, with and without the USB console where applicable.

ESP32 ESP32-C3 ESP32-C6 ESP32-H2 ESP32-P4 ESP32-S3
See verified devices →

Choose your Ruby VM

Both VMs are available on the boards that have enough memory.

FemtoRuby (mruby/c)
The lightweight VM. Runs on every supported chip, including boards without SPIRAM.
PicoRuby (mruby)
The fuller mruby-based VM, verified on ESP32-S3 boards.

Ready to dive in?

Follow the quick start guide to flash your board and run your first Ruby program in minutes.

Read the docs