Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
aoa_pwm.h
Go to the documentation of this file.
1/*
2* Copyright (C) 2015 Jean-François Erdelyi, Gautier Hattenberger
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*/
20
34#ifndef AOA_PWM_H
35#define AOA_PWM_H
36
37#include "std.h"
38
39struct Aoa_Pwm {
41 float angle;
42 float offset;
43 float sens;
44
49 float filter;
50};
51
52extern struct Aoa_Pwm aoa_pwm; // angle of attack sensor
53extern struct Aoa_Pwm ssa_pwm; // sideslip angle sensor
54
61extern enum Aoa_Type aoa_send_type;
62
63extern void aoa_pwm_init(void);
64extern void aoa_pwm_update(void);
65
66#endif /* AOA_PWM_H */
67
float sens
sensitiviy, i.e. scale to conver raw to angle
Definition aoa_pwm.h:43
struct Aoa_Pwm ssa_pwm
Definition aoa_pwm.c:119
Aoa_Type
Selection of sensor type to be send over telemetry.
Definition aoa_pwm.h:57
@ SEND_TYPE_SIDESLIP
Definition aoa_pwm.h:59
@ SEND_TYPE_AOA
Definition aoa_pwm.h:58
float angle
Angle of attack in radians.
Definition aoa_pwm.h:41
float offset
Angle of attack offset in radians.
Definition aoa_pwm.h:42
void aoa_pwm_init(void)
Definition aoa_pwm.c:145
struct Aoa_Pwm aoa_pwm
Definition aoa_pwm.c:92
void aoa_pwm_update(void)
Definition aoa_pwm.c:167
enum Aoa_Type aoa_send_type
Definition aoa_pwm.c:123
uint32_t raw
raw PWM value
Definition aoa_pwm.h:40
float filter
Filtering value [0-1] 0: no filtering 1: output is a constant value.
Definition aoa_pwm.h:49
unsigned int uint32_t
Typedef defining 32 bit unsigned int type.