FlightTaskManual: method to reset all members setpoints to NAN

This commit is contained in:
Dennis Mannhart
2018-02-15 11:09:39 +01:00
committed by Beat Küng
parent 52eeb02549
commit 2e9cb659c9
+10 -1
View File
@@ -1,6 +1,6 @@
/****************************************************************************
*
* Copyright (c) 2017 PX4 Development Team. All rights reserved.
* Copyright (c) 2018 PX4 Development Team. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -98,3 +98,12 @@ bool FlightTaskManual::_evaluateSticks()
return false;
}
}
void FlightTaskManual::_resetToNAN()
{
_thr_sp *= NAN;
_vel_sp *= NAN;
_pos_sp *= NAN;
_yaw_sp = NAN;
_yaw_rate_sp = NAN;
}