as2_python_api.modules.traj_generation_module module

Trajectory Generation module.

class as2_python_api.modules.traj_generation_module.TrajGenerationModule(drone: DroneInterface)

Bases: ModuleBase, TrajGenerationBehavior

Trajectory Generation Module.

traj_generation_with_keep_yaw(path: nav_msgs.msg.Path, speed: float, frame_id: str = 'earth') bool

Trajectory generation. With keep yaw mode. Blocking call.

Parameters:
  • path (Path) – path to follow

  • speed (float) – speed (m/s) limit

  • frame_id (str, optional) – reference frame of the coordinates, defaults to “earth”

Returns:

True if was accepted, False otherwise

Return type:

bool

traj_generation_with_path_facing(path: nav_msgs.msg.Path, speed: float, frame_id: str = 'earth') bool

Trajectory generation. With path facing yaw mode. Blocking call.

Parameters:
  • path (Path) – path to follow

  • speed (float) – speed (m/s) limit

  • frame_id (str, optional) – reference frame of the coordinates, defaults to “earth”

Returns:

True if was accepted, False otherwise

Return type:

bool

traj_generation_with_yaw(path: nav_msgs.msg.Path, speed: float, angle: float, frame_id: str = 'earth') bool

Trajectory generation. With desired yaw angle. Blocking call.

Parameters:
  • path (Path) – path to follow

  • speed (float) – speed (m/s) limit

  • yaw_angle (float) – yaw angle (rad) when fixed yaw is set

  • frame_id (str, optional) – reference frame of the coordinates, defaults to “earth”

Returns:

True if was accepted, False otherwise

Return type:

bool