Merge pull request #5178 from mikeller/increase_eeprom_version

Fixed parameter group violations in `motorDevConfig_t`, incremented EEPROM config version before 3.3.0 release.
This commit is contained in:
Michael Keller 2018-02-18 03:19:30 +13:00 committed by GitHub
commit 0f790332a3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 4 deletions

View File

@ -20,7 +20,7 @@
#include <stdint.h> #include <stdint.h>
#include <stdbool.h> #include <stdbool.h>
#define EEPROM_CONF_VERSION 167 #define EEPROM_CONF_VERSION 168
bool isEEPROMContentValid(void); bool isEEPROMContentValid(void);
bool loadEEPROM(void); bool loadEEPROM(void);

View File

@ -165,14 +165,13 @@ typedef struct {
IO_t io; IO_t io;
} pwmOutputPort_t; } pwmOutputPort_t;
//CAVEAT: This is used in the `motorConfig_t` parameter group, so the parameter group constraints apply
typedef struct motorDevConfig_s { typedef struct motorDevConfig_s {
uint16_t motorPwmRate; // The update rate of motor outputs (50-498Hz) uint16_t motorPwmRate; // The update rate of motor outputs (50-498Hz)
uint8_t motorPwmProtocol; // Pwm Protocol uint8_t motorPwmProtocol; // Pwm Protocol
uint8_t motorPwmInversion; // Active-High vs Active-Low. Useful for brushed FCs converted for brushless operation uint8_t motorPwmInversion; // Active-High vs Active-Low. Useful for brushed FCs converted for brushless operation
uint8_t useUnsyncedPwm; uint8_t useUnsyncedPwm;
#ifdef USE_DSHOT_DMAR
uint8_t useBurstDshot; uint8_t useBurstDshot;
#endif
ioTag_t ioTags[MAX_SUPPORTED_MOTORS]; ioTag_t ioTags[MAX_SUPPORTED_MOTORS];
} motorDevConfig_t; } motorDevConfig_t;

View File

@ -66,7 +66,7 @@ PG_RESET_TEMPLATE(mixerConfig_t, mixerConfig,
.yaw_motors_reversed = false, .yaw_motors_reversed = false,
); );
PG_REGISTER_WITH_RESET_FN(motorConfig_t, motorConfig, PG_MOTOR_CONFIG, 0); PG_REGISTER_WITH_RESET_FN(motorConfig_t, motorConfig, PG_MOTOR_CONFIG, 1);
void pgResetFn_motorConfig(motorConfig_t *motorConfig) void pgResetFn_motorConfig(motorConfig_t *motorConfig)
{ {