|
Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
Ground detection module. More...
#include "ground_detect.h"#include "filters/median_filter.h"#include "firmwares/rotorcraft/autopilot_firmware.h"#include "modules/core/abi.h"#include "state.h"#include "pprzlink/messages.h"#include "modules/datalink/downlink.h"#include "modules/datalink/telemetry.h"
Include dependency graph for ground_detect.c:Go to the source code of this file.
Data Structures | |
| struct | force_sensor_data_t |
Functions | |
| static void | send_ground_detect (struct transport_tx *trans, struct link_device *dev) |
| void | ground_detect_init () |
| bool | ground_detect (void) |
| void | ground_detect_periodic () |
| void | ground_detect_filter_accel (void) |
| Filter the vertical acceleration with a low cutoff frequency. | |
| bool | ground_detect_reverse_thrust (void) |
| void | ground_detect_stop_reverse_thrust (void) |
| void | ground_detect_start_reverse_thrust (void) |
| void | ground_detect_set_offset_sensors (bool set_offset) |
Ground detection module.
Definition in file ground_detect.c.
| struct force_sensor_data_t |
Definition at line 127 of file ground_detect.c.
| Data Fields | ||
|---|---|---|
| uint8_t | count | |
| int32_t | offsets[FORCE_SENSOR_MAX_NB] | |
| int32_t | values_filt[FORCE_SENSOR_MAX_NB] | |
| #define FORCE_SENSOR_MAX_NB 16 |
Definition at line 67 of file ground_detect.c.
| #define GROUND_DETECT_COUNTER_TRIGGER 5 |
Definition at line 107 of file ground_detect.c.
| #define GROUND_DETECT_FILT_FREQ 5.0 |
Definition at line 112 of file ground_detect.c.
| #define GROUND_DETECT_FORCE_SENSOR_MEDIAN_FILT_SIZE 3 |
Definition at line 63 of file ground_detect.c.
| #define GROUND_DETECT_FORCE_SENSOR_THRESHOLD 100000 |
Definition at line 59 of file ground_detect.c.
| #define GROUND_DETECT_NUM_TRIGGERS 3 |
Definition at line 38 of file ground_detect.c.
Definition at line 78 of file ground_detect.c.
| #define GROUND_DETECT_SPECIFIC_THRUST_THRESHOLD -5.0 |
Definition at line 92 of file ground_detect.c.
| #define GROUND_DETECT_USE_FORCE_SENSOR 0 |
Definition at line 55 of file ground_detect.c.
| #define GROUND_DETECT_VERTICAL_ACCEL_THRESHOLD -3.0 |
Definition at line 102 of file ground_detect.c.
| #define GROUND_DETECT_VERTICAL_SPEED_THRESHOLD 0.1 |
Definition at line 97 of file ground_detect.c.
Definition at line 230 of file ground_detect.c.
References ground_detected.
Filter the vertical acceleration with a low cutoff frequency.
Definition at line 313 of file ground_detect.c.
References ground_detect_values_t::accel_down_filt, ground_detect_values, stateGetAccelNed_f(), update_butterworth_2_low_pass(), and NedCoor_f::z.
Here is the call graph for this function:Definition at line 199 of file ground_detect.c.
References ground_detect_values_t::accel_down_filt, ground_detect_values_t::agl_dist_value_filtered, force_sensor_data_t::count, DefaultPeriodic, foo, force_sensor, FORCE_SENSOR_MAX_NB, GROUND_DETECT_FILT_FREQ, GROUND_DETECT_FORCE_SENSOR_MEDIAN_FILT_SIZE, ground_detect_status, ground_detect_values, init_butterworth_2_low_pass(), init_median_filter_i(), force_sensor_data_t::offsets, register_periodic_telemetry(), send_ground_detect(), ground_detect_values_t::spec_thrust_down, ground_detect_values_t::speed_down, ground_detect_bitmask_t::value, and force_sensor_data_t::values_filt.
Here is the call graph for this function:Definition at line 241 of file ground_detect.c.
References ground_detect_values_t::accel_down_filt, act_is_servo, actuator_state_filt_vect, agl_dist_valid, ground_detect_values_t::agl_dist_value_filtered, agl_dist_value_filtered, autopilot_set_motors_on(), counter, disarm_on_not_in_flight, foo, g1g2, GROUND_DETECT_COUNTER_TRIGGER, GROUND_DETECT_NUM_TRIGGERS, GROUND_DETECT_SPECIFIC_THRUST_THRESHOLD, ground_detect_status, ground_detect_values, GROUND_DETECT_VERTICAL_ACCEL_THRESHOLD, GROUND_DETECT_VERTICAL_SPEED_THRESHOLD, ground_detected, SecondOrderLowPass::o, ground_detect_values_t::spec_thrust_down, ground_detect_values_t::speed_down, stateGetNedToBodyRMat_f(), stateGetSpeedNed_f(), ground_detect_bitmask_t::value, and NedCoor_f::z.
Here is the call graph for this function:Definition at line 319 of file ground_detect.c.
References GROUND_DETECT_REVERSE_THRUST_ON_GROUND_DETECTED, and reverse_thrust.
Definition at line 339 of file ground_detect.c.
References foo.
Definition at line 334 of file ground_detect.c.
References reverse_thrust.
Definition at line 329 of file ground_detect.c.
References reverse_thrust.
|
static |
Definition at line 182 of file ground_detect.c.
References ground_detect_values_t::accel_down_filt, ground_detect_values_t::agl_dist_value_filtered, force_sensor_data_t::count, dev, foo, force_sensor, ground_detect_status, ground_detect_values, ground_detected, SecondOrderLowPass::o, ground_detect_values_t::spec_thrust_down, ground_detect_values_t::speed_down, ground_detect_bitmask_t::value, and force_sensor_data_t::values_filt.
Referenced by ground_detect_init().
Here is the caller graph for this function:| int32_t counter = 0 |
Definition at line 117 of file ground_detect.c.
Referenced by ground_detect_periodic().
Definition at line 115 of file ground_detect.c.
Referenced by ground_detect_periodic().
|
static |
Definition at line 133 of file ground_detect.c.
Referenced by ground_detect_init(), and send_ground_detect().
| float force_sensor_ground_threshold = GROUND_DETECT_FORCE_SENSOR_THRESHOLD |
Definition at line 125 of file ground_detect.c.
| union ground_detect_bitmask_t ground_detect_status |
Definition at line 122 of file ground_detect.c.
Referenced by ground_detect_init(), ground_detect_periodic(), and send_ground_detect().
| struct ground_detect_values_t ground_detect_values |
Definition at line 123 of file ground_detect.c.
Referenced by ground_detect_filter_accel(), ground_detect_init(), ground_detect_periodic(), and send_ground_detect().
Definition at line 118 of file ground_detect.c.
Referenced by ground_detect(), ground_detect_periodic(), and send_ground_detect().
| uint16_t reverse_th_level = 0 |
Definition at line 88 of file ground_detect.c.
Definition at line 120 of file ground_detect.c.
Referenced by ground_detect_reverse_thrust(), ground_detect_start_reverse_thrust(), and ground_detect_stop_reverse_thrust().