Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
rc_datalink.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2010-2014 The Paparazzi Team
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 
27 #ifndef RC_DATALINK_H
28 #define RC_DATALINK_H
29 
30 #include "std.h"
31 
32 #define RC_DL_NB_CHANNEL 5
33 #define RADIO_CONTROL_NB_CHANNEL RC_DL_NB_CHANNEL
34 
39 #define RADIO_ROLL 0
40 #define RADIO_PITCH 1
41 #define RADIO_YAW 2
42 #define RADIO_THROTTLE 3
43 #define RADIO_MODE 4
44 
46 extern volatile bool rc_dl_frame_available;
47 
52 extern void parse_rc_3ch_datalink(
53  uint8_t throttle_mode,
54  int8_t roll,
55  int8_t pitch);
56 
60 extern void parse_rc_4ch_datalink(
61  uint8_t mode,
62  uint8_t throttle,
63  int8_t roll,
64  int8_t pitch,
65  int8_t yaw);
66 
70 extern void radio_control_impl_event(void (* _received_frame_handler)(void));
71 
75 #define RadioControlEvent(_received_frame_handler) radio_control_impl_event(_received_frame_handler)
76 
77 #endif /* RC_DATALINK_H */
unsigned char uint8_t
Definition: types.h:14
static uint8_t mode
mode holds the current sonar mode mode = 0 used at high altitude, uses 16 wave patterns mode = 1 used...
Definition: sonar_bebop.c:69
signed char int8_t
Definition: types.h:15