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.36.2.tar.gz (3.3 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.36.2-cp313-cp313-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.13Windows x86-64

openbricks-1.36.2-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.2 MB view details)

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

openbricks-1.36.2-cp313-cp313-macosx_10_13_universal2.whl (3.2 MB view details)

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

openbricks-1.36.2-cp312-cp312-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.12Windows x86-64

openbricks-1.36.2-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.2 MB view details)

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

openbricks-1.36.2-cp312-cp312-macosx_10_13_universal2.whl (3.2 MB view details)

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

openbricks-1.36.2-cp311-cp311-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.11Windows x86-64

openbricks-1.36.2-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.2 MB view details)

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

openbricks-1.36.2-cp311-cp311-macosx_10_9_universal2.whl (3.2 MB view details)

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

openbricks-1.36.2-cp310-cp310-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.10Windows x86-64

openbricks-1.36.2-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.2 MB view details)

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

openbricks-1.36.2-cp310-cp310-macosx_10_9_universal2.whl (3.2 MB view details)

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

openbricks-1.36.2-cp39-cp39-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.9Windows x86-64

openbricks-1.36.2-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl (3.2 MB view details)

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

openbricks-1.36.2-cp39-cp39-macosx_10_9_universal2.whl (3.2 MB view details)

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

File details

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

File metadata

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

File hashes

Hashes for openbricks-1.36.2.tar.gz
Algorithm Hash digest
SHA256 6dd904b15fac60e3e8dd6f02314f19b5eaa75ad316b0daea5ce03af200c6f55a
MD5 5014b4311329b38581bd4e9ef8497d85
BLAKE2b-256 51882286426951f985061b9a708e48529be1a456df70f03d1b103ec8e609a8dd

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 eb89d87141791a9e603fc4349451afab4c141e0f9fc0b31d5ffb25aa353be762
MD5 0b8c2598564abfabf3ddbaef8732e305
BLAKE2b-256 7e9c8b65af69061073b5ae24a1e3ae0fdd0f1ee73a96770d276baab42d77ee85

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.36.2-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.36.2-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.36.2-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 891b0f45aa76ed6fc400d778c06422641b4a5cee406adf8b60e7cf836f7d1ff7
MD5 c1b6fe601dbfe5b61128131328c945ab
BLAKE2b-256 6c4799af42847e0461fa12b93302e807e531b93c3c62bfd07cc9e5c356b84378

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp313-cp313-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 6118dd40d9fe0d18ca6ad745611dee5b7425c2d70ee56c3985d0b5e65ec3698a
MD5 5aa3d746281da36305554e0b5e4d0b07
BLAKE2b-256 3388d0d56b342762eb8054bab2d7f61012f38d0e592ebdd53998b133bd891ca1

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 d791db581ac8d98bbdb8f1c8106fec603db2b101dce2d7bcb2914fbe96eb604e
MD5 d37d4cd75c63150867e7ea34938b8438
BLAKE2b-256 d9c0517e5700e4c6fefa395ec3ae53c2df27caa840a866d9bfc3e07022619206

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.36.2-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.36.2-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.36.2-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 9a2749ceeac29e0fe9e2206b1020a86d69662d400eb4a4760a8ee8c2f11e57d7
MD5 8e693003eeea36bebe9ee84b222d8ddb
BLAKE2b-256 5728e3ea2a1d282cde361b08273e3e0ab22e744914122b1ab519fa43107b0069

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp312-cp312-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 6f4bee6be9e9c6a8cab4f9bdef1c10606eef94e19c5197217051b021e333ae06
MD5 575866f262116258374d0d7f62406908
BLAKE2b-256 003fbc9ab1b62c51b2a03f35bef59e37fd87f3a4aeb6606a605a39d2e4d20ae4

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 c69267f947d3d7b4c714fff8ddcd33405a2bddc3bbbfd3e912d0ab0988549559
MD5 ed8576743f8f80960443e8a018b921b2
BLAKE2b-256 8c8ba795954b03e3af7eb2d3cacdf9d35347f791c762ed3aab817ae06e99e6d5

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.36.2-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.36.2-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.36.2-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 ca33e6d94fe56bc8a99a95119369b72dd658ac4d2cbf4a7985d4081346926e24
MD5 aafa8c24ab25beb67cf861ea6fa4d79a
BLAKE2b-256 f4fe39bb9fbe2cdae18c1de0af697f16777234fb92a7c2c06548e859d324cf54

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp311-cp311-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 4f5607e5951ba6bca300a483ba1146732d0e962758d966ebe46a3b04d5a2252d
MD5 c60d07f09464b1fa40f2fc21a3da9048
BLAKE2b-256 55b70492d01014d0284ab11a1e2489f4db2fe8706af2e5fb550280d307320fc4

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 e9120e434bd1d51f498615f2737b4d5b572eb1a6cad9bfbc62da921aa3df5a1a
MD5 4d04f13327dbb2f503967d4eb8f9edcd
BLAKE2b-256 1c4ab8ef4a701c08c8e2f8b11fe36fc0be04bda1d9a585d2a5d1c260456550f4

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.36.2-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.36.2-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.36.2-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 9f6b5bef387968aa690432abf5a5e7ab9060669ceb41c506554494fccca58a45
MD5 409f87c2d0444820cfd321338c9aa040
BLAKE2b-256 ea946e9c146e009e314656ff1cf61db151d1b7f5cf48f330358b2d15b9957655

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp310-cp310-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 ab7c38c37b150c8883c10117f78d1b5cdbb57b9a963d9f8049521702ea6c4872
MD5 e9194fdd3ee8e106fca78c7681040a30
BLAKE2b-256 6756240896c4b089ba19234fa614c9d5303a7a4399be0714e1669bc7db6a5436

See more details on using hashes here.

Provenance

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

File metadata

  • Download URL: openbricks-1.36.2-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 3.2 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.36.2-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 bddf15369bd6afef839e7c33816712a0b967ed47011dc4cc964f3b08ac983574
MD5 2f40781707d8fbc20c9f08d73673fa98
BLAKE2b-256 57ddd402cd924cdcc23b3476ba01446b7ddee8aa1a2bcd1201a730d696ad82f1

See more details on using hashes here.

Provenance

The following attestation bundles were made for openbricks-1.36.2-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.36.2-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl.

File metadata

File hashes

Hashes for openbricks-1.36.2-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 337e77b20efd972475a44160571041f809d163b23ad1e0cbebd256d9cd36c145
MD5 42421f8b8927c2af8a45d96811088ce4
BLAKE2b-256 8d1179fb7cd2904dd0e434b41138dee0018f4713afc5a87432a031af50cfb9b1

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.36.2-cp39-cp39-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 60aa17dedcbd8aca5c3ee0731f67635ce026817c0acbe2716a290866e1a49ec1
MD5 7303affc85beca78fa9d09d58be4ed00
BLAKE2b-256 1103711af1652bca770b456a992e3c4089655d2f00f2785f7cfb7c942e65c3e3

See more details on using hashes here.

Provenance

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