From 7f03b42ac048001c7b62a9426db6ec060147f773 Mon Sep 17 00:00:00 2001 From: Bruce Luckcuck Date: Sun, 8 Mar 2020 18:58:16 -0400 Subject: [PATCH] Required modifications to the BoschSensortec/BMI270-Sensor-API library --- .../BMI270-Sensor-API/betaflight_info.txt | 13 +++++++++++++ lib/main/BoschSensortec/BMI270-Sensor-API/bmi270.h | 5 +++++ 2 files changed, 18 insertions(+) create mode 100644 lib/main/BoschSensortec/BMI270-Sensor-API/betaflight_info.txt diff --git a/lib/main/BoschSensortec/BMI270-Sensor-API/betaflight_info.txt b/lib/main/BoschSensortec/BMI270-Sensor-API/betaflight_info.txt new file mode 100644 index 000000000..b2cf88929 --- /dev/null +++ b/lib/main/BoschSensortec/BMI270-Sensor-API/betaflight_info.txt @@ -0,0 +1,13 @@ +This library is used to support the Bosch BMI270 gyro sensor (see drivers/accgyro/accgyro_spi_bmi270.c). + +Library download location: + https://github.com/BoschSensortec/BMI270-Sensor-API + +The only file that is compiled as part of Betaflight is bmi270.c. This file contains the device microcode that must be uploaded during initialization. + +When upgrading this library the bmi270.h header must have the following code block added: + +// Betaflight modifications begin +#define BMI270_CONFIG_SIZE 8192 +extern const uint8_t bmi270_config_file[BMI270_CONFIG_SIZE]; +// Betaflight modifications end diff --git a/lib/main/BoschSensortec/BMI270-Sensor-API/bmi270.h b/lib/main/BoschSensortec/BMI270-Sensor-API/bmi270.h index 7179ac8ed..e8b87ed0a 100644 --- a/lib/main/BoschSensortec/BMI270-Sensor-API/bmi270.h +++ b/lib/main/BoschSensortec/BMI270-Sensor-API/bmi270.h @@ -130,3 +130,8 @@ int8_t bmi270_init(struct bmi2_dev *dev); #endif /* End of CPP guard */ #endif /* BMI270_H_ */ + +// Betaflight modifications begin +#define BMI270_CONFIG_SIZE 8192 +extern const uint8_t bmi270_config_file[BMI270_CONFIG_SIZE]; +// Betaflight modifications end