Texas Aerial Robotics Documentation
flight.cpp File Reference
#include <iostream>
#include <ros/ros.h>
#include <geometry_msgs/PoseStamped.h>
#include <nav_msgs/Odometry.h>
#include "std_msgs/Float64.h"
#include <mavros_msgs/CommandBool.h>
#include <mavros_msgs/SetMode.h>
#include <mavros_msgs/State.h>
#include <mavros_msgs/PositionTarget.h>
#include <unistd.h>
#include <geometry_msgs/Pose2D.h>
#include <mavros_msgs/CommandTOL.h>
#include <time.h>
#include <cmath>
#include <math.h>
#include <ros/duration.h>

Go to the source code of this file.

Functions

void state_cb (const mavros_msgs::State::ConstPtr &msg)
 
void pose_cb (const geometry_msgs::PoseStamped::ConstPtr &msg)
 
void heading_cb (const std_msgs::Float64::ConstPtr &msg)
 
void setHeading (float heading)
 
void setDestination (float x, float y, float z)
 
int main (int argc, char **argv)
 

Variables

mavros_msgs::State current_state
 
geometry_msgs::PoseStamped current_pose
 
geometry_msgs::PoseStamped pose
 
std_msgs::Float64 current_heading
 
float GYM_OFFSET
 

Function Documentation

◆ heading_cb()

void heading_cb ( const std_msgs::Float64::ConstPtr &  msg)

Definition at line 49 of file flight.cpp.

◆ main()

int main ( int  argc,
char **  argv 
)

Definition at line 93 of file flight.cpp.

◆ pose_cb()

void pose_cb ( const geometry_msgs::PoseStamped::ConstPtr &  msg)

Definition at line 36 of file flight.cpp.

◆ setDestination()

void setDestination ( float  x,
float  y,
float  z 
)

Definition at line 81 of file flight.cpp.

◆ setHeading()

void setHeading ( float  heading)

Definition at line 55 of file flight.cpp.

◆ state_cb()

void state_cb ( const mavros_msgs::State::ConstPtr &  msg)

Definition at line 29 of file flight.cpp.

Variable Documentation

◆ current_heading

std_msgs::Float64 current_heading

Definition at line 25 of file flight.cpp.

◆ current_pose

geometry_msgs::PoseStamped current_pose

Definition at line 23 of file flight.cpp.

◆ current_state

mavros_msgs::State current_state

Definition at line 21 of file flight.cpp.

◆ GYM_OFFSET

float GYM_OFFSET

Definition at line 26 of file flight.cpp.

◆ pose

geometry_msgs::PoseStamped pose

Definition at line 24 of file flight.cpp.