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

Go to the source code of this file.

Macros

#define RANGE_FORCEFIELD_RECIEVE_ID   ABI_BROADCAST
 
#define RANGE_FORCEFIELD_INNER_LIMIT   1.0f
 
#define RANGE_FORCEFIELD_OUTER_LIMIT   1.4f
 
#define RANGE_FORCEFIELD_MIN_VEL   0.0f
 
#define RANGE_FORCEFIELD_MAX_VEL   0.5f
 

Functions

static float compute_ff_vel (float range)
 
static void store_min_dist (float pos, float *nearest_pos, float range)
 
static void obstacle_cb (uint8_t sender_id, float range, float azimuth, float bearing)
 
void range_forcefield_init (void)
 
void range_forcefield_periodic (void)
 
void range_forcefield_update (float range, struct FloatEulers *body_to_sensor_eulers)
 

Variables

struct range_forcefield_param_t range_forcefield_param
 
static struct FloatVect3 ff_nearest_obs_pos
 
static struct FloatVect3 ff_nearest_obs_neg
 
static abi_event obstacle_ev
 

Macro Definition Documentation

#define RANGE_FORCEFIELD_INNER_LIMIT   1.0f

Definition at line 37 of file range_forcefield.c.

Referenced by range_forcefield_init().

#define RANGE_FORCEFIELD_MAX_VEL   0.5f

Definition at line 52 of file range_forcefield.c.

Referenced by range_forcefield_init().

#define RANGE_FORCEFIELD_MIN_VEL   0.0f

Definition at line 47 of file range_forcefield.c.

Referenced by range_forcefield_init().

#define RANGE_FORCEFIELD_OUTER_LIMIT   1.4f

Definition at line 42 of file range_forcefield.c.

Referenced by range_forcefield_init(), and range_forcefield_periodic().

#define RANGE_FORCEFIELD_RECIEVE_ID   ABI_BROADCAST

Definition at line 33 of file range_forcefield.c.

Referenced by range_forcefield_init().

Function Documentation

static float compute_ff_vel ( float  range)
static
static void obstacle_cb ( uint8_t  sender_id,
float  range,
float  azimuth,
float  bearing 
)
static

Definition at line 64 of file range_forcefield.c.

References FloatEulers::phi, FloatEulers::psi, range_forcefield_update(), and FloatEulers::theta.

Referenced by range_forcefield_init().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void range_forcefield_periodic ( void  )
void range_forcefield_update ( float  range,
struct FloatEulers body_to_sensor_eulers 
)

Definition at line 121 of file range_forcefield.c.

References ff_nearest_obs_neg, ff_nearest_obs_pos, float_rmat_of_eulers, float_rmat_transp_vmult(), store_min_dist(), FloatVect3::x, FloatVect3::y, and FloatVect3::z.

Referenced by obstacle_cb().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

static void store_min_dist ( float  pos,
float *  nearest_pos,
float  range 
)
static

Definition at line 165 of file range_forcefield.c.

Referenced by range_forcefield_update().

+ Here is the caller graph for this function:

Variable Documentation

struct FloatVect3 ff_nearest_obs_neg
static
struct FloatVect3 ff_nearest_obs_pos
static
abi_event obstacle_ev
static

Definition at line 63 of file range_forcefield.c.

Referenced by range_forcefield_init().

struct range_forcefield_param_t range_forcefield_param

Definition at line 56 of file range_forcefield.c.

Referenced by compute_ff_vel(), and range_forcefield_init().