Index: firmware/App/Controllers/Switches.h =================================================================== diff -u -r04c5d5d9198c1fde05df66ec8f5e660f7f7174b1 -r7d4711edd7b40cd3e29f43e766f79a8a09586fe9 --- firmware/App/Controllers/Switches.h (.../Switches.h) (revision 04c5d5d9198c1fde05df66ec8f5e660f7f7174b1) +++ firmware/App/Controllers/Switches.h (.../Switches.h) (revision 7d4711edd7b40cd3e29f43e766f79a8a09586fe9) @@ -1,14 +1,14 @@ /************************************************************************** * -* Copyright (c) 2021-2022 Diality Inc. - All Rights Reserved. +* Copyright (c) 2021-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 Switches.h * * @author (last) Dara Navaei -* @date (last) 13-Aug-2021 +* @date (last) 14-Jun-2022 * * @author (original) Dara Navaei * @date (original) 24-Jul-2021 @@ -31,46 +31,35 @@ */ // ********** public definitions ********** -/**@}*/ -/** - * @addtogroup Switches - * @{ - */ + /// DG doors and caps enumeration -typedef enum switches_names +typedef enum cap_names { CONCENTRATE_CAP = 0, ///< Concentrate cap DIALYSATE_CAP, ///< Dialysate cap - NUM_OF_CAPS ///< Number of doors and caps -} SWITCH_T; + NUM_OF_CAPS ///< Number of caps +} CAP_T; -/**@}*/ - /// DG doors and caps data publish structure typedef struct { U32 concentrateCap; ///< Concentrate cap U32 dialysateCap; ///< Dialysate cap } SWITCHES_DATA_T; -/// DG doors and caps switches changed publish structure -typedef struct -{ - U32 SwitchId; ///< Switch ID - U32 newstate; ///< New state of switch -} SWITCH_CHANGED_DATA_T; - // ********** public function prototypes ********** void initSwitches( void ); void execSwitches( void ); -OPN_CLS_STATE_T getSwitchStatus( SWITCH_T switchId ); +OPN_CLS_STATE_T getSwitchStatus( CAP_T switchId ); BOOL testSetSwitchesDataPublishIntervalOverride( U32 value ); BOOL testResetSwitchesDataPublishIntervalOverride( void ); BOOL testSetSwitchesStatusOverride( U32 switchId, U32 status ); BOOL testResetSwitchesStatusOverride( U32 switchId ); -#endif /* APP_CONTROLLERS_SWITCHES_H_ */ +/**@}*/ + +#endif