diff --git a/sw/airborne/arch/lpc21/subsystems/radio_control/ppm_arch.h b/sw/airborne/arch/lpc21/subsystems/radio_control/ppm_arch.h index b06954aa48..b42eefcd95 100644 --- a/sw/airborne/arch/lpc21/subsystems/radio_control/ppm_arch.h +++ b/sw/airborne/arch/lpc21/subsystems/radio_control/ppm_arch.h @@ -28,6 +28,8 @@ #include "LPC21xx.h" #include BOARD_CONFIG +#include "mcu_periph/sys_time.h" + /** * On tiny (and booz) the ppm counter is running at the same speed as * the systic counter. There is no reason for this to be true. diff --git a/sw/airborne/arch/stm32/subsystems/radio_control/ppm_arch.h b/sw/airborne/arch/stm32/subsystems/radio_control/ppm_arch.h index f1be912ecd..c3eebdec23 100644 --- a/sw/airborne/arch/stm32/subsystems/radio_control/ppm_arch.h +++ b/sw/airborne/arch/stm32/subsystems/radio_control/ppm_arch.h @@ -29,6 +29,8 @@ #ifndef PPM_ARCH_H #define PPM_ARCH_H +#include "mcu_periph/sys_time.h" + /** * On tiny (and booz) the ppm counter is running at the same speed as * the systic counter. There is no reason for this to be true. diff --git a/sw/airborne/boards/booz_1.0.h b/sw/airborne/boards/booz_1.0.h index 2d6d2a5b8a..95048428e7 100644 --- a/sw/airborne/boards/booz_1.0.h +++ b/sw/airborne/boards/booz_1.0.h @@ -142,7 +142,7 @@ #define PWM1_PINSEL_BIT 14 -#define BOARD_HAS_BARO +#define BOARD_HAS_BARO 1 /* * Modem diff --git a/sw/airborne/boards/lisa_l_1.0.h b/sw/airborne/boards/lisa_l_1.0.h index 5cf7ef8e27..f593587a10 100644 --- a/sw/airborne/boards/lisa_l_1.0.h +++ b/sw/airborne/boards/lisa_l_1.0.h @@ -37,6 +37,6 @@ #define BOARD_ADC_CHANNEL_3 ADC_Channel_0 #define BOARD_ADC_CHANNEL_4 ADC_Channel_15 -#define BOARD_HAS_BARO +#define BOARD_HAS_BARO 1 #endif /* CONFIG_LISA_L_1_0_H */ diff --git a/sw/airborne/boards/lisa_m_1.0.h b/sw/airborne/boards/lisa_m_1.0.h index 65c50d754d..9ef15ac72b 100644 --- a/sw/airborne/boards/lisa_m_1.0.h +++ b/sw/airborne/boards/lisa_m_1.0.h @@ -54,7 +54,7 @@ #define BOARD_ADC_CHANNEL_3 ADC_Channel_14 #define BOARD_ADC_CHANNEL_4 ADC_Channel_11 -#define BOARD_HAS_BARO +#define BOARD_HAS_BARO 1 #define USE_OPENCM3 1 diff --git a/sw/airborne/boards/navgo_1.0.h b/sw/airborne/boards/navgo_1.0.h index 17a6fbf118..0f23fa9ee0 100644 --- a/sw/airborne/boards/navgo_1.0.h +++ b/sw/airborne/boards/navgo_1.0.h @@ -76,6 +76,6 @@ #define PWM1_PINSEL_VAL 0x02 #define PWM1_PINSEL_BIT 14 -#define BOARD_HAS_BARO +#define BOARD_HAS_BARO 1 #endif /* CONFIG_NAVGO_V1_0_H */ diff --git a/sw/airborne/boards/umarim_1.0.h b/sw/airborne/boards/umarim_1.0.h index eb47a0545c..6c0b01187c 100644 --- a/sw/airborne/boards/umarim_1.0.h +++ b/sw/airborne/boards/umarim_1.0.h @@ -99,6 +99,6 @@ #define SPI1_DRDY_EINT 0 #define SPI1_DRDY_VIC_IT VIC_EINT0 -#define BOARD_HAS_BARO +#define BOARD_HAS_BARO 1 #endif /* CONFIG_UMARIM_V1_0_H */ diff --git a/sw/airborne/firmwares/fixedwing/ap_downlink.h b/sw/airborne/firmwares/fixedwing/ap_downlink.h index 30dee8aec7..08e80ea45f 100644 --- a/sw/airborne/firmwares/fixedwing/ap_downlink.h +++ b/sw/airborne/firmwares/fixedwing/ap_downlink.h @@ -245,7 +245,9 @@ extern uint8_t telemetry_mode_Ap_DefaultChannel; #define PERIODIC_SEND_SCP_STATUS(_trans, _dev) {} #endif -#ifdef BOARD_HAS_BARO +//FIXME: we need a better switch here... +#if BOARD_HAS_BARO && USE_BARO_AS_ALTIMETER +#include "subsystems/sensors/baro.h" #define PERIODIC_SEND_BARO_RAW(_trans, _dev) { \ DOWNLINK_SEND_BARO_RAW(_trans, _dev, \ &baro.absolute, \ diff --git a/sw/airborne/firmwares/fixedwing/main_ap.c b/sw/airborne/firmwares/fixedwing/main_ap.c index f5d76ff2a5..787d6c59e0 100644 --- a/sw/airborne/firmwares/fixedwing/main_ap.c +++ b/sw/airborne/firmwares/fixedwing/main_ap.c @@ -69,7 +69,7 @@ #include "subsystems/datalink/datalink.h" #include "subsystems/settings.h" #include "subsystems/datalink/xbee.h" -#include "ap_downlink.h" +#include "firmwares/fixedwing/ap_downlink.h" // modules & settings #include "generated/modules.h" diff --git a/sw/airborne/subsystems/imu/imu_b2.h b/sw/airborne/subsystems/imu/imu_b2.h index 1860501be9..02b7e69c59 100644 --- a/sw/airborne/subsystems/imu/imu_b2.h +++ b/sw/airborne/subsystems/imu/imu_b2.h @@ -169,7 +169,7 @@ } \ } #elif defined IMU_B2_MAG_TYPE && IMU_B2_MAG_TYPE == IMU_B2_MAG_HMC5843 -include "peripherals/hmc5843.h" +#include "peripherals/hmc5843.h" #define foo_handler() {} #define ImuMagEvent(_mag_handler) { \ MagEvent(foo_handler); \