From c6a0bc8f103aeaccaee8ffcd83d8f0741e006bfc Mon Sep 17 00:00:00 2001 From: Shlomo Hecht Date: Wed, 6 Mar 2019 18:11:12 +0200 Subject: current added to the diagnostics data. added protobuf parameters compiled. --- .../PMR/Diagnostics/DiagnosticsMonitors.pb-c.c | 110 ++++++++++++++++++++- .../PMR/Diagnostics/DiagnosticsMonitors.pb-c.h | 18 +++- .../ConfigurationParameters.pb-c.c | 45 ++++++++- .../ConfigurationParameters.pb-c.h | 8 +- 4 files changed, 173 insertions(+), 8 deletions(-) (limited to 'Software/Embedded_SW/Embedded/Communication') diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.c index 3bbdcdd8c..2a5974162 100644 --- a/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.c +++ b/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.c @@ -52,7 +52,7 @@ void diagnostics_monitors__free_unpacked assert(message->base.descriptor == &diagnostics_monitors__descriptor); protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator); } -static const ProtobufCFieldDescriptor diagnostics_monitors__field_descriptors[55] = +static const ProtobufCFieldDescriptor diagnostics_monitors__field_descriptors[63] = { { "Dancer1Angle", @@ -714,6 +714,102 @@ static const ProtobufCFieldDescriptor diagnostics_monitors__field_descriptors[55 0, /* flags */ 0,NULL,NULL /* reserved1,reserved2, etc */ }, + { + "DrierZone1HeaterCurrent", + 56, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_drierzone1heatercurrent), + offsetof(DiagnosticsMonitors, drierzone1heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "DrierZone2HeaterCurrent", + 57, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_drierzone2heatercurrent), + offsetof(DiagnosticsMonitors, drierzone2heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "HeadZone1HeaterCurrent", + 58, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_headzone1heatercurrent), + offsetof(DiagnosticsMonitors, headzone1heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "HeadZone2HeaterCurrent", + 59, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_headzone2heatercurrent), + offsetof(DiagnosticsMonitors, headzone2heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "HeadZone3HeaterCurrent", + 60, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_headzone3heatercurrent), + offsetof(DiagnosticsMonitors, headzone3heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "HeadZone4HeaterCurrent", + 61, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_headzone4heatercurrent), + offsetof(DiagnosticsMonitors, headzone4heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "HeadZone5_6HeaterCurrent", + 62, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_headzone5_6heatercurrent), + offsetof(DiagnosticsMonitors, headzone5_6heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "Mixer1HeaterCurrent", + 63, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(DiagnosticsMonitors, n_mixer1heatercurrent), + offsetof(DiagnosticsMonitors, mixer1heatercurrent), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, }; static const unsigned diagnostics_monitors__field_indices_by_name[] = { 38, /* field[38] = BlowerVoltage */ @@ -741,6 +837,8 @@ static const unsigned diagnostics_monitors__field_indices_by_name[] = { 23, /* field[23] = DispensersLinearPositions */ 21, /* field[21] = DispensersMotorsFrequency */ 24, /* field[24] = DispensersPressure */ + 55, /* field[55] = DrierZone1HeaterCurrent */ + 56, /* field[56] = DrierZone2HeaterCurrent */ 19, /* field[19] = DryerAirFlow */ 4, /* field[4] = DryerMotor */ 16, /* field[16] = DryerZone1Temperature */ @@ -750,11 +848,16 @@ static const unsigned diagnostics_monitors__field_indices_by_name[] = { 14, /* field[14] = FeederTension */ 25, /* field[25] = FilterDeltaPressure */ 13, /* field[13] = HeadAirFlow */ + 57, /* field[57] = HeadZone1HeaterCurrent */ 10, /* field[10] = HeadZone1Temperature */ + 58, /* field[58] = HeadZone2HeaterCurrent */ 11, /* field[11] = HeadZone2Temperature */ + 59, /* field[59] = HeadZone3HeaterCurrent */ 12, /* field[12] = HeadZone3Temperature */ + 60, /* field[60] = HeadZone4HeaterCurrent */ 35, /* field[35] = HeadZone4Temperature */ 36, /* field[36] = HeadZone5Temperature */ + 61, /* field[61] = HeadZone5_6HeaterCurrent */ 37, /* field[37] = HeadZone6Temperature */ 47, /* field[47] = MidTank1Level */ 48, /* field[48] = MidTank2Level */ @@ -764,6 +867,7 @@ static const unsigned diagnostics_monitors__field_indices_by_name[] = { 52, /* field[52] = MidTank6Level */ 53, /* field[53] = MidTank7Level */ 54, /* field[54] = MidTank8Level */ + 62, /* field[62] = Mixer1HeaterCurrent */ 9, /* field[9] = MixerTemperature */ 5, /* field[5] = PollerMotor */ 15, /* field[15] = PullerTension */ @@ -775,7 +879,7 @@ static const unsigned diagnostics_monitors__field_indices_by_name[] = { static const ProtobufCIntRange diagnostics_monitors__number_ranges[1 + 1] = { { 1, 0 }, - { 0, 55 } + { 0, 63 } }; const ProtobufCMessageDescriptor diagnostics_monitors__descriptor = { @@ -785,7 +889,7 @@ const ProtobufCMessageDescriptor diagnostics_monitors__descriptor = "DiagnosticsMonitors", "", sizeof(DiagnosticsMonitors), - 55, + 63, diagnostics_monitors__field_descriptors, diagnostics_monitors__field_indices_by_name, 1, diagnostics_monitors__number_ranges, diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.h index 5917ffd76..13ebbaf21 100644 --- a/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.h +++ b/Software/Embedded_SW/Embedded/Communication/PMR/Diagnostics/DiagnosticsMonitors.pb-c.h @@ -137,10 +137,26 @@ struct _DiagnosticsMonitors double *midtank7level; size_t n_midtank8level; double *midtank8level; + size_t n_drierzone1heatercurrent; + double *drierzone1heatercurrent; + size_t n_drierzone2heatercurrent; + double *drierzone2heatercurrent; + size_t n_headzone1heatercurrent; + double *headzone1heatercurrent; + size_t n_headzone2heatercurrent; + double *headzone2heatercurrent; + size_t n_headzone3heatercurrent; + double *headzone3heatercurrent; + size_t n_headzone4heatercurrent; + double *headzone4heatercurrent; + size_t n_headzone5_6heatercurrent; + double *headzone5_6heatercurrent; + size_t n_mixer1heatercurrent; + double *mixer1heatercurrent; }; #define DIAGNOSTICS_MONITORS__INIT \ { PROTOBUF_C_MESSAGE_INIT (&diagnostics_monitors__descriptor) \ - , 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL } + , 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL, 0,NULL } /* DiagnosticsMonitors methods */ diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.c b/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.c index 5e36720c9..b5e08ea1f 100644 --- a/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.c +++ b/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.c @@ -52,7 +52,7 @@ void configuration_parameters__free_unpacked assert(message->base.descriptor == &configuration_parameters__descriptor); protobuf_c_message_free_unpacked ((ProtobufCMessage*)message, allocator); } -static const ProtobufCFieldDescriptor configuration_parameters__field_descriptors[18] = +static const ProtobufCFieldDescriptor configuration_parameters__field_descriptors[21] = { { "BreakSensorLimit", @@ -270,6 +270,42 @@ static const ProtobufCFieldDescriptor configuration_parameters__field_descriptor 0, /* flags */ 0,NULL,NULL /* reserved1,reserved2, etc */ }, + { + "DispenserPresegmentWFCF", + 19, + PROTOBUF_C_LABEL_OPTIONAL, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(ConfigurationParameters, has_dispenserpresegmentwfcf), + offsetof(ConfigurationParameters, dispenserpresegmentwfcf), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "StartHeatingOnInitSequence", + 20, + PROTOBUF_C_LABEL_OPTIONAL, + PROTOBUF_C_TYPE_BOOL, + offsetof(ConfigurationParameters, has_startheatingoninitsequence), + offsetof(ConfigurationParameters, startheatingoninitsequence), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, + { + "GeneralParameters", + 21, + PROTOBUF_C_LABEL_REPEATED, + PROTOBUF_C_TYPE_DOUBLE, + offsetof(ConfigurationParameters, n_generalparameters), + offsetof(ConfigurationParameters, generalparameters), + NULL, + NULL, + 0, /* flags */ + 0,NULL,NULL /* reserved1,reserved2, etc */ + }, }; static const unsigned configuration_parameters__field_indices_by_name[] = { 13, /* field[13] = ACHeatersLowerOperationLimit */ @@ -283,18 +319,21 @@ static const unsigned configuration_parameters__field_indices_by_name[] = { 10, /* field[10] = DispenserBuildPressureLimit */ 9, /* field[9] = DispenserBuildPressureSpeed */ 11, /* field[11] = DispenserBuildPressureTimeout */ + 18, /* field[18] = DispenserPresegmentWFCF */ + 20, /* field[20] = GeneralParameters */ 6, /* field[6] = InitialDispenserPressure */ 8, /* field[8] = InitialDispenserTimeLag */ 7, /* field[7] = InitialDispenserTimeout */ 17, /* field[17] = MidTankPressureCorrection */ 5, /* field[5] = OpenValveTimeout */ 2, /* field[2] = OverHeatCountLimit */ + 19, /* field[19] = StartHeatingOnInitSequence */ 3, /* field[3] = UnderHeatCountLimit */ }; static const ProtobufCIntRange configuration_parameters__number_ranges[1 + 1] = { { 1, 0 }, - { 0, 18 } + { 0, 21 } }; const ProtobufCMessageDescriptor configuration_parameters__descriptor = { @@ -304,7 +343,7 @@ const ProtobufCMessageDescriptor configuration_parameters__descriptor = "ConfigurationParameters", "", sizeof(ConfigurationParameters), - 18, + 21, configuration_parameters__field_descriptors, configuration_parameters__field_indices_by_name, 1, configuration_parameters__number_ranges, diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.h index 307352efd..3911bbcb1 100644 --- a/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.h +++ b/Software/Embedded_SW/Embedded/Communication/PMR/EmbeddedParameters/ConfigurationParameters.pb-c.h @@ -62,10 +62,16 @@ struct _ConfigurationParameters uint32_t dcheatersupperoperationlimit; protobuf_c_boolean has_midtankpressurecorrection; double midtankpressurecorrection; + protobuf_c_boolean has_dispenserpresegmentwfcf; + double dispenserpresegmentwfcf; + protobuf_c_boolean has_startheatingoninitsequence; + protobuf_c_boolean startheatingoninitsequence; + size_t n_generalparameters; + double *generalparameters; }; #define CONFIGURATION_PARAMETERS__INIT \ { PROTOBUF_C_MESSAGE_INIT (&configuration_parameters__descriptor) \ - , 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } + , 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,NULL } /* ConfigurationParameters methods */ -- cgit v1.3.1 From 7080d6422a5c20b2acd0562fa2d8b3c91ba1590d Mon Sep 17 00:00:00 2001 From: Shlomo Hecht Date: Tue, 19 Mar 2019 11:27:51 +0200 Subject: Version 1.3.8.0 lock --- .../Embedded_SW/Embedded/Common/SW_Info/SW_Info.c | 2 +- .../PMR/Debugging/DebugLogCategory.pb-c.h | 2 +- .../Embedded_SW/Embedded/Drivers/Motors/Motor.h | 1 - Software/Embedded_SW/Embedded/Main.c | 3 +- .../Embedded/Modules/AlarmHandling/AlarmHandling.c | 58 +++++++++++++--------- .../Embedded/Modules/Heaters/Heaters_print.c | 5 +- Software/Embedded_SW/Embedded/Modules/IDS/IDS.h | 1 + .../Embedded/Modules/IDS/IDS_dispenser.c | 10 +--- Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h | 4 -- .../Embedded_SW/Embedded/Modules/IDS/IDS_print.c | 27 +--------- .../Embedded/Modules/Thread/Thread_print.c | 4 +- .../EmbeddedParameters/AlarmSourceType.proto | 4 ++ .../ConfigurationParameters.proto | 4 ++ 13 files changed, 54 insertions(+), 71 deletions(-) (limited to 'Software/Embedded_SW/Embedded/Communication') diff --git a/Software/Embedded_SW/Embedded/Common/SW_Info/SW_Info.c b/Software/Embedded_SW/Embedded/Common/SW_Info/SW_Info.c index 5efeaa71d..336cfd9aa 100644 --- a/Software/Embedded_SW/Embedded/Common/SW_Info/SW_Info.c +++ b/Software/Embedded_SW/Embedded/Common/SW_Info/SW_Info.c @@ -20,7 +20,7 @@ typedef struct } TangoVersion_t; -TangoVersion_t _gTangoVersion = {1,3,7,9}; +TangoVersion_t _gTangoVersion = {1,3,8,0}; #define BUILD_DATE __DATE__ char Dat[50] = BUILD_DATE; char _gTangoName [MAX_STRING_LEN] = "Tango01 ";//d diff --git a/Software/Embedded_SW/Embedded/Communication/PMR/Debugging/DebugLogCategory.pb-c.h b/Software/Embedded_SW/Embedded/Communication/PMR/Debugging/DebugLogCategory.pb-c.h index 1fda3ab01..d97b42d33 100644 --- a/Software/Embedded_SW/Embedded/Communication/PMR/Debugging/DebugLogCategory.pb-c.h +++ b/Software/Embedded_SW/Embedded/Communication/PMR/Debugging/DebugLogCategory.pb-c.h @@ -24,7 +24,7 @@ typedef enum _DebugLogCategory { DEBUG_LOG_CATEGORY__Warning = 1, DEBUG_LOG_CATEGORY__Error = 2, DEBUG_LOG_CATEGORY__Critical = 3, - DEBUG_LOG_CATEGORY__Safety = 4 + DEBUG_LOG_CATEGORY__Debug = 4 PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(DEBUG_LOG_CATEGORY) } DebugLogCategory; diff --git a/Software/Embedded_SW/Embedded/Drivers/Motors/Motor.h b/Software/Embedded_SW/Embedded/Drivers/Motors/Motor.h index ecc70765b..7599c10db 100644 --- a/Software/Embedded_SW/Embedded/Drivers/Motors/Motor.h +++ b/Software/Embedded_SW/Embedded/Drivers/Motors/Motor.h @@ -201,7 +201,6 @@ uint32_t MotorMovetoBreakSensor (TimerMotors_t _motorId,bool direction, uint32_t uint32_t MotorMovetoDancerPosition (TimerMotors_t _motorId,bool direction, uint32_t Freq,uint32_t DancerId,bool dancervaluedirection, callback_fptr callback,uint32_t timeout); uint32_t MotorAbortMovetoLimitSwitch (TimerMotors_t _motorId); uint32_t MotorMoveToStopper (TimerMotors_t _motorId,bool direction, uint32_t Speed, callback_fptr callback,uint32_t backlash,uint32_t timeout); -uint32_t MotorMovetoEncoderPosition (TimerMotors_t MotorId, callback_fptr callback,uint32_t timeout); uint32_t MotorGoTo(TimerMotors_t _motorIdn, uint32_t Steps); #endif /* DRIVERS_MOTOR_H_ */ diff --git a/Software/Embedded_SW/Embedded/Main.c b/Software/Embedded_SW/Embedded/Main.c index fc3d09402..64f4380a8 100644 --- a/Software/Embedded_SW/Embedded/Main.c +++ b/Software/Embedded_SW/Embedded/Main.c @@ -58,14 +58,13 @@ #include "Drivers/I2C_Communication/I2C.h" -#include "Drivers/I2C_Communication/Dispenser_Card/EEPROM/Dispenser_EEPROM.h" +//#include "Drivers/I2C_Communication/Dispensers_EEPROM_MUX/Disp_EEPROM_MUX.h" #include "drivers/FPGA/FPGA_GPIO/FPGA_GPIO.h" #include "drivers/Flash_Memory/FATFS/ff.h" #include "drivers/Flash_Memory/FATFS/Control_File_System.h" - //#define WATCHDOG //***************************************************************************** // diff --git a/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c b/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c index 94c7614d1..fa46a84e4 100644 --- a/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c +++ b/Software/Embedded_SW/Embedded/Modules/AlarmHandling/AlarmHandling.c @@ -270,15 +270,24 @@ const AlarmHandlingItemStruc HardCodedAlarmItem[MAX_SYSTEM_ALARMS]={ { eOneSecond, MotorAlarm, HARDWARE_MOTOR_TYPE__MOTO_DH_CLEANMECH , HARDWARE_MOTOR_TYPE__MOTO_DH_CLEANMECH , x_STATUS_UVLO , FALSE , DEBUG_LOG_CATEGORY__Error , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_CLEANING_MECHANISM_MOTOR_UNDERVOLTAGE ," MotorDyeingHeadCleaningUnderVoltage " }, /* 5038 */ { eOneSecond, MotorAlarm, HARDWARE_MOTOR_TYPE__MOTO_DH_CLEANHEAD , HARDWARE_MOTOR_TYPE__MOTO_DH_CLEANHEAD , x_STATUS_UVLO , FALSE , DEBUG_LOG_CATEGORY__Error , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_CLEANING_HEAD_MOTOR_UNDERVOLTAGE ," MotorDyeingHeadCleaningHeadUnderVoltage " }, /* 5042 */ -// { eOneSecond, CurrentAlarm, HEAD_ZONE_1 , HEAD_ZONE_1 , 312 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_1_CURRENT_OUT_OF_RANGE ," Head Zone 1 Heater Current Out Of Range " }, /* 5018 */ -// { eOneSecond, CurrentAlarm, HEAD_ZONE_2 , HEAD_ZONE_2 , 187 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_2_CURRENT_OUT_OF_RANGE ," Head Zone 2 Heater Current Out Of Range " }, /* 5019 */ -// { eOneSecond, CurrentAlarm, HEAD_ZONE_3 , HEAD_ZONE_3 , 187 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_3_CURRENT_OUT_OF_RANGE ," Head Zone 3 Heater Current Out Of Range " }, /* 5020 */ -// { eOneSecond, CurrentAlarm, HEAD_ZONE_4 , HEAD_ZONE_4 , 312 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_4_CURRENT_OUT_OF_RANGE ," Head Zone 4 Heater Current Out Of Range " }, /* 5021 */ -// { eOneSecond, CurrentAlarm, HEAD_ZONE_5_6 , HEAD_ZONE_5_6 , 312 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_5_6_CURRENT_OUT_OF_RANGE ," Head Zone 5-6 Heater Current Out Of Range " }, /* 5022 */ -// { eOneSecond, CurrentAlarm, MIXCHIP , MIXCHIP , 187 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__MIXER_CURRENT_OUT_OF_RANGE ," Mixer Heater Current Out Of Range " }, /* 6004 */ -// { eOneSecond, CurrentAlarm, DRYER_CURRENT_1, DRYER_CURRENT_1, 1 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DRYER_HEATERS_ZONE_1_CURRENT_OUT_OF_RANGE ," Drier Heater 1 Current Out Of Range " }, /* 6004 */ -// { eOneSecond, CurrentAlarm, DRYER_CURRENT_2, DRYER_CURRENT_2, 1 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DRYER_HEATERS_ZONE_2_CURRENT_OUT_OF_RANGE ," Drier Heater 2 Current Out Of Range " }, /* 6004 */ -// {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DYEING_HEAD_THERMAL_CUTOFF,"Dyeing head Thermal Cut-Off"}, +// { eOneSecond, CurrentAlarm, HEAD_ZONE_1 , HEAD_ZONE_1 , 125 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_1_CURRENT_OUT_OF_RANGE ," Head Zone 1 Heater Current Out Of Range " }, /* 5018 */ +// { eOneSecond, CurrentAlarm, HEAD_ZONE_2 , HEAD_ZONE_2 , 187 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_2_CURRENT_OUT_OF_RANGE ," Head Zone 2 Heater Current Out Of Range " }, /* 5019 */ +// { eOneSecond, CurrentAlarm, HEAD_ZONE_3 , HEAD_ZONE_3 , 187 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_3_CURRENT_OUT_OF_RANGE ," Head Zone 3 Heater Current Out Of Range " }, /* 5020 */ +// { eOneSecond, CurrentAlarm, HEAD_ZONE_4 , HEAD_ZONE_4 , 312 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_4_CURRENT_OUT_OF_RANGE ," Head Zone 4 Heater Current Out Of Range " }, /* 5021 */ +// { eOneSecond, CurrentAlarm, HEAD_ZONE_5_6 , HEAD_ZONE_5_6 , 500 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_5_6_CURRENT_OUT_OF_RANGE ," Head Zone 5-6 Heater Current Out Of Range " }, /* 5022 */ +// { eOneSecond, CurrentAlarm, MIXCHIP , MIXCHIP , 187 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__MIXER_CURRENT_OUT_OF_RANGE ," Mixer Heater Current Out Of Range " }, /* 6004 */ +// { eOneSecond, CurrentAlarm, DRYER_CURRENT_1, DRYER_CURRENT_1, 800 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DRYER_HEATERS_ZONE_1_CURRENT_OUT_OF_RANGE ," Drier Heater 1 Current Out Of Range " }, /* 6004 */ +// { eOneSecond, CurrentAlarm, DRYER_CURRENT_2, DRYER_CURRENT_2, 400 , TRUE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DRYER_HEATERS_ZONE_2_CURRENT_OUT_OF_RANGE ," Drier Heater 2 Current Out Of Range " }, /* 6004 */ + + // { eOneSecond, CurrentAlarm, HEAD_ZONE_1 , HEAD_ZONE_1 , 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_1_CURRENT_LOOP_BREAK ," Head Zone 1 Heater Current Loop Break " }, /* 5018 */ + // { eOneSecond, CurrentAlarm, HEAD_ZONE_2 , HEAD_ZONE_2 , 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_2_CURRENT_LOOP_BREAK ," Head Zone 2 Heater Current Loop Break " }, /* 5019 */ + // { eOneSecond, CurrentAlarm, HEAD_ZONE_3 , HEAD_ZONE_3 , 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_3_CURRENT_LOOP_BREAK ," Head Zone 3 Heater Current Loop Break " }, /* 5020 */ + // { eOneSecond, CurrentAlarm, HEAD_ZONE_4 , HEAD_ZONE_4 , 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_4_CURRENT_LOOP_BREAK ," Head Zone 4 Heater Current Loop Break " }, /* 5021 */ + // { eOneSecond, CurrentAlarm, HEAD_ZONE_5_6 , HEAD_ZONE_5_6 , 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DYEING_HEAD_ZONE_5_6_CURRENT_LOOP_BREAK ," Head Zone 5-6 Heater Current Loop Break " }, /* 5022 */ + // { eOneSecond, CurrentAlarm, MIXCHIP , MIXCHIP , 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__MIXER_CURRENT_LOOP_BREAK ," Mixer Heater Current Loop Break " }, /* 6004 */ + // { eOneSecond, CurrentAlarm, DRYER_CURRENT_1, DRYER_CURRENT_1, 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DRYER_HEATERS_ZONE_1_CURRENT_LOOP_BREAK ," Drier Heater 1 Current Loop Break " }, /* 6004 */ + // { eOneSecond, CurrentAlarm, DRYER_CURRENT_2, DRYER_CURRENT_2, 0 , FALSE , DEBUG_LOG_CATEGORY__Warning , 0xFF , 2 , EVENT_TYPE__DRYER_HEATERS_ZONE_2_CURRENT_LOOP_BREAK ," Drier Heater 2 Current Loop Break " }, /* 6004 */ +// {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DYEING_HEAD_THERMAL_CUTOFF,"Dyeing head Thermal Cut-Off"}, {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Warning,0xFF,0,EVENT_TYPE__THREAD_BREAK,"Thread Break"}, {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Warning,0xFF,0,EVENT_TYPE__THREAD_TENSION_CONTROL_FAILURE_FEEDER_DANCER,"Thread Feeder Tension Control Failure"}, @@ -286,18 +295,20 @@ const AlarmHandlingItemStruc HardCodedAlarmItem[MAX_SYSTEM_ALARMS]={ {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Warning,0xFF,0,EVENT_TYPE__THREAD_TENSION_CONTROL_FAILURE_WINDER_DANCER,"Thread Winder Tension Control Failure"}, {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Warning,0xFF,0,EVENT_TYPE__WINDER_CONE_DOES_NOT_EXIST,"No cone in winder"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_1_OVERPRESSURE,"Dispenser 1 OverPressure"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_2_OVERPRESSURE,"Dispenser 2 OverPressure"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_3_OVERPRESSURE,"Dispenser 3 OverPressure"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_4_OVERPRESSURE,"Dispenser 4 OverPressure"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_5_OVERPRESSURE,"Dispenser 5 OverPressure"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_6_OVERPRESSURE,"Dispenser 6 OverPressure"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_7_OVERPRESSURE,"Dispenser 7 OverPressure"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DISPENSER_8_OVERPRESSURE,"Dispenser 8 OverPressure"}, - - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__DRYER_DOOR_OPEN,"Dryer Door is open"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__NO_AIR_PRESSURE,"No suction in the waste handling system"}, - {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Safety,0xFF,0,EVENT_TYPE__AIR_FILTER_NOT_INSTALLED,"Air filter missing"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_1_OVERPRESSURE,"Dispenser 1 OverPressure"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_2_OVERPRESSURE,"Dispenser 2 OverPressure"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_3_OVERPRESSURE,"Dispenser 3 OverPressure"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_4_OVERPRESSURE,"Dispenser 4 OverPressure"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_5_OVERPRESSURE,"Dispenser 5 OverPressure"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_6_OVERPRESSURE,"Dispenser 6 OverPressure"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_7_OVERPRESSURE,"Dispenser 7 OverPressure"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DISPENSER_8_OVERPRESSURE,"Dispenser 8 OverPressure"}, + + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__DRYER_DOOR_OPEN,"Dryer Door is open"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__NO_AIR_PRESSURE,"No suction in the waste handling system"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Critical,0xFF,0,EVENT_TYPE__AIR_FILTER_NOT_INSTALLED,"Air filter missing"}, + {eOneSecond,DoNotPollAlarm,0,0,0,0,DEBUG_LOG_CATEGORY__Error,0xFF,0,EVENT_TYPE__WASTE_CONTAINER_EMPTYING_TIMEOUT,"Waste Container Emptying Timeout"}, + }; char AlarmStorePath[25] = "0://SysInfo//AlarmPrm.cfg"; @@ -393,7 +404,6 @@ uint32_t AlarmHandlingConsequentActions(uint32_t AlarmId, DebugLogCategory Sever //raise flag fr next job break; case DEBUG_LOG_CATEGORY__Critical: - case DEBUG_LOG_CATEGORY__Safety: // watchdogCriticalAlarm = true; LOG_ERROR(AlarmId,"Critical Alarm - Watchdog activated to reset hardware"); @@ -742,14 +752,14 @@ uint32_t AlarmHandlingLoop(uint32_t tick) value = Get_Heaters_Current_Integer(AlarmItem[Alarm_i].DeviceId); if (AlarmItem[Alarm_i].AlarmDirection == true) { - if (value >= AlarmItem[Alarm_i].AlarmValue) + if ((value >= (AlarmItem[Alarm_i].AlarmValue*1.07))||(value <= (AlarmItem[Alarm_i].AlarmValue*0.80))) { Status = true; } } else { - if (value <= AlarmItem[Alarm_i].AlarmValue) + if (value == 0) { Status = true; } diff --git a/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c b/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c index a6fbe3ebc..8b9db2126 100644 --- a/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c +++ b/Software/Embedded_SW/Embedded/Modules/Heaters/Heaters_print.c @@ -385,7 +385,7 @@ uint32_t HeaterCommandRequestMessage(int HeaterId, bool OnOff, int Temperature) PrepareHeater(HeaterId,Temperature); //prepare the heaters control info //set the power balance handler (if not set yet) // if the heater is off (?) start it. - ActivateHeater(HeaterId); + //ActivateHeater(HeaterId); //set the heater operation mode to fast heating - depended on the current temperature // timers are prepared but not started yet!!! only when the system is hot. @@ -518,7 +518,7 @@ uint32_t PrepareHeater(int HeaterId, uint32_t SetTemperatue) return ERROR; } - //Report("PrepareHeater ", __FILE__,__LINE__,HeaterId, SetTemperatue, 0, 0); + Report("PrepareHeater ", __FILE__,__LINE__,HeaterId, SetTemperatue, 0, 0); //start thread control for all motors HeaterPIDConfig[HeaterId].m_params.MAX = HeaterControl[HeaterId].outputproportionalpowerlimit*100; @@ -699,6 +699,7 @@ uint32_t DcHeaterMaxTempCBFunction(uint32_t IfIndex, uint32_t eadValue) } } DeActivateHeater(index); + HeaterRecalculateHeaterParams(index, 0); HeaterMaxTempFlag[index] = true; //LOG_ERROR ((MinreadValue/100), "Heater Over the max temperature, turned off"); Report("Heater Over the max temperature, turned off",__FILE__,__LINE__,index,RpWarning,HeaterPreviousRead[index], HeaterControl[index].sensormaxvalue); diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS.h b/Software/Embedded_SW/Embedded/Modules/IDS/IDS.h index e7e6f3ff6..d27fb7c56 100644 --- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS.h +++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS.h @@ -31,6 +31,7 @@ void IDS_Dispenser_Set_Flow_Params (char DispenserId,double NanoLitterPerPulse,c void IDS_Dispenser_RefillStarted (char DispenserId); void IDS_Dispenser_RefillEnded (char DispenserId); void IDS_Dispenser_MovingDirection (char DispenserId, bool direction); +uint32_t IDS_Dispenser_Build_Pressure(int DispenserId, callback_fptr callback); #endif //MODULES_IDS_IDS_H_ diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_dispenser.c b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_dispenser.c index abfabe17d..acaf19744 100644 --- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_dispenser.c +++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_dispenser.c @@ -62,15 +62,10 @@ uint32_t IdsGetMotorSpeed(uint32_t DispenserId) uint32_t IDS_Dispenser_Build_Pressure_Callback(uint32_t DispenserId, uint32_t ReadValue) { - uint32_t status; DispenserPrepareTime[DispenserId]+=DispenserPrepareTimeLag; if ((GetDispenserPressure(DispenserId)>=DispenserPreparePressure)||(DispenserPrepareTime[DispenserId]>=DispenserPrepareTimeout)) { - if (DispenserPrepareTime[DispenserId]>=DispenserPrepareTimeout) - status = ERROR; - else - status = OK; if (SafeRemoveControlCallback(DispenserControlId[DispenserId], IDS_Dispenser_Build_Pressure_Callback )==OK) DispenserControlId[DispenserId] = 0xFF; else @@ -81,12 +76,11 @@ uint32_t IDS_Dispenser_Build_Pressure_Callback(uint32_t DispenserId, uint32_t Re if (DispenserCallback[DispenserId]) { - - DispenserCallback[DispenserId](DispenserId,status); + DispenserCallback[DispenserId](DispenserId,ReadValue); DispenserCallback[DispenserId] = 0; } } - return status; + return OK; } uint32_t IDS_Dispenser_Build_Pressure(int DispenserId, callback_fptr callback) diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h index b201e6611..bf73ed7fa 100644 --- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h +++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h @@ -39,9 +39,6 @@ uint32_t IDSSegmentState(void *JobDetails, int SegmentId); uint32_t IDSDistanceToSpoolState(void); uint32_t IDSEndState(void *JobDetails); -uint32_t IDS_StartLubrication(void); -uint32_t IDS_StopLubrication(void); - uint32_t IDS_DispenserPidRequestMessage(HardwarePidControl* request); uint32_t IDS_DispenserControlInit(); @@ -52,7 +49,6 @@ uint32_t IDS_Dispenser_Alarm_On (uint8_t deviceID); uint32_t IDS_Dispenser_Alarm_Off (uint8_t deviceID); uint32_t IDS_CheckDispenserLimitSwitch (LimitSwitchAlarms LS_Id); -uint32_t IDS_Dispenser_Build_Pressure(int DispenserId, callback_fptr callback); void IDS_Dispenser_SetTimeOutValues(uint32_t CloseTimeout, uint32_t OpenTimeout); void IDS_Dispenser_SetBackLashValues(double initialdispenserpressure, uint32_t initialdispensertimeout, uint32_t initialdispensertimelag); diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c index 0a9d40a15..2be233962 100644 --- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c +++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_print.c @@ -31,12 +31,11 @@ typedef struct PID_Config_Params m_params; }DispenserControlConfig_t; HardwarePidControl *DispensersControl;// = (HardwarePidControl *)GENHWCFG_MAP_IN_FLASH + 0x4000; -#define LUBRICANT_DISPENSER 7 -#define MAX_DYE_DISPENSERS 7 + int32_t DispenserSamples[MAX_SYSTEM_DISPENSERS][MAX_CONTROL_SAMPLES] = {0}; int DispenserSamplePointer[MAX_SYSTEM_DISPENSERS] = {0}; double DispenserNormalizedErrorCoEfficient[MAX_SYSTEM_DISPENSERS] = {0}; -double lubricant_speed = 0.0; + HardwarePidControlType ThreadDispenserIdToControlId[MAX_SYSTEM_DISPENSERS] = { HARDWARE_PID_CONTROL_TYPE__Dispenser1,HARDWARE_PID_CONTROL_TYPE__Dispenser2,HARDWARE_PID_CONTROL_TYPE__Dispenser3,HARDWARE_PID_CONTROL_TYPE__Dispenser4,HARDWARE_PID_CONTROL_TYPE__Dispenser5,HARDWARE_PID_CONTROL_TYPE__Dispenser6,HARDWARE_PID_CONTROL_TYPE__Dispenser7,HARDWARE_PID_CONTROL_TYPE__Dispenser8}; bool DispenserReady[MAX_SYSTEM_DISPENSERS] = {true}; @@ -161,13 +160,6 @@ void DispenserPrepareReady(void) if (JobTicket->segments[Segment_i]->brushstops[Brush_i]->dispensers[Dispenser_i]->nanolitterpersecond>0.0) { DispenserUsedInJob[DispenserId] = true; - if(DispenserId == LUBRICANT_DISPENSER) - { - lubricant_speed = JobTicket->segments[0]->brushstops[0]->dispensers[Dispenser_i]->nanolitterpersecond/ - JobTicket->segments[0]->brushstops[0]->dispensers[Dispenser_i]->nanoliterperpulse; - REPORT_MSG (lubricant_speed*100, "LUBRICANT_SPEED*100"); - } - } }//for dispenser }//if dispensers @@ -530,18 +522,3 @@ uint32_t IDSPreSegmentState(void *JobDetails, int SegmentId) return OK; } -uint32_t IDS_StartLubrication(void) -{ - IDS_Dispenser_Start_Motor_and_Open_Valve(LUBRICANT_DISPENSER,lubricant_speed,NULL); - Lubricant_2Way_Valve (START); - return OK; -} -uint32_t IDS_StopLubrication(void) -{ - if(DispenserUsedInJob[LUBRICANT_DISPENSER]) - { - IDS_Dispenser_Close_Valve_And_Stop_Motor(LUBRICANT_DISPENSER,IDS_Valve_EndValveReady); - Lubricant_2Way_Valve (STOP); - } - return OK; -} diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c index f4dc6a170..6a8474438 100644 --- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c +++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c @@ -30,7 +30,6 @@ #include "drivers/FPGA/FPGA_GPIO/FPGA_GPIO.h" #include "modules/heaters/heaters.h" #include "modules/General/process.h" -#include "modules/ids/ids_ex.h" #include "Modules/AlarmHandling/AlarmHandling.h" #include "Control/MillisecTask.h" @@ -709,7 +708,6 @@ uint32_t ThreadPreSegmentState(void *JobDetails, uint32_t SegmentId) MotorSetDirection((TimerMotors_t)HARDWARE_MOTOR_TYPE__MOTO_LLOADING,MotorsCfg[HARDWARE_MOTOR_TYPE__MOTO_LLOADING].directionthreadwize); MotorSetSpeed(HARDWARE_MOTOR_TYPE__MOTO_LLOADING, 1); } - IDS_StartLubrication(); } // activate control fr all motors //set speed for both rocker motors @@ -809,7 +807,7 @@ char Endstr[150]; } MotorStop(HARDWARE_MOTOR_TYPE__MOTO_RLOADING,Hard_Hiz); MotorStop(HARDWARE_MOTOR_TYPE__MOTO_LLOADING,Hard_Hiz); - IDS_StopLubrication(); + return OK; } diff --git a/Software/PMR/Messages/EmbeddedParameters/AlarmSourceType.proto b/Software/PMR/Messages/EmbeddedParameters/AlarmSourceType.proto index 85f6f3dd6..46b6cf692 100644 --- a/Software/PMR/Messages/EmbeddedParameters/AlarmSourceType.proto +++ b/Software/PMR/Messages/EmbeddedParameters/AlarmSourceType.proto @@ -13,4 +13,8 @@ enum AlarmSourceType MotorAlarm = 4; CoversAlarm = 5; DoNotPollAlarm = 6; + HardLimitAlarm = 7; + TachoAlarm = 8; + FluidLevelAlarm = 9; + } diff --git a/Software/PMR/Messages/EmbeddedParameters/ConfigurationParameters.proto b/Software/PMR/Messages/EmbeddedParameters/ConfigurationParameters.proto index 9b7a5c8d7..733651a34 100644 --- a/Software/PMR/Messages/EmbeddedParameters/ConfigurationParameters.proto +++ b/Software/PMR/Messages/EmbeddedParameters/ConfigurationParameters.proto @@ -46,6 +46,10 @@ message ConfigurationParameters bool StartHeatingOnInitSequence = 20; // general storage for parameters that do not have a specific name updated repeated double GeneralParameters = 21; + //0: CheckHardLimitAlarms + //1: CheckCurrentAlarms + //2: checkTamperAlarms + // a limit percentage for current deviation below predefined level double CurrentAlarmLowLimit = 22; // a limit percentage for current deviation predefined level -- cgit v1.3.1 From 98daf1c80688585d2a34586c30a7ac0bf67dd91b Mon Sep 17 00:00:00 2001 From: Shlomo Hecht Date: Tue, 19 Mar 2019 11:52:26 +0200 Subject: PreVersion 1.3.8.1 lubrication, IDS presegment improvement start. alarm handling improved, pressure buildup on init, improve centering of drier arm. NON Operative, NOT TESTED! --- Software/Embedded_SW/Embedded/.cproject | 3 +- .../Embedded_SW/Embedded/Common/SW_Info/SW_Info.c | 2 +- .../PMR/Debugging/DebugLogCategory.pb-c.c | 4 +- .../PMR/EmbeddedParameters/AlarmSourceType.pb-c.c | 16 +- .../PMR/EmbeddedParameters/AlarmSourceType.pb-c.h | 5 +- .../ConfigurationParameters.pb-c.c | 110 ++++- .../ConfigurationParameters.pb-c.h | 18 +- .../Communication/PMR/Printing/JobTicket.pb-c.c | 19 +- .../Communication/PMR/Printing/JobTicket.pb-c.h | 4 +- .../Embedded/Drivers/FPGA/FPGA_SPI_Comm.c | 2 + .../Drivers/FPGA/Full_Vme/ispvme/ispvm_ui.c | 11 +- .../Drivers/FPGA/Full_Vme/ispvme/ivm_core.c | 2 +- .../Drivers/FPGA/Full_Vme/ispvme/vmopcode.h | 2 - .../Drivers/I2C_Communication/ADC_MUX/ADC_MUX.c | 5 + .../Drivers/I2C_Communication/ADC_MUX/ADC_MUX.h | 1 + .../Embedded_SW/Embedded/Drivers/Motors/Motor.h | 1 + .../Embedded/Drivers/Motors/MotorActions.c | 148 +++++- Software/Embedded_SW/Embedded/Embedded.cfg | 3 + Software/Embedded_SW/Embedded/Main.c | 1 - .../Embedded/Modules/AlarmHandling/AlarmHandling.c | 534 ++++++++++++--------- .../Embedded/Modules/AlarmHandling/AlarmHandling.h | 1 + .../Embedded/Modules/General/GeneralHardware.c | 6 +- .../Embedded/Modules/IDS/IDS_dispenser.c | 10 +- Software/Embedded_SW/Embedded/Modules/IDS/IDS_ex.h | 4 + .../Embedded_SW/Embedded/Modules/IDS/IDS_maint.c | 4 +- .../Embedded_SW/Embedded/Modules/IDS/IDS_print.c | 74 ++- .../Embedded/Modules/Thread/ThreadLoad.c | 1 + .../Embedded/Modules/Thread/Thread_Winder.c | 12 +- .../Embedded/Modules/Thread/Thread_print.c | 7 +- .../Embedded/Software Release Notes.txt | 2 +- .../StateMachines/Initialization/InitSequence.c | 25 +- 31 files changed, 742 insertions(+), 295 deletions(-) (limited to 'Software/Embedded_SW/Embedded/Communication') diff --git a/Software/Embedded_SW/Embedded/.cproject b/Software/Embedded_SW/Embedded/.cproject index ae0630bbb..2dfc05eca 100644 --- a/Software/Embedded_SW/Embedded/.cproject +++ b/Software/Embedded_SW/Embedded/.cproject @@ -329,7 +329,6 @@