Enable blackbox flash logging only on SPRacingF3 and Naze rev5 targets.
This commit is contained in:
parent
5d49451916
commit
070b556a07
2
Makefile
2
Makefile
|
@ -504,6 +504,8 @@ SPRACINGF3_SRC = \
|
|||
drivers/barometer_ms5611.c \
|
||||
drivers/compass_hmc5883l.c \
|
||||
drivers/display_ug2864hsweg01.h \
|
||||
drivers/flash_m25p16.c \
|
||||
io/flashfs.c \
|
||||
$(HIGHEND_SRC) \
|
||||
$(COMMON_SRC)
|
||||
|
||||
|
|
|
@ -365,10 +365,14 @@ void init(void)
|
|||
#endif
|
||||
|
||||
#ifdef USE_FLASHFS
|
||||
#ifdef NAZE
|
||||
// naze32 rev5 and above have 16mbit of flash available
|
||||
#ifdef NAZE
|
||||
if (hardwareRevision == NAZE32_REV5) {
|
||||
m25p16_init();
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
#ifdef SPRACINGF3
|
||||
m25p16_init();
|
||||
#endif
|
||||
flashfsInit();
|
||||
#endif
|
||||
|
||||
|
|
|
@ -45,6 +45,9 @@
|
|||
#define USE_MAG_HMC5883
|
||||
#define MAG_HMC5883_ALIGN CW270_DEG
|
||||
|
||||
#define USE_FLASHFS
|
||||
#define USE_FLASH_M25P16
|
||||
|
||||
#define BEEPER
|
||||
#define LED0
|
||||
|
||||
|
@ -81,8 +84,23 @@
|
|||
#define USE_I2C
|
||||
#define I2C_DEVICE (I2CDEV_1) // PB6/SCL, PB7/SDA
|
||||
|
||||
//#define USE_SPI
|
||||
//#define USE_SPI_DEVICE_2 // PB12,13,14,15 on AF5
|
||||
#define USE_SPI
|
||||
#define USE_SPI_DEVICE_2 // PB12,13,14,15 on AF5
|
||||
|
||||
#define SPI2_GPIO GPIOB
|
||||
#define SPI2_GPIO_PERIPHERAL RCC_AHBPeriph_GPIOB
|
||||
#define SPI2_NSS_PIN Pin_12
|
||||
#define SPI2_NSS_PIN_SOURCE GPIO_PinSource12
|
||||
#define SPI2_SCK_PIN Pin_13
|
||||
#define SPI2_SCK_PIN_SOURCE GPIO_PinSource13
|
||||
#define SPI2_MISO_PIN Pin_14
|
||||
#define SPI2_MISO_PIN_SOURCE GPIO_PinSource14
|
||||
#define SPI2_MOSI_PIN Pin_15
|
||||
#define SPI2_MOSI_PIN_SOURCE GPIO_PinSource15
|
||||
|
||||
#define M25P16_CS_GPIO GPIOB
|
||||
#define M25P16_CS_PIN GPIO_Pin_12
|
||||
#define M25P16_SPI_INSTANCE SPI2
|
||||
|
||||
#define USE_ADC
|
||||
|
||||
|
|
Loading…
Reference in New Issue