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

Uploaded CPython 3.13Windows x86-64

openbricks-1.80.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.80.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.80.1-cp312-cp312-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.12Windows x86-64

openbricks-1.80.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.80.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.80.1-cp311-cp311-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.11Windows x86-64

openbricks-1.80.1-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.6 MB view details)

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

openbricks-1.80.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.80.1-cp310-cp310-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.10Windows x86-64

openbricks-1.80.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.80.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.80.1-cp39-cp39-win_amd64.whl (3.6 MB view details)

Uploaded CPython 3.9Windows x86-64

openbricks-1.80.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.80.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.80.1.tar.gz.

File metadata

  • Download URL: openbricks-1.80.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.80.1.tar.gz
Algorithm Hash digest
SHA256 5af6ff7a76c8fd498595bc4ed010408f1843698ec7efc4187073771e75e7d29b
MD5 9808b081919e3cf6b98026c8d1efda18
BLAKE2b-256 c0736f88ae7e36a0b2bf7f761bc9bfcefc34e7a525ed0523fd955948209d6882

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 e0fee5c567b1ae90e9466cc5c25091c1487712fc0deb5d0bb4226b9721c75878
MD5 2ffbc76ce66947cea318a1f5853d95e8
BLAKE2b-256 1917c7b5dc23477d94ee1e51016aae0d1b40971c1bac43568954cff9496bc2cf

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.80.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.80.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.80.1-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 159437d20111874c0c53892c6fb2844b6b1fc746a66131564c4115a607945b98
MD5 96587afe6df1c7cfdf339d2f036c76d0
BLAKE2b-256 873bb5f917fb4f48af4ed44038c7c607c402df6fba1ba32ddede115de2bfcedd

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp313-cp313-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 b097cf3d161258c9c217f2d2b1c39e520fe00b6b44ca89c4255a85965c2422a8
MD5 5c08cd601d8d852719dfa1a8e0cf41d0
BLAKE2b-256 91553a83d5907ca41ebf42a1a2542d36c1956038b5aafa9c7e8f84f8c712fb02

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 262aae59f903f8ed674e12eb5f81f344596bbf9db40d7f281d601de775121717
MD5 ce7e9c9c00133466da3244265bf5eba8
BLAKE2b-256 6a927c2891c21ab250a868da6f9f6464a20c7b4b3b664f4b80c1df29bb93ae71

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.80.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.80.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.80.1-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 142d640658d3c45ff034478e6270ba66fa114b73033fd5c568b03d509ff57744
MD5 2bc6e055b176d747a6fc182eb263eaf1
BLAKE2b-256 d40062e9ce06de774aead4e0aa0eb1ccf65e8974be1f3cad7edb9313759e8aba

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp312-cp312-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 c3b835111ab6ba043ed001c15a3e5d3c2eabb287dc45813200052e7ea41a4221
MD5 710eaf4cb963a5a071582b098f53fb56
BLAKE2b-256 3468b5e91072c7d9b6bc1309de5be075d360eed6324e1946c66c28faa5d4d9fe

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 ad9a136bf9b302a1109a83c077f7eb23b27083121613eaca7a93f4ef2a6c7a10
MD5 a8b620e1d83ce1cd3fbf5c4f39f08d7d
BLAKE2b-256 f4fe22417bc41b01f23c1ba0dae161eeca1d00a659344b92c42c9827a2061ed0

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.80.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.80.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.80.1-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 8f33677d84cf104f7b3512d80e00fe2268c7dcc65eaff9465c7f9ab80dda6a2b
MD5 5c7bfb06d2b75cf60ac8b7b7d00fc91c
BLAKE2b-256 a031115eaa7da45c4271fd5c3781b489f924db64c0f01e4a1a17651dd15b0712

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp311-cp311-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 ae60f9ed1e5ce1875e4db39116196cb25dce586ad8a973125a266cf43273d712
MD5 35c37ae6c9959206fba2746c8f6361cc
BLAKE2b-256 76c72a485c8f3c59f0064289f1aa8b1c834b27765bea45d5498d54d0732ce741

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 83b008f2b5e8ab0e24449072304bbedba9cc8a01385a404fba7d0283f0e7f6be
MD5 c1b1536e74f8d9a3464bbf00ac5eef9c
BLAKE2b-256 1dcce9a2d1d9a742e3290b74059f6170bf8006fc9f8f3461e47d5f71bb2b6023

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.80.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.80.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.80.1-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 383bb5728481d4a139b2c91c10769484e2112b0c777ea71d9cf1c1f7486dd808
MD5 998d41666e6892adacb16dfb5a08b421
BLAKE2b-256 887c85e917f72eeec186aa4bbbdbed57e14aba597e0cfb267284c365a8d78dc6

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp310-cp310-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 d0b0f6b90c0fdaa8e63d6882451b9eb3f901db5f9f9083ed2999303c9cc1d2b8
MD5 b7d4a9dd7961b8a08795f32ffb0747e7
BLAKE2b-256 7013a8e3b9ce37bc4ba5f603376651819313d69c2280fb8a66f5b65b37658404

See more details on using hashes here.

Provenance

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

File metadata

  • Download URL: openbricks-1.80.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.80.1-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 2f4ed7cde9820765e622250b9231ae0be619bef82ab9990745a715d5b8162c73
MD5 ee4f51049f3b0babeaedd3319a8f204f
BLAKE2b-256 38c92b4ad8ccb0225451dc1b4c797b09af0c58785a410698e79a0db473b9f52a

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.80.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.80.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.80.1-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 781cc3dc6e8b12361289b5310e1d79302ded024438cd2382305e8755f5eb4c25
MD5 340c58ec0ec1ebea89801d32b6e05b08
BLAKE2b-256 5d7a059bedba5e10b477742dc93f9bc4b61c47cf389810907d23641625039fbf

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.80.1-cp39-cp39-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 5ae91266054a393738fe5ed8162c0426566aae6fce1410efb485d85531eca13f
MD5 8c3cb7984ffde3065ed55f750cc61d5e
BLAKE2b-256 dcd63474966f92a53567370a59b432112b54ccf7ad8edb56c5264002c86c7ce9

See more details on using hashes here.

Provenance

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