25 #include "FwSmConstants.h" 26 #include "FwSmConfig.h" 28 #include "FwPrConfig.h" 30 #include "FwPrConstants.h" 50 FwSmDesc_t inManager1, inManagerIll;
87 if (inManagerIll != NULL)
107 FwSmDesc_t inRep1, inCmd1;
146 if (loadOutcome != 1)
154 if (loadOutcome != 1)
185 if (loadOutcome != 0)
230 FwSmDesc_t sampleInRep;
231 FwSmCounterU3_t execCnt;
275 execCnt = FwSmGetExecCnt(sampleInRep);
282 if (FwSmGetExecCnt(sampleInRep) != execCnt+1)
307 FwSmDesc_t sampleInCmd;
308 FwSmCounterU3_t execCnt;
358 execCnt = FwSmGetExecCnt(sampleInCmd);
365 if (FwSmGetExecCnt(sampleInCmd) != execCnt+2)
382 if (FwSmGetExecCnt(sampleInCmd) != execCnt+3)
409 FwSmDesc_t sampleInCmd;
410 FwSmCounterU3_t execCnt;
460 execCnt = FwSmGetExecCnt(sampleInCmd);
467 if (FwSmGetExecCnt(sampleInCmd) != execCnt+1)
494 FwSmDesc_t sampleInCmd1, sampleInCmd2, inRep1, inRep2, inRep3, inRep4;
664 FwSmDesc_t sampleInCmd1, sampleInCmd2, inRep1, inRep2;
763 FwSmDesc_t sampleInCmd1, sampleInCmd2, inRep1, inRep2;
849 FwSmStart(inManager3);
void CrFwPcktSetAckLevel(CrFwPckt_t pckt, CrFwBool_t accept, CrFwBool_t start, CrFwBool_t progress, CrFwBool_t term)
Set the acknowledge level for the command encapsulated in a packet.
Interface through which framework components access the current time.
CrFwTypeId_t CrFwCmpGetTypeId(FwSmDesc_t smDesc)
Return the type identifier of the argument component.
void CrFwCmpInit(FwSmDesc_t smDesc)
Initialize a framework component.
Definition of the Framework Component Data (FCD) Type.
void CrFwInCmdSample1SetValidityFlag(CrFwBool_t flag)
Set the value of the Validity Flag (see CrFwInCmdSample1ValidityCheck).
void CrFwInCmdSample1SetProgressActionOutcome(CrFwOutcome_t outcome)
Set the value of the Progress Action Outcome (see CrFwInCmdSample1ProgressAction).
CrFwBool_t CrFwInManagerTestCase4()
Check the execution function of an InManager with one InCommand loaded.
CrFwBool_t CrFwCmpIsInConfigured(FwSmDesc_t smDesc)
Return true if the argument component is in state CONFIGURED.
void CrFwSetAppErrCode(CrFwAppErrCode_t errCode)
Set the value of the application error code (see CrFwGetAppErrCode).
unsigned char * CrFwPckt_t
Type for packets (see CrFwPckt.h).
The Pending Command/Report List (PCRL) of an InManager is full (see CrFwInManager.h)
CrFwBool_t CrFwCmpIsInCreated(FwSmDesc_t smDesc)
Return true if the argument component is in state CREATED.
CrFwInstanceId_t CrFwCmpGetInstanceId(FwSmDesc_t smDesc)
Return the instance identifier of the argument component.
CrFwPckt_t CrFwPcktMake(CrFwPcktLength_t pcktLength)
Make function for command or report packets.
CrFwBool_t CrFwInCmdIsInAborted(FwSmDesc_t smDesc)
Return true if the argument InCommand is in state ABORTED.
static FwSmDesc_t inFactory
The singleton instance of the InFactory.
CrFwBool_t CrFwInCmdIsInProgress(FwSmDesc_t smDesc)
Return true if the argument InCommand is in state PROGRESS.
CrFwCounterU1_t CrFwInManagerGetPCRLSize(FwSmDesc_t smDesc)
Return the size of the PCRL of an InManager.
CrFwBool_t CrFwInManagerTestCase3()
Check the execution function of an InManager with one single InReport loaded.
Interface for creating and accessing a report or command packet.
int CrFwBool_t
Type used for boolean values (1 represent "true" and 0 represents "false").
#define CR_FW_INMANAGER_TYPE
Type identifier for the InManager component.
void CrFwInCmdSample1SetTerminationActionOutcome(CrFwOutcome_t outcome)
Set the value of the Termination Action Outcome Counter (see CrFwInCmdSample1TerminationAction).
#define CR_FW_NOF_INMANAGER
The number of InManager components in the application.
CrFwBool_t CrFwInManagerTestCase5()
Check the execution function of an InManager with one InCommand loaded.
Definition of the InRegistry Component.
CrFwBool_t CrFwCmpIsInInitialized(FwSmDesc_t smDesc)
Return true if the argument component is in state INITIALIZED.
Incoming command has been aborted.
Interface for reporting an error detected by a framework component.
FwSmDesc_t CrFwInRegistryMake()
Factory function for the singleton instance of the InRegistry.
CrFwBool_t CrFwInManagerTestCase2()
Check the load function of an InManager.
CrFwTypeId_t CrFwRepErrStubGetTypeId(CrFwCounterU2_t errRepPos)
Return the type identifier of the error report at position errRepPos.
CrFwRepErrCode_t CrFwRepErrStubGetErrCode(CrFwCounterU2_t errRepPos)
Return the error code of the error report at position errRepPos.
Definition of the InReport Component of the framework.
User-modifiable parameters for the InRegistry component (see CrFwInRegistry.h).
unsigned short CrFwCounterU2_t
Type used for unsigned integers with a "medium" range.
A framework function has been called with an illegal InManager identifier.
void CrFwPcktSetServSubType(CrFwPckt_t pckt, CrFwServSubType_t servSubType)
Set the service sub-type of the command or report encapsulated in a packet.
FwSmDesc_t CrFwInManagerMake(CrFwInstanceId_t i)
Factory function to retrieve the i-th InManager State Machine instance.
void CrFwInCmdSample1SetStartActionOutcome(CrFwOutcome_t outcome)
Set the value of the Start Action Outcome Counter (see CrFwInCmdSample1StartAction).
Definition of the InFactory component.
Definition of the utility functions for the CORDET Framework.
CrFwBool_t CrFwInCmdIsInTerminated(FwSmDesc_t smDesc)
Return true if the argument InCommand is in state TERMINATED.
CrFwBool_t CrFwInManagerLoad(FwSmDesc_t smDesc, FwSmDesc_t inCmp)
Load a new InReport or InCommand into the InManager.
void CrFwCmpReset(FwSmDesc_t smDesc)
Reset a framework component.
CrFwInRegistryCmdRepState_t CrFwInRegistryGetState(CrFwInstanceId_t cmdRepId)
Query the InRegistry for the state of an incoming command or report.
void CrFwPcktSetServType(CrFwPckt_t pckt, CrFwServType_t servType)
Set the service type of the command or report encapsulated in a packet.
CrFwBool_t CrFwInManagerTestCase7()
Check the reset function of an InManager.
void CrFwCmpExecute(FwSmDesc_t smDesc)
Execute a framework component.
Definition of Base Component.
User-modifiable parameters for the OutFactory component (see CrFwOutFactory.h).
FwSmDesc_t CrFwInFactoryMake()
Factory function for the singleton instance of the InFactory.
The CORDET Framework defines an interface for generating error reports (see CrFwRepErr.h).
User-modifiable parameters for the InManager components (see CrFwInManager.h).
void CrFwInFactoryReleaseInCmd(FwSmDesc_t inCmdInstance)
Release function for an InCommand.
CrFwBool_t CrFwInManagerTestCase8()
Check the shutdown function of an InManager.
CrFwBool_t CrFwInManagerTestCase1()
Check the configuration of a newly created InManager.
CrFwCounterU2_t CrFwPcktGetNOfAllocated()
Return the number of packets which are currently allocated.
FwSmDesc_t CrFwInFactoryMakeInRep(CrFwPckt_t pckt)
Make function for a component encapsulating an incoming report (InReport).
void CrFwInCmdSample1SetReadyFlag(CrFwBool_t flag)
Set the value of the Ready Flag (see CrFwInCmdSample1ReadyCheck).
void CrFwInRepSample1SetValidityFlag(CrFwBool_t flag)
Set the value of the Validity Flag (see CrFwInRepSample1ValidityCheck).
CrFwCounterU2_t CrFwInManagerGetNOfLoadedInCmp(FwSmDesc_t smDesc)
Return the number of InReport or InCommands successfully loaded since the InManager was last reset...
CrFwCounterU2_t CrFwRepErrStubGetPos()
Return the position in the error report array at which the next error report will be written...
Sample InReport used in the Test Suite.
CrFwInFactoryPoolIndex_t CrFwInFactoryGetNOfAllocatedInCmd()
Return the number of InCommands which are currently allocated.
CrFwInFactoryPoolIndex_t CrFwInFactoryGetNOfAllocatedInRep()
Return the number of InReports which are currently allocated.
CrFwInstanceId_t CrFwRepErrStubGetInstanceId(CrFwCounterU2_t errRepPos)
Return the type identifier of the error report at position errRepPos.
void CrFwCmpShutdown(FwSmDesc_t smDesc)
Shutdown a framework component.
void CrFwPcktSetDiscriminant(CrFwPckt_t pckt, CrFwDiscriminant_t discriminant)
Set the discriminant of the command or report encapsulated in a packet.
No application errors have been detected.
static FwSmDesc_t inRegistry
The InRegistry singleton.
CrFwBool_t CrFwInManagerTestCase6()
Check the execution function of an InManager with several InReports and InCommands loaded...
FwSmDesc_t CrFwInFactoryMakeInCmd(CrFwPckt_t pckt)
Make function for a component encapsulating an incoming command (InCommand).
CrFwAppErrCode_t CrFwGetAppErrCode()
Return the value of the application error code.
CrFwCounterU1_t CrFwInManagerGetNOfPendingInCmp(FwSmDesc_t smDesc)
Return the number of InReport or InCommands currently in the PCRL of an InManager.
Incoming command or report is pending (waiting to be sent)
Declaration of the test cases for the InManager Component (see CrFwInManager.h).
Sample InCommand used in the Test Suite.
Definition of the InCommand Component of the framework.
void CrFwInCmdSample1SetProgressActionCompletionOutcome(CrFwOutcome_t outcome)
Set the value of the Progress Action Completion Outcome (see CrFwInCmdSample1ProgressAction).
Incoming command or report has completed execution.