aboutsummaryrefslogtreecommitdiff
path: root/src/modules/fixedwing_backside/fixedwing.cpp
diff options
context:
space:
mode:
authorJulian Oes <julian@oes.ch>2014-03-29 11:16:15 +0100
committerJulian Oes <julian@oes.ch>2014-03-29 11:16:15 +0100
commit33d65eae97994ab5b47188853029965b18a819a2 (patch)
tree8054384373de19db243a4a8289ff4c837da7d4ea /src/modules/fixedwing_backside/fixedwing.cpp
parent873fa4cb40a8ac5b57f3212bb233027f422b92a3 (diff)
parent9b1de5004c673ebe8bdf68f1b518565cccd6b05b (diff)
downloadpx4-firmware-33d65eae97994ab5b47188853029965b18a819a2.tar.gz
px4-firmware-33d65eae97994ab5b47188853029965b18a819a2.tar.bz2
px4-firmware-33d65eae97994ab5b47188853029965b18a819a2.zip
Merge remote-tracking branch 'px4/master' into bottle_drop
Diffstat (limited to 'src/modules/fixedwing_backside/fixedwing.cpp')
-rw-r--r--src/modules/fixedwing_backside/fixedwing.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/modules/fixedwing_backside/fixedwing.cpp b/src/modules/fixedwing_backside/fixedwing.cpp
index f7c0b6148..cfae07275 100644
--- a/src/modules/fixedwing_backside/fixedwing.cpp
+++ b/src/modules/fixedwing_backside/fixedwing.cpp
@@ -175,14 +175,14 @@ void BlockMultiModeBacksideAutopilot::update()
// the min/max velocity
float v = _vLimit.update(sqrtf(
_pos.vel_n * _pos.vel_n +
- _pos.vy * _pos.vy +
+ _pos.vel_e * _pos.vel_e +
_pos.vel_d * _pos.vel_d));
// limit velocity command between min/max velocity
float vCmd = _vLimit.update(_vCmd.get());
// altitude hold
- float dThrottle = _h2Thr.update(_missionCmd.current.altitude - _pos.alt);
+ float dThrottle = _h2Thr.update(_missionCmd.current.alt - _pos.alt);
// heading hold
float psiError = _wrap_pi(_guide.getPsiCmd() - _att.yaw);
@@ -237,7 +237,7 @@ void BlockMultiModeBacksideAutopilot::update()
// the min/max velocity
float v = _vLimit.update(sqrtf(
_pos.vel_n * _pos.vel_n +
- _pos.vy * _pos.vy +
+ _pos.vel_e * _pos.vel_e +
_pos.vel_d * _pos.vel_d));
// pitch channel -> rate of climb