diff --git a/libraries/AP_HAL/AP_HAL.h b/libraries/AP_HAL/AP_HAL.h index aed2715e19..4322098fd7 100644 --- a/libraries/AP_HAL/AP_HAL.h +++ b/libraries/AP_HAL/AP_HAL.h @@ -3,6 +3,7 @@ #define __AP_HAL_H__ #include "AP_HAL_Namespace.h" +#include "AP_HAL_Boards.h" /* HAL Module Classes (all pure virtual) */ #include "UARTDriver.h" diff --git a/libraries/AP_HAL/AP_HAL_Boards.h b/libraries/AP_HAL/AP_HAL_Boards.h new file mode 100644 index 0000000000..01d9072b6f --- /dev/null +++ b/libraries/AP_HAL/AP_HAL_Boards.h @@ -0,0 +1,18 @@ + +#ifndef __AP_HAL_BOARDS_H__ +#define __AP_HAL_BOARDS_H__ + +/** + * C preprocesor enumeration of the boards supported by the AP_HAL. + * This list exists so HAL_BOARD == HAL_BOARD_xxx preprocessor blocks + * can be used to exclude HAL boards from the build when appropriate. + * Its not an elegant solution but we cant get too fancy if we want to + * work with the Arduino mk and IDE builds without too much modification. + */ + +#define HAL_BOARD_APM1 1 +#define HAL_BOARD_APM2 2 +#define HAL_BOARD_AVR_SITL 3 + +#endif // __AP_HAL_BOARDS_H__ +