Index: firmware/App/Modes/FPModes/FPModeStandby.c =================================================================== diff -u -r830213bc6dcc1a684610caf78c79d55f2cb41e93 -r886964fa2bf6a5bb61b33b8b5547f3d0c585b360 --- firmware/App/Modes/FPModes/FPModeStandby.c (.../FPModeStandby.c) (revision 830213bc6dcc1a684610caf78c79d55f2cb41e93) +++ firmware/App/Modes/FPModes/FPModeStandby.c (.../FPModeStandby.c) (revision 886964fa2bf6a5bb61b33b8b5547f3d0c585b360) @@ -146,4 +146,56 @@ *************************************************************************/ +/*********************************************************************//** + * @brief + * The testValidateStandbyChangeReq function validate whether + * requested sub mode change is legal or not. + * @details \b Inputs: none + * @details \b Outputs: none + * @param newSubMode the enumerated sub state of the mode. + * @return TRUE if request is legal, FALSE if not. + *************************************************************************/ +BOOL testValidateStandbyChangeReq( U32 newSubMode ) +{ + BOOL result = FALSE; + + if ( newSubMode < NUM_OF_FP_STANDBY_MODE_STATES ) + { + switch ( newSubMode ) + { + case FP_STANDBY_MODE_STATE_IDLE: + default: + result = TRUE; + break; + } + } + + return result; +} + +/*********************************************************************//** + * @brief + * The testSignalNewStandbySubMode function requests transition + * to a new standby sub mode. + * @details \b Inputs: none + * @details \b Outputs: none + * @param newSubMode the enumerated sub state of the mode. + * @return none + *************************************************************************/ +void testSignalNewStandbySubMode( U32 newSubMode ) +{ + if ( newSubMode < NUM_OF_FP_STANDBY_MODE_STATES ) + { + standbyState = (FP_STANDBY_MODE_STATE_T)newSubMode; + // handle the prerequisite if any + switch ( newSubMode ) + { + // Any of these state require no special handling + case FP_STANDBY_MODE_STATE_IDLE: + default: + break; + } + } +} + /**@}*/