Skip to main content

openbricks (host CLI + sim)

Host-side tooling for openbricks hubs — same UX as pybricksdev, built on commodity Python tooling (bleak, esptool, mpremote). One package, one console script: openbricks flash / list / run / upload / stop / log. The MuJoCo-backed simulator is built in too — openbricks sim … opens the sim's CLI when the [sim] extra is installed.

Website: https://openbricks.dev · Documentation: https://docs.openbricks.dev

Install

Recommended — with pipx so the CLI lands in an isolated venv and avoids the "externally managed environment" error on modern macOS / Linux distros:

pipx install openbricks            # CLI only (lightweight; bleak / esptool / mpremote)
pipx install 'openbricks[sim]'     # CLI + MuJoCo physics simulator

Plain pip works too:

pip install openbricks
pip install 'openbricks[sim]'

For development against a repo checkout (editable install):

pip install -e 'tools/openbricks[sim]'

[sim] adds mujoco (~50 MB, native OpenGL) and numpy — most users (flash + run + log) don't need it. Without [sim], openbricks sim … prints a helpful "pip install openbricks[sim]" hint instead of crashing.

Note: binary wheels (manylinux, macOS universal2, Windows AMD64; CPython 3.9–3.13) ship on PyPI since 0.10.3, so installs are toolchain-free on common platforms. On anything outside that matrix, pip falls back to the sdist and compiles the bundled native extension (openbricks_sim._native), which needs a C compiler + Python headers.

Commands

flash — program a hub

openbricks flash \
    --name RobotA \
    --port /dev/tty.usbserial-XXXX \
    --firmware native/micropython/ports/esp32/build-openbricks_esp32s3/firmware.bin

Writes the firmware image and bakes the hub's BLE advertising name into NVS. --name is mandatory: two hubs with the same name can't be individually addressed over BLE.

Port syntax: /dev/ttyUSB0 (Linux), /dev/cu.usbserial-* (macOS), COM5 (Windows).

Useful flags: --chip esp32s3, --baud 921600, --skip-erase (faster dev loop, keeps stale NVS).

list — scan for hubs

openbricks list [--timeout 5.0] [--all]

Runs a BLE scan and prints every named device found, sorted by RSSI (strongest first). --all includes unnamed devices too.

run — stage and launch; button stops it; client exits on stop

openbricks run -n RobotA examples/hello.py

Stages the script to /program.py (same target as upload) and triggers the hub's launcher to execute it immediately. Output streams back to your terminal in real time.

  • Button stop. Pressing the hub button while the program runs raises KeyboardInterrupt via the same launcher path upload+button uses. The client sees the clean "stopped by button press" line and exits.
  • Program completion. When the program finishes (or raises), the client disconnects and exits — same as pybricksdev run.
  • Script persists. Because run stages to /program.py, the hub can re-run the last program via a button press without another upload. upload and run differ only in whether the client auto-launches after upload.

Stderr (e.g. exception tracebacks) arrives after stdout and is surfaced with a blank-line separator. No paste-mode === echo — raw-paste mode is clean.

stop — interrupt the running program

openbricks stop -n RobotA

Sends a single Ctrl-C byte over the NUS REPL bridge, which MicroPython surfaces as KeyboardInterrupt. Useful when openbricks run has already exited but the hub's still chewing on a long-running user program.

upload — stage a script; hub button launches it

openbricks upload -n RobotA examples/wander.py

Writes the script to /program.py on the hub. The code does not run automatically. Place your robot, press the program button (GPIO 4), and the program starts. Press again to stop it mid-run.

