Skip to content

Commit

Permalink
Update AP_Avoidance.cpp
Browse files Browse the repository at this point in the history
bug fix in z calc
  • Loading branch information
PeterJBurke authored Dec 15, 2024
1 parent 2e775b1 commit b421c1b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libraries/AP_Avoidance/AP_Avoidance.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -737,7 +737,7 @@ void AP_Avoidance::handle_avoidance_local(AP_Avoidance::Obstacle *threat)
m_altitude_geodetic -= undulation;
// Now we have m_altitude_geodetic in meters of craft under threat (i.e. this one)
//instantaneous_z = 0.01*threat->_location.alt-m_altitude_geodetic;
instantaneous_z = m_altitude_geodetic- 0.01*threat._location.alt; // altitude of drone over threat now
instantaneous_z = m_altitude_geodetic- 0.01*threat->_location.alt; // altitude of drone over threat now
}
}
// ************ BUG FIXED END *************************
Expand Down

0 comments on commit b421c1b

Please sign in to comment.