aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2020-10-29 15:59:47 +0200
committerShlomo Hecht <shlomo@twine-s.com>2020-10-29 15:59:47 +0200
commit227e1f5959eaae9c3bacfed34aa91c5dd6d5a46a (patch)
treeb673f0d6e1ff8c836ddba1733534a3798160c0cc
parent4b789f33eadfc5cc1d937a80ce03ea8425955ffe (diff)
downloadTango-227e1f5959eaae9c3bacfed34aa91c5dd6d5a46a.tar.gz
Tango-227e1f5959eaae9c3bacfed34aa91c5dd6d5a46a.zip
disconnection on file analysis solved
-rw-r--r--Software/Embedded_SW/Embedded/Communication/Connection.c2
-rw-r--r--Software/Embedded_SW/Embedded/Communication/Container.c2
-rw-r--r--Software/Embedded_SW/Embedded/Drivers/I2C_Communication/WHS_Card/D_Max5805_ADC_Blower/WHS_Blower.c2
-rw-r--r--Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c8
-rw-r--r--Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.h1
-rw-r--r--Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c2
-rw-r--r--Software/Embedded_SW/Embedded/Modules/Waste/Waste_maint.c2
7 files changed, 15 insertions, 4 deletions
diff --git a/Software/Embedded_SW/Embedded/Communication/Connection.c b/Software/Embedded_SW/Embedded/Communication/Connection.c
index b566aa0e0..2be123948 100644
--- a/Software/Embedded_SW/Embedded/Communication/Connection.c
+++ b/Software/Embedded_SW/Embedded/Communication/Connection.c
@@ -199,6 +199,8 @@ void KeepAliveOneSecondCall(void)
{
if (FileUploadGetState()==false)
return;
+ if (FileAnalysisGetState()==true)
+ return;
KeepAliveRequest1Second();
if (KeepAliveActive == false)
return;
diff --git a/Software/Embedded_SW/Embedded/Communication/Container.c b/Software/Embedded_SW/Embedded/Communication/Container.c
index d12d70aa2..b9580ef81 100644
--- a/Software/Embedded_SW/Embedded/Communication/Container.c
+++ b/Software/Embedded_SW/Embedded/Communication/Container.c
@@ -148,7 +148,7 @@ void receive_callback(char* buffer, size_t length)
ReportWithPackageFilter(CommFilter,"Message received", __FILE__,__LINE__,requestContainer->type, RpMessage,length, 0);
}
#endif
- if (requestContainer->type != MESSAGE_TYPE__KeepAliveRequest)
+ if ((requestContainer->type != MESSAGE_TYPE__KeepAliveRequest)||(requestContainer->type != MESSAGE_TYPE__KeepAliveResponse))
resetIdleCounter();
//ReportWithPackageFilter(CommFilter,"Message received", __FILE__,__LINE__,requestContainer->type, RpMessage,length, 0);
KeepAliveOneSecondCounter = 0;
diff --git a/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/WHS_Card/D_Max5805_ADC_Blower/WHS_Blower.c b/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/WHS_Card/D_Max5805_ADC_Blower/WHS_Blower.c
index aef2be5fe..43b636f7a 100644
--- a/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/WHS_Card/D_Max5805_ADC_Blower/WHS_Blower.c
+++ b/Software/Embedded_SW/Embedded/Drivers/I2C_Communication/WHS_Card/D_Max5805_ADC_Blower/WHS_Blower.c
@@ -594,7 +594,7 @@ void WHS_Start_Blower_Control_Closed_Loop ()
return; //do not start before controller is initialized and running
if (EnableControlLoop == false)
return; //do not start loop
- if (WHS_Type == WHS_TYPE_NEW)
+ if (WHS_Type != WHS_TYPE_NEW)
return; //do not start loop
if (count == close_loop_time)
diff --git a/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c b/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c
index 53394f4c0..881a02f8e 100644
--- a/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c
+++ b/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c
@@ -813,6 +813,12 @@ uint32_t AlarmHandlingConsequentActions(uint32_t AlarmId, DebugLogCategory Sever
}
return OK;
}
+bool FileAnalysis = false;
+bool FileAnalysisGetState(void)
+{
+ return FileAnalysis;
+}
+
JobEndReasonEnum AlarmHandlingPrepareJob(void *CurrentJob)
{
//JobTicket* JobTicket = CurrentJob;
@@ -829,6 +835,7 @@ JobEndReasonEnum AlarmHandlingPrepareJob(void *CurrentJob)
ACTIVITY_GREEN_LED_ON;
Task_setPri(TaskHandle1, 11);
+ FileAnalysis = true;
Task_sleep(10);
Report("Task_setPri", __FILE__, pri, 3, RpWarning, (int)TaskHandle1, 0);
IDS_MapDispenserUsedinJob(CurrentJob);
@@ -836,6 +843,7 @@ JobEndReasonEnum AlarmHandlingPrepareJob(void *CurrentJob)
Report("Task_setPri", __FILE__, __LINE__, pri, RpWarning, (int)Task_self(), 0);
Task_sleep(10);
ACTIVITY_GREEN_LED_OFF;
+ FileAnalysis = false;
if (n_segments == 0)
{
ReportWithPackageFilter(AlarmFilter,"no segments in the job", __FILE__,__LINE__,0, DEBUG_LOG_CATEGORY__Warning, 222, 0);
diff --git a/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.h b/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.h
index 0ce6d4816..a8dd43a17 100644
--- a/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.h
+++ b/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.h
@@ -26,6 +26,7 @@ uint32_t AlarmHandlingStop(void);
void AlarmHandlingSetAlarm(uint32_t AlarmId, bool Value);
JobEndReasonEnum AlarmHandlingPrepareJob(void *CurrentJob);
+bool FileAnalysisGetState(void);
extern char AlarmReasonStr[100];
uint32_t StartEventsNotificationRequestFunc(MessageContainer* requestContainer);
diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c
index 9f8491aa1..d2fd74256 100644
--- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c
+++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c
@@ -1948,6 +1948,6 @@ uint32_t IDS_StopLubrication(void)
TimerMotors_t HW_Motor_Id = DispenserIdToMotorId[LUBRICANT_DISPENSER];
MotorStop(HW_Motor_Id,Hard_Hiz);
CurrentDispenserSpeed[LUBRICANT_DISPENSER] = 0;
- IDS_HomeDispenser (LUBRICANT_DISPENSER, 1000 , NULL);
+ //IDS_HomeDispenser (LUBRICANT_DISPENSER, 1000 , NULL); do not fill lubricant between jobs
return OK;
}
diff --git a/Software/Embedded_SW/Embedded/Modules/Waste/Waste_maint.c b/Software/Embedded_SW/Embedded/Modules/Waste/Waste_maint.c
index 4343c1607..83755376f 100644
--- a/Software/Embedded_SW/Embedded/Modules/Waste/Waste_maint.c
+++ b/Software/Embedded_SW/Embedded/Modules/Waste/Waste_maint.c
@@ -625,7 +625,7 @@ bool WHS_IsVocPpmOverAlarmLimit()
if( ( Latest_Gas_Sens_PPM > VocPpmAlarmLimit ) || //PPM
( (Latest_Gas_Sens_PPM > VocPpmAlarmLimit90Percent) && (ReadingVocEverySec == true) ) ) //Hysteresis
{
- Report("VOC nearing alarm state", __FILE__, (int)(Latest_Gas_Sens_PPM*100), VocPpmAlarmLimit, RpMessage, counter, 0);
+ //Report("VOC nearing alarm state", __FILE__, (int)(Latest_Gas_Sens_PPM*100), VocPpmAlarmLimit, RpMessage, counter, 0);
//reading every sec
ReadingVocEverySec = true;
if(counter < 0xFF)