feathersdk.robot.robot_module Module

class feathersdk.robot.robot_module.RobotModuleConfig(*, module_name)

Bases: PyDFrozenBaseModel

Base config for all robot modules.

Parameters:

module_name (str)

module_name: str

The name of the module.

model_config: ClassVar[ConfigDict] = {'frozen': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class feathersdk.robot.robot_module.RobotModule(config, *args, **kwargs)

Bases: Configurable[TRobotModuleConfig], Abortable, Generic[TRobotModuleConfig]

Base class for all robot modules.

Parameters:

config (TRobotModuleConfig)

robot: FeatherRobot | None = None

The robot instance, set by FeatherRobot during initialization.

on_power_event(event)

Function that is run when the power event occurs.

Parameters:

event (PowerEvent)