Commit 9384d9ac authored by Patrick José Pereira's avatar Patrick José Pereira

QGC: Solve problem with limitAngleToPMPId when angle is bigger than PI

Signed-off-by: 's avatarPatrick José Pereira <patrickelectric@gmail.com>
parent 10215bbd
......@@ -61,14 +61,14 @@ double limitAngleToPMPId(double angle)
{
while (angle < -M_PI)
{
angle += M_PI;
angle += 2.0f * M_PI;
}
}
else if (angle > M_PI)
{
while (angle > M_PI)
{
angle -= M_PI;
angle -= 2.0f * M_PI;
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment