Index: firmware/App/Services/NVRecordsDD.h =================================================================== diff -u -r6d135d17d73d70a909f346bff2a9b14fec7d2478 -r1e742ba641458eaf36c8d953275a3e1c32b943d4 --- firmware/App/Services/NVRecordsDD.h (.../NVRecordsDD.h) (revision 6d135d17d73d70a909f346bff2a9b14fec7d2478) +++ firmware/App/Services/NVRecordsDD.h (.../NVRecordsDD.h) (revision 1e742ba641458eaf36c8d953275a3e1c32b943d4) @@ -127,7 +127,7 @@ /// DD Institutional advanced items typedef enum DD_instit_advanced_items { - INSTIT_PARAM_RO_REJECTION_RATIO_ALRAM = 0, ///< RO Rejection Ratio Alarm Threshold + INSTIT_PARAM_RO_REJECTION_RATIO_ALRAM = 0, ///< RO Rejection Ratio Alarm Threshold FIRST_INSTIT_ADVANCED_PARAM = INSTIT_PARAM_RO_REJECTION_RATIO_ALRAM, ///< First Institutional advanced parameter INSTIT_PARAM_DISINFECTION_FREQUENCY, ///< Disinfection Frequency INSTIT_PARAM_DISINFECTION_CYCLE_TIME, ///< Disinfection Parameters, Cycle Time @@ -163,19 +163,19 @@ /// Pressure sensors calibration record typedef struct { - LINEAR_CAL_PAYLOAD_T pressureSensors[ NUM_OF_PRESSURE_SENSORS ]; ///< Pressure sensors to calibrate. + LINEAR_CAL_PAYLOAD_T pressureSensors[ NUM_OF_PRESSURE_SENSORS ]; ///< Pressure sensors to calibrate. } DD_PRES_SENSORS_CAL_RECORD_T; /// Temperature sensors calibration record typedef struct { - LINEAR_CAL_PAYLOAD_T tempSensors[ NUM_OF_TEMPERATURE_SENSORS ]; ///< Temperature sensors to calibrate. + LINEAR_CAL_PAYLOAD_T tempSensors[ NUM_OF_TEMPERATURE_SENSORS ]; ///< Temperature sensors to calibrate. } DD_TEMP_SENSORS_CAL_RECORD_T; /// DD concentrate pumps calibration record typedef struct { - LINEAR_CAL_PAYLOAD_T concentratePumps[ NUM_OF_CONCENTRATE_PUMPS ]; ///< DD concentrate pumps calibration data. + LINEAR_CAL_PAYLOAD_T concentratePumps[ NUM_OF_CONCENTRATE_PUMPS ]; ///< DD concentrate pumps calibration data. } DD_CONC_PUMPS_CAL_RECORD_T; /// DD D12 dialysate pump calibration record @@ -247,31 +247,68 @@ /// DD conductivity sensor calibration record. typedef struct { - CONDUCTIVITY_COEFFICIENTS_T condSensors[ NUM_OF_CONDUCTIVITY_SENSORS ]; ///< DD Conductivity Sensors + CONDUCTIVITY_COEFFICIENTS_T condSensors[ NUM_OF_CONDUCTIVITY_SENSORS ]; ///< DD Conductivity Sensors } DD_CONDUCTIVITY_SENSOR_CAL_RECORD_T; +/// DD calibration groups structure +typedef struct +{ + DD_PRES_SENSORS_CAL_RECORD_T presSensorsCalRecord; ///< DD pressure sensors calibration record + DD_TEMP_SENSORS_CAL_RECORD_T tempSensorsCalRecord; ///< DD temperature sensors calibration record + DD_CONC_PUMPS_CAL_RECORD_T concentratePumpsRecord; ///< DD concentrate pumps calibration record + DD_D12_DIALYSATE_PUMP_RECORD_T d12DialysatePumpRecord; ///< DD dialysate pump d12 calibration data. + DD_D48_DIALYSATE_PUMP_RECORD_T d48DialysatePumpRecord; ///< DD dialysate pumps calibration record + DD_ACID_CONCENTRATES_RECORD_T acidConcentratesRecord; ///< DD acid concentrates calibration record + DD_BICARB_CONCENTRATES_RECORD_T bicarbConcentratesRecord; ///< DD bicarb concentrates calibration record + DD_ACCEL_SENSOR_CAL_RECORD_T accelerometerSensorCalRecord; ///< DD accelerometer sensor. + DD_BLOOD_LEAK_SENSOR_CAL_RECORD_T bloodLeakSensorCalRecord; ///< DD blood leak detector calibration record +} DD_CALIBRATION_RECORD_T; + /// DD systems record structure typedef struct { BOOL isROFeatured; ///< True : RO featured. False : RO de-featured. BOOL isROFeaturedBoostPump; ///< True : RO featured with boost pump. False : RO featured without the boost pump. char topLevelPN[ MAX_TOP_LEVEL_PN_CHARS ]; ///< DD top level part number. char topLevelSN[ MAX_TOP_LEVEL_SN_CHARS ]; ///< DD top level serial number. - U08 mfgLocation; ///< DD manufacturing location. + U32 mfgLocation; ///< DD manufacturing location. U32 mfgDate; ///< DD manufacturing date. U16 crc; ///< CRC for the DD system record structure. } DD_SYSTEM_RECORD_T; +/// FP service record structure +typedef struct +{ + U32 waterRecovery; ///< Low : 0, Medium : 1, High : 2. + U32 primaryFilterReplacementDate; ///< Last replacement date of primary carbon filter + U32 secondaryFilterReplacementDate; ///< Last replacement date of secondary carbon filter + U32 ROMembraneReplacementDate; ///< Last replacement date of RO Membrane + U32 serviceLoc; ///< DD service location. + U32 lastServiceEpochDate; ///< DD last service date in epoch. + U32 serviceIntervalSeconds; ///< DD service interval in seconds. + U32 lastResetTimeEpoch; ///< Last time the record was reset in epoch. + U16 crc; ///< CRC for the DD service record structure. +} SERVICE_RECORD_FP_T; + /// DD service record structure typedef struct { BOOL isHDFOnlineFluidAvailable; ///< True : HDF Online Fluid feature is available, False if not. - U32 waterRecovery; ///< Low : 0, Medium : 1, High : 2. - U08 serviceLoc; ///< DD service location. + U32 UltraFilter1ReplacementDate; ///< Last replacement date of Ultrafilter 1 + U32 UltraFilter2ReplacementDate; ///< Last replacement date of Ultrafilter 2 + U32 UFPumpTubingReplacementDate; ///< Last replacement date of UP Pump Tubing + U32 serviceLoc; ///< DD service location. U32 lastServiceEpochDate; ///< DD last service date in epoch. U32 serviceIntervalSeconds; ///< DD service interval in seconds. U32 lastResetTimeEpoch; ///< Last time the record was reset in epoch. U16 crc; ///< CRC for the DD service record structure. +} SERVICE_RECORD_DD_T; + +/// DD service record structure +typedef struct +{ + SERVICE_RECORD_FP_T fpRecord; ///< FP service record + SERVICE_RECORD_DD_T ddRecord; ///< DD service record. } DD_SERVICE_RECORD_T; /// Institutional data structure. @@ -310,17 +347,51 @@ U16 crc; ///< CRC of the institutional record. } DD_INSTIT_ADDITIONAL_RECORD_T; +/// DD institutional record structure +typedef struct +{ + DD_INSTIT_BASIC_RECORD_T basicRecord; ///< DD basic institutional record + DD_INSTIT_ADVANCED_RECORD_T advancedRecord; ///< DD advanced institutional record + DD_INSTIT_ADDITIONAL_RECORD_T additionalRecord; ///< DD additional institutional record +} DD_INSTITUTIONAL_RECORD_T; + +/// FP usage info structure. +typedef struct +{ + U32 primaryFilterTreatmentNum; ///< Number of treatments performed on ultrafilter 1 since last replaced + U32 primaryFilterDisinfectionNum; ///< Number of disinfections performed on ultrafilter 1 since last replaced + U32 secondaryFilterTreatmentNum; ///< Number of treatments performed on ultrafilter 2 since last replaced + U32 secondaryFilterDisinfectionNum; ///< Number of disinfections performed on ultrafilter 2 since last replaced + U32 ROMembraneTreatmentNum; ///< Number of treatments performed on UF Pump Tubing since last replaced + U32 ROMembraneDisinfectionNum; ///< Number of disinfections performed on UF Pump Tubing since last replaced + U32 lastResetTimeEpoch; ///< Last time the record was reset in epoch. + U16 crc; ///< CRC for the DD usage info structure. +} USAGE_RECORD_FP_T; + /// DD usage info structure. typedef struct { F32 roWaterGenTotalL; ///< Total RO water generated in liters. (Cannot be reset) F32 roWaterGenSinceLastServiceL; ///< RO water generated since last treatment in liters. + U32 UltraFilter1TreatmentNum; ///< Number of treatments performed on ultrafilter 1 since last replaced + U32 UltraFilter1DisinfectionNum; ///< Number of disinfections performed on ultrafilter 1 since last replaced + U32 UltraFilter2TreatmentNum; ///< Number of treatments performed on ultrafilter 2 since last replaced + U32 UltraFilter2DisinfectionNum; ///< Number of disinfections performed on ultrafilter 2 since last replaced + U32 UFPumpTubingTreatmentNum; ///< Number of treatments performed on UF Pump Tubing since last replaced + U32 UFPumpTubingDisinfectionNum; ///< Number of disinfections performed on UF Pump Tubing since last replaced U32 lastBasicFlushCompleteDateEpoch; ///< Last basic flush complete date in epoch. U32 lastHeatDisCompleteDateEpoch; ///< Last heat disinfect complete date in epoch. U32 lastHeatActiveCoolCompleteDateEpoch; ///< Last heat disinfect active cool complete date in epoch. U32 lastFilterFlushCompleteDateEpoch; ///< Last filter flush complete date in epoch. U32 lastResetTimeEpoch; ///< Last time the record was reset in epoch. U16 crc; ///< CRC for the DD usage info structure. +} USAGE_RECORD_DD_T; + +/// DD usage info record structure +typedef struct +{ + USAGE_RECORD_FP_T fpRecord; ///< FP usage info record. + USAGE_RECORD_DD_T ddRecord; ///< DD usage info record. } DD_USAGE_INFO_RECORD_T; #pragma pack(pop)