Index: firmware/App/Modes/Prime.h =================================================================== diff -u -r4d2dcd2d5ee3c7684be139b7e560b16d8c3abc06 -rcd5be724d5a3ba7457e761191d82f278654d7f5c --- firmware/App/Modes/Prime.h (.../Prime.h) (revision 4d2dcd2d5ee3c7684be139b7e560b16d8c3abc06) +++ firmware/App/Modes/Prime.h (.../Prime.h) (revision cd5be724d5a3ba7457e761191d82f278654d7f5c) @@ -1,17 +1,17 @@ /************************************************************************** * -* Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. +* Copyright (c) 2020-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 Prime.h +* @file Prime.h * -* @author (last) Quang Nguyen -* @date (last) 08-Dec-2020 +* @author (last) Darren Cox +* @date (last) 10-Mar-2022 * -* @author (original) Quang Nguyen -* @date (original) 08-Dec-2020 +* @author (original) Quang Nguyen +* @date (original) 08-Dec-2020 * ***************************************************************************/ @@ -24,20 +24,32 @@ /** * @defgroup Prime Prime * @brief Prime sub-mode of pre-treatment mode. This sub-mode handles blood and dialysate circuits priming functionality. + * This sub-mode also executes wet self-tests after prime is completed. * * @addtogroup Prime * @{ */ // ********** public definitions ********** +/// Payload record structure for a priming status data broadcast message. +typedef struct +{ + U32 totalTime; ///< Total priming time in seconds. + U32 remainingTime; ///< Remaining time for priming in seconds. +} PRIMING_DATA_PAYLOAD_T; + // ********** public function prototypes ********** -void initPrime( void ); -void transitionToPrime( void ); -void execPrime( void ); +void initPrime( void ); // Initialize prime sub-mode (of pre-treatment mode). +void transitionToPrime( void ); // Transition to prime sub-mode (of pre-treatment mode). +void execPrime( void ); // Execute the prime state machine. +U32 getPrimeState( void ); // Get the current state of the prime state machine. +U32 getDialyzerBloodVolume( void ); // Get the blood volume (in mL) associated with a given dialyzer type. +U32 getDialyzerDialysateVolume( void ); // Get the dialysate volume (in mL) associated with a given dialyzer type. -BOOL isPrimingPassed( void ); +void signalStartPrime( void ); // User has requested to start prime +void signalResumePrime( void ); // User has requested to resume prime /**@}*/