PX4 Firmware
PX4 Autopilot Software http://px4.io
|
Classes | |
struct | accel_calibration_s |
struct | gyro_calibration_s |
Public Member Functions | |
DfMPU6050Wrapper (enum Rotation rotation) | |
~DfMPU6050Wrapper () | |
int | start () |
Start automatic measurement. More... | |
int | stop () |
Stop automatic measurement. More... | |
void | info () |
Print some debug info. More... | |
Private Member Functions | |
int | _publish (struct imu_sensor_data &data) |
void | _update_accel_calibration () |
void | _update_gyro_calibration () |
Definition at line 78 of file df_mpu6050_wrapper.cpp.
DfMPU6050Wrapper::DfMPU6050Wrapper | ( | enum Rotation | rotation | ) |
Definition at line 158 of file df_mpu6050_wrapper.cpp.
References _accel_calibration, _accel_int, _accel_orb_class_instance, _accel_range_hit_counter, _error_counter, _fifo_corruption_counter, _fifo_overflow_counter, _gyro_calibration, _gyro_int, _gyro_orb_class_instance, _gyro_range_hit_counter, _last_accel_range_hit_count, _last_accel_range_hit_time, _publish_count, _publish_perf, _read_counter, _rotation_matrix, get_rot_matrix(), MPU6050_NEVER_AUTOPUBLISH_US, PC_COUNT, PC_ELAPSED, perf_alloc, DfMPU6050Wrapper::accel_calibration_s::x_offset, DfMPU6050Wrapper::gyro_calibration_s::x_offset, DfMPU6050Wrapper::accel_calibration_s::x_scale, DfMPU6050Wrapper::gyro_calibration_s::x_scale, DfMPU6050Wrapper::accel_calibration_s::y_offset, DfMPU6050Wrapper::gyro_calibration_s::y_offset, DfMPU6050Wrapper::accel_calibration_s::y_scale, DfMPU6050Wrapper::gyro_calibration_s::y_scale, DfMPU6050Wrapper::accel_calibration_s::z_offset, DfMPU6050Wrapper::gyro_calibration_s::z_offset, DfMPU6050Wrapper::accel_calibration_s::z_scale, and DfMPU6050Wrapper::gyro_calibration_s::z_scale.
Referenced by df_mpu6050_wrapper::start().
DfMPU6050Wrapper::~DfMPU6050Wrapper | ( | ) |
Definition at line 200 of file df_mpu6050_wrapper.cpp.
References _accel_range_hit_counter, _error_counter, _fifo_corruption_counter, _fifo_overflow_counter, _gyro_range_hit_counter, _publish_perf, _read_counter, and perf_free().
|
private |
Definition at line 419 of file df_mpu6050_wrapper.cpp.
References _accel_calibration, _accel_int, _accel_orb_class_instance, _accel_range_hit_counter, _accel_topic, _error_counter, _fifo_corruption_counter, _fifo_overflow_counter, _gyro_calibration, _gyro_int, _gyro_orb_class_instance, _gyro_range_hit_counter, _gyro_topic, _last_accel_range_hit_count, _last_accel_range_hit_time, _mavlink_log_pub, _param_update_sub, _publish_count, _publish_perf, _read_counter, _rotation_matrix, _update_accel_calibration(), _update_gyro_calibration(), sensor_gyro_s::device_id, sensor_accel_s::device_id, Integrator::get_and_filtered(), hrt_absolute_time(), hrt_elapsed_time(), sensor_gyro_s::integral_dt, sensor_accel_s::integral_dt, mavlink_log_critical, orb_advertise_multi(), orb_check(), orb_copy(), ORB_ID, ORB_PRIO_DEFAULT, orb_publish(), perf_begin(), perf_end(), perf_set_count(), Integrator::put(), sensor_gyro_s::scaling, sensor_accel_s::scaling, sensor_accel_s::timestamp, sensor_gyro_s::timestamp, sensor_accel_s::x, sensor_gyro_s::x, sensor_gyro_s::x_integral, sensor_accel_s::x_integral, DfMPU6050Wrapper::accel_calibration_s::x_offset, DfMPU6050Wrapper::gyro_calibration_s::x_offset, sensor_gyro_s::x_raw, sensor_accel_s::x_raw, DfMPU6050Wrapper::accel_calibration_s::x_scale, DfMPU6050Wrapper::gyro_calibration_s::x_scale, sensor_accel_s::y, sensor_gyro_s::y, sensor_accel_s::y_integral, sensor_gyro_s::y_integral, DfMPU6050Wrapper::accel_calibration_s::y_offset, DfMPU6050Wrapper::gyro_calibration_s::y_offset, sensor_accel_s::y_raw, sensor_gyro_s::y_raw, DfMPU6050Wrapper::accel_calibration_s::y_scale, DfMPU6050Wrapper::gyro_calibration_s::y_scale, sensor_gyro_s::z, sensor_accel_s::z, sensor_accel_s::z_integral, sensor_gyro_s::z_integral, DfMPU6050Wrapper::accel_calibration_s::z_offset, DfMPU6050Wrapper::gyro_calibration_s::z_offset, sensor_gyro_s::z_raw, sensor_accel_s::z_raw, DfMPU6050Wrapper::accel_calibration_s::z_scale, and DfMPU6050Wrapper::gyro_calibration_s::z_scale.
|
private |
Definition at line 343 of file df_mpu6050_wrapper.cpp.
References _accel_calibration, device_id, OK, param_find(), param_get(), DfMPU6050Wrapper::accel_calibration_s::x_offset, DfMPU6050Wrapper::accel_calibration_s::x_scale, DfMPU6050Wrapper::accel_calibration_s::y_offset, DfMPU6050Wrapper::accel_calibration_s::y_scale, DfMPU6050Wrapper::accel_calibration_s::z_offset, and DfMPU6050Wrapper::accel_calibration_s::z_scale.
Referenced by _publish(), and start().
|
private |
Definition at line 268 of file df_mpu6050_wrapper.cpp.
References _gyro_calibration, device_id, OK, param_find(), param_get(), DfMPU6050Wrapper::gyro_calibration_s::x_offset, DfMPU6050Wrapper::gyro_calibration_s::x_scale, DfMPU6050Wrapper::gyro_calibration_s::y_offset, DfMPU6050Wrapper::gyro_calibration_s::y_scale, DfMPU6050Wrapper::gyro_calibration_s::z_offset, and DfMPU6050Wrapper::gyro_calibration_s::z_scale.
Referenced by _publish(), and start().
void DfMPU6050Wrapper::info | ( | ) |
Print some debug info.
Definition at line 256 of file df_mpu6050_wrapper.cpp.
References _accel_range_hit_counter, _error_counter, _fifo_corruption_counter, _fifo_overflow_counter, _gyro_range_hit_counter, _publish_perf, _read_counter, and perf_print_counter().
Referenced by df_mpu6050_wrapper::info().
int DfMPU6050Wrapper::start | ( | ) |
Start automatic measurement.
Definition at line 212 of file df_mpu6050_wrapper.cpp.
References _param_update_sub, _update_accel_calibration(), _update_gyro_calibration(), ToneAlarmInterface::init(), ORB_ID, orb_subscribe(), and start().
Referenced by df_mpu6050_wrapper::start().
int DfMPU6050Wrapper::stop | ( | ) |
Stop automatic measurement.
Definition at line 243 of file df_mpu6050_wrapper.cpp.
References stop().
Referenced by df_mpu6050_wrapper::stop().
|
private |
Referenced by _publish(), _update_accel_calibration(), and DfMPU6050Wrapper().
|
private |
Definition at line 140 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().
|
private |
Definition at line 137 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().
|
private |
Definition at line 150 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), DfMPU6050Wrapper(), info(), and ~DfMPU6050Wrapper().
|
private |
Definition at line 110 of file df_mpu6050_wrapper.cpp.
Referenced by _publish().
|
private |
Definition at line 146 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), DfMPU6050Wrapper(), info(), and ~DfMPU6050Wrapper().
|
private |
Definition at line 148 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), DfMPU6050Wrapper(), info(), and ~DfMPU6050Wrapper().
|
private |
Definition at line 147 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), DfMPU6050Wrapper(), info(), and ~DfMPU6050Wrapper().
|
private |
Referenced by _publish(), _update_gyro_calibration(), and DfMPU6050Wrapper().
|
private |
Definition at line 141 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().
|
private |
Definition at line 138 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().
|
private |
Definition at line 149 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), DfMPU6050Wrapper(), info(), and ~DfMPU6050Wrapper().
|
private |
Definition at line 111 of file df_mpu6050_wrapper.cpp.
Referenced by _publish().
|
private |
Definition at line 154 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().
|
private |
Definition at line 153 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().
|
private |
Definition at line 113 of file df_mpu6050_wrapper.cpp.
Referenced by _publish().
|
private |
Definition at line 115 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and start().
|
private |
Definition at line 143 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().
|
private |
Definition at line 151 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), DfMPU6050Wrapper(), info(), and ~DfMPU6050Wrapper().
|
private |
Definition at line 145 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), DfMPU6050Wrapper(), info(), and ~DfMPU6050Wrapper().
|
private |
Definition at line 135 of file df_mpu6050_wrapper.cpp.
Referenced by _publish(), and DfMPU6050Wrapper().