diff --git a/sw/airborne/firmwares/rotorcraft/autopilot.c b/sw/airborne/firmwares/rotorcraft/autopilot.c index b2fa265ff2..e9685f32c5 100644 --- a/sw/airborne/firmwares/rotorcraft/autopilot.c +++ b/sw/airborne/firmwares/rotorcraft/autopilot.c @@ -239,7 +239,7 @@ static inline void autopilot_check_motors_on( void ) { void autopilot_on_rc_frame(void) { uint8_t new_autopilot_mode = 0; - BOOZ_AP_MODE_OF_PPRZ(radio_control.values[RADIO_CONTROL_MODE], new_autopilot_mode); + AP_MODE_OF_PPRZ(radio_control.values[RADIO_CONTROL_MODE], new_autopilot_mode); autopilot_set_mode(new_autopilot_mode); #ifdef RADIO_CONTROL_KILL_SWITCH diff --git a/sw/airborne/firmwares/rotorcraft/autopilot.h b/sw/airborne/firmwares/rotorcraft/autopilot.h index 1dbd543810..909aa433de 100644 --- a/sw/airborne/firmwares/rotorcraft/autopilot.h +++ b/sw/airborne/firmwares/rotorcraft/autopilot.h @@ -80,26 +80,26 @@ extern uint16_t autopilot_flight_time; #define TRESHOLD_1_PPRZ (MIN_PPRZ / 2) #define TRESHOLD_2_PPRZ (MAX_PPRZ / 2) -#define BOOZ_AP_MODE_OF_PPRZ(_rc, _booz_mode) { \ - if (_rc > TRESHOLD_2_PPRZ) \ - _booz_mode = autopilot_mode_auto2; \ +#define AP_MODE_OF_PPRZ(_rc, _mode) { \ + if (_rc > TRESHOLD_2_PPRZ) \ + _mode = autopilot_mode_auto2; \ else if (_rc > TRESHOLD_1_PPRZ) \ - _booz_mode = MODE_AUTO1; \ - else \ - _booz_mode = MODE_MANUAL; \ + _mode = MODE_AUTO1; \ + else \ + _mode = MODE_MANUAL; \ } -#define autopilot_KillThrottle(_v) { \ - kill_throttle = _v; \ +#define autopilot_KillThrottle(_v) { \ + kill_throttle = _v; \ if (kill_throttle) autopilot_motors_on = FALSE; \ - else autopilot_motors_on = TRUE; \ + else autopilot_motors_on = TRUE; \ } -#define autopilot_SetPowerSwitch(_v) { \ - autopilot_power_switch = _v; \ - if (_v) { LED_OFF(POWER_SWITCH_LED); } \ - else { LED_ON(POWER_SWITCH_LED); } \ -} +#define autopilot_SetPowerSwitch(_v) { \ + autopilot_power_switch = _v; \ + if (_v) { LED_OFF(POWER_SWITCH_LED); } \ + else { LED_ON(POWER_SWITCH_LED); } \ + } #ifndef TRESHOLD_GROUND_DETECT #define TRESHOLD_GROUND_DETECT ACCEL_BFP_OF_REAL(15.) diff --git a/sw/airborne/firmwares/rotorcraft/main.h b/sw/airborne/firmwares/rotorcraft/main.h index a4ef18200b..5fa7b01594 100644 --- a/sw/airborne/firmwares/rotorcraft/main.h +++ b/sw/airborne/firmwares/rotorcraft/main.h @@ -1,6 +1,6 @@ /* * $Id$ - * + * * Copyright (C) 2008-2009 Antoine Drouin * * This file is part of paparazzi. @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with paparazzi; see the file COPYING. If not, write to * the Free Software Foundation, 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. + * Boston, MA 02111-1307, USA. */ #ifndef BOOZ2_MAIN_H