Skip to main content

ORION Lab Bridge

Modular WebSocket bridge for industrial robotics labs. Connects physical and simulated devices (xArm, ABB, Siemens PLC, shell) to the ORION platform.

Quick start

Option A — one line, no Python required

This installs uv, downloads Python 3.10 if needed, and puts the orion command on your PATH. Nothing to preinstall.

Windows (PowerShell):

irm https://raw.githubusercontent.com/Starman26/orion-bridge-v2/main/install.ps1 | iex

Linux / macOS:

curl -LsSf https://raw.githubusercontent.com/Starman26/orion-bridge-v2/main/install.sh | sh

Then:

orion login   # authenticate (first time)
orion         # opens the GUI (use `orion --cli` for the terminal menu)

To include optional hardware drivers (mujoco, plc, abb, gazebo, http), set ORION_EXTRAS before running the one-liner, e.g. $env:ORION_EXTRAS = "mujoco,plc" (PowerShell) or ORION_EXTRAS="mujoco,plc" (bash).

Option B — already have Python? Just pip install

pip install --upgrade "orion-bridge[all]"   # core + GUI + all device drivers
orion                                        # opens the GUI (use `orion --cli` for the terminal menu)

The GUI ships with the core package, so even a plain pip install orion-bridge gives a working orion --gui. On Windows the first run registers the Python Scripts directory in your user PATH automatically — if orion is not recognized right after installing, open a new terminal. If another program named orion shadows the command (e.g. Oracle's ORION disk benchmark), use the orion-bridge alias or python -m orion_bridge.

For a lighter install pick only the device drivers you need:

pip install "orion-bridge[xarm]"    # physical xArm only
pip install "orion-bridge[mujoco]"  # MuJoCo simulation
pip install "orion-bridge[gazebo]"  # Gazebo via rosbridge
pip install "orion-bridge[plc]"     # Siemens S7 snap7
pip install "orion-bridge[http]"    # PLC REST sidecar (Flask)

Available extras: xarm, abb, plc, gazebo, mujoco, http, all

Configuration

Profiles are stored in ~/.orion/connections.toml. The wizard creates this file on first run. You can also edit it directly.

connections.toml format

# Which profile to use when no --connection flag is given
[default]
profile = "mezzanine"

# One [connections.<name>] section per lab
[connections.mezzanine]
server    = "wss://your-server.example.com/ws/robot"
lab_id    = "mezzanine"
bridge_id = "hostname-mezzanine"   # unique per bridge process
token_env = "ORION_TOKEN_MEZZANINE"  # real token read from this env-var

[[connections.mezzanine.devices]]
type = "xarm"
id   = "xarm-lab1"
ip   = "192.168.1.185"

[[connections.mezzanine.devices]]
type = "shell"
id   = "shell-local"

# A second profile (e.g. local dev)
[connections.dev]
server    = "ws://localhost:8000/ws/robot"
lab_id    = "dev"
bridge_id = "localhost-dev"
token_env = "ORION_TOKEN_DEV"

[[connections.dev.devices]]
type    = "xarm"
id      = "xarm6-mujoco"
handler = "mujoco"
viewer  = true
mjcf_path = "sim/models/xarm6/scene_xarm6.xml"

Token management

The token is never stored in the TOML file. Set the env-var named in token_env before starting:

export ORION_TOKEN_MEZZANINE="your-secret-token"
orion --connection mezzanine

Or use a .env file with python-dotenv / direnv.

CLI flags

Flag Description
orion Interactive wizard (first run) or menu
orion --list Print all saved profiles
orion --connection NAME Start bridge using a specific profile
orion --local Run without a server (local dispatch only)
orion --config FILE Legacy: load a JSON config file

Migrating from lab_config.json

If you have a legacy lab_config.json from an older installation, run orion once — the bridge automatically detects the file and migrates it to connections.toml. The JSON file is left untouched.

You can also migrate manually from Python:

from orion_bridge.connections import migrate_from_json
name = migrate_from_json("lab_config.json")
print(f"Migrated to profile '{name}'")

Supported devices

Type Handler Notes
xarm physical (default) UFACTORY SDK over IP
xarm mujoco MuJoCo simulation (pip install mujoco)
xarm gazebo Gazebo via rosbridge (pip install roslibpy)
abb TCP socket RAPID SocketServer
plc snap7 Siemens S7-1200 (pip install python-snap7)
shell subprocess Local commands (whitelisted)

Environment variables

Variable Required Description
ORION_BRIDGE_ID Yes Unique bridge ID, provisioned by owner
ORION_BRIDGE_TOKEN Yes Unique bridge token, provisioned by owner
SUPABASE_URL Yes Supabase project URL
SUPABASE_ANON_KEY Yes (for orion login) Anon key — NOT service_role

Authentication

Bridges have two authentication layers:

  1. Bridge identity: ORION_BRIDGE_ID + ORION_BRIDGE_TOKEN, provisioned once and stored in .env. Required for the bridge to connect to the server.
  2. User identity: orion login with email OTP. Required for orion repl.
orion login     # sends OTP to your email, stores JWT in ~/.orion/credentials.json
orion logout    # removes stored credentials
orion repl      # interactive REPL — requires prior login

orion (menu) and orion --start work without login.

Development

pip install -e ".[all]"   # editable install with all extras
pytest tests/ -v

Metadata

Release files for orion-bridge 3.8.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for orion-bridge 3.8.0
File Size Uploaded
orion_bridge-3.8.0.tar.gz 3.7 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for orion-bridge 3.8.0
File Interpreter ABI Platform
orion_bridge-3.8.0-py3-none-any.whl Python 3 none any Details

Total release size: 7.3 MB

Release files / orion_bridge-3.8.0.tar.gz

Download URL orion_bridge-3.8.0.tar.gz
Size 3.7 MB
Tags Source
SHA-256 checksum
How to use checksums
3dea58568def35e17797890db2c68eeefb9b9a528070803b9935735f6b8d724e
BLAKE2b-256 checksum
How to use checksums
e3442f2d97d2582e6adfae96e03b3317409ed5e2c4bfe2492268c5b580a16fe7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.8

Release files / orion_bridge-3.8.0-py3-none-any.whl

Download URL orion_bridge-3.8.0-py3-none-any.whl
Size 3.7 MB
Tags Python 3
SHA-256 checksum
How to use checksums
b5d6d68100d01582b885b05fb154997522ec3a4c5218a6946ef9e6c0faa904df
BLAKE2b-256 checksum
How to use checksums
59fdd03d4ca4e9cf5e16a85e8527cca199eb153abb277928590eef4e38e65156
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.8

Release history Release notifications | RSS feed

3.12.0

2 release files

3.11.0

2 release files

3.10.0

2 release files

3.9.0

2 release files

3.8.2

2 release files

3.8.1

2 release files

This release

3.8.0 This release

2 release files

3.7.0

2 release files

3.6.5

2 release files

3.6.4

2 release files

3.6.3

2 release files

3.6.2

2 release files

3.6.1

2 release files

3.6.0

2 release files

3.5.0

2 release files

3.4.0

2 release files

3.3.0

2 release files

3.2.4

2 release files

3.2.3

2 release files

3.2.2

2 release files

3.2.1

2 release files

3.2.0

2 release files

3.1.3

2 release files

3.1.2

2 release files

3.1.1

2 release files

3.1.0

2 release files

3.0.1

2 release files

3.0.0

2 release files

2.1.4

2 release files

2.1.3

1 release file

2.1.2

1 release file

2.1.1

1 release file

2.1.0

1 release file

2.0.8

1 release file

2.0.7

1 release file

2.0.6

1 release file

2.0.5

1 release file

2.0.4

1 release file

2.0.3

1 release file

2.0.2

1 release file

2.0.1

1 release file

2.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page