Paparazzi UAS  v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
nav_heli_spinup.c
Go to the documentation of this file.
1 /*
2  * Copyright (C) Freek van Tienen <freek.v.tienen@gmail.com>
3  *
4  * This file is part of paparazzi
5  *
6  * paparazzi is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2, or (at your option)
9  * any later version.
10  *
11  * paparazzi is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with paparazzi; see the file COPYING. If not, see
18  * <http://www.gnu.org/licenses/>.
19  */
28 #include "navigation.h"
29 #include "paparazzi.h"
30 
32 
41 {
44 
45 #ifdef COMMAND_ROLL
46  stabilization_cmd[COMMAND_ROLL] = 0;
47 #endif
48 #ifdef COMMAND_PITCH
49  stabilization_cmd[COMMAND_PITCH] = 0;
50 #endif
51 #ifdef COMMAND_YAW
52  stabilization_cmd[COMMAND_YAW] = 0;
53 #endif
54  nav.throttle = 0;
55 
58 }
59 
65 {
67  return false;
68  }
69 
70 #ifdef COMMAND_ROLL
71  stabilization_cmd[COMMAND_ROLL] = 0;
72 #endif
73 #ifdef COMMAND_PITCH
74  stabilization_cmd[COMMAND_PITCH] = 0;
75 #endif
76 #ifdef COMMAND_YAW
77  stabilization_cmd[COMMAND_YAW] = 0;
78 #endif
80 
83  return true;
84 }
uint16_t stage_time
In s.
bool nav_heli_spinup_run(void)
Runs the heli spinup routine, with the parameters set by nav_heli_spinup_setup.
void nav_heli_spinup_setup(uint16_t duration, float throttle)
Initialization function.
static struct nav_heli_spinup_t nav_heli_spinup
uint16_t duration
The duration in seconds to reach the final throttle.
uint32_t throttle
The final throttle level.
#define MAX_PPRZ
Definition: paparazzi.h:8
struct RotorcraftNavigation nav
Definition: navigation.c:51
uint32_t throttle
throttle command (in pprz_t)
Definition: navigation.h:130
#define NAV_VERTICAL_MODE_MANUAL
Definition: navigation.h:92
#define NAV_HORIZONTAL_MODE_NONE
Definition: navigation.h:89
int32_t stabilization_cmd[COMMANDS_NB]
Stabilization commands.
Definition: stabilization.c:34
General stabilization interface for rotorcrafts.
unsigned short uint16_t
Typedef defining 16 bit unsigned short type.
Definition: vl53l1_types.h:88