From dab8f9362853b7259cce2fb1def633159c7ddeb6 Mon Sep 17 00:00:00 2001 From: LukeMike Date: Sat, 3 Feb 2018 14:53:48 +0100 Subject: [PATCH] VRBRAIN / AP_HAL: changed vrbrain board configuration file --- libraries/AP_HAL/board/vrbrain.h | 46 +++++++++++++++++++++++++++++--- 1 file changed, 43 insertions(+), 3 deletions(-) diff --git a/libraries/AP_HAL/board/vrbrain.h b/libraries/AP_HAL/board/vrbrain.h index 8b0cb035b0..cdbe66b5dd 100644 --- a/libraries/AP_HAL/board/vrbrain.h +++ b/libraries/AP_HAL/board/vrbrain.h @@ -9,9 +9,8 @@ #define HAL_INS_DEFAULT HAL_INS_VRBRAIN #define HAL_BARO_DEFAULT HAL_BARO_VRBRAIN #define HAL_COMPASS_DEFAULT HAL_COMPASS_VRBRAIN -#define HAL_SERIAL0_BAUD_DEFAULT 115200 -#if defined(CONFIG_ARCH_BOARD_VRBRAIN_V45) +#ifdef CONFIG_ARCH_BOARD_VRBRAIN_V45 #define CONFIG_HAL_BOARD_SUBTYPE HAL_BOARD_SUBTYPE_VRBRAIN_V45 #define HAL_STORAGE_SIZE 8192 #elif defined(CONFIG_ARCH_BOARD_VRBRAIN_V51) @@ -32,6 +31,8 @@ #elif defined(CONFIG_ARCH_BOARD_VRBRAIN_V54) #define CONFIG_HAL_BOARD_SUBTYPE HAL_BOARD_SUBTYPE_VRBRAIN_V54 #define HAL_STORAGE_SIZE 16384 +#else +#error "Unknown VRBRAIN board type" #endif #define HAL_GPIO_A_LED_PIN 25 @@ -44,7 +45,46 @@ #define EXTERNAL_LED_MOTOR1 30 // Motor1 LED - AN8 #define EXTERNAL_LED_MOTOR2 31 // Motor2 LED - AN12 +#define HAL_BARO_MS5611_NAME "ms5611" +#define HAL_BARO_MS5611_SPI_INT_NAME "ms5611_int" +#define HAL_BARO_MS5611_SPI_EXT_NAME "ms5611_ext" +#define HAL_BARO_MS5611_SPI_IMU_NAME "ms5611_imu" + +#define HAL_INS_MPU60x0_NAME "mpu6000" +#define HAL_INS_MPU60x0_EXT_NAME "mpu6000_ext" +#define HAL_INS_MPU60x0_IMU_NAME "mpu6000_imu" + +#define HAL_INS_LSM9DS0_G_NAME "lsm9ds0_g" +#define HAL_INS_LSM9DS0_A_NAME "lsm9ds0_am" + +#define HAL_INS_LSM9DS0_EXT_G_NAME "lsm9ds0_ext_g" +#define HAL_INS_LSM9DS0_EXT_A_NAME "lsm9ds0_ext_am" + +#define HAL_INS_MPU9250_NAME "mpu9250" +#define HAL_INS_MPU9250_EXT_NAME "mpu9250_ext" + +#define HAL_INS_MPU6500_NAME "mpu6500" + +#define HAL_INS_ICM20608_NAME "icm20608" +#define HAL_INS_ICM20608_AM_NAME "icm20608-am" +#define HAL_INS_ICM20608_EXT_NAME "icm20608_ext" + +#define HAL_COMPASS_HMC5843_NAME "hmc5843" +#define HAL_COMPASS_HMC5843_EXT_NAME "hmc5843_ext" +#define HAL_COMPASS_HMC5843_IMU_NAME "hmc5843_imu" +#define HAL_COMPASS_LIS3MDL_NAME "lis3mdl" + +#ifndef HAL_HAVE_BOARD_VOLTAGE #define HAL_HAVE_BOARD_VOLTAGE 0 -#define HAL_HAVE_SAFETY_SWITCH 1 +#endif + +#ifndef HAL_PX4_HAVE_MTD_SUPPORT #define HAL_PX4_HAVE_MTD_SUPPORT 1 +#endif +#ifndef HAL_PX4_HAVE_PWM_INPUT #define HAL_PX4_HAVE_PWM_INPUT 1 +#endif + +#ifndef HAL_HAVE_SAFETY_SWITCH +#define HAL_HAVE_SAFETY_SWITCH 1 +#endif