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
BuiltInVelocityControllerDroneConnector Class Reference

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

#include <builtin_velocity_controller_drone_connector.h>

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

Public Member Functions

 BuiltInVelocityControllerDroneConnector (parsernode::Parser &drone_hardware, Controller< VelocityYaw, VelocityYaw, VelocityYaw > &controller)
 Constructor. More...
 
- Public Member Functions inherited from ControllerHardwareConnector< VelocityYaw, VelocityYaw, VelocityYaw >
 ControllerHardwareConnector (Controller< VelocityYaw, VelocityYaw, VelocityYaw > &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 (VelocityYawgoal)
 Set the goal for controller. More...
 
VelocityYaw 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 (VelocityYaw &sensor_data)
 does not extract any data since nothing is needed More...
 
virtual void sendHardwareCommands (VelocityYaw controls)
 Send velocity commands to hardware. More...
 

Additional Inherited Members

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

Detailed Description

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

Constructor & Destructor Documentation

BuiltInVelocityControllerDroneConnector::BuiltInVelocityControllerDroneConnector ( parsernode::Parser &  drone_hardware,
Controller< VelocityYaw, VelocityYaw, VelocityYaw > &  controller 
)
inline

Constructor.

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

Parameters
drone_hardwareDrone hardware used to send commands
controllerVelocity controller that achieves a desired velocity, yaw

Member Function Documentation

bool BuiltInVelocityControllerDroneConnector::extractSensorData ( VelocityYaw sensor_data)
protectedvirtual

does not extract any data since nothing is needed

Parameters
sensor_datacurrent velocity and yaw of UAV
Returns
true if velocity and yaw can be found

Implements ControllerHardwareConnector< VelocityYaw, VelocityYaw, VelocityYaw >.

void BuiltInVelocityControllerDroneConnector::sendHardwareCommands ( VelocityYaw  controls)
protectedvirtual

Send velocity commands to hardware.

Parameters
controlsvelocity command to send to UAV

Implements ControllerHardwareConnector< VelocityYaw, VelocityYaw, VelocityYaw >.


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