Fix config_version mapping

This commit is contained in:
Norbert Richter 2022-02-08 16:30:10 +01:00
parent 9cef794259
commit e79db330d5
No known key found for this signature in database
GPG Key ID: 6628701A626FA674
1 changed files with 8 additions and 8 deletions

View File

@ -444,11 +444,11 @@ bool SettingsConfigRestore(void) {
valid_settings = (0 == settings_buffer[0xF36]); // Settings->config_version valid_settings = (0 == settings_buffer[0xF36]); // Settings->config_version
#endif // ESP8266 #endif // ESP8266
#ifdef ESP32 #ifdef ESP32
#ifdef CONFIG_IDF_TARGET_ESP32C3 #ifdef CONFIG_IDF_TARGET_ESP32S3
valid_settings = (2 == settings_buffer[0xF36]); // Settings->config_version valid_settings = (2 == settings_buffer[0xF36]); // Settings->config_version
#else #else
valid_settings = (1 == settings_buffer[0xF36]); // Settings->config_version valid_settings = (1 == settings_buffer[0xF36]); // Settings->config_version
#endif // CONFIG_IDF_TARGET_ESP32C3 #endif // CONFIG_IDF_TARGET_ESP32S3
#endif // ESP32 #endif // ESP32
} }
@ -828,11 +828,11 @@ void SettingsDefaultSet2(void) {
// Settings->config_version = 0; // ESP8266 (Has been 0 for long time) // Settings->config_version = 0; // ESP8266 (Has been 0 for long time)
#endif // ESP8266 #endif // ESP8266
#ifdef ESP32 #ifdef ESP32
#ifdef CONFIG_IDF_TARGET_ESP32C3 #ifdef CONFIG_IDF_TARGET_ESP32S3
Settings->config_version = 2; // ESP32C3 Settings->config_version = 2; // ESP32S3
#else #else
Settings->config_version = 1; // ESP32 Settings->config_version = 1; // ESP32
#endif // CONFIG_IDF_TARGET_ESP32C3 #endif // CONFIG_IDF_TARGET_ESP32S3
#endif // ESP32 #endif // ESP32
flag.stop_flash_rotate |= APP_FLASH_CYCLE; flag.stop_flash_rotate |= APP_FLASH_CYCLE;
@ -1354,11 +1354,11 @@ void SettingsDelta(void) {
Settings->config_version = 0; // ESP8266 (Has been 0 for long time) Settings->config_version = 0; // ESP8266 (Has been 0 for long time)
#endif // ESP8266 #endif // ESP8266
#ifdef ESP32 #ifdef ESP32
#ifdef CONFIG_IDF_TARGET_ESP32C3 #ifdef CONFIG_IDF_TARGET_ESP32S3
Settings->config_version = 2; // ESP32C3 Settings->config_version = 2; // ESP32S3
#else #else
Settings->config_version = 1; // ESP32 Settings->config_version = 1; // ESP32
#endif // CONFIG_IDF_TARGET_ESP32C3 #endif // CONFIG_IDF_TARGET_ESP32S3
#endif // ESP32 #endif // ESP32
} }
if (Settings->version < 0x08020006) { if (Settings->version < 0x08020006) {