Index: firmware/App/Services/FPGA.c =================================================================== diff -u -r6158f53357d5d4023df091b6ed1e8f6aa9f30947 -rc12bff518c0b58065eede15469ad8a2a6f6e317b --- firmware/App/Services/FPGA.c (.../FPGA.c) (revision 6158f53357d5d4023df091b6ed1e8f6aa9f30947) +++ firmware/App/Services/FPGA.c (.../FPGA.c) (revision c12bff518c0b58065eede15469ad8a2a6f6e317b) @@ -1106,12 +1106,13 @@ { return ( fpgaSensorReadings.fpgaTPoTemp & MASK_OFF_U32_MSB ); } + /*********************************************************************//** * @brief * The getFPGATD1Temp function gets the latest conductivity sensor 1 \n * temperature reading in ADC. * @details - * Inputs : fpgaSensorReadings.fpgaTD1Temp + * Inputs : fpgaSensorReadings.fpgaCD1Temp * Outputs : none * @param none * @return last conductivity sensor 1 outlet temperature reading @@ -1120,36 +1121,98 @@ { return ( fpgaSensorReadings.fpgaCD1Temp & MASK_OFF_U32_MSB ); } + /*********************************************************************//** * @brief * The getFPGATD2Temp function gets the latest conductivity sensor 2 \n * temperature reading in ADC. * @details - * Inputs : fpgaSensorReadings.fpgaTD2Temp + * Inputs : fpgaSensorReadings.fpgaCD2Temp * Outputs : none * @param none * @return last conductivity sensor 2 outlet temperature reading *************************************************************************/ -U32 getFPGATC2Temp( void ) +U32 getFPGACD2Temp( void ) { return ( fpgaSensorReadings.fpgaCD2Temp & MASK_OFF_U32_MSB ); } + /*********************************************************************//** * @brief + * The getFPGARTDErrorCount function gets error count of the RTD. It covers \n + * all the four conductivity sensors which include temperature sensors + * @details + * Inputs : fpgaSensorReadings.fpgaRTDErrorCnt + * Outputs : none + * @param none + * @return Last error count of the RTD conductivity sensors + *************************************************************************/ +U08 getFPGARTDErrorCount( void ) +{ + return fpgaSensorReadings.fpgaRTDErrorCnt; +} + +/*********************************************************************//** + * @brief + * The getFPGARTDReadCount function gets the read count of the RTD \n + * conductivity sensors. It covers all the 4 conductivity sensors + * @details + * Inputs : fpgaSensorReadings.fpgaRTDReadCnt + * Outputs : none + * @param none + * @return Last read count of the RTC conductivity sensors + *************************************************************************/ +U08 getFPGARTDReadCount( void ) +{ + return fpgaSensorReadings.fpgaRTDReadCnt; +} + +/*********************************************************************//** + * @brief * The getFPGATRoTemp function gets the latest redundant sensor outlet \n * temperature reading in ADC. * @details - * Inputs : fpgaSensorReadings.fpgaTRoTemp + * Inputs : fpgaSensorReadings.fpgaTHDoTemp * Outputs : none * @param none - * @return last redundant sensor outlet temperature reading + * @return Last redundant sensor outlet temperature reading *************************************************************************/ U32 getFPGATHDoTemp( void ) { return ( fpgaSensorReadings.fpgaTHDoTemp & MASK_OFF_U32_MSB ); } + /*********************************************************************//** * @brief + * The getFPGATHDoErrorCount gets the error count of the THDo (redundant) \n + * temperature sensor + * @details + * Inputs : fpgaSensorReadings.fpgaTHDoErrorCnt + * Outputs : none + * @param none + * @return Last redundant sensor outlet temperature error count + *************************************************************************/ +U08 getFPGATHDoErrorCount( void ) +{ + return fpgaSensorReadings.fpgaTHDoErrorCnt; +} + +/*********************************************************************//** + * @brief + * The getFPGATHDoReadCount gets the read count of the THDo (redundant) \n + * @details + * Inputs : fpgaSensorReadings.fpgaTHDoReadCnt + * Outputs : none + * @param none + * @return Last redundant sensor outlet temperature error count reading + *************************************************************************/ +U08 getFPGATHDoReadCount( void ) +{ + return fpgaSensorReadings.fpgaTHDoReadCnt; +} + +/*********************************************************************//** + * @brief * The getFPGATDiTemp function gets the latest dialysate inlet \n * temperature reading in ADC. * @details @@ -1162,8 +1225,39 @@ { return ( fpgaSensorReadings.fpgaTDiTemp & MASK_OFF_U32_MSB ); } + /*********************************************************************//** * @brief + * The getFPGATDiErrorCount function gets the latest dialysate inlet \n + * temperature error count. + * @details + * Inputs : fpgaSensorReadings.fpgaTDiErrorCnt + * Outputs : none + * @param none + * @return Last dialysate inlet error count + *************************************************************************/ +U08 getFPGATDiErrorCount( void ) +{ + return fpgaSensorReadings.fpgaTDiErrorCnt; +} + +/*********************************************************************//** + * @brief + * The getFPGATDiReadCount function gets the latest dialysate inlet \n + * temperature read count. + * @details + * Inputs : fpgaSensorReadings.fpgaTDiReadCnt + * Outputs : none + * @param none + * @return Last dialysate inlet read count + *************************************************************************/ +U08 getFPGATDiReadCount( void ) +{ + return fpgaSensorReadings.fpgaTDiReadCnt; +} + +/*********************************************************************//** + * @brief * The getFPGAPrimaryHeaterTemp function gets the latest primary heater \n * internal temperature reading. * @details @@ -1179,8 +1273,38 @@ /*********************************************************************//** * @brief + * The getFPGAPrimaryHeaterFlags function gets the latest primary heater \n + * internal temperature sensor flags read + * @details + * Inputs : fpgaSensorReadings.fpgaPrimaryHeaterFlags + * Outputs : none + * @param none + * @return Last primary heater internal temperature sensor flag read + *************************************************************************/ +U08 getFPGAPrimaryHeaterFlags( void ) +{ + return fpgaSensorReadings.fpgaPrimaryHeaterFlags; +} + +/*********************************************************************//** + * @brief + * The geetFPGAPrimaryHeaterReadCount function gets the latest primary heater \n + * internal temperature sensor read count + * @details + * Inputs : fpgaSensorReadings.fpgaPrimaryHeaterReadCnt + * Outputs : none + * @param none + * @return Last primary heater internal temperature sensor read count + *************************************************************************/ +U08 geetFPGAPrimaryHeaterReadCount( void ) +{ + return fpgaSensorReadings.fpgaPrimaryHeaterReadCnt; +} + +/*********************************************************************//** + * @brief * The getFPGATrimmerHeaterTemp function gets the latest trimmer heater \n - * internal temperature reading. + * internal temperature sensor reading. * @details * Inputs : fpgaSensorReadings.fpgaTrimmerHeaterIntTemp * Outputs : none @@ -1191,3 +1315,36 @@ { return fpgaSensorReadings.fpgaTrimmerHeaterIntTemp; } + +/*********************************************************************//** + * @brief + * The getFPGATrimmerHeaterFlags function gets the latest trimmer heater \n + * internal temperature flags read. + * @details + * Inputs : fpgaSensorReadings.fpgaTrimmerHeaterFlags + * Outputs : none + * @param none + * @return Last trimmer heater internal temperature flags read + *************************************************************************/ +U08 getFPGATrimmerHeaterFlags( void ) +{ + return fpgaSensorReadings.fpgaTrimmerHeaterFlags; +} + +/*********************************************************************//** + * @brief + * The getFPGATrimmerHeaterReadCount function gets the latest trimmer heater \n + * internal temperature read count. + * @details + * Inputs : fpgaSensorReadings.fpgaTrimmerHeaterReadCnt + * Outputs : none + * @param none + * @return Last trimmer heater internal temperature read count + *************************************************************************/ +U08 getFPGATrimmerHeaterReadCount( void ) +{ + return fpgaSensorReadings.fpgaTrimmerHeaterReadCnt; +} + + +