(Pybricks calls this same operation download from the hub's "download to me" perspective. We name by direction-of-data-travel — bytes flow up to the hub, hence upload.)

This works because the firmware ships a frozen main.py that:

  1. Brings BLE + REPL bridge up immediately (so openbricks run / upload / stop are always reachable, even when no program is running).
  2. Instantiates the board's Hub, which wires the BLE-toggle button (short-press on GPIO 5) with LED feedback.
  3. Watches the program button (GPIO 4) via openbricks.launcher.run() — a short-press runs /program.py, a second short-press raises KeyboardInterrupt in the running program.

Two separate pins (4 for program, 5 for BLE toggle), each handled by short-press only — no duration-based dispatch.

Pass --path /alt.py to stage at a different filename (if you've written your own main.py that reads from there).

Tests

cd tools/openbricks
PYTHONPATH=. python -m unittest discover -s tests -t .

No real hardware needed — esptool, mpremote, and bleak are mocked.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

openbricks-1.90.1.tar.gz (3.8 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

openbricks-1.90.1-cp313-cp313-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.13Windows x86-64

openbricks-1.90.1-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64manylinux: glibc 2.5+ x86-64

openbricks-1.90.1-cp313-cp313-macosx_10_13_universal2.whl (3.6 MB view details)

Uploaded CPython 3.13macOS 10.13+ universal2 (ARM64, x86-64)

openbricks-1.90.1-cp312-cp312-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.12Windows x86-64

openbricks-1.90.1-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64manylinux: glibc 2.5+ x86-64

openbricks-1.90.1-cp312-cp312-macosx_10_13_universal2.whl (3.6 MB view details)

Uploaded CPython 3.12macOS 10.13+ universal2 (ARM64, x86-64)

openbricks-1.90.1-cp311-cp311-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.11Windows x86-64

openbricks-1.90.1-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64manylinux: glibc 2.5+ x86-64

openbricks-1.90.1-cp311-cp311-macosx_10_9_universal2.whl (3.6 MB view details)

Uploaded CPython 3.11macOS 10.9+ universal2 (ARM64, x86-64)

openbricks-1.90.1-cp310-cp310-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.10Windows x86-64

openbricks-1.90.1-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64manylinux: glibc 2.5+ x86-64

openbricks-1.90.1-cp310-cp310-macosx_10_9_universal2.whl (3.6 MB view details)

Uploaded CPython 3.10macOS 10.9+ universal2 (ARM64, x86-64)

openbricks-1.90.1-cp39-cp39-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.9Windows x86-64

openbricks-1.90.1-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.28+ x86-64manylinux: glibc 2.5+ x86-64

openbricks-1.90.1-cp39-cp39-macosx_10_9_universal2.whl (3.6 MB view details)

Uploaded CPython 3.9macOS 10.9+ universal2 (ARM64, x86-64)

File details

Details for the file openbricks-1.90.1.tar.gz.

File metadata

  • Download URL: openbricks-1.90.1.tar.gz
  • Upload date:
  • Size: 3.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for openbricks-1.90.1.tar.gz
Algorithm Hash digest
SHA256 da4d1629354d84fe9223bcc67b68102e8df3f31698519c40784891a51860873c
MD5 63444523c59591d73e8ddc467dabb5c9
BLAKE2b-256 4f331888d77589ae42c555f39f92701d079c24f0490ed9200fbabc78fb30571b

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1.tar.gz:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 3fc5567f8d00e9229903f15bc2c62ef22c74055c74e5101845c347c59484215c
MD5 f987c5348b7543a55e227802f168a99c
BLAKE2b-256 026f30ca04a9c312ff5f8782ca9faf9e834cb8e53c6e97acab1a2733430cbe85

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp313-cp313-win_amd64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 916d51b668468491015e348f0c0f75adfd111ccb52a74841c5c82534bdc187c9
MD5 6c4f8eeb4d69678ce60ed3d96c3a519c
BLAKE2b-256 12da16ae807e68f6a6d76c352d8433792011c56ec94ceb0fbbd20070388f57a6

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp313-cp313-macosx_10_13_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp313-cp313-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 c68cd2fb0606aefd2bc69b226aa1d5a5109babec481e61ff954f5b13960daccc
MD5 36baaa06e357104d8f2d800180d45bb0
BLAKE2b-256 b4e96e2ccc991fb1852ae9b7e4a8500c9796e221b48b7234ebf1c3826ccbc55b

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp313-cp313-macosx_10_13_universal2.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 e3994615f895ee8ba1ea10a72d5b099d0699646259b7eb238eeb40c2ef785674
MD5 16755b62136ce8eaeef415f931b28b55
BLAKE2b-256 07700dce17096aa97dbc837098b2d8635ff47e64e296b45f8c19cb5b63fd5a74

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp312-cp312-win_amd64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 74e933b6f5de0d24e21be3785c3c77cccd2d0963e3a353fbf5d6b0cf8b74a414
MD5 f506943dddb58a0bfc3f2b273aa11ffd
BLAKE2b-256 490fc887ee02e994c3c6dd5eaf5df85efcaecca69f846bbf0fc235db6d888ea4

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp312-cp312-macosx_10_13_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp312-cp312-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 5b64ad26f86119026fabca2ce1dbc52fb04c819819d05a228953d624a2558d94
MD5 1cf521b57b1b0b55df43a9b8b4c7a7ef
BLAKE2b-256 ed6a0c4ca763b693e7976f898245744777792c81d4e63b9319a695eab001a8c3

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp312-cp312-macosx_10_13_universal2.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 d4862868b8c13776912ccd95a5c89fa357d1602fd9ff9e41472c0c802485375f
MD5 97f8d307db8153eb5d49636512ba55c8
BLAKE2b-256 b5bd3d79401d11cabce62b9a5ab68938325551f1e8fc047df5ec02e67f404fe6

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp311-cp311-win_amd64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 eb122c41c829f659e13ae24773232759402b0db15951bf78370d0e8d4fc0e14e
MD5 3defc182f6146da144b239ec9f87d2d3
BLAKE2b-256 538ec886e4da62509dc491372f24a3540738e6ae724534e6a0ce557998e68430

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp311-cp311-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp311-cp311-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 ee108c9c59d8e863da2710f3de99226d76bdd53608e47ca508689e57131317ea
MD5 300e1a9d0ca4175f33a028c861034c5a
BLAKE2b-256 8ce6aeb6ce9c7c898d67c937923a18613c754a6446169fedad3b5125c5d138bb

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp311-cp311-macosx_10_9_universal2.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 2ba11779df9fe2db189e74a953686cea4d85b48f361fdad1602b23a57a42ca32
MD5 1f42b8f98633f8721779e279b5220a5d
BLAKE2b-256 ecf630a17d1301c3005d28ca4e19256b508e1bd243e160589d45905d7e9f26a8

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp310-cp310-win_amd64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 e50eb085e843759ea6e98c303d18f4861e5d9cee21ae5908ad8dbae7dbfd94bc
MD5 4ceaf0ce80cf02152d6832a1fb1c03f7
BLAKE2b-256 7c3076801a048b2fa94e942ba5ada32dc1a16f634820010b3d47ea2896b4be86

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp310-cp310-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp310-cp310-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 217261cc9b2159aa72681694d6ccf20fceb8f77d579e08fe61a2891b777ec3ff
MD5 f063172e3d369a53c566b5e9f111839c
BLAKE2b-256 3862693ff7254a1aeeb056765341bf934e3a97b5caf9f17a6870e978e3839234

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp310-cp310-macosx_10_9_universal2.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: openbricks-1.90.1-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 3.6 MB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for openbricks-1.90.1-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 e47871e9b80f336cf7aa5ca11d3e6d2d3ce9970591b49182569a9cb5dac24b9a
MD5 0a31853379ce711074740ce2d36fcf6b
BLAKE2b-256 7fbbb0173ee901cd96b84818939e5483c8cb17c0a22260af1500981d4529bbf5

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp39-cp39-win_amd64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 b76641a98744036d8524ed6a3a517c3cf5ea41bf47d9b3415752a6fbde2245fa
MD5 f38a2db16fe94c637abfbe5981fe191e
BLAKE2b-256 0a1af34cec282c885f5c55a7fc3c62411cf804521e2ddd9bcd6a61451411ae72

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openbricks-1.90.1-cp39-cp39-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.90.1-cp39-cp39-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 e45cf777c9a1c97916791339a4d16bc2be09d0b6445be2ceb55a807647202249
MD5 9ae5ff48cfec81fc8c4ae92f911c6c3b
BLAKE2b-256 8c5771f195f0bbc954a1363df85617bd1a675d85f7f73b4c25af73fb4a6e6912

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.90.1-cp39-cp39-macosx_10_9_universal2.whl:

Publisher: ci.yaml on 1e0ng/openbricks

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page