aboutsummaryrefslogtreecommitdiff
path: root/apps/systemlib/pid
diff options
context:
space:
mode:
authorTobias Naegeli <naegelit@student.ethz.ch>2012-11-01 16:50:52 +0100
committerTobias Naegeli <naegelit@student.ethz.ch>2012-11-01 16:50:52 +0100
commit80ac43e21dadf727133201663169e6e931bc5a35 (patch)
treec865806b1b329e84314bdbeeb0d15007ea742d62 /apps/systemlib/pid
parent6af2ea9fbc019b023e2b1201b788c9185690e193 (diff)
downloadpx4-firmware-80ac43e21dadf727133201663169e6e931bc5a35.tar.gz
px4-firmware-80ac43e21dadf727133201663169e6e931bc5a35.tar.bz2
px4-firmware-80ac43e21dadf727133201663169e6e931bc5a35.zip
Fine tuning of manual control
Diffstat (limited to 'apps/systemlib/pid')
-rw-r--r--apps/systemlib/pid/pid.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/systemlib/pid/pid.c b/apps/systemlib/pid/pid.c
index 0358caa25..dd8b6adc6 100644
--- a/apps/systemlib/pid/pid.c
+++ b/apps/systemlib/pid/pid.c
@@ -172,9 +172,9 @@ __EXPORT float pid_calculate(PID_t *pid, float sp, float val, float val_dot, flo
// Calculate the output. Limit output magnitude to pid->limit
float output = (pid->error_previous * pid->kp) + (i * pid->ki) + (d * pid->kd);
- if (output > pid->limit) output = pid->limit;
+ //if (output > pid->limit) output = pid->limit;
- if (output < -pid->limit) output = -pid->limit;
+ //if (output < -pid->limit) output = -pid->limit;
if (isfinite(output)) {
pid->last_output = output;