vehicle_gps_position: remove timestamp_variance & timestamp_velocity (they're not used)

This commit is contained in:
Beat Küng
2016-06-24 00:22:01 +02:00
committed by Lorenz Meier
parent 89f5bd27e8
commit e2a7145379
8 changed files with 6 additions and 22 deletions
+2 -2
View File
@@ -525,7 +525,7 @@ void Ekf2::task_main()
gps_msg.eph = gps.eph;
gps_msg.epv = gps.epv;
gps_msg.sacc = gps.s_variance_m_s;
gps_msg.time_usec_vel = gps.timestamp_velocity;
gps_msg.time_usec_vel = gps.timestamp;
gps_msg.vel_m_s = gps.vel_m_s;
gps_msg.vel_ned[0] = gps.vel_n_m_s;
gps_msg.vel_ned[1] = gps.vel_e_m_s;
@@ -910,7 +910,7 @@ void Ekf2::task_main()
// only write gps data if we had a gps update.
if (gps_updated) {
replay.time_usec = gps.timestamp;
replay.time_usec_vel = gps.timestamp_velocity;
replay.time_usec_vel = gps.timestamp;
replay.lat = gps.lat;
replay.lon = gps.lon;
replay.alt = gps.alt;
-2
View File
@@ -1791,10 +1791,8 @@ MavlinkReceiver::handle_message_hil_gps(mavlink_message_t *msg)
hil_gps.eph = (float)gps.eph * 1e-2f; // from cm to m
hil_gps.epv = (float)gps.epv * 1e-2f; // from cm to m
hil_gps.timestamp_variance = timestamp;
hil_gps.s_variance_m_s = 5.0f;
hil_gps.timestamp_velocity = timestamp;
hil_gps.vel_m_s = (float)gps.vel * 1e-2f; // from cm/s to m/s
hil_gps.vel_n_m_s = gps.vn * 1e-2f; // from cm to m
hil_gps.vel_e_m_s = gps.ve * 1e-2f; // from cm to m
@@ -1212,7 +1212,7 @@ int position_estimator_inav_thread_main(int argc, char *argv[])
inertial_filter_correct(corr_gps[0][0], dt, x_est, 0, w_xy_gps_p);
inertial_filter_correct(corr_gps[1][0], dt, y_est, 0, w_xy_gps_p);
if (gps.vel_ned_valid && t < gps.timestamp_velocity + gps_topic_timeout) {
if (gps.vel_ned_valid && t < gps.timestamp + gps_topic_timeout) {
inertial_filter_correct(corr_gps[0][1], dt, x_est, 1, w_xy_gps_v);
inertial_filter_correct(corr_gps[1][1], dt, y_est, 1, w_xy_gps_v);
}
-3
View File
@@ -109,8 +109,6 @@ void UavcanGnssBridge::gnss_fix_sub_cb(const uavcan::ReceivedDataStructure<uavca
report.lon = msg.longitude_deg_1e8 / 10;
report.alt = msg.height_msl_mm;
report.timestamp_variance = report.timestamp;
// Check if the msg contains valid covariance information
const bool valid_position_covariance = !msg.position_covariance.empty();
@@ -163,7 +161,6 @@ void UavcanGnssBridge::gnss_fix_sub_cb(const uavcan::ReceivedDataStructure<uavca
report.fix_type = msg.status;
report.timestamp_velocity = report.timestamp;
report.vel_n_m_s = msg.ned_velocity[0];
report.vel_e_m_s = msg.ned_velocity[1];
report.vel_d_m_s = msg.ned_velocity[2];