AP_ADC: remove checks for HAL_BOARD_APM2 and HAL_BOARD_APM1

This commit is contained in:
Lucas De Marchi 2015-11-03 11:46:28 -02:00 committed by Andrew Tridgell
parent c495bdb299
commit 4ae35c9a74

View File

@ -17,10 +17,11 @@
uint32_t timer; uint32_t timer;
#if CONFIG_HAL_BOARD == HAL_BOARD_APM1 || CONFIG_HAL_BOARD == HAL_BOARD_LINUX
/* Only build this sketch for APM1 and Linux */
const AP_HAL::HAL& hal = AP_HAL::get_HAL(); const AP_HAL::HAL& hal = AP_HAL::get_HAL();
/* Only build this sketch for Linux */
#if CONFIG_HAL_BOARD == HAL_BOARD_LINUX
AP_ADC_ADS7844 adc; AP_ADC_ADS7844 adc;
void setup() void setup()
@ -106,9 +107,8 @@ void loop()
} }
} }
#else // Non-APM1: #else
#warning AP_ADC_test built as stub for APM2 #warning AP_ADC_test built as stub
const AP_HAL::HAL& hal = AP_HAL_AVR_APM2;
void setup () {} void setup () {}
void loop () {} void loop () {}
#endif // CONFIG_HAL_BOARD #endif // CONFIG_HAL_BOARD