#include <sensors.h>
|
turbomath::Vector | acc_sum_ = {0, 0, 0} |
|
float | acc_temp_sum_ = 0.0f |
|
float | accel_ [3] = {0, 0, 0} |
|
uint16_t | accel_calibration_count_ = 0 |
|
turbomath::Vector | accel_int_ |
|
bool | baro_calibrated_ = false |
|
uint16_t | baro_calibration_count_ = 0 |
|
float | baro_calibration_mean_ = 0.0f |
|
float | baro_calibration_var_ = 0.0f |
|
OutlierFilter | baro_outlier_filt_ |
|
float | battery_current_alpha_ {0.995} |
|
float | battery_voltage_alpha_ {0.995} |
|
bool | calibrating_acc_flag_ = false |
|
bool | calibrating_gyro_flag_ = false |
|
Data | data_ |
|
OutlierFilter | diff_outlier_filt_ |
|
bool | diff_pressure_calibrated_ = false |
|
uint16_t | diff_pressure_calibration_count_ = 0 |
|
float | diff_pressure_calibration_mean_ = 0.0f |
|
float | diff_pressure_calibration_var_ = 0.0f |
|
const turbomath::Vector | gravity_ = {0.0f, 0.0f, 9.80665f} |
|
float | ground_pressure_ = 0.0f |
|
float | gyro_ [3] = {0, 0, 0} |
|
uint16_t | gyro_calibration_count_ = 0 |
|
turbomath::Vector | gyro_int_ |
|
turbomath::Vector | gyro_sum_ = {0, 0, 0} |
|
bool | imu_data_sent_ |
|
uint64_t | int_start_us_ |
|
uint32_t | last_baro_cal_iter_ms_ = 0 |
|
uint32_t | last_battery_monitor_update_ms_ = 0 |
|
uint32_t | last_diff_pressure_cal_iter_ms_ = 0 |
|
uint32_t | last_imu_update_ms_ = 0 |
|
uint32_t | last_time_look_for_disarmed_sensors_ = 0 |
|
turbomath::Vector | max_ = {-1000.0f, -1000.0f, -1000.0f} |
|
turbomath::Vector | min_ = {1000.0f, 1000.0f, 1000.0f} |
|
bool | new_imu_data_ |
|
uint8_t | next_sensor_to_update_ = BAROMETER |
|
uint64_t | prev_imu_read_time_us_ |
|
ROSflight & | rf_ |
|
OutlierFilter | sonar_outlier_filt_ |
|
Definition at line 123 of file sensors.h.
◆ anonymous enum
Enumerator |
---|
BAROMETER | |
GNSS | |
DIFF_PRESSURE | |
SONAR | |
MAGNETOMETER | |
BATTERY_MONITOR | |
NUM_LOW_PRIORITY_SENSORS | |
Definition at line 218 of file sensors.h.
◆ Sensors()
rosflight_firmware::Sensors::Sensors |
( |
ROSflight & |
rosflight | ) |
|
◆ calibrate_accel()
void rosflight_firmware::Sensors::calibrate_accel |
( |
void |
| ) |
|
|
private |
◆ calibrate_baro()
void rosflight_firmware::Sensors::calibrate_baro |
( |
void |
| ) |
|
|
private |
◆ calibrate_diff_pressure()
void rosflight_firmware::Sensors::calibrate_diff_pressure |
( |
void |
| ) |
|
|
private |
◆ calibrate_gyro()
void rosflight_firmware::Sensors::calibrate_gyro |
( |
void |
| ) |
|
|
private |
◆ correct_baro()
void rosflight_firmware::Sensors::correct_baro |
( |
void |
| ) |
|
|
private |
◆ correct_diff_pressure()
void rosflight_firmware::Sensors::correct_diff_pressure |
( |
void |
| ) |
|
|
private |
◆ correct_imu()
void rosflight_firmware::Sensors::correct_imu |
( |
void |
| ) |
|
|
private |
◆ correct_mag()
void rosflight_firmware::Sensors::correct_mag |
( |
void |
| ) |
|
|
private |
◆ data()
const Data& rosflight_firmware::Sensors::data |
( |
| ) |
const |
|
inline |
◆ get_filtered_IMU()
◆ gyro_calibration_complete()
bool rosflight_firmware::Sensors::gyro_calibration_complete |
( |
void |
| ) |
|
◆ init()
void rosflight_firmware::Sensors::init |
( |
| ) |
|
◆ init_imu()
void rosflight_firmware::Sensors::init_imu |
( |
| ) |
|
|
private |
◆ look_for_disabled_sensors()
void rosflight_firmware::Sensors::look_for_disabled_sensors |
( |
void |
| ) |
|
|
private |
◆ param_change_callback()
void rosflight_firmware::Sensors::param_change_callback |
( |
uint16_t |
param_id | ) |
|
|
overridevirtual |
◆ run()
bool rosflight_firmware::Sensors::run |
( |
void |
| ) |
|
◆ should_send_imu_data()
bool rosflight_firmware::Sensors::should_send_imu_data |
( |
void |
| ) |
|
|
inline |
◆ start_baro_calibration()
bool rosflight_firmware::Sensors::start_baro_calibration |
( |
void |
| ) |
|
◆ start_diff_pressure_calibration()
bool rosflight_firmware::Sensors::start_diff_pressure_calibration |
( |
void |
| ) |
|
◆ start_gyro_calibration()
bool rosflight_firmware::Sensors::start_gyro_calibration |
( |
void |
| ) |
|
◆ start_imu_calibration()
bool rosflight_firmware::Sensors::start_imu_calibration |
( |
void |
| ) |
|
◆ update_battery_monitor()
void rosflight_firmware::Sensors::update_battery_monitor |
( |
void |
| ) |
|
|
private |
◆ update_battery_monitor_multipliers()
void rosflight_firmware::Sensors::update_battery_monitor_multipliers |
( |
void |
| ) |
|
|
private |
◆ update_imu()
bool rosflight_firmware::Sensors::update_imu |
( |
void |
| ) |
|
|
private |
◆ update_other_sensors()
void rosflight_firmware::Sensors::update_other_sensors |
( |
void |
| ) |
|
|
private |
◆ acc_sum_
◆ acc_temp_sum_
float rosflight_firmware::Sensors::acc_temp_sum_ = 0.0f |
|
private |
◆ accel_
float rosflight_firmware::Sensors::accel_[3] = {0, 0, 0} |
|
private |
◆ accel_calibration_count_
uint16_t rosflight_firmware::Sensors::accel_calibration_count_ = 0 |
|
private |
◆ accel_int_
◆ baro_calibrated_
bool rosflight_firmware::Sensors::baro_calibrated_ = false |
|
private |
◆ baro_calibration_count_
uint16_t rosflight_firmware::Sensors::baro_calibration_count_ = 0 |
|
private |
◆ baro_calibration_mean_
float rosflight_firmware::Sensors::baro_calibration_mean_ = 0.0f |
|
private |
◆ baro_calibration_var_
float rosflight_firmware::Sensors::baro_calibration_var_ = 0.0f |
|
private |
◆ BARO_MAX_CALIBRATION_VARIANCE
const float rosflight_firmware::Sensors::BARO_MAX_CALIBRATION_VARIANCE = 25.0 |
|
staticprivate |
◆ BARO_MAX_CHANGE_RATE
const float rosflight_firmware::Sensors::BARO_MAX_CHANGE_RATE = 200.0f |
|
staticprivate |
◆ baro_outlier_filt_
◆ BARO_SAMPLE_RATE
const float rosflight_firmware::Sensors::BARO_SAMPLE_RATE = 50.0f |
|
staticprivate |
◆ battery_current_alpha_
float rosflight_firmware::Sensors::battery_current_alpha_ {0.995} |
|
private |
◆ BATTERY_MONITOR_UPDATE_PERIOD_MS
constexpr uint32_t rosflight_firmware::Sensors::BATTERY_MONITOR_UPDATE_PERIOD_MS = 10 |
|
staticprivate |
◆ battery_voltage_alpha_
float rosflight_firmware::Sensors::battery_voltage_alpha_ {0.995} |
|
private |
◆ calibrating_acc_flag_
bool rosflight_firmware::Sensors::calibrating_acc_flag_ = false |
|
private |
◆ calibrating_gyro_flag_
bool rosflight_firmware::Sensors::calibrating_gyro_flag_ = false |
|
private |
◆ data_
Data rosflight_firmware::Sensors::data_ |
|
private |
◆ DIFF_MAX_CHANGE_RATE
const float rosflight_firmware::Sensors::DIFF_MAX_CHANGE_RATE = 225.0f |
|
staticprivate |
◆ diff_outlier_filt_
◆ diff_pressure_calibrated_
bool rosflight_firmware::Sensors::diff_pressure_calibrated_ = false |
|
private |
◆ diff_pressure_calibration_count_
uint16_t rosflight_firmware::Sensors::diff_pressure_calibration_count_ = 0 |
|
private |
◆ diff_pressure_calibration_mean_
float rosflight_firmware::Sensors::diff_pressure_calibration_mean_ = 0.0f |
|
private |
◆ diff_pressure_calibration_var_
float rosflight_firmware::Sensors::diff_pressure_calibration_var_ = 0.0f |
|
private |
◆ DIFF_PRESSURE_MAX_CALIBRATION_VARIANCE
const float rosflight_firmware::Sensors::DIFF_PRESSURE_MAX_CALIBRATION_VARIANCE = 100.0 |
|
staticprivate |
◆ DIFF_SAMPLE_RATE
const float rosflight_firmware::Sensors::DIFF_SAMPLE_RATE = 50.0f |
|
staticprivate |
◆ gravity_
const turbomath::Vector rosflight_firmware::Sensors::gravity_ = {0.0f, 0.0f, 9.80665f} |
|
private |
◆ ground_pressure_
float rosflight_firmware::Sensors::ground_pressure_ = 0.0f |
|
private |
◆ gyro_
float rosflight_firmware::Sensors::gyro_[3] = {0, 0, 0} |
|
private |
◆ gyro_calibration_count_
uint16_t rosflight_firmware::Sensors::gyro_calibration_count_ = 0 |
|
private |
◆ gyro_int_
◆ gyro_sum_
◆ imu_data_sent_
bool rosflight_firmware::Sensors::imu_data_sent_ |
|
private |
◆ int_start_us_
uint64_t rosflight_firmware::Sensors::int_start_us_ |
|
private |
◆ last_baro_cal_iter_ms_
uint32_t rosflight_firmware::Sensors::last_baro_cal_iter_ms_ = 0 |
|
private |
◆ last_battery_monitor_update_ms_
uint32_t rosflight_firmware::Sensors::last_battery_monitor_update_ms_ = 0 |
|
private |
◆ last_diff_pressure_cal_iter_ms_
uint32_t rosflight_firmware::Sensors::last_diff_pressure_cal_iter_ms_ = 0 |
|
private |
◆ last_imu_update_ms_
uint32_t rosflight_firmware::Sensors::last_imu_update_ms_ = 0 |
|
private |
◆ last_time_look_for_disarmed_sensors_
uint32_t rosflight_firmware::Sensors::last_time_look_for_disarmed_sensors_ = 0 |
|
private |
◆ max_
◆ min_
◆ new_imu_data_
bool rosflight_firmware::Sensors::new_imu_data_ |
|
private |
◆ next_sensor_to_update_
uint8_t rosflight_firmware::Sensors::next_sensor_to_update_ = BAROMETER |
|
private |
◆ prev_imu_read_time_us_
uint64_t rosflight_firmware::Sensors::prev_imu_read_time_us_ |
|
private |
◆ rf_
◆ SENSOR_CAL_CYCLES
const int rosflight_firmware::Sensors::SENSOR_CAL_CYCLES = 127 |
|
staticprivate |
◆ SENSOR_CAL_DELAY_CYCLES
const int rosflight_firmware::Sensors::SENSOR_CAL_DELAY_CYCLES = 128 |
|
staticprivate |
◆ SONAR_MAX_CHANGE_RATE
const float rosflight_firmware::Sensors::SONAR_MAX_CHANGE_RATE = 100.0f |
|
staticprivate |
◆ sonar_outlier_filt_
◆ SONAR_SAMPLE_RATE
const float rosflight_firmware::Sensors::SONAR_SAMPLE_RATE = 50.0f |
|
staticprivate |
The documentation for this class was generated from the following files: