landdetector: delete function update_alt_max

This commit is contained in:
Dennis Mannhart
2017-02-27 22:54:19 +01:00
committed by Lorenz Meier
parent 1774e01c00
commit 3d4e7819a0
2 changed files with 2 additions and 10 deletions
+2 -7
View File
@@ -125,7 +125,8 @@ void LandDetector::_cycle()
_update_state(); _update_state();
float alt_max_prev = _altitude_max; float alt_max_prev = _altitude_max;
_update_max_altitude(); _altitude_max = _get_max_altitude();
bool freefallDetected = (_state == LandDetectionState::FREEFALL); bool freefallDetected = (_state == LandDetectionState::FREEFALL);
bool landDetected = (_state == LandDetectionState::LANDED); bool landDetected = (_state == LandDetectionState::LANDED);
@@ -221,12 +222,6 @@ void LandDetector::_update_state()
} }
} }
void LandDetector::_update_max_altitude()
{
_altitude_max = _get_max_altitude();
}
bool LandDetector::_orb_update(const struct orb_metadata *meta, int handle, void *buffer) bool LandDetector::_orb_update(const struct orb_metadata *meta, int handle, void *buffer)
{ {
bool newData = false; bool newData = false;
-3
View File
@@ -169,9 +169,6 @@ private:
void _update_state(); void _update_state();
void _update_max_altitude();
bool _taskShouldExit; bool _taskShouldExit;
bool _taskIsRunning; bool _taskIsRunning;