as2_python_api.modules.go_to_module module

Go to Module.

class as2_python_api.modules.go_to_module.GoToModule(drone: DroneInterface)

Bases: ModuleBase, GoToBehavior

Go to Module.

go_to(x: float, y: float, z: float, speed: float, frame_id: str = 'earth') bool

Go to point, blocking call.

Parameters:
  • x (float) – x coordinate (m) to go to

  • y (float) – y coordinate (m) to go to

  • z (float) – z coordinate (m) to go to

  • speed (float) – speed (m/s) to go to the point

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

Returns:

True if was accepted, False otherwise

Return type:

bool

go_to_path_facing(x: float, y: float, z: float, speed: float, frame_id: str = 'earth') bool

Go to point. With path facing yaw mode. Blocking call.

Parameters:
  • x (float) – x coordinate (m) to go to

  • y (float) – y coordinate (m) to go to

  • z (float) – z coordinate (m) to go to

  • speed (float) – speed (m/s) to go to the point

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

Returns:

True if was accepted, False otherwise

Return type:

bool

go_to_point(point: list[float], speed: float, frame_id: str = 'earth') bool

Go to point. With keep yaw mode. Blocking call.

Parameters:
  • point (list[float]) – [x, y, z] (m) coordinates to go to

  • speed (float) – speed (m/s) to go to the point

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

Returns:

True if was accepted, False otherwise

Return type:

bool

go_to_point_path_facing(point: list[float], speed: float, frame_id: str = 'earth') bool

Go to point. With path facing yaw mode. Blocking call.

Parameters:
  • point (list[float]) – [x, y, z] (m) coordinates to go to

  • speed (float) – speed (m/s) to go to the point

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

Returns:

True if was accepted, False otherwise

Return type:

bool

go_to_point_with_yaw(point: list[float], speed: float, angle: float, frame_id: str = 'earth') bool

Go to point. With desired yaw angle (degrees). Blocking call.

Parameters:
  • point (list[float]) – [x, y, z] (m) coordinates to go to

  • speed (float) – speed (m/s) to go to the point

  • yaw_angle (float) – yaw angle

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

Returns:

True if was accepted, False otherwise

Return type:

bool

go_to_with_yaw(x: float, y: float, z: float, speed: float, angle: float, frame_id: str = 'earth') bool

Go to point. With desired yaw angle (degrees). Blocking call.

Parameters:
  • x (float) – x coordinate (m) to go to

  • y (float) – y coordinate (m) to go to

  • z (float) – z coordinate (m) to go to

  • speed (float) – speed (m/s) to go to the point

  • yaw_angle (float) – yaw angle

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

Returns:

True if was accepted, False otherwise

Return type:

bool