Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
gvf.c File Reference
+ Include dependency graph for gvf.c:

Go to the source code of this file.

Functions

static void send_gvf (struct transport_tx *trans, struct link_device *dev)
 
static void send_circle (struct transport_tx *trans, struct link_device *dev)
 
static void send_segment (struct transport_tx *trans, struct link_device *dev)
 
static int out_of_segment_area (float x1, float y1, float x2, float y2, float d1, float d2)
 
void gvf_init (void)
 
void gvf_control_2D (float ke, float kn, float e, struct gvf_grad *grad, struct gvf_Hess *hess)
 
void gvf_set_direction (int8_t s)
 
static void gvf_line (float a, float b, float heading)
 
bool gvf_line_XY_heading (float a, float b, float heading)
 
bool gvf_line_XY1_XY2 (float x1, float y1, float x2, float y2)
 
bool gvf_line_wp1_wp2 (uint8_t wp1, uint8_t wp2)
 
bool gvf_segment_loop_XY1_XY2 (float x1, float y1, float x2, float y2, float d1, float d2)
 
bool gvf_segment_loop_wp1_wp2 (uint8_t wp1, uint8_t wp2, float d1, float d2)
 
bool gvf_segment_XY1_XY2 (float x1, float y1, float x2, float y2)
 
bool gvf_segment_wp1_wp2 (uint8_t wp1, uint8_t wp2)
 
bool gvf_line_wp_heading (uint8_t wp, float heading)
 
bool gvf_ellipse_XY (float x, float y, float a, float b, float alpha)
 
bool gvf_ellipse_wp (uint8_t wp, float a, float b, float alpha)
 
bool gvf_sin_XY_alpha (float a, float b, float alpha, float w, float off, float A)
 
bool gvf_sin_wp1_wp2 (uint8_t wp1, uint8_t wp2, float w, float off, float A)
 
bool gvf_sin_wp_alpha (uint8_t wp, float alpha, float w, float off, float A)
 

Variables

gvf_con gvf_control
 
gvf_tra gvf_trajectory
 
gvf_seg gvf_segment
 

Function Documentation

void gvf_control_2D ( float  ke,
float  kn,
float  e,
struct gvf_grad grad,
struct gvf_Hess hess 
)
bool gvf_ellipse_wp ( uint8_t  wp,
float  a,
float  b,
float  alpha 
)

Definition at line 392 of file gvf.c.

References gvf_ellipse_XY(), and waypoints.

+ Here is the call graph for this function:

bool gvf_ellipse_XY ( float  x,
float  y,
float  a,
float  b,
float  alpha 
)

Definition at line 356 of file gvf.c.

References alpha, gvf_con::error, gvf_control_2D(), gvf_ellipse_info(), gvf_ellipse_par, horizontal_mode, HORIZONTAL_MODE_CIRCLE, HORIZONTAL_MODE_WAYPOINT, gvf_ell_par::ke, gvf_con::ke, gvf_ell_par::kn, gvf_tra::p, and gvf_tra::type.

Referenced by distributed_circular(), gvf_ellipse_wp(), and gvf_nav_survey_polygon_run().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void gvf_init ( void  )

Definition at line 124 of file gvf.c.

References DefaultPeriodic, gvf_con::ke, gvf_con::kn, NONE, register_periodic_telemetry(), gvf_con::s, send_circle(), send_gvf(), send_segment(), and gvf_tra::type.

+ Here is the call graph for this function:

static void gvf_line ( float  a,
float  b,
float  heading 
)
static

Definition at line 212 of file gvf.c.

References gvf_con::error, gvf_control_2D(), gvf_line_info(), gvf_line_par, heading, horizontal_mode, HORIZONTAL_MODE_WAYPOINT, gvf_li_par::ke, gvf_con::ke, gvf_li_par::kn, gvf_tra::p, gvf_seg::seg, and gvf_tra::type.

Referenced by gvf_line_XY1_XY2(), gvf_line_XY_heading(), and gvf_segment_loop_XY1_XY2().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool gvf_line_wp1_wp2 ( uint8_t  wp1,
uint8_t  wp2 
)

Definition at line 269 of file gvf.c.

References gvf_line_XY1_XY2(), waypoints, point::x, and point::y.

+ Here is the call graph for this function:

bool gvf_line_wp_heading ( uint8_t  wp,
float  heading 
)

Definition at line 344 of file gvf.c.

References gvf_line_XY_heading(), waypoints, point::x, and point::y.

+ Here is the call graph for this function:

bool gvf_line_XY1_XY2 ( float  x1,
float  y1,
float  x2,
float  y2 
)

Definition at line 240 of file gvf.c.

References alpha, gvf_line(), gvf_set_direction(), horizontal_mode, HORIZONTAL_MODE_ROUTE, gvf_seg::seg, gvf_seg::x1, gvf_seg::x2, gvf_seg::y1, and gvf_seg::y2.

Referenced by gvf_line_wp1_wp2(), and gvf_segment_XY1_XY2().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool gvf_line_XY_heading ( float  a,
float  b,
float  heading 
)

Definition at line 233 of file gvf.c.

References gvf_line(), and gvf_set_direction().

Referenced by gvf_line_wp_heading().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool gvf_segment_loop_wp1_wp2 ( uint8_t  wp1,
uint8_t  wp2,
float  d1,
float  d2 
)

Definition at line 302 of file gvf.c.

References gvf_segment_loop_XY1_XY2(), waypoints, point::x, and point::y.

+ Here is the call graph for this function:

bool gvf_segment_loop_XY1_XY2 ( float  x1,
float  y1,
float  x2,
float  y2,
float  d1,
float  d2 
)

Definition at line 279 of file gvf.c.

References alpha, gvf_line(), horizontal_mode, HORIZONTAL_MODE_ROUTE, out_of_segment_area(), s, gvf_con::s, gvf_seg::seg, gvf_seg::x1, gvf_seg::x2, gvf_seg::y1, and gvf_seg::y2.

Referenced by gvf_segment_loop_wp1_wp2().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool gvf_segment_wp1_wp2 ( uint8_t  wp1,
uint8_t  wp2 
)

Definition at line 334 of file gvf.c.

References gvf_segment_XY1_XY2(), waypoints, point::x, and point::y.

+ Here is the call graph for this function:

bool gvf_segment_XY1_XY2 ( float  x1,
float  y1,
float  x2,
float  y2 
)

Definition at line 312 of file gvf.c.

References gvf_line_XY1_XY2(), p, stateGetPositionEnu_f(), EnuCoor_f::x, and EnuCoor_f::y.

Referenced by gvf_nav_points(), and gvf_segment_wp1_wp2().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void gvf_set_direction ( int8_t  s)

Definition at line 205 of file gvf.c.

References s, and gvf_con::s.

Referenced by gvf_line_XY1_XY2(), gvf_line_XY_heading(), and gvf_nav_direction_circle().

+ Here is the caller graph for this function:

bool gvf_sin_wp1_wp2 ( uint8_t  wp1,
uint8_t  wp2,
float  w,
float  off,
float  A 
)

Definition at line 423 of file gvf.c.

References alpha, gvf_sin_XY_alpha(), waypoints, point::x, and point::y.

+ Here is the call graph for this function:

bool gvf_sin_wp_alpha ( uint8_t  wp,
float  alpha,
float  w,
float  off,
float  A 
)

Definition at line 442 of file gvf.c.

References gvf_sin_XY_alpha(), waypoints, point::x, and point::y.

+ Here is the call graph for this function:

bool gvf_sin_XY_alpha ( float  a,
float  b,
float  alpha,
float  w,
float  off,
float  A 
)

Definition at line 400 of file gvf.c.

References A, alpha, gvf_con::error, gvf_control_2D(), gvf_sin_info(), gvf_sin_par, gvf_con::ke, gvf_s_par::ke, gvf_s_par::kn, gvf_tra::p, and gvf_tra::type.

Referenced by gvf_sin_wp1_wp2(), and gvf_sin_wp_alpha().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static int out_of_segment_area ( float  x1,
float  y1,
float  x2,
float  y2,
float  d1,
float  d2 
)
static

Definition at line 93 of file gvf.c.

References alpha, p, s, stateGetPositionEnu_f(), EnuCoor_f::x, and EnuCoor_f::y.

Referenced by gvf_segment_loop_XY1_XY2().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void send_circle ( struct transport_tx *  trans,
struct link_device *  dev 
)
static

Definition at line 72 of file gvf.c.

References ELLIPSE, gvf_tra::p, and gvf_tra::type.

Referenced by gvf_init().

+ Here is the caller graph for this function:

static void send_gvf ( struct transport_tx *  trans,
struct link_device *  dev 
)
static

Definition at line 45 of file gvf.c.

References ELLIPSE, gvf_con::error, gvf_con::ke, LINE, gvf_tra::p, gvf_con::s, SIN, and gvf_tra::type.

Referenced by gvf_init().

+ Here is the caller graph for this function:

static void send_segment ( struct transport_tx *  trans,
struct link_device *  dev 
)
static

Definition at line 82 of file gvf.c.

References LINE, gvf_seg::seg, gvf_tra::type, gvf_seg::x1, gvf_seg::x2, gvf_seg::y1, and gvf_seg::y2.

Referenced by gvf_init().

+ Here is the caller graph for this function:

Variable Documentation

gvf_con gvf_control

Definition at line 37 of file gvf.c.

Referenced by distributed_circular().

gvf_seg gvf_segment

Definition at line 41 of file gvf.c.

gvf_tra gvf_trajectory

Definition at line 40 of file gvf.c.

Referenced by gvf_ellipse_info(), gvf_line_info(), and gvf_sin_info().