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

Uploaded CPython 3.13Windows x86-64

openbricks-1.83.5-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.83.5-cp313-cp313-macosx_10_13_universal2.whl (3.6 MB view details)

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

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

Uploaded CPython 3.12Windows x86-64

openbricks-1.83.5-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.83.5-cp312-cp312-macosx_10_13_universal2.whl (3.6 MB view details)

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

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

Uploaded CPython 3.11Windows x86-64

openbricks-1.83.5-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.83.5-cp311-cp311-macosx_10_9_universal2.whl (3.6 MB view details)

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

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

Uploaded CPython 3.10Windows x86-64

openbricks-1.83.5-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.83.5-cp310-cp310-macosx_10_9_universal2.whl (3.6 MB view details)

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

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

Uploaded CPython 3.9Windows x86-64

openbricks-1.83.5-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.83.5-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.83.5.tar.gz.

File metadata

  • Download URL: openbricks-1.83.5.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.83.5.tar.gz
Algorithm Hash digest
SHA256 2321484f37e4ff9be32dfbda49521128d77a9877b7a003e309c673fb9bf9a668
MD5 44f5729723968aebd5a4f69172b71e79
BLAKE2b-256 46101f06fee3a21f1d02010c5efdebfe822fbae190dff636e9dc65fed93beb24

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 350052ce2b1a708533f8fecc624087bb4e8c6b2042b90e324187ef1ab75e0e5e
MD5 4201fcab1c8c3a12f3e890055bd7d780
BLAKE2b-256 c34fe691b3ae16c1b31f9910ca6646042470734652c83ef4c60816962c267968

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp313-cp313-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 7ca27a446f998a8f987e3c42e8208fa08b36a85bbb9a953a397cc64ef598b5b8
MD5 c49094868b3e83708a1f6832b1415c67
BLAKE2b-256 c36ec16131ffccb47652b56969724b2eae20bc67bf7662d12db95d0ce1553b21

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp313-cp313-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 6c524877f6f5a712a129d3881681a6b08da8507fa89e87a923892e198849a2b9
MD5 1a2a5383dbc1e77e16a955cc77c94da6
BLAKE2b-256 e36b05171778fe5dba61692dcb7a95768d313b4cc0fc01dbf61086320d1cb055

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 c07b6e0e4d4cc18661e14664cb161e369dc79fd191732f2d1efd262c49665269
MD5 50e4f051ea26fd7e0f90a92f5e89572f
BLAKE2b-256 43d006aa3466d8d9282526db5bc718c42db6115ffcf8d4b33caede89b01315d8

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp312-cp312-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 c36077420b212b4f41f3f71b87f71e27f51d6eb21410501e130b569f8db81652
MD5 de47f5068c1526db0644b935cb4ea81b
BLAKE2b-256 4c3bfff882c593706e04cd6e9eadd1e5dd042e0cf72a9b3e2b46591f2656b468

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp312-cp312-macosx_10_13_universal2.whl
Algorithm Hash digest
SHA256 db0032661b7a22c4b466dd22aece9cbe718e30601f3579ccde4fd52469a03c3f
MD5 ea78f7d685915e04458cc960a140e80a
BLAKE2b-256 9b7a4a515f19ee82b9b4d04de6953a9b392cb2800d66a4dd085bca18704571d7

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 35df0a2df2b5423b29835c26d474c959c095e072217bcaf7c549c33db251cd2c
MD5 9c700ba5cf28db398780e33026e91d36
BLAKE2b-256 5886d519f00251e95f0fc9340733655f38b1f9571e22f0f44981035ee1b9b605

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp311-cp311-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 e013a5e80840d1cb8637d2b6ec203314f363cf29f0592457f1d0956a2ee0f78f
MD5 c466e89b6e9a86b8ed713759fcd5e344
BLAKE2b-256 25dc5da58539b4829de0bf4b40543d1e21290870af5d70d69091ade061833a1f

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp311-cp311-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 402504893deb7802dfbc7be3f7bd94f4fc06868c198258a5f5a14661b5a121d4
MD5 0b7e422373d44c5088a39904fa6ccdc5
BLAKE2b-256 10ab2137137c232662918d05fa2d992cb2e71e212ce1c0591fd3d3376fc66cca

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 7f7b58d89c29c8d02a9c22709f6916cee4ecedaaf1426285845fe2953c8636ab
MD5 7daf10a4c120ed07814bf06b96307d01
BLAKE2b-256 e77f97fae3cf52fe614cee0164a6885e6d22d3a9e2f6a0915c9fda053c2199de

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp310-cp310-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 37d515a1c60e28fe1e0c6edbe7c0babcb07bc472ba3a5c5cbbaae401a5651a4e
MD5 04eb0dc1d63eeb64307fa020af89bb07
BLAKE2b-256 67ede6f0ffbc67ba6a514b96236148c4bd733a67e0079233c8b967e1245cc339

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp310-cp310-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 b5369cfc9d55d016b5896ee08599d3fbc79200f2e44b4711828a5bbdc285fd11
MD5 c4e865e0c071de5e4c44d5e7ade4de27
BLAKE2b-256 af06b3c6cdba27fd1e96b3d9b800064838adc310ae4cdd8d33f0c09db43fa0f7

See more details on using hashes here.

Provenance

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

File metadata

  • Download URL: openbricks-1.83.5-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.83.5-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 efcbbe6e510b8bbccef5255ca980084c1457f0740ae8b3a4ece1b499173d0bc6
MD5 2d338edaf55e150279ab3c503e7adf91
BLAKE2b-256 701431dade88040a5c871f8f694887d0fea7ded7928392e86a465f65004db3fb

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp39-cp39-manylinux1_x86_64.manylinux_2_28_x86_64.manylinux_2_5_x86_64.whl
Algorithm Hash digest
SHA256 b4f5dec5db27737cf1062cefd2e1681ff72b8db31ed7b43e6a0e9fecfde955b9
MD5 6e0a9ff8818fb292d82a6e94ea0b640d
BLAKE2b-256 b32010f079b517631fd1c06ae074f09b95ce98704d5c013075c7b1f7af6165af

See more details on using hashes here.

Provenance

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

File metadata

File hashes

Hashes for openbricks-1.83.5-cp39-cp39-macosx_10_9_universal2.whl
Algorithm Hash digest
SHA256 63cd3cdd0c24d020fb6d724c10e062f69feea61d4f7aa28b6c589ca05e3e4a3b
MD5 c09a9e5f3846d1df4aa6a254c98bcb54
BLAKE2b-256 672eb74bf5890d26be6d9b7f2e935a30f2746de7297a80e821352a32cb6e39bb

See more details on using hashes here.

Provenance

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