diff options
| author | Shlomo Hecht <shlomo@twine-s.com> | 2020-02-10 16:06:50 +0200 |
|---|---|---|
| committer | Shlomo Hecht <shlomo@twine-s.com> | 2020-02-10 16:06:50 +0200 |
| commit | 88169a21caf5587f3ad57467c8a4a6de9b1f29ef (patch) | |
| tree | 3ecd13bb3900e3b7f1e9dcfe0a9e3a6a751bcac4 /Software/Embedded_SW/Embedded/Modules | |
| parent | 25fa087b38d74942ee94a88391059a820b5d22b4 (diff) | |
| download | Tango-88169a21caf5587f3ad57467c8a4a6de9b1f29ef.tar.gz Tango-88169a21caf5587f3ad57467c8a4a6de9b1f29ef.zip | |
bypass stubs for feature #2203
Diffstat (limited to 'Software/Embedded_SW/Embedded/Modules')
7 files changed, 76 insertions, 14 deletions
diff --git a/Software/Embedded_SW/Embedded/Modules/General/process.c b/Software/Embedded_SW/Embedded/Modules/General/process.c index ad53149f0..74a6cfe90 100644 --- a/Software/Embedded_SW/Embedded/Modules/General/process.c +++ b/Software/Embedded_SW/Embedded/Modules/General/process.c @@ -57,6 +57,12 @@ void HeatersStopControlOnHeatersOff(ProcessParameters* ProcessParams) temp_sum += ProcessParams->headzone4temp; temp_sum += ProcessParams->headzone5temp; temp_sum += ProcessParams->headzone6temp; + temp_sum += ProcessParams->headzone7temp; + temp_sum += ProcessParams->headzone8temp; + temp_sum += ProcessParams->headzone9temp; + temp_sum += ProcessParams->headzone10temp; + temp_sum += ProcessParams->headzone11temp; + temp_sum += ProcessParams->headzone12temp; if (temp_sum == 0)// heating off { diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h index a819448a8..5c01d7563 100644 --- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h +++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h @@ -76,6 +76,8 @@ uint32_t IDS_StopHomeDispenser (uint32_t deviceID); uint32_t IDS_HomeDispenserWaitForHomingEnd(uint32_t DispenserId, uint32_t timeout , callback_fptr callback); bool IDS_IsHomingActive(uint32_t DispenserId); + + uint32_t IDS_EmptyDispenser (uint32_t deviceID, uint32_t speed , callback_fptr callback); uint32_t IDS_Dispenser_Alarm_On (uint8_t deviceID); uint32_t IDS_Dispenser_Alarm_Off (uint8_t deviceID); @@ -90,6 +92,8 @@ void IDS_Dispenser_SetPreSegmentWFCFValues(double dispenserpresegmentwfcf, doubl void IDS_Dispenser_SetPreSegmentCleaningValues(double ids_cleaningspeed,double ids_cleaningstartspraypresegmenttime ,double ids_cleaningstopbeforesegmenttime,double ids_leftcleaningmotorspeed,double ids_rightcleaningmotorspeed); void IDS_Dispenser_SetAutoHoming_Config(AutoHoming_Config_enum Config); +bool Set_Check_Pressure_Bypass(int); + uint32_t IDS_Dispenser_Close_Valve_And_Stop_Motor(int DispenserId, callback_fptr callback); uint32_t IDS_Dispenser_Start_Motor_and_Open_Valve(int DispenserId, int MotorSpeed, callback_fptr callback); diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_maint.c b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_maint.c index e1be0358b..79d169ace 100644 --- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_maint.c +++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_maint.c @@ -496,6 +496,15 @@ uint32_t IDS_ReCheck_Pressure_Callback(uint32_t DispenserId, uint32_t ReadValue) return OK; } +bool Check_Pressure_Bypass = false; +bool Set_Check_Pressure_Bypass (int value) +{ + if (value == 0) + Check_Pressure_Bypass = false; + else + Check_Pressure_Bypass = true; + return Check_Pressure_Bypass; +} uint32_t IDS_Check_Pressure_Callback(uint32_t DispenserId, uint32_t ReadValue) { TimerMotors_t HW_Motor_Id = DispenserIdToMotorId[DispenserId]; @@ -507,6 +516,8 @@ uint32_t IDS_Check_Pressure_Callback(uint32_t DispenserId, uint32_t ReadValue) return ERROR; } } + if (Check_Pressure_Bypass == true) + return OK; if (GetDispenserPressure(DispenserId)>3.0) { diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c index 708b11342..688ecf7c5 100644 --- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c +++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c @@ -1024,7 +1024,7 @@ uint32_t IDS_Cleaning_Stop_Cleaning_Solution (callback_fptr callback); */ //InterSegmentStepsLimit = lInterSegmentLength*10;//100 millisec steps InterSegmentStepsCount+=100; - if (InterSegmentStepsCount == lInterSegmentLength) + if (InterSegmentStepsCount >= lInterSegmentLength) { //IDS_Valve_PresegmentReady(1,0); Report("End of Pre-segment Handling",__FILE__,__LINE__,InterSegmentStepsCount,RpWarning,(int)lInterSegmentLength,0); @@ -1622,13 +1622,13 @@ uint32_t IDSSegmentState(void *SegmentDetails, int SegmentId) lInterSegmentLength = (dryerbufferCentimeters*1000/dyeingspeed); lInterSegmentLength-=(lInterSegmentLength%100); //round to a 100 multiplication InterSegmentStepsCount = 0; - DispenserPreSegmentControlId = AddControlCallback(NULL, IDSPreSegmentStateCallbackRunner, 100,TemplateDataReadCBFunction ,0, 0, 0 ); + DispenserPreSegmentControlId = AddControlCallback("IDS DTS", IDSPreSegmentStateCallbackRunner, 100,TemplateDataReadCBFunction ,0, 0, 0 ); if (DispenserPreSegmentControlId == 0xFF) { Report("Add control callback failed",__FILE__,__LINE__,(int)100,RpWarning,(int)0,0); return ERROR; } - Report("Add control callback ",__FILE__,__LINE__,(int)100,RpWarning,(int)IntersegmentLength,0); + Report("Add control callback ",__FILE__,__LINE__,(int)100,RpWarning,(int)lInterSegmentLength,0); /*if (EnableCleaning == true) { InterSegmentStartSprayCleaner = 500; diff --git a/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Progress.c b/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Progress.c index c22ed4cde..2652c38b9 100644 --- a/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Progress.c +++ b/Software/Embedded_SW/Embedded/Modules/Stubs_Handler/Progress.c @@ -192,6 +192,34 @@ void Stub_ProgressRequest(MessageContainer* requestContainer) response.has_progress = true; } else + if(request->amount == 0xAD1) //Set_Check_Pressure_Bypass + { + LOG_ERROR((request->delay)?1:0,"Set_Check_Pressure_Bypass"); + response.progress = Set_Check_Pressure_Bypass(request->delay); + response.has_progress = true; + } + else + if(request->amount == 0xAD2) //Set_Thread_Rockers_Bypass + { + LOG_ERROR((request->delay)?1:0,"Set_Thread_Rockers_Bypass"); + response.progress = Set_Thread_Rockers_Bypass(request->delay); + response.has_progress = true; + } + else + if(request->amount == 0xAD3) //Set_Auto_Shutdown_Bypass + { + LOG_ERROR((request->delay)?1:0,"Set_Auto_Shutdown_Bypass"); + response.progress = Set_Auto_Shutdown_Bypass(request->delay); + response.has_progress = true; + } + else + if(request->amount == 0xAD4) //Set_Auto_Idle_Bypass + { + LOG_ERROR((request->delay)?1:0,"Set_Auto_Idle_Bypass"); + response.progress = Set_Auto_Idle_Bypass(request->delay); + response.has_progress = true; + } + else if((request->amount == 0x01) && ((request->delay &0x010000) == 0x010000)) //change mode powerset01 { response.progress = Power_Step_01_Mode(((request->delay &0x00FF00)>>8), request->delay &0x0000FF); diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_ex.h b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_ex.h index 420b782b5..114edc0cd 100644 --- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_ex.h +++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_ex.h @@ -38,6 +38,8 @@ uint32_t ThreadDistanceToSpoolState(void); uint32_t ThreadEndState(); uint32_t ThreadInitialTestStub(); +bool Set_Thread_Rockers_Bypass (int value); + uint32_t StoreDancerConfigMessage(void); uint32_t LoadDancerConfigMessage(void); diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c index fd53d6da2..fd48e799a 100644 --- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c +++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c @@ -958,6 +958,15 @@ uint32_t ThreadDryerRampUp(uint32_t IfIndex, uint32_t BusyFlag) return OK; } +bool Thread_Rockers_Bypass = false; +bool Set_Thread_Rockers_Bypass (int value) +{ + if (value == 0) + Thread_Rockers_Bypass = false; + else + Thread_Rockers_Bypass = true; + return Thread_Rockers_Bypass; +} //******************************************************************************************************************** uint32_t ThreadPreSegmentState(void *SegmentDetails, uint32_t SegmentId) @@ -995,17 +1004,19 @@ uint32_t ThreadPreSegmentState(void *SegmentDetails, uint32_t SegmentId) #ifdef HUNDRED_MICROSECONDS_DANCER_READ MillisecLogInit(); #endif - - if (MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_RLOADING].maxfrequency > 0) - { - MotorSetDirection((TimerMotors_t)HARDWARE_MOTOR_TYPE__MOTO_RLOADING,MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_RLOADING].directionthreadwize); - MotorSetSpeed(HARDWARE_MOTOR_TYPE__MOTO_RLOADING, 1); - } - if (MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_LLOADING].maxfrequency > 0) - { - MotorSetDirection((TimerMotors_t)HARDWARE_MOTOR_TYPE__MOTO_LLOADING,MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_LLOADING].directionthreadwize); - MotorSetSpeed(HARDWARE_MOTOR_TYPE__MOTO_LLOADING, 1); - } + if (Thread_Rockers_Bypass == false) + { + if (MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_RLOADING].maxfrequency > 0) + { + MotorSetDirection((TimerMotors_t)HARDWARE_MOTOR_TYPE__MOTO_RLOADING,MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_RLOADING].directionthreadwize); + MotorSetSpeed(HARDWARE_MOTOR_TYPE__MOTO_RLOADING, 1); + } + if (MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_LLOADING].maxfrequency > 0) + { + MotorSetDirection((TimerMotors_t)HARDWARE_MOTOR_TYPE__MOTO_LLOADING,MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_LLOADING].directionthreadwize); + MotorSetSpeed(HARDWARE_MOTOR_TYPE__MOTO_LLOADING, 1); + } + } if (EnableLubrication == true) { IDS_StartLubrication(); |
