Skip to main content

list_sensors

Available since v1.1.0

Signature:

BoosterRobot.list_sensors() -> list[SensorInfo]

Description:

Gets the list of sensor metadata mounted on the current robot.

Parameters:

None.

Returns:

list[SensorInfo], the list of sensor metadata. See "Robot Metadata / SensorInfo".

Raises:

RuntimeError: Failed to query the sensor list.

Example:

from boosteros.robots.booster import BoosterRobot

robot = BoosterRobot()
sensors = robot.list_sensors()

# Filter by sensor type
imus = [s for s in sensors if s.sensor_type == "imu"]
cameras = [s for s in sensors if s.sensor_type == "camera"]

# Look up by id
head_cam = next((s for s in sensors if s.id == "head"), None)
if head_cam:
print(head_cam.id, head_cam.model)
# Example output: head CAMERA_Model_BOOSTER_MIPI