Docs

Python SDK

Integrate existing robot hardware

The SDK is for control-plane integration: naming components, writing compact observations, making hidden physical behavior visible, reading Oplut-managed services, and syncing evidence. Keep high-frequency control, sensor fusion, and inference in native services, firmware, ROS, OpenCV, or hardware-specific runtimes.

Device identity

Use the current authenticated device as the anchor for local evidence and optional cloud sync.

from oplut import Device

device = Device.current()
print(device.identity())

Components

Name the physical part that future metrics and events refer to. This can be built-in hardware or a private enterprise component.

imu = device.component("imu.bno085", kind="imu", display_name="BNO085 IMU")
imu.register(
    vendor="Teyleten",
    model="GY-BNO085",
    attachment_summary="ESP32-S3 USB serial bridge",
)

Metrics and events

Write compact facts that can be compared against baselines without uploading raw sensor streams.

imu.metric("sample_rate_hz", 98.6, unit="hz")
imu.metric("timestamp_jitter_ms", 2.4, unit="ms")
imu.event("wire.suspect", severity="warn", message="Intermittent serial resets")

Upload control

Keep evidence local by default while prototyping, then opt in to sync when the team wants dashboard history.

# local only
imu.metric("gyro_noise_norm", 0.018, upload=False)

# compact cloud evidence after auth
imu.metric("gyro_noise_norm", 0.018, upload=True)

Example files

Custom IMU metric writer

/cli/examples/custom_imu_metric_writer.py

Camera baseline reader

/cli/examples/camera_baseline_reader.py

Enterprise component registration

/cli/examples/enterprise_component_registration.py

Local-only evidence

/cli/examples/local_only_evidence.py