Paparazzi UAS
v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
inter_mcu.c
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2003-2005 Pascal Brisset, Antoine Drouin
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
#include "
inter_mcu.h
"
28
29
#if defined SINGLE_MCU
30
static
struct
fbw_state
_fbw_state;
31
static
struct
ap_state
_ap_state;
32
struct
fbw_state
*
fbw_state
= &_fbw_state;
33
struct
ap_state
*
ap_state
= &_ap_state;
34
#else
/* SINGLE_MCU */
35
#include "
link_mcu.h
"
36
struct
fbw_state
*
fbw_state
= &
link_mcu_from_fbw_msg
.
payload
.from_fbw;
37
struct
ap_state
*
ap_state
= &
link_mcu_from_ap_msg
.
payload
.from_ap;
38
#endif
/* ! SINGLE_MCU */
39
40
volatile
bool
inter_mcu_received_fbw
=
false
;
41
volatile
bool
inter_mcu_received_ap
=
false
;
42
43
PPRZ_MUTEX
(ap_state_mtx);
44
PPRZ_MUTEX
(fbw_state_mtx);
45
46
#ifdef FBW
47
48
bool
ap_ok;
49
uint8_t
time_since_last_ap;
50
#endif
inter_mcu_received_ap
volatile bool inter_mcu_received_ap
Definition:
inter_mcu.c:41
inter_mcu.h
fbw_state
struct fbw_state * fbw_state
Definition:
inter_mcu.c:36
PPRZ_MUTEX
PPRZ_MUTEX(ap_state_mtx)
inter_mcu_received_fbw
volatile bool inter_mcu_received_fbw
Definition:
inter_mcu.c:40
uint8_t
unsigned char uint8_t
Definition:
types.h:14
link_mcu_msg::payload
union link_mcu_msg::@281 payload
link_mcu_from_fbw_msg
struct link_mcu_msg link_mcu_from_fbw_msg
Definition:
link_mcu_can.c:177
ap_state
struct ap_state * ap_state
Definition:
inter_mcu.c:37
link_mcu_from_ap_msg
struct link_mcu_msg link_mcu_from_ap_msg
Definition:
link_mcu_can.c:176
link_mcu.h
sw
airborne
inter_mcu.c
Generated on Tue Feb 1 2022 13:51:14 for Paparazzi UAS by
1.8.17