Index: firmware/App/Controllers/DGInterface.c =================================================================== diff -u -re7c4a51e6057f0cc83fabc72f2df9bb5dffee391 -r9b6d9a0db373b39c3d04dd07516fde59b292bbc5 --- firmware/App/Controllers/DGInterface.c (.../DGInterface.c) (revision e7c4a51e6057f0cc83fabc72f2df9bb5dffee391) +++ firmware/App/Controllers/DGInterface.c (.../DGInterface.c) (revision 9b6d9a0db373b39c3d04dd07516fde59b292bbc5) @@ -8,7 +8,7 @@ * @file DGInterface.c * * @author (last) Sean Nash -* @date (last) 07-Jul-2023 +* @date (last) 14-Aug-2023 * * @author (original) Sean * @date (original) 08-Apr-2020 @@ -96,8 +96,8 @@ static BOOL dgOpModeDataFreshFlag = FALSE; ///< Flag to signal the handleDGOpMode() to process fresh dg op mode data // Reservoir data -static DG_RESERVOIR_ID_T dgActiveReservoir = DG_RESERVOIR_2; ///< Latest active reservoir reported by the DG. -static DG_RESERVOIR_ID_T dgActiveReservoirSet = DG_RESERVOIR_2; ///< Active reservoir commanded. +static DG_RESERVOIR_ID_T dgActiveReservoir; ///< Latest active reservoir reported by the DG. +static DG_RESERVOIR_ID_T dgActiveReservoirSet; ///< Active reservoir commanded. static U32 dgReservoirFillVolumeTarget = 0; ///< Latest fill-to volume reported by the DG. static U32 dgReservoirFillVolumeTargetSet = 0; ///< Fill-to volume commanded. @@ -129,12 +129,13 @@ { U32 i, j; + // NOTE: the active reservoir is set to reservoir 1 since DG will send active reservoir 1 as active on power up dgStarted = FALSE; dgTrimmerHeaterOn = FALSE; dgTrimmerTempSet = 0.0F; dgTrimmerTempCheckTimerCtr = 0; - dgActiveReservoirSet = DG_RESERVOIR_2; - dgActiveReservoir = DG_RESERVOIR_2; + dgActiveReservoirSet = DG_RESERVOIR_1; + dgActiveReservoir = DG_RESERVOIR_1; dgReservoirFillVolumeTargetSet = 0; dgReservoirDrainVolumeTargetSet = 0; dgDialysateTemp = 0.0F; @@ -966,6 +967,21 @@ /*********************************************************************//** * @brief + * The cmdDGParkConcentratePumps function sends a park concentrate pumps command + * message to the DG. + * @details Inputs: none + * @details Outputs: park concentrate pumps command sent to DG. + * @return none + *************************************************************************/ +void cmdDGParkConcentratePumps( void ) +{ + dgCmdResp[ DG_CMD_PARK_CONCENTRATE_PUMPS ].commandID = DG_CMD_NONE; + + sendDGParkConcentratePumpsCommand( ); +} + +/*********************************************************************//** + * @brief * The cmdStartDGFlush function sends a start flush command message to * the DG. * @details Inputs: none