Index: firmware/App/Modes/OperationModes.c =================================================================== diff -u -rb67373adbc581690febb1e1c2bb521f108d9b92e -rd371983d84daf213db3e39d21cf30c13161ce062 --- firmware/App/Modes/OperationModes.c (.../OperationModes.c) (revision b67373adbc581690febb1e1c2bb521f108d9b92e) +++ firmware/App/Modes/OperationModes.c (.../OperationModes.c) (revision d371983d84daf213db3e39d21cf30c13161ce062) @@ -8,7 +8,7 @@ * @file OperationModes.c * * @author (last) Michael Garthwaite -* @date (last) 24-Aug-2023 +* @date (last) 18-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