Defines | Functions

map_handling.c File Reference

#include <robot.h>
#include <robodim.h>
#include <map.h>
#include <robomath.h>
#include <hokuyo.h>
Include dependency graph for map_handling.c:

Defines

#define OBS_SIZE_M   0.1
 Expected size of detected obstacle.
#define IGNORE_CLOSER_THAN_M   0.1
 Do not mark any obstacle closer than this to center of the robot (avoid path planning deadlock).
#define IGNORE_FURTHER_THAN_M   0.5
 Ignore data from sharp if further than this.
#define OBS_FORGET_PERIOD   100
 The period of thread_obstacle_forgeting [ms].
#define OBS_FORGET_SEC   1
 Time to completely forget detected obstacle.
#define OBS_OFFSET   0.6

Functions

void obstacle_detected_at (double x, double y, bool real_obstacle)
void obst_coord (struct robot_pos_type *e, const struct sharp_pos *s, double v, double *x, double *y)
 A thread running the trajectory recalc.
void update_map_hokuyo (struct hokuyo_scan_type *s)
void * thread_obstacle_forgeting (void *arg)
 A thread updating the map.

Define Documentation

#define IGNORE_CLOSER_THAN_M   0.1

Do not mark any obstacle closer than this to center of the robot (avoid path planning deadlock).

#define IGNORE_FURTHER_THAN_M   0.5

Ignore data from sharp if further than this.

#define OBS_FORGET_PERIOD   100

The period of thread_obstacle_forgeting [ms].

#define OBS_FORGET_SEC   1

Time to completely forget detected obstacle.

#define OBS_OFFSET   0.6
#define OBS_SIZE_M   0.1

Expected size of detected obstacle.


Function Documentation

void obst_coord ( struct robot_pos_type *  e,
const struct sharp_pos s,
double  v,
double *  x,
double *  y 
)

A thread running the trajectory recalc.

This (low-medium priority) thread updates the map with sensors information. If it is necesary, it recalculate the path.

Parameters:
arg 
Returns:

Here is the call graph for this function:

Here is the caller graph for this function:

void obstacle_detected_at ( double  x,
double  y,
bool  real_obstacle 
)

Then all the cells arround obstacle cell are set as MAP_NEW_OBSTACLE. Cells of current robot position are not set to avoid path planning deadlock. If there are a path cell between them, the path will be recalculated.

See also:
OBS_CSPACE.

Here is the call graph for this function:

Here is the caller graph for this function:

void* thread_obstacle_forgeting ( void *  arg  ) 

A thread updating the map.

Here is the call graph for this function:

Here is the caller graph for this function:

void update_map_hokuyo ( struct hokuyo_scan_type *  s  ) 

Here is the call graph for this function:

Here is the caller graph for this function: