Index: firmware/App/Services/FpgaDD.c =================================================================== diff -u -r02c2059fd465609e56c6240d2855c91be2129fd6 -r3643a2e648ab2b216fd08579e56bdc02fb94836d --- firmware/App/Services/FpgaDD.c (.../FpgaDD.c) (revision 02c2059fd465609e56c6240d2855c91be2129fd6) +++ firmware/App/Services/FpgaDD.c (.../FpgaDD.c) (revision 3643a2e648ab2b216fd08579e56bdc02fb94836d) @@ -1,7 +1,7 @@ /************************************************************************** * -* Copyright (c) 2024-2025 Diality Inc. - All Rights Reserved. +* Copyright (c) 2024-2026 Diality Inc. - All Rights Reserved. * * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. @@ -234,7 +234,7 @@ U16 flowRateP7; ///< Reg 704. P7 flow sensor rate. U16 flowTempP7; ///< Reg 706. P7 flow sensor temperature. U16 p12PumpTachCount; ///< Reg 708. P12 pump tachometer counter. - U16 dsPumpTachCount; ///< Reg 710. DSP tachometer counter. + U16 d79SpeedPulseWidth; ///< Reg 710. D79 pusle width feedback. U16 flowIntTempP7; ///< Reg 712. P7 flow sensor internal temperature. U08 valveIOControlReadback; ///< Reg 714. IO Valve control bits read back. U08 valveFPControlReadback; ///< Reg 715. FP Valve control enable read back. @@ -295,7 +295,7 @@ U08 fpgaD42FIFOTx; ///< Reg 48. Blood leak sensor FIFO transmit control U08 fpgaD5HeaterPWMControl; ///< Reg 49. Primary heater PWM control U08 fpgaD45HeaterPWMControl; ///< Reg 50. Trimmer heater PWM control - U08 fpgaNotUsed; ///< Reg 51. Not used + U08 fpgaD79PWMPumpCtl; ///< Reg 51. Rinse pump PWM control U16 fpgaVBCPWMLow; ///< Reg 52. VBC PWM low ( Balancing chamber valves) U16 fpgaVBCPWMPeriod; ///< Reg 54. VBC PWM period U16 fpgaVBCPWMPullIn; ///< Reg 56. VBC PWM pull in @@ -3105,6 +3105,45 @@ /*********************************************************************//** * @brief + * The setFPGAD79RinsePumpControl function sets the control bit of the rinse + * pump to turn it on or off. + * @details \b Inputs: none + * @details \b Outputs: fpgaActuatorSetPoints.fpgaDDSpareValveControl + * @return none + *************************************************************************/ +void setFPGAD79RinsePumpControl( U08 value ) +{ + fpgaActuatorSetPoints.fpgaDDSpareValveControl &= value; +} + +/*********************************************************************//** + * @brief + * The setFPGAD79RinsePumpPWMControl function sets the PWM value of the rinse + * pump to turn it on or off. + * @details \b Inputs: none + * @details \b Outputs: fpgaActuatorSetPoints.fpgaD79PWMPumpCtl + * @return none + *************************************************************************/ +void setFPGAD79RinsePumpPWMControl( U08 value ) +{ + fpgaActuatorSetPoints.fpgaD79PWMPumpCtl = value; +} + +/*********************************************************************//** + * @brief + * The getFPGAD79RinsePumpPulseWidth function returns the 4-wire rinse pump + * pulse width. + * @details \b Inputs: d79SpeedPulseWidth + * @details \b Outputs: none + * @return fpgaSensorReadings.d79SpeedPulseWidth + *************************************************************************/ +U16 getFPGAD79RinsePumpPulseWidth( void ) +{ + return fpgaSensorReadings.d79SpeedPulseWidth; +} + +/*********************************************************************//** + * @brief * The setFPGAFPValveStates function sets the FP valve states with an 8-bit * mask of states - one bit per valve, with a 1 meaning "energized" and a 0 * meaning "de-energized". The bit positions for these bit states are as follows: