Index: firmware/App/Modes/ModeStandby.h =================================================================== diff -u -r4efb2d1786c717ca6cf4b1bc992cec8e16820bff -re6c60e07b450ec8d58e87bf13d45f96efab54d8b --- firmware/App/Modes/ModeStandby.h (.../ModeStandby.h) (revision 4efb2d1786c717ca6cf4b1bc992cec8e16820bff) +++ firmware/App/Modes/ModeStandby.h (.../ModeStandby.h) (revision e6c60e07b450ec8d58e87bf13d45f96efab54d8b) @@ -1,18 +1,19 @@ -/**********************************************************************//** - * - * Copyright (c) 2019-2020 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. - * - * @file ModeStandby.h - * - * @date 11-Dec-2019 - * @author S. Nash - * - * @brief Header file for Standby Mode. - * - **************************************************************************/ +/************************************************************************** +* +* Copyright (c) 2019-2024 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. +* +* @file ModeStandby.h +* +* @author (last) Dara Navaei +* @date (last) 23-Jul-2024 +* +* @author (original) Dara Navaei +* @date (original) 05-Nov-2019 +* +***************************************************************************/ #ifndef __MODE_STANDBY_H__ #define __MODE_STANDBY_H__ @@ -22,26 +23,44 @@ /** * @defgroup DGStandbyMode DGStandbyMode - * @brief Standby mode module. - * Manages standby mode functions via a state machine. + * @brief Standby mode module. Manages standby mode functions via a state machine. * * @addtogroup DGStandbyMode * @{ */ // ********** public definitions ********** -// ********** private function prototypes ********** +/// Standby mode data structure +typedef struct +{ + U32 timeout; ///< Timeout. + U32 countdown; ///< Count down. +} STANDBY_MODE_DATA_T; -void initStandbyMode( void ); // initialize this module -void transitionToStandbyMode( void ); // prepares for transition to standby mode -U32 execStandbyMode( void ); // execute the standby mode state machine (call from OperationModes) +// ********** public function prototypes ********** -DG_STANDBY_MODE_STATE_T getCurrentStandbyState( void ); // get the current state of the standby mode. +void initStandbyMode( void ); // initialize this module +U32 transitionToStandbyMode( void ); // prepares for transition to standby mode +U32 execStandbyMode( void ); // execute the standby mode state machine (call from OperationModes) -BOOL requestWaterSample( void ); // HD requests water sample -BOOL requestDGStart( void ); // HD requests DG start (go to re-circulate mode) +void waterSampleCommandHandler( SAMPLE_WATER_CMD_T sampleWaterCmd ); // handle water sample command +BOOL requestDGStart( void ); // HD requests DG start (go to generation idle mode) +BOOL signalAbortWaterSampling( void ); // HD signal to abort water sampling. +BOOL startDGFlush( void ); // HD start flush mode +BOOL startDGHeatDisinfect( BOOL isPassive ); // HD start heat disinfect mode +BOOL startDGHeatDisinfectActiveCool( void ); +DG_STANDBY_MODE_STATE_T getCurrentStandbyState( void ); // get the current state of the standby mode. + +BOOL startDGChemicalDisinfect( void ); // HD start chemical disinfect mode +BOOL startDGChemicalDisinfectFlush( void ); // HD start chemical disinfect flush mode + +BOOL startDGROPermeateSample( void ); // HD start RO permeate sample + +BOOL testSetFilterFlushTimePeriodOverride( U32 value ); // set filter flush time period override. +BOOL testResetFilterFlushTimePeriodOverride( void ); // reset filter flush time period override. + /**@}*/ #endif