Inputs and Outputs

Strict typing and standardized data streams

In Kompass, Components are designed with strict interfaces to “lock” their functionality. Each input and output is associated with a unique keyword name and restricted to a set of specific ROS2 message types.

A single keyword (e.g., sensor_data) can accept:

  1. A Single Topic: One laser scan.

  2. Multiple Topics: A list of topics (e.g., LiDAR + Radar) which are then fused internally by the component.

Configuration

Configuring inputs and outputs is done via the .inputs() and .outputs() methods on any Component instance.

from kompass.components import DriveManager
from kompass.ros import Topic

driver = DriveManager(component_name="driver")

# 1. Configure Inputs
# The 'sensor_data' key accepts a list of topics (fusion)
driver.inputs(
    sensor_data=[
        Topic(name='/scan', msg_type='LaserScan'),
        Topic(name='/radar_data', msg_type='Float64')
    ]
)

# 2. Configure Outputs
# Remap the 'emergency_stop' signal to a custom topic name
driver.outputs(
    emergency_stop=Topic(name='/system/alarm', msg_type='Bool')
)

See also

See the Topic configuration class details in the API Documentation.

Standard Stream Keys

Kompass uses a standardized set of keys across the entire stack.

Mapping & Perception

Enum Key

Keyword String

Description

GLOBAL_MAP

"map"

The static global reference map.

LOCAL_MAP

"local_map"

Dynamic occupancy grid of immediate surroundings.

SPATIAL_SENSOR

"sensor_data"

Raw spatial data (LIDAR, Radar, Depth).

VISION_TRACKINGS

"vision_tracking"

Tracking data from vision systems (bounding boxes/masks).

DEPTH_CAM_INFO

"depth_camera_info"

Camera intrinsics parameters.

TRACKED_POINT

"tracked_point"

Specific point or object currently being tracked.

Control & Actuation

Enum Key

Keyword String

Description

INTERMEDIATE_CMD

"command"

Velocity command produced by the Controller.

INTERMEDIATE_CMD_LIST

"multi_command"

List of candidate velocity commands.

FINAL_COMMAND

"robot_command"

Final, safety-checked command sent to the Driver.

EMERGENCY

"emergency_stop"

Signal for immediate robot halt.

System & State

Enum Key

Keyword String

Description

ROBOT_LOCATION

"location"

Current robot position and orientation (Odometry).

RUN_TESTS

"run_tests"

Trigger flag to initiate calibration procedures.

Tip

Each component’s specific requirements (required vs. optional streams) can be found in its respective documentation page (e.g., Planner Inputs, DriveManager Outputs).