|
Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
Library for generic map to store and search from sensor data. More...
Include dependency graph for search_map.c:Go to the source code of this file.
Macros | |
| #define | SEARCH_MAP_DEBUG 0 |
| #define | DEBUG_PRINT(...) {} |
Functions | |
| void | search_map_init (struct search_map_t *map, struct NedCoor_f pos, float res) |
| init map | |
| void | search_map_init_from_wp (struct search_map_t *map, uint8_t wp_id, float res) |
| init map from waypoint | |
| void | search_map_reset (struct search_map_t *map) |
| reset map | |
| bool | search_map_update (struct search_map_t *map, float data, struct NedCoor_f pos) |
| update map with new data | |
| float | search_map_get_barycenter (struct search_map_t *map, float threshold, struct NedCoor_f *pos) |
| get weighted center of the data, expected to be the search position | |
| void | search_map_update_wp (struct search_map_t *map, float threshold, uint8_t wp_id) |
| update waypoint position from map | |
Library for generic map to store and search from sensor data.
Definition in file search_map.c.
| #define DEBUG_PRINT | ( | ... | ) | {} |
Definition at line 34 of file search_map.c.
| #define SEARCH_MAP_DEBUG 0 |
Definition at line 29 of file search_map.c.
| float search_map_get_barycenter | ( | struct search_map_t * | map, |
| float | threshold, | ||
| struct NedCoor_f * | pos | ||
| ) |
get weighted center of the data, expected to be the search position
| [in] | map | pointer to map |
| [in] | threshold | value between 0 and 1 to filter data (only consider the normalized data above the threshold) |
| [out] | pos | pointer to computed position |
Definition at line 79 of file search_map.c.
References search_map_t::center, DEBUG_PRINT, foo, search_map_t::grid, offset, search_map_t::res, SEARCH_MAP_SIZE, val, NedCoor_f::x, NedCoor_f::y, and NedCoor_f::z.
Referenced by search_map_update_wp().
Here is the caller graph for this function:| void search_map_init | ( | struct search_map_t * | map, |
| struct NedCoor_f | pos, | ||
| float | res | ||
| ) |
init map
| [in] | map | pointer to map |
| [in] | pos | position of the map center |
| [in] | res | resolution of the map in m per cell |
Definition at line 38 of file search_map.c.
References search_map_t::center, DEBUG_PRINT, foo, search_map_t::grid, search_map_t::res, SEARCH_MAP_SIZE, NedCoor_f::x, and NedCoor_f::y.
Referenced by search_map_init_from_wp().
Here is the caller graph for this function:| void search_map_init_from_wp | ( | struct search_map_t * | map, |
| uint8_t | wp_id, | ||
| float | res | ||
| ) |
init map from waypoint
| [in] | map | pointer to map |
| [in] | wp_id | waypoint ID |
| [in] | res | resolution of the map in m per cell |
Definition at line 50 of file search_map.c.
References ENU_OF_TO_NED, foo, search_map_init(), and waypoint_get_enu_f().
Referenced by scout_detector_init().
Here is the call graph for this function:
Here is the caller graph for this function:| void search_map_reset | ( | struct search_map_t * | map | ) |
reset map
| [in] | map | pointer to map |
Definition at line 58 of file search_map.c.
References foo, search_map_t::grid, and SEARCH_MAP_SIZE.
| bool search_map_update | ( | struct search_map_t * | map, |
| float | data, | ||
| struct NedCoor_f | pos | ||
| ) |
update map with new data
| [in] | map | pointer to map |
| [in] | data | new data |
| [in] | pos | position of the new data |
Definition at line 67 of file search_map.c.
References search_map_t::center, DEBUG_PRINT, foo, search_map_t::grid, search_map_t::res, SEARCH_MAP_SIZE, NedCoor_f::x, and NedCoor_f::y.
Referenced by scout_detector_sim(), and scout_detector_uavcan_cb().
Here is the caller graph for this function:| void search_map_update_wp | ( | struct search_map_t * | map, |
| float | threshold, | ||
| uint8_t | wp_id | ||
| ) |
update waypoint position from map
| [in] | map | pointer to map |
| [in] | threshold | value between 0 and 1 to filter data (only consider the normalized data above the threshold) |
| [in] | wp_id | waypoint ID |
Definition at line 135 of file search_map.c.
References ENU_OF_TO_NED, foo, search_map_get_barycenter(), and waypoint_set_enu().
Here is the call graph for this function: