Index: Common.h =================================================================== diff -u -r6f87c4d6e2c23308af2524cea6aed41e679ca000 -r5a6ad1d7cd7a517fbf0a8eb1293cb6d4d0dff13b --- Common.h (.../Common.h) (revision 6f87c4d6e2c23308af2524cea6aed41e679ca000) +++ Common.h (.../Common.h) (revision 5a6ad1d7cd7a517fbf0a8eb1293cb6d4d0dff13b) @@ -253,6 +253,58 @@ sendEvent( e, dat1, dat2 ); \ } +// **** Common Broadcast Data **** + +#pragma pack(push,1) +/// Heaters data structure. +typedef struct +{ + F32 mainPrimayHeaterDC; ///< Main primary heater DC + F32 smallPrimaryHeaterDC; ///< Small primary heater DC + F32 trimmerHeaterDC; ///< Trimmer heater DC + F32 primaryTargetTemp; ///< Primary heater target temperature + F32 trimmerTargetTemp; ///< Trimmer heater target temperature + U32 primaryHeaterState; ///< Primary heater state + U32 trimmerHeaterState; ///< Trimmer heater state + F32 primaryEfficiency; ///< Primary heater efficiency + F32 primaryCalcTargetTemp; ///< Primary heater calculated target temperature + F32 trimmerCalcCurrentTemp; ///< Trimmer heater calculated current temperature +} HEATERS_DATA_T; + +/// Temperature sensors data. +typedef struct +{ + F32 inletPrimaryHeater; ///< Inlet primary heater temperature sensor + F32 heatDisinfect; ///< Heat Disinfect temperature sensor + F32 outletPrimaryHeater; ///< Outlet primary heater temperature sensor + F32 conductivitySensor1; ///< Conductivity sensor 1 temperature sensor + F32 conductivitySensor2; ///< Conductivity sensor 2 temperature sensor + F32 outletRedundant; ///< Outlet redundant temperature sensor + F32 inletDialysate; ///< Inlet dialysate temperature sensor + F32 primaryHeaterThermocouple; ///< Primary heaters thermocouple sensor + F32 trimmerHeaterThermocouple; ///< Trimmer heater thermocouple sensor + F32 priamyHeaterColdjunction; ///< Primary heaters cold junction temperature sensor + F32 trimmerHeaterColdjunction; ///< Trimmer heater cold junction temperature sensor + F32 primaryHeaterInternal; ///< Primary heaters internal temperature (calculated from thermocouple and cold junction) + F32 trimmerHeaterInternal; ///< Trimmer heater internal temperature (calculated from thermocouple and cold junction) + F32 fpgaBoard; ///< FPGA board temperature sensor + F32 loadCellA1B1; ///< Load cell A1/B1 temperature sensor + F32 loadCellA2B2; ///< Load cell A2/B2 temperature sensor + F32 internalTHDORTD; ///< THDo RTD channel temperature sensor + F32 internalTDIRTD; ///< TDI RTD channel temperature sensor + F32 internalCondSnsrTemp; ///< Conductivity Sensor internal temperature sensor +} TEMPERATURE_SENSORS_DATA_T; + +/// Loadcell measurements struct. +typedef struct +{ + F32 loadCellA1inGram; ///< Loadcell A1 measurement in gram + F32 loadCellA2inGram; ///< Loadcell A2 measurement in gram + F32 loadCellB1inGram; ///< Loadcell B1 measurement in gram + F32 loadCellB2inGram; ///< Loadcell B2 measurement in gram +} LOAD_CELL_DATA_T; +#pragma pack(pop) + // **** VectorCAST Definitions **** #ifdef _VECTORCAST_ Index: Integrity.c =================================================================== diff -u -r9f5f85b3bddb2b94f5ec4111cdc33077892cae77 -r5a6ad1d7cd7a517fbf0a8eb1293cb6d4d0dff13b --- Integrity.c (.../Integrity.c) (revision 9f5f85b3bddb2b94f5ec4111cdc33077892cae77) +++ Integrity.c (.../Integrity.c) (revision 5a6ad1d7cd7a517fbf0a8eb1293cb6d4d0dff13b) @@ -41,6 +41,9 @@ #define RADDR_PAR_FAIL 0x00000100 ///< Bit 8 - Read Address Parity Failure in TCRAM Module Error Status Register #define WADDR_PAR_FAIL 0x00000200 ///< Bit 9 - Write Address Parity Failure in TCRAM Module Error Status Register +/// Time threshold to check RAM error is 2 seconds +static const U32 RAM_ERROR_CHECK_TIME_THRESHOLD = ((2 * MS_PER_SECOND) / TASK_GENERAL_INTERVAL); + // ********** private data ********** static U32 currentRecord; ///< Current CRC table record to check. @@ -49,10 +52,7 @@ static SELF_TEST_STATUS_T integrityTestStatus; ///< Current firmware integrity test status. static U32 processorRAMStatusCounter = 0; ///< Counter used to check processor RAM error. static BOOL singleBitRAMErrorFlag = FALSE; ///< Flag to signal the processor RAM error. -/// Time threshold to check RAM error is 2 seconds -static const U32 RAM_ERROR_CHECK_TIME_THRESHOLD = ((2 * MS_PER_SECOND) / TASK_GENERAL_INTERVAL); - /*********************************************************************//** * @brief * The initIntegrity function initializes the Integrity module. Index: PersistentAlarm.c =================================================================== diff -u -r75e6d3ffab11ae6ff0521efb9c16d5698402a669 -r5a6ad1d7cd7a517fbf0a8eb1293cb6d4d0dff13b --- PersistentAlarm.c (.../PersistentAlarm.c) (revision 75e6d3ffab11ae6ff0521efb9c16d5698402a669) +++ PersistentAlarm.c (.../PersistentAlarm.c) (revision 5a6ad1d7cd7a517fbf0a8eb1293cb6d4d0dff13b) @@ -293,8 +293,12 @@ } else { - // TODO software fault - } +#ifdef _DG_ + SET_ALARM_WITH_2_U32_DATA( ALARM_ID_DG_SOFTWARE_FAULT, SW_FAULT_ID_INVALID_FPGA_SENSOR_GROUP_SELECTED, (U32)group ); +#endif +#ifdef _HD_ + SET_ALARM_WITH_2_U32_DATA( ALARM_ID_HD_SOFTWARE_FAULT, SW_FAULT_ID_INVALID_FPGA_SENSOR_GROUP_SELECTED, (U32)group ); +#endif } } /**@}*/