mirror of
https://github.com/iNavFlight/inav.git
synced 2025-07-26 01:35:35 +03:00
added USE_GPS_FIX_ESTIMATION
fixed indentation
This commit is contained in:
parent
2b9a5a6a8d
commit
599e45c48f
29 changed files with 626 additions and 397 deletions
|
@ -313,13 +313,13 @@ static void calculateVirtualPositionTarget_FW(float trackingPeriod)
|
|||
loiterCenterPos.x = posControl.activeWaypoint.pos.x + navLoiterRadius * cos_approx(CENTIDEGREES_TO_RADIANS(loiterCenterBearing));
|
||||
loiterCenterPos.y = posControl.activeWaypoint.pos.y + navLoiterRadius * sin_approx(CENTIDEGREES_TO_RADIANS(loiterCenterBearing));
|
||||
|
||||
posErrorX = loiterCenterPos.x - navGetCurrentActualPositionAndVelocity()->pos.x;
|
||||
posErrorY = loiterCenterPos.y - navGetCurrentActualPositionAndVelocity()->pos.y;
|
||||
posErrorX = loiterCenterPos.x - navGetCurrentActualPositionAndVelocity()->pos.x;
|
||||
posErrorY = loiterCenterPos.y - navGetCurrentActualPositionAndVelocity()->pos.y;
|
||||
|
||||
// turn direction to next waypoint
|
||||
loiterTurnDirection = posControl.activeWaypoint.nextTurnAngle > 0 ? 1 : -1; // 1 = right
|
||||
// turn direction to next waypoint
|
||||
loiterTurnDirection = posControl.activeWaypoint.nextTurnAngle > 0 ? 1 : -1; // 1 = right
|
||||
|
||||
needToCalculateCircularLoiter = true;
|
||||
needToCalculateCircularLoiter = true;
|
||||
}
|
||||
posControl.flags.wpTurnSmoothingActive = true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue