1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-23 00:05:33 +03:00

Merge branch 'patch_v3.1.7' of https://github.com/betaflight/betaflight into patch_v3.1.7

This commit is contained in:
borisbstyle 2017-03-06 23:49:45 +01:00
commit aed87872f1
4 changed files with 21 additions and 8 deletions

View file

@ -23,10 +23,17 @@
#define ICM20602_WHO_AM_I_CONST (0x12)
#define MPU6500_BIT_RESET (0x80)
// Register 0x37/55 - INT_PIN_CFG / Pin Bypass Enable Configuration
#define MPU6500_BIT_RESERVED (1 << 0)
#define MPU6500_BIT_BYPASS_EN (1 << 1)
#define MPU6500_BIT_INT_ANYRD_2CLEAR (1 << 4)
#define MPU6500_BIT_BYPASS_EN (1 << 0)
// Register 0x38/56 INT_ENABLE
#define MPU6500_BIT_RAW_RDY_EN (1 << 0)
// Register 0x6a/106 - USER_CTRL / User Control
#define MPU6500_BIT_I2C_IF_DIS (1 << 4)
#define MPU6500_BIT_RAW_RDY_EN (0x01)
bool mpu6500AccDetect(accDev_t *acc);
bool mpu6500GyroDetect(gyroDev_t *gyro);

View file

@ -1216,6 +1216,11 @@ void validateAndFixConfig(void)
resetSerialConfig(serialConfig);
}
// Prevent invalid notch cutoff
if (currentProfile->pidProfile.dterm_notch_cutoff >= currentProfile->pidProfile.dterm_notch_hz) {
currentProfile->pidProfile.dterm_notch_hz = 0;
}
validateAndFixGyroConfig();
#if defined(TARGET_VALIDATECONFIG)

View file

@ -238,6 +238,7 @@ void init(void)
}
#endif
#ifdef SPEKTRUM_BIND
if (feature(FEATURE_RX_SERIAL)) {
switch (rxConfig()->serialrx_provider) {
@ -250,6 +251,7 @@ void init(void)
break;
}
}
delay(200); // Make sure the satellite times out and closes the bind window. (Delay(100) below is not enough and needed for non-sat configs)
#endif
delay(100);

View file

@ -71,17 +71,16 @@
#define USE_UART1
#define USE_UART2
#define USE_UART3
#define USE_SOFTSERIAL1
#define USE_SOFTSERIAL2
// Disabled to make targets fit into flash space in 3.1.7
//#define USE_SOFTSERIAL1
//#define USE_SOFTSERIAL2
#define SERIAL_PORT_COUNT 6
//#define SERIAL_PORT_COUNT 6
#define SERIAL_PORT_COUNT 4
#define USE_ESCSERIAL
#define ESCSERIAL_TIMER_TX_HARDWARE 0 // PWM 1
#undef USE_SOFTSERIAL1
#undef USE_SOFTSERIAL2
#define UART1_TX_PIN PA9
#define UART1_RX_PIN PA10