AP_Notify: remove HAL-VRBRAIN-specific code

This commit is contained in:
Peter Barker 2019-01-19 19:18:51 +11:00 committed by Andrew Tridgell
parent 4d67435b9c
commit 002070ae9e

View File

@ -48,9 +48,7 @@ AP_Notify *AP_Notify::_instance;
Notify_LED_NCP5623_I2C_Internal | Notify_LED_NCP5623_I2C_External)
#ifndef BUILD_DEFAULT_LED_TYPE
// PX4 boards
#if CONFIG_HAL_BOARD == HAL_BOARD_CHIBIOS || \
CONFIG_HAL_BOARD == HAL_BOARD_VRBRAIN
#if CONFIG_HAL_BOARD == HAL_BOARD_CHIBIOS
#define BUILD_DEFAULT_LED_TYPE (Notify_LED_Board | I2C_LEDS)
// Linux boards
@ -212,18 +210,18 @@ void AP_Notify::add_backends(void)
#endif
#endif // CONFIG_HAL_BOARD == HAL_BOARD_LINUX
#if CONFIG_HAL_BOARD == HAL_BOARD_VRBRAIN || CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRBRAIN_V52 || CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRUBRAIN_V51
#if CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRBRAIN_V52 || CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRUBRAIN_V51
ADD_BACKEND(new ExternalLED()); // despite the name this is a built in set of onboard LED's
#endif // CONFIG_HAL_BOARD == HAL_BOARD_VRBRAIN
#endif // CONFIG_HAL_BOARD_SUBTYPE == various CHIBIOS-VRBRAINs
#if defined(HAL_HAVE_PIXRACER_LED)
ADD_BACKEND(new PixRacerLED());
#elif (defined(HAL_GPIO_A_LED_PIN) && defined(HAL_GPIO_B_LED_PIN) && defined(HAL_GPIO_C_LED_PIN))
#if (CONFIG_HAL_BOARD == HAL_BOARD_VRBRAIN && CONFIG_HAL_BOARD_SUBTYPE != HAL_BOARD_SUBTYPE_VRBRAIN_V45) || CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRBRAIN_V52 || CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRUBRAIN_V51
#if CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRBRAIN_V52 || CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_CHIBIOS_VRUBRAIN_V51
ADD_BACKEND(new VRBoard_LED());
#else
ADD_BACKEND(new AP_BoardLED());
#endif // CONFIG_HAL_BOARD != HAL_BOARD_VRBRAIN || CONFIG_HAL_BOARD_SUBTYPE == HAL_BOARD_SUBTYPE_VRBRAIN_V45
#endif
#elif (defined(HAL_GPIO_A_LED_PIN) && defined(HAL_GPIO_B_LED_PIN))
ADD_BACKEND(new AP_BoardLED2());
#endif