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.85.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.85.1-cp313-cp313-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.13Windows x86-64

openbricks-1.85.1-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.6 MB view details)

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

openbricks-1.85.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.85.1-cp312-cp312-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.12Windows x86-64

openbricks-1.85.1-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.6 MB view details)

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

openbricks-1.85.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.85.1-cp311-cp311-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.11Windows x86-64

openbricks-1.85.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.85.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.85.1-cp310-cp310-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.10Windows x86-64

openbricks-1.85.1-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.6 MB view details)

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

openbricks-1.85.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.85.1-cp39-cp39-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.9Windows x86-64

openbricks-1.85.1-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.6 MB view details)

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

openbricks-1.85.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.85.1.tar.gz.

File metadata

  • Download URL: openbricks-1.85.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.85.1.tar.gz
Algorithm Hash digest
SHA256 5e6f6f3d920fbcf98274e48eacac1add259ca1365c3fcd0d102e1e54b33ca8ce
MD5 2276c71bd7e99a6e047f75079ce8e350
BLAKE2b-256 b4a6f3b4f0643816ed04f6ced83d0d765f3a9b7e5c1eaa8be40dc028b45389bd

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 6ec029b3b053b918cf5a3d8ca32f13776501dfd6b03bc37546ceef984f95536b
MD5 7b0646222244ee615a967708cc99fb04
BLAKE2b-256 7c4333ac4b79dbb29385f9078d725de5f22130213aaef515929a46c9a6ae40c8

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.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.85.1-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 b8db34418a2043c509aeeda6cfce356957eca00c899fbefc96c5768af946d1ef
MD5 d9acff2533e4a6bd59442c3bd5963974
BLAKE2b-256 9a8043465a790df92ed1df07a8a9df920470505ab1b8e3391c6be35c91f404b8

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp313-cp313-macosx_10_13_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp313-cp313-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 969fd4aa98e2f370dcddee0e75bb4a6f49e89031ae0d917e8f27ba1e11c82aa4
MD5 a1589d0444e504c160146fcc3938523e
BLAKE2b-256 308333a12404f9e30ae9417303e02a9fe96f6d14a4befc5978ef9602f4d5cfec

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 cfa58e3bf60d7001af0ca24a814c9468d6040627b4b5096fcde172aadd546f5d
MD5 6390188118497efd45cf6cd6ea869393
BLAKE2b-256 2fa232f98563cf532c71fdcd099d66c39cd916292e418bdd9da819ea0e2a8286

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.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.85.1-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 a88b963d7cdad5d245b53239bc0fa0fc14c64a4d888c6fd7b78d0dba1ea738d5
MD5 5b1b9b86f8df169e0f2047fbffd078df
BLAKE2b-256 1c413dea4d9d3d5981c74fbaca27a03daf1ced96d2fed6a921fef92e14970a82

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp312-cp312-macosx_10_13_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp312-cp312-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 ec7bd17c050fc54dd9f78b6fa55fc18a0594372f2336d94e93109c895dc48c85
MD5 fbd36df2156c5a5e09036d98a81dbab0
BLAKE2b-256 f5275cf0c71175b36fc70b67d0f9ec431234f36b56e27e5476f9d3410653819e

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 1f03a06b662f4babeb5851a2dd578439c2d88269742371839cdaca5cb862bb70
MD5 aa433aa54fd3350a69dbd297e58ad9a0
BLAKE2b-256 cf15768d81533e354e6af7174e7f459e934738dc0fa05cc6ecef610edd82c08f

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.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.85.1-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 3a45f6a59be04155267e899005b8a4d547af3e594a6195b19228774578a58832
MD5 e03f89aed39318b096e9543066df7dcf
BLAKE2b-256 71bd9f99e9b1f0fc56e36f2a225e7df360778a2a8b73b771ff0d172010dca31c

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp311-cp311-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp311-cp311-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 77a5dcecb968973545c9aa5455d489aa0f3158a2ff7666791f563720b59bafa7
MD5 2f171a0c7784b2bd61da4b337da31101
BLAKE2b-256 0b1d4c4d8b0f5b3e313283627fa78783cf45f2df580119c0a39e4d564d1b1d4e

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 79a6075d5797d7bdb7d86a011c58a6a261f6762c1db9c4c7358a8d8b3bbd61e2
MD5 0cc2ea0e93fd55b8600f79b91e59205b
BLAKE2b-256 db973d3298d01204dfe255dcdf2fd36574f7d6b81ff7f00e813ca32a24edaeee

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.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.85.1-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 b3cd082f53359c28cdf785240b948bfc6d595880b303873305cb483fe7fc7059
MD5 a879b30fbb6e7f133cd2f39204746d92
BLAKE2b-256 f71d4064c0b2aa03fd688972a0ca4cce9e811045ad581b1f4dae10dcb6ed8a31

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp310-cp310-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp310-cp310-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 cb3738b09489d5406e12fef7a118d480c6773368fc22d796c94fc70c729164b3
MD5 28213b313aba6c866038c9a160048125
BLAKE2b-256 f9f4ed461d401735374f12907dff6b88f3e063c5a702806ed13d4663095c60de

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: openbricks-1.85.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.85.1-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 a0415411c4c75231b5d2c93dd6cdf5776ccadf4ac72fa40f55b27bbef365a854
MD5 7f97ea5942ffdda0518bc042ac6f9583
BLAKE2b-256 949d0d043cc6e769e614d7704860493610b2d9714111801c2e8132c886ba35fb

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.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.85.1-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 54df7cb11d1ab16d0bc9edde61f8169fbc7df97bed5e66d4e0bae7abc61cc3ec
MD5 fdf41a3bfd6b516c966d8369c2bc264e
BLAKE2b-256 126fec205d7f0f74897996572f7c6e4c190b545505d60a22ad0544925d517224

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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.85.1-cp39-cp39-macosx_10_9_universal2.whl.

File metadata

File hashes

Hashes for openbricks-1.85.1-cp39-cp39-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 ed6c6d73383d2fdc91b195bf82d5451e292ae037e4dfaf3c5402e717bf2f1ac0
MD5 d2aeabe4ad90ad0a511505e015dc28c3
BLAKE2b-256 3a1d2eca481fcf91129911da6e168f94336737f30d35f1bc0b5a5fcff246eaeb

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.85.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