ASCO Aerial Autonomy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Member Functions | List of all members
PositionControllerDroneConnector Class Reference

Manages communication between a drone plugin and a position controller that outputs position commands. More...

#include <position_controller_drone_connector.h>

Inheritance diagram for PositionControllerDroneConnector:
Inheritance graph
[legend]
Collaboration diagram for PositionControllerDroneConnector:
Collaboration graph
[legend]

Public Member Functions

 PositionControllerDroneConnector (parsernode::Parser &drone_hardware, Controller< PositionYaw, PositionYaw, PositionYaw > &controller)
 Constructor. More...
 
- Public Member Functions inherited from ControllerHardwareConnector< PositionYaw, PositionYaw, PositionYaw >
 ControllerHardwareConnector (Controller< PositionYaw, PositionYaw, PositionYaw > &controller, HardwareType hardware_type)
 ControlHardwareConnector runs the controller and sends the commands to hardware. More...
 
virtual void run ()
 Extracts sensor data, run controller and send data back to hardware. More...
 
void setGoal (PositionYawgoal)
 Set the goal for controller. More...
 
PositionYaw getGoal () const
 Get the goal for controller. More...
 
HardwareType getHardwareType ()
 Return the type of hardware (HardwareType) used by the controller. More...
 
ControllerStatus getStatus () const
 Provide the status of the controller. More...
 
- Public Member Functions inherited from AbstractControllerHardwareConnector
virtual ~AbstractControllerHardwareConnector ()
 Destructor to get polymorphism. More...
 

Protected Member Functions

virtual bool extractSensorData (PositionYaw &sensor_data)
 does not extract any data since nothing is needed More...
 
virtual void sendHardwareCommands (PositionYaw controls)
 Send position commands to hardware. More...
 

Additional Inherited Members

- Protected Attributes inherited from ControllerHardwareConnector< PositionYaw, PositionYaw, PositionYaw >
HardwareType hardware_type_
 Type of hardware controlled by the controller. More...
 

Detailed Description

Manages communication between a drone plugin and a position controller that outputs position commands.

Constructor & Destructor Documentation

PositionControllerDroneConnector::PositionControllerDroneConnector ( parsernode::Parser &  drone_hardware,
Controller< PositionYaw, PositionYaw, PositionYaw > &  controller 
)
inline

Constructor.

Store drone hardware with hardware type as UAV. Uses parsernode::Parser::cmdwaypoint function.

Parameters
drone_hardwareDrone hardware used to send commands
controllerPosition controller that achieves a desired position, yaw

Member Function Documentation

bool PositionControllerDroneConnector::extractSensorData ( PositionYaw sensor_data)
protectedvirtual

does not extract any data since nothing is needed

Parameters
sensor_dataCurrent position and yaw of UAV
Returns
true if position and yaw can be extracted

Implements ControllerHardwareConnector< PositionYaw, PositionYaw, PositionYaw >.

void PositionControllerDroneConnector::sendHardwareCommands ( PositionYaw  controls)
protectedvirtual

Send position commands to hardware.

Parameters
controlsposition command to send to UAV

Implements ControllerHardwareConnector< PositionYaw, PositionYaw, PositionYaw >.


The documentation for this class was generated from the following files: