跳转至

base

Base interfaces for LAV2 controllers.

类:

名称 描述
ControllerBase

Abstract controller base class.

ControllerBase

ControllerBase(params: VehicleParams, control_mask: ndarray | Tensor, gains: dict | None = None)

Bases: ABC

Abstract controller base class.

Initialize shared controller state.

方法:

名称 描述
update

Update the controller and return control outputs.

reset

Reset controller state if necessary.

属性:

名称 类型 描述
params VehicleParams

Vehicle parameters for the controller.

control_mask ndarray | Tensor

unified control mask for target/state channels, used in update(). e.g. using 9~11 for attitude yaw control.

gains dict | None

Optional gains configuration for derived controllers.

target ndarray | Tensor

Latest target input to the controller.

params instance-attribute

params: VehicleParams = params

Vehicle parameters for the controller.

control_mask instance-attribute

control_mask: ndarray | Tensor = control_mask

unified control mask for target/state channels, used in update(). e.g. using 9~11 for attitude yaw control.

gains instance-attribute

gains: dict | None = gains

Optional gains configuration for derived controllers.

target instance-attribute

target: ndarray | Tensor

Latest target input to the controller.

update abstractmethod

update(target, state)

Update the controller and return control outputs.

reset abstractmethod

reset(*args, **kwargs)

Reset controller state if necessary.