mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-07-02 06:00:36 +08:00
Use namespace std so that we can use the isfinite function, which should be available from math.h but the compiler gives an error that the function is undeclared
This commit is contained in:
@@ -51,7 +51,8 @@
|
||||
#else
|
||||
#include<ros_error.h>
|
||||
#include <cmath>
|
||||
#define isfinite std::isfinite
|
||||
//#define isfinite std::isfinite
|
||||
using namespace std;
|
||||
#endif
|
||||
|
||||
ECL_PitchController::ECL_PitchController() :
|
||||
@@ -68,7 +69,7 @@ ECL_PitchController::ECL_PitchController() :
|
||||
_integrator(0.0f),
|
||||
_rate_error(0.0f),
|
||||
_rate_setpoint(0.0f),
|
||||
_bodyrate_setpoint(0.0f)
|
||||
_bodyrate_setpoint(0.0f),
|
||||
_nonfinite_input_perf(perf_alloc(PC_COUNT, "fw att control pitch nonfinite input"))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
#else
|
||||
#include<ros_error.h>
|
||||
#include <cmath>
|
||||
#define isfinite std::isfinite
|
||||
using namespace std;
|
||||
#endif
|
||||
|
||||
ECL_RollController::ECL_RollController() :
|
||||
@@ -67,7 +67,7 @@ ECL_RollController::ECL_RollController() :
|
||||
_rate_error(0.0f),
|
||||
_rate_setpoint(0.0f),
|
||||
_bodyrate_setpoint(0.0f),
|
||||
_nonfinite_input_perf(perf_alloc(PC_COUNT, "fw att control roll nonfinite input")),
|
||||
_nonfinite_input_perf(perf_alloc(PC_COUNT, "fw att control roll nonfinite input"))
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
#else
|
||||
#include<ros_error.h>
|
||||
#include <cmath>
|
||||
#define isfinite std::isfinite
|
||||
using namespace std;
|
||||
#endif
|
||||
|
||||
ECL_YawController::ECL_YawController() :
|
||||
|
||||
Reference in New Issue
Block a user