aboutsummaryrefslogtreecommitdiff
path: root/src/modules/multirotor_att_control
diff options
context:
space:
mode:
authorAnton Babushkin <anton.babushkin@me.com>2013-08-16 23:36:49 +0200
committerAnton Babushkin <anton.babushkin@me.com>2013-08-16 23:36:49 +0200
commitc543f89ec17048c1b5264623a885a9247a05304c (patch)
tree85ac36792b75824e5364f4e087ed09f3dc4699c0 /src/modules/multirotor_att_control
parent4882bc0f1c74e9ddebbeaa73bc3e753ac43bdf9c (diff)
downloadpx4-firmware-c543f89ec17048c1b5264623a885a9247a05304c.tar.gz
px4-firmware-c543f89ec17048c1b5264623a885a9247a05304c.tar.bz2
px4-firmware-c543f89ec17048c1b5264623a885a9247a05304c.zip
commander, multirotor_pos_control, multirotor_att_control: bugfixes
Diffstat (limited to 'src/modules/multirotor_att_control')
-rw-r--r--src/modules/multirotor_att_control/multirotor_att_control_main.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/modules/multirotor_att_control/multirotor_att_control_main.c b/src/modules/multirotor_att_control/multirotor_att_control_main.c
index 65b19c8e9..1aa24a4fc 100644
--- a/src/modules/multirotor_att_control/multirotor_att_control_main.c
+++ b/src/modules/multirotor_att_control/multirotor_att_control_main.c
@@ -250,12 +250,12 @@ mc_thread_main(int argc, char *argv[])
/* if the RC signal is lost, try to stay level and go slowly back down to ground */
if (control_mode.failsave_highlevel) {
- if (!control_mode.flag_control_position_enabled) {
+ if (!control_mode.flag_control_velocity_enabled) {
/* Don't reset attitude setpoint in position control mode, it's handled by position controller. */
att_sp.roll_body = 0.0f;
att_sp.pitch_body = 0.0f;
- if (!control_mode.flag_control_altitude_enabled) {
+ if (!control_mode.flag_control_climb_rate_enabled) {
/* Don't touch throttle in modes with altitude hold, it's handled by position controller.
*
* Only go to failsafe throttle if last known throttle was
@@ -309,12 +309,12 @@ mc_thread_main(int argc, char *argv[])
control_yaw_position = true;
}
- if (!control_mode.flag_control_position_enabled) {
+ if (!control_mode.flag_control_velocity_enabled) {
/* don't update attitude setpoint in position control mode */
att_sp.roll_body = manual.roll;
att_sp.pitch_body = manual.pitch;
- if (!control_mode.flag_control_position_enabled) {
+ if (!control_mode.flag_control_climb_rate_enabled) {
/* don't set throttle in altitude hold modes */
att_sp.thrust = manual.throttle;
}