Index: firmware/App/Modes/OperationModes.c =================================================================== diff -u -re5a51671c1c91cf2dd97d03ccaa27bd225198f4c -r164e1a3ffca18c703676bc7f57f5903c76050600 --- firmware/App/Modes/OperationModes.c (.../OperationModes.c) (revision e5a51671c1c91cf2dd97d03ccaa27bd225198f4c) +++ firmware/App/Modes/OperationModes.c (.../OperationModes.c) (revision 164e1a3ffca18c703676bc7f57f5903c76050600) @@ -7,8 +7,8 @@ * * @file OperationModes.c * -* @author (last) Michael Garthwaite -* @date (last) 08-Aug-2023 +* @author (last) Sean Nash +* @date (last) 30-Sep-2023 * * @author (original) Dara Navaei * @date (original) 05-Nov-2019 @@ -168,6 +168,9 @@ lastMode = currentMode; transitionToNewOperationMode( newMode ); currentMode = newMode; + // Set the last sub mode to 0 + // to ensure events cover the transition from submode 0 -> 1 -> 2 + priorSubMode = 0; sendOperationStatusEvent(); } @@ -296,6 +299,18 @@ /*********************************************************************//** * @brief + * The getCurrentOperationSubMode function gets the current operation submode. + * @details Inputs: currentSubMode + * @details Outputs: none + * @return the current operation submode + *************************************************************************/ +U32 getCurrentOperationSubMode( void ) +{ + return currentSubMode; +} + +/*********************************************************************//** + * @brief * The arbitrateModeRequest function selects highest priority mode request * and clear all requests. * @details Inputs: none @@ -466,7 +481,6 @@ * status event. * @details Inputs: currentMode, currentSubMode, currentSubState * @details Outputs: dat1, dat2. - * @param none * @return none *************************************************************************/ static void sendOperationStatusEvent()