Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
Loading...
Searching...
No Matches
rover_obstacles.h File Reference
#include "std.h"
Include dependency graph for rover_obstacles.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  bayesian_map
struct  world_grid

Macros

#define N_COL_GRID   100
#define N_ROW_GRID   100
#define GRID_BLOCK_SIZE   4

Functions

void init_grid (uint8_t pa, uint8_t pb)
void init_grid_4 (uint8_t wp1, uint8_t wp2, uint8_t wp3, uint8_t wp4)
void obtain_cell_xy (float px, float py, int *cell_x, int *cell_y)
void fill_cell (float px, float py)
void fill_bayesian_cell (float px, float py)
void fill_free_cells (float lidar, float angle)
void decay_map (void)
void update_line_bayes (int x0, int y0, int x1, int y1)
void update_cell (int x, int y, int new_value)
void compute_cell_bayes (int x, int y, bool is_occupied)
void check_probs (void)

Variables

world_grid obstacle_grid
uint8_t grid_block_size

Data Structure Documentation

◆ bayesian_map

struct bayesian_map

Definition at line 44 of file rover_obstacles.h.

Data Fields
uint8_t decay
float free
int8_t LT
float occ
float threshold

◆ world_grid

struct world_grid

Definition at line 53 of file rover_obstacles.h.

Collaboration diagram for world_grid:
Data Fields
float dx
float dy
float home[2]
int is_ready
bayesian_map map
uint16_t now_row
int8_t world[N_ROW_GRID][N_COL_GRID]
float xmax
float xmin
float ymax
float ymin

Macro Definition Documentation

◆ GRID_BLOCK_SIZE

#define GRID_BLOCK_SIZE   4

Definition at line 69 of file rover_obstacles.h.

◆ N_COL_GRID

#define N_COL_GRID   100

◆ N_ROW_GRID

#define N_ROW_GRID   100

Function Documentation

◆ check_probs()

void check_probs ( void )
extern

Definition at line 344 of file rover_obstacles.c.

References LFREE, LOCC, LT, obstacle_grid, PFREE, POCC, PT, and SCALE.

Referenced by compute_cell_bayes().

Here is the caller graph for this function:

◆ compute_cell_bayes()

void compute_cell_bayes ( int x,
int y,
bool is_occupied )
extern

Definition at line 325 of file rover_obstacles.c.

References check_probs(), L_MAX, L_MIN, LFREE, LOCC, N_COL_GRID, N_ROW_GRID, obstacle_grid, update_cell(), EnuCoor_f::x, and EnuCoor_f::y.

Referenced by fill_bayesian_cell(), fill_free_cells(), and update_line_bayes().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ decay_map()

void decay_map ( void )
extern

Definition at line 256 of file rover_obstacles.c.

References DECAY_INTERVAL, get_sys_time_msec(), last_s, N_COL_GRID, N_ROW_GRID, obstacle_grid, update_cell(), EnuCoor_f::x, and EnuCoor_f::y.

Here is the call graph for this function:

◆ fill_bayesian_cell()

void fill_bayesian_cell ( float px,
float py )
extern

Definition at line 203 of file rover_obstacles.c.

References compute_cell_bayes(), obstacle_grid, obtain_cell_xy(), rover_pos, stateGetPositionEnu_f(), and update_line_bayes().

Referenced by ins_update_lidar().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fill_cell()

void fill_cell ( float px,
float py )
extern

Definition at line 194 of file rover_obstacles.c.

References obstacle_grid, and obtain_cell_xy().

Here is the call graph for this function:

◆ fill_free_cells()

void fill_free_cells ( float lidar,
float angle )
extern

◆ init_grid()

void init_grid ( uint8_t pa,
uint8_t pb )
extern

Definition at line 109 of file rover_obstacles.c.

References DefaultPeriodic, L0, N_COL_GRID, N_ROW_GRID, obstacle_grid, register_periodic_telemetry(), send_grid_init(), WaypointX, and WaypointY.

Here is the call graph for this function:

◆ init_grid_4()

void init_grid_4 ( uint8_t wp1,
uint8_t wp2,
uint8_t wp3,
uint8_t wp4 )
extern

◆ obtain_cell_xy()

void obtain_cell_xy ( float px,
float py,
int * cell_x,
int * cell_y )
extern

Definition at line 182 of file rover_obstacles.c.

References obstacle_grid.

Referenced by fill_bayesian_cell(), fill_cell(), and fill_free_cells().

Here is the caller graph for this function:

◆ update_cell()

void update_cell ( int x,
int y,
int new_value )
extern

Definition at line 306 of file rover_obstacles.c.

References DefaultChannel, DefaultDevice, LT, obstacle_grid, EnuCoor_f::x, and EnuCoor_f::y.

Referenced by compute_cell_bayes(), and decay_map().

Here is the caller graph for this function:

◆ update_line_bayes()

void update_line_bayes ( int x0,
int y0,
int x1,
int y1 )
extern

Definition at line 289 of file rover_obstacles.c.

References compute_cell_bayes().

Referenced by fill_bayesian_cell(), and fill_free_cells().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ grid_block_size

uint8_t grid_block_size
extern

Definition at line 76 of file rover_obstacles.c.

◆ obstacle_grid