From c97c8998b178d15c146576b107dbc50658d23b2f Mon Sep 17 00:00:00 2001 From: Martin Budden Date: Thu, 7 Sep 2017 21:35:37 +0100 Subject: [PATCH] Update PG version numbers --- src/main/fc/config.c | 2 +- src/main/sensors/battery.c | 4 ++-- src/main/sensors/battery.h | 2 +- src/main/sensors/gyro.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/fc/config.c b/src/main/fc/config.c index 007596ab27..c98325151d 100755 --- a/src/main/fc/config.c +++ b/src/main/fc/config.c @@ -124,7 +124,7 @@ PG_RESET_TEMPLATE(pilotConfig_t, pilotConfig, .name = { 0 } ); -PG_REGISTER_WITH_RESET_TEMPLATE(systemConfig_t, systemConfig, PG_SYSTEM_CONFIG, 0); +PG_REGISTER_WITH_RESET_TEMPLATE(systemConfig_t, systemConfig, PG_SYSTEM_CONFIG, 1); #ifndef USE_OSD_SLAVE #if defined(STM32F4) && !defined(DISABLE_OVERCLOCK) diff --git a/src/main/sensors/battery.c b/src/main/sensors/battery.c index 97254497a6..a0320b3cd4 100644 --- a/src/main/sensors/battery.c +++ b/src/main/sensors/battery.c @@ -87,7 +87,7 @@ static batteryState_e consumptionState; #define DEFAULT_VOLTAGE_METER_SOURCE VOLTAGE_METER_NONE #endif -PG_REGISTER_WITH_RESET_TEMPLATE(batteryConfig_t, batteryConfig, PG_BATTERY_CONFIG, 1); +PG_REGISTER_WITH_RESET_TEMPLATE(batteryConfig_t, batteryConfig, PG_BATTERY_CONFIG, 2); PG_RESET_TEMPLATE(batteryConfig_t, batteryConfig, // voltage @@ -265,7 +265,7 @@ void batteryUpdateStates(timeUs_t currentTimeUs) batteryState = MAX(voltageState, consumptionState); } -lowVoltageCutoff_t *getLowVoltageCutoff(void) +const lowVoltageCutoff_t *getLowVoltageCutoff(void) { return &lowVoltageCutoff; } diff --git a/src/main/sensors/battery.h b/src/main/sensors/battery.h index 770c6b3759..467b229329 100644 --- a/src/main/sensors/battery.h +++ b/src/main/sensors/battery.h @@ -87,4 +87,4 @@ int32_t getMAhDrawn(void); void batteryUpdateCurrentMeter(timeUs_t currentTimeUs); -lowVoltageCutoff_t *getLowVoltageCutoff(void); +const lowVoltageCutoff_t *getLowVoltageCutoff(void); diff --git a/src/main/sensors/gyro.c b/src/main/sensors/gyro.c index aee591e446..91e0f0e05a 100644 --- a/src/main/sensors/gyro.c +++ b/src/main/sensors/gyro.c @@ -118,7 +118,7 @@ static void gyroInitSensorFilters(gyroSensor_t *gyroSensor); #define GYRO_SYNC_DENOM_DEFAULT 4 #endif -PG_REGISTER_WITH_RESET_TEMPLATE(gyroConfig_t, gyroConfig, PG_GYRO_CONFIG, 0); +PG_REGISTER_WITH_RESET_TEMPLATE(gyroConfig_t, gyroConfig, PG_GYRO_CONFIG, 1); PG_RESET_TEMPLATE(gyroConfig_t, gyroConfig, .gyro_align = ALIGN_DEFAULT,