aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Main.c
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2020-01-26 16:28:56 +0200
committerShlomo Hecht <shlomo@twine-s.com>2020-01-26 16:28:56 +0200
commit6d0d04a9f1d3ebbc679190ff49df69406eabe24a (patch)
tree697ec870789091d0b26075696915120713270388 /Software/Embedded_SW/Embedded/Main.c
parent494d0f61b0800d96b1694930388397d9d9318d58 (diff)
downloadTango-6d0d04a9f1d3ebbc679190ff49df69406eabe24a.tar.gz
Tango-6d0d04a9f1d3ebbc679190ff49df69406eabe24a.zip
updating : special dispensers handling (for Moti), new process parameters, bugs and features. merged with Shai
Diffstat (limited to 'Software/Embedded_SW/Embedded/Main.c')
-rw-r--r--Software/Embedded_SW/Embedded/Main.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/Software/Embedded_SW/Embedded/Main.c b/Software/Embedded_SW/Embedded/Main.c
index 3616404d1..90b303ddb 100644
--- a/Software/Embedded_SW/Embedded/Main.c
+++ b/Software/Embedded_SW/Embedded/Main.c
@@ -135,6 +135,7 @@ Void errHook(Error_Block *eb)
site = Error_getSite(eb);
eid = Error_getId(eb);
eCode = Error_getCode(eb);
+ CloseLogFile();
if (UpdateFlag == true)
return;
FileHandle = my_malloc(sizeof(FIL));
@@ -155,7 +156,7 @@ Void errHook(Error_Block *eb)
site->file,site->line);
Fresult = f_write(FileHandle,message,len,&Bytes );
- LOG_ERROR (eCode, "error # ");
+ //LOG_ERROR (eCode, "error # ");
/* check originator's mod id against known mods */
if (site->mod == Main_Module_id()) {
Fresult = f_write(FileHandle,"\r\napp error: ",12,&Bytes );
@@ -236,6 +237,14 @@ int main(void)
Init_EVB();
#endif
+ FRESULT iFResult = Init_Flash_File_System(false);// true
+ if(iFResult != FR_OK)
+ {
+ LOG_ERROR (iFResult, "Error during init Flash File System");
+ assert(iFResult);
+ }
+ OpenLogFile();
+
Init_All_I2C();
Block_Main_MUX_TCA9548A_0xE4();//unused, same i2c as head and whs cards
Check_Head_Type_Via_EEPROM();
@@ -294,13 +303,6 @@ int main(void)
//calibration(); //test vme communication
- FRESULT iFResult = Init_Flash_File_System(false);// true
- if(iFResult != FR_OK)
- {
- LOG_ERROR (iFResult, "Error during init Flash File System");
- assert(iFResult);
- }
-
//GetFiles(); - to start jtag
//GetVmeByte();