aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2019-07-09 16:52:02 +0300
committerShlomo Hecht <shlomo@twine-s.com>2019-07-09 16:52:02 +0300
commite4eaedb7bcca2276a17bda687d7773dc1540346d (patch)
tree10b63964c75e8a628e3a72138aa36ff1077e6963 /Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c
parent5cf2e060dcb21338d838e103951762b3e7eb4702 (diff)
downloadTango-e4eaedb7bcca2276a17bda687d7773dc1540346d.tar.gz
Tango-e4eaedb7bcca2276a17bda687d7773dc1540346d.zip
improve flash handling
Diffstat (limited to 'Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c')
-rw-r--r--Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c
index 3bae023db..273dfb49d 100644
--- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c
+++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FirmwareUpgrade.c
@@ -143,21 +143,26 @@ uint32_t ActivateVersionRequestFunc(MessageContainer* requestContainer)
usnprintf(FullPath, 50, "%s%s%s", request->path,"/", VersionPackage->filedescriptors[File_i]->filename);
Fresult = f_unlink("//SYSINFO//EMBPARAM.CFG");
Fresult |= f_rename (FullPath, "//SYSINFO//EMBPARAM.CFG");
+ LoadConfigurationParamsFromFile();
+ CurrentRunningFile++;
break;
case VERSION_FILE_DESTINATION__ProcessParams:
usnprintf(FullPath, 50, "%s%s%s", request->path,"/", VersionPackage->filedescriptors[File_i]->filename);
Fresult = f_unlink("//SYSINFO//PROCESSP.CFG");
Fresult |= f_rename (FullPath, "//SYSINFO//PROCESSP.CFG");
+ CurrentRunningFile++;
break;
case VERSION_FILE_DESTINATION__AlarmParams:
usnprintf(FullPath, 50, "%s%s%s", request->path,"/", VersionPackage->filedescriptors[File_i]->filename);
Fresult = f_unlink("//SYSINFO//ALARMPRM.CFG");
Fresult |= f_rename (FullPath, "//SYSINFO//ALARMPRM.CFG");
+ CurrentRunningFile++;
break;
case VERSION_FILE_DESTINATION__GeneralHWConfigParams:
usnprintf(FullPath, 50, "%s%s%s", request->path,"/", VersionPackage->filedescriptors[File_i]->filename);
Fresult = f_unlink("//SYSINFO//GENHWCFG.CFG");
Fresult |= f_rename (FullPath, "//SYSINFO//GENHWCFG.CFG");
+ CurrentRunningFile++;
break;
default:
LOG_ERROR (VersionPackage->filedescriptors[File_i]->destination,"wrong file update Destination");