picoruby/picoruby
picoruby/picoruby has 1,109 GitHub stars and 77 forks. GitHot measured 0 stars in 24 hours and -1 in 7 days. Last checked 2026-11-11 00:13 UTC. Last push 2026-11-01.
PicoRuby is the smallest Ruby implementation for one-chip microcontrollers
Measured star growth
- in 24h
- 0
- in 7 days
- -1
- in 15 days
- Update delayed
- in 1 month
- Update delayed
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
README.md
OriginalPicoRuby
PicoRuby is an alternative mruby implementation which is:
- Small foot print (depending on build config)
- RAM: 512 KB or less (PicoRuby with networking)
- RAM: 128 KB or less (FemtoRuby)
- Portable
- Depends on only standard C library such as glibc, Newlib or Newlib-nano, and emcc
- Reference microcontroller boards
- Raspberry Pi Pico 2 W - Arm Cortex-M33, 520 KB RAM, 4 MB Flash with CYW43 network module
- Raspberry Pi Pico - Arm Cortex-M0+, 264 KB RAM, 2 MB Flash
FemtoRuby?
From version 4.x, we call the artifacts below:
- PicoRuby (used to be MicroRuby) ... mruby VM version
- FemtoRuby (used to be PicoRuby) ... mruby/c VM version
mruby VM version is mainly being developed.
API documentation with some demo videos

Depends on
- PicoRuby compiler (picoruby/mruby-compiler2) as mruby-compiler
- Estalloc (picoruby/estalloc)
- Littlefs (littlefs-project/littlefs)
- mruby (mruby/mruby)
- mruby/c (mrubyc/mrubyc)
Used by
- R2P2: PicoRuby shell system for Raspberry Pi Pico
- R2P2-ESP32: ESP32 port
- PicoRuby.wasm: PicoRuby WASI runtime for WebAssembly
- PRK Firmware: Keyboard firmware for Raspberry Pi Pico
Testing
For detailed information on testing PicoRuby, refer to the Testing Guide.
Build
- Prerequisites
- C toolchain
- git
- ruby (should be CRuby 3.4+)
git clone --recurse-submodules https://github.com/picoruby/picoruby
cd picoruby/
git submodule update --init --recursive # If you forgot --recurse-submodules when git clone
rake # same for `rake picoruby:prod`
rake picoruby:debug # for debug build
bin/picoruby -e 'puts "Hello World!"'
- Building on a mac
- openssl is not linked in homebrew to avoid mixing with system ssl
- extend the C/LD flags to point to the right locations:
rake LDFLAGS=-L$(brew --prefix openssl@3)/lib CFLAGS=-I$(brew --prefix openssl@3)/include
FemtoRuby (mruby/c VM version)
rake femtoruby:prod
# or
rake femtoruby:debug
Cross compilation
See an example: build_config/r2p2-picoruby-pico2.rb
Binaries
rake command will make three kinds of executable binary
- bin/mrbc
bin/mrbc path/to/source.rbmakespath/to/source.mrbthat is VM code runs on an mruby-compatible virtual machine
- bin/picoruby
bin/picoruby source.rbexecutes Ruby just like normalrubycommandbin/picoruby -e "puts 'Hello1'"also works
- bin/r2p2
- POSIX version of R2P2 (See mrbgems/picoruby-r2p2 for the Raspi Pico edition)
Acknowledgement
Part of this project was coded by Monstarlab with the support of the Ruby Association Grant Program 2020 and 2021.
See also picoruby/picoruby/wiki.
Stargazers over time
License
Copyright © 2020- HASUMI Hitoshi. See MIT-LICENSE for further details.
Copyright © 2020-2021 Monstarlab. See MIT-LICENSE for further details.
Explore related projects
codecrafters-io/build-your-own-x
Master programming by recreating your favorite technologies from scratch.
561,861 starspublic-apis/public-apis
A collective list of free APIs
498,217 starsmorluto/rea
Reverse engineer anything with agents, from app behavior down to native binaries.
452,546 starsopenclaw/openclaw
The AI that really does things. Any OS. Any Platform. The lobster way. 🦞
394,367 stars