 |
Paparazzi UAS
v6.1.0_stable
Paparazzi is a free software Unmanned Aircraft System.
|
Go to the documentation of this file.
33 #include "generated/flight_plan.h"
36 #ifndef NAV_ROSETTE_RECOVER_MAX_TURN
37 #define NAV_ROSETTE_RECOVER_MAX_TURN 1.5f
40 #ifndef NAV_ROSETTE_BORDER_FILTER
41 #define NAV_ROSETTE_BORDER_FILTER 60.f
97 float alpha = dt / (dt + tau);
136 float start_x = params[0];
137 float start_y = params[1];
138 float start_z = params[2];
139 int first_turn = params[3];
140 float circle_radius = params[4];
141 float vx = params[5];
142 float vy = params[6];
143 float vz = params[7];
144 nav_rosette_setup(start_x, start_y, start_z, first_turn, circle_radius, vx, vy, vz);
157 float vx = params[0];
158 float vy = params[1];
165 float vz = params[0];
178 #ifndef NAV_ROSETTE_LWC_ID
179 #define NAV_ROSETTE_LWC_ID ABI_BROADCAST
186 if (data_type == 1 && size == 1) {
208 int turn,
float desired_radius,
209 float vx,
float vy,
float vz)
211 struct EnuCoor_f start = {init_x, init_y, init_z};
235 float pre_climb = 0.f;
#define NAV_ROSETTE_RECOVER_MAX_TURN
unsigned int uint32_t
Typedef defining 32 bit unsigned int type.
unsigned char uint8_t
Typedef defining 8 bit unsigned char type.
static float stateGetHorizontalSpeedDir_f(void)
Get dir of horizontal ground speed (float).
void nav_send_waypoint(uint8_t wp_id)
Send a waypoint throught default telemetry channel.
static float change_rep(float dir)
void nav_rosette_init(void)
Init function called by modules init.
static float get_sys_time_float(void)
Get the time in seconds since startup.
static struct EnuCoor_f * stateGetPositionEnu_f(void)
Get position in local ENU coordinates (float).
Event structure to store callbacks in a linked list.
void nav_circle_XY(float x, float y, float radius)
Navigates around (x, y).
enum RotationDir rotation
#define VECT3_ADD(_a, _b)
#define NAV_ROSETTE_LWC_ID
struct EnuCoor_f estim_border
#define NavVerticalAutoThrottleMode(_pitch)
Set the climb control to auto-throttle with the specified pitch pre-command.
#define NavCircleCountNoRewind()
struct FloatVect3 pos_incr
void nav_route_xy(float last_wp_x, float last_wp_y, float wp_x, float wp_y)
Computes the carrot position along the desired segment.
void nav_rosette_setup(float init_x, float init_y, float init_z, int turn, float desired_radius, float vx, float vy, float vz)
Initialized the exploration with a first target point inside the cloud Called from flight plan or wit...
#define DEFAULT_CIRCLE_RADIUS
default nav_circle_radius in meters
void nav_init_stage(void)
needs to be implemented by fixedwing and rotorcraft seperately
static struct NavRosette nav_rosette
#define NAVIGATION_FREQUENCY
Default fixedwing navigation frequency.
static struct EnuCoor_f process_new_point_rosette(struct EnuCoor_f *position, float uav_direction)
vector in East North Up coordinates Units: meters
void nav_move_waypoint_enu(uint8_t wp_id, float x, float y, float alt)
Move a waypoint in local frame.
enum RosetteStatus status
uint16_t f
Camera baseline, in meters (i.e. horizontal distance between the two cameras of the stereo setup)
int int32_t
Typedef defining 32 bit int type.
static const float nav_dt
float ground_alt
size == nb_waypoint, waypoint 0 is a dummy waypoint
@ MissionUpdate
param update
bool nav_rosette_run(void)
Navigation function Called by flight plan or mission run function.
bool mission_register(mission_custom_cb cb, char *type)
Register a new navigation or action callback function.
struct EnuCoor_f recover_circle
#define VECT3_ASSIGN(_a, _x, _y, _z)
static void update_barycenter(struct EnuCoor_f *bary, struct EnuCoor_f *border, struct EnuCoor_f *first, float alt_sp, float dt, float tau)
static void lwc_cb(uint8_t sender_id UNUSED, uint32_t stamp UNUSED, int32_t data_type, uint32_t size, uint8_t *data)
#define NAV_ROSETTE_BORDER_FILTER
#define NavVerticalAltitudeMode(_alt, _pre_climb)
Set the vertical mode to altitude control with the specified altitude setpoint and climb pre-command.