aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/StateMachines
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2020-12-01 18:28:41 +0200
committerShlomo Hecht <shlomo@twine-s.com>2020-12-01 18:28:41 +0200
commitbeec9e4961b89d0146ca6cf8d4c42b5b7a94fed0 (patch)
tree7c2ce66244fc50604331fa40ca33ae420764b033 /Software/Embedded_SW/Embedded/StateMachines
parente1ee0eafc192d6df9fa41a2749d016473d7563f4 (diff)
downloadTango-beec9e4961b89d0146ca6cf8d4c42b5b7a94fed0.tar.gz
Tango-beec9e4961b89d0146ca6cf8d4c42b5b7a94fed0.zip
several changes in stubs, some fixes, stub for WHS v0 read
Diffstat (limited to 'Software/Embedded_SW/Embedded/StateMachines')
-rw-r--r--Software/Embedded_SW/Embedded/StateMachines/Initialization/InitSequence.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/Software/Embedded_SW/Embedded/StateMachines/Initialization/InitSequence.c b/Software/Embedded_SW/Embedded/StateMachines/Initialization/InitSequence.c
index 802ce81cc..0d3b5e2f0 100644
--- a/Software/Embedded_SW/Embedded/StateMachines/Initialization/InitSequence.c
+++ b/Software/Embedded_SW/Embedded/StateMachines/Initialization/InitSequence.c
@@ -83,7 +83,6 @@ uint32_t InitSequenceMachineReadyToDye(void);
uint32_t InitSequenceStateMachine( INIT_SEQUENCE_STAGES_ENUM ReadValue);
uint32_t PowerUpUpdate(MACHINE_STATE_STAGES_ENUM stage);
int InitFailures = 0;
-extern uint32_t PressureSensorV0[2];
MACHINE_STATE_STAGES_ENUM GetMachineState(void)
{
@@ -112,19 +111,19 @@ uint32_t InitSequenceCallBackFunction(uint32_t IfIndex, uint32_t BusyFlag)
MCU_E2PromProgram(EEPROM_INIT_FAILURE_COUNTER,InitFailures+1);
- if (InitFailures >= REPEATED_INIT_FAILURE_LIMIT+3)
+ /*if (InitFailures >= REPEATED_INIT_FAILURE_LIMIT+3)
{
InitFailures = 0;
MCU_E2PromProgram(EEPROM_INIT_FAILURE_COUNTER,0);
- }
- if (InitFailures > REPEATED_INIT_FAILURE_LIMIT)
- {
+ }*/
+ //if (InitFailures > REPEATED_INIT_FAILURE_LIMIT)
+ //{
Report("HWConfigurationInit repeated failure",__FILE__,__LINE__,(int)InitFailures,RpWarning,(int)EEPROM_INIT_FAILURE_COUNTER,0);
/*SetMachineState(MACHINE_STATE_HW_CONFIG_FAILED);
AlarmHandlingSetAlarm (EVENT_TYPE__MACHINE_STATE_HW_CONFIG_FAILED,ON);
SetMachineStatus(MACHINE_STATE__Error);
return ERROR;*/
- }
+ //}
status = (MACHINE_STATE_STAGES_ENUM)HWConfigurationInit();
if (status == OK)
{
@@ -834,6 +833,10 @@ uint32_t PowerUpUpdate(MACHINE_STATE_STAGES_ENUM stage)
calculate = (double)((MillisecGetTemperatures(TEMP_SENSE_ANALOG_DRYER_TEMP1)/100)/(dryerzone1temp))*70.0;
if (calculate > 0)
result = (int)calculate;
+ if (result > 70.00)
+ result = 70.0;
+ if (HeaterCheckReady()==false)
+ result-=2;
response.progresspercentage = 30.0 + result;
}
//Report("Heating calculation",__FILE__,(int)dryerzone1temp,(int)response.progresspercentage,RpWarning,(int)result,0);