1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2025-01-30 15:52:12 +01:00

OP-1474 Fix label compile error

This commit is contained in:
Stefan Karlsson 2014-09-19 01:29:04 +02:00
parent 31c5f1c519
commit f0c47976a5

View File

@ -163,10 +163,12 @@ static void altitudeHoldTask(void)
dT = PIOS_DELTATIME_GetAverageSeconds(&timeval);
switch (thrustMode) {
case ALTITUDEHOLD:
{
// altitude control loop
// No scaling.
pid_scaler scaler = { .p = 1.0f, .i = 1.0f, .d = 1.0f };
const pid_scaler scaler = { .p = 1.0f, .i = 1.0f, .d = 1.0f };
altitudeHoldStatus.VelocityDesired = pid_apply_setpoint(&pid0, &scaler, thrustSetpoint, positionStateDown, dT);
}
break;
case ALTITUDEVARIO:
altitudeHoldStatus.VelocityDesired = thrustSetpoint;
@ -183,11 +185,12 @@ static void altitudeHoldTask(void)
thrustDemand = thrustSetpoint;
break;
default:
{
// velocity control loop
// No scaling.
pid_scaler scaler = { .p = 1.0f, .i = 1.0f, .d = 1.0f };
const pid_scaler scaler = { .p = 1.0f, .i = 1.0f, .d = 1.0f };
thrustDemand = startThrust - pid_apply_setpoint(&pid1, &scaler, altitudeHoldStatus.VelocityDesired, velocityStateDown, dT);
}
break;
}
}