23 #include "FwSmConstants.h"
24 #include "FwSmConfig.h"
26 #include "FwPrConfig.h"
28 #include "FwPrConstants.h"
46 FwSmDesc_t InFactory, inRep1, inRep2;
99 if (FwSmCheck(inRep1) != 1)
101 if (FwSmCheck(inRep2) != 1)
171 FwSmDesc_t InFactory,
inRep;
215 FwSmDesc_t InFactory,
inRep;
CrFwInstanceId_t CrFwCmpGetInstanceId(FwSmDesc_t smDesc)
Return the instance identifier of the argument component.
void CrFwCmpInit(FwSmDesc_t smDesc)
Initialize a framework component.
CrFwBool_t CrFwCmpIsInInitialized(FwSmDesc_t smDesc)
Return true if the argument component is in state INITIALIZED.
CrFwBool_t CrFwCmpIsInConfigured(FwSmDesc_t smDesc)
Return true if the argument component is in state CONFIGURED.
void CrFwCmpReset(FwSmDesc_t smDesc)
Reset a framework component.
void CrFwCmpExecute(FwSmDesc_t smDesc)
Execute a framework component.
CrFwTypeId_t CrFwCmpGetTypeId(FwSmDesc_t smDesc)
Return the type identifier of the argument component.
Definition of Base Component.
Definition of the Framework Component Data (FCD) Type.
#define CR_FW_INREPORT_TYPE
Type identifier for the InReport component.
unsigned char * CrFwPckt_t
Type for packets (see CrFwPckt.h).
int CrFwBool_t
Type used for boolean values (1 represent "true" and 0 represents "false").
static CrFwCmpData_t inRepData[CR_FW_INFACTORY_MAX_NOF_INREP]
The base data for the pre-allocated InReport instances.
static FwSmDesc_t inRep[CR_FW_INFACTORY_MAX_NOF_INREP]
The pre-allocated InReport instances.
void CrFwInFactoryReleaseInRep(FwSmDesc_t inRepInstance)
Release function for an InReport.
FwSmDesc_t CrFwInFactoryMakeInRep(CrFwPckt_t pckt)
Make function for a component encapsulating an incoming report (InReport).
FwSmDesc_t CrFwInFactoryMake()
Factory function for the singleton instance of the InFactory.
Definition of the InFactory component.
User-modifiable parameters for the InFactory component (see CrFwInFactory.h).
CrFwPckt_t CrFwInRepGetPckt(FwSmDesc_t smDesc)
Return the pointer to the packet which holds the InReport.
CrFwServType_t CrFwInRepGetServSubType(FwSmDesc_t smDesc)
Return the sub-type of the InReport.
CrFwSeqCnt_t CrFwInRepGetSeqCnt(FwSmDesc_t smDesc)
Return the sequence counter of the InReport.
CrFwServType_t CrFwInRepGetServType(FwSmDesc_t smDesc)
Return the type of the InReport.
CrFwGroup_t CrFwInRepGetGroup(FwSmDesc_t smDesc)
Return the group of the InReport.
CrFwDestSrc_t CrFwInRepGetSrc(FwSmDesc_t smDesc)
Return the source of the InReport.
CrFwPcktLength_t CrFwInRepGetParLength(FwSmDesc_t smDesc)
Return the length in bytes of the parameter area of the InReport.
CrFwDiscriminant_t CrFwInRepGetDiscriminant(FwSmDesc_t smDesc)
Return the discriminant of the InReport.
CrFwPckt_t CrFwInRepGetParStart(FwSmDesc_t smDesc)
Return the start address of the parameter area of the InReport.
Definition of the InReport Component of the framework.
void CrFwInRepSample1SetValidityFlag(CrFwBool_t flag)
Set the value of the Validity Flag (see CrFwInRepSample1ValidityCheck).
CrFwCounterU1_t CrFwInRepSample1GetUpdateActionCounter()
Get the value of the Update Action Counter (see CrFwInRepSample1UpdateAction).
CrFwServType_t CrFwInRepSample1GetType()
Get the value of the InReport's type as it is computed by the Validity Check (see CrFwInRepSample1Val...
CrFwBool_t CrFwInRepTestCase3()
Check the update action of an InReport.
CrFwBool_t CrFwInRepTestCase2()
Check the failure of the Validity Check of an InReport.
CrFwBool_t CrFwInRepTestCase1()
Check the configuration of a newly created InReport.
Declaration of the test cases for the InReport Component (see CrFwInRep.h).
Definition of the OutRegistry Component.
User-modifiable parameters for the OutRegistry component (see CrFwOutRegistry.h).
Interface for creating and accessing a report or command packet.
void CrFwPcktSetServSubType(CrFwPckt_t pckt, CrFwServSubType_t servSubType)
Set the service sub-type of the command or report encapsulated in a packet.
CrFwPckt_t CrFwPcktGetParStart(CrFwPckt_t pckt)
Return the start address of the packet's parameter area.
void CrFwPcktSetCmdRepId(CrFwPckt_t pckt, CrFwInstanceId_t id)
Set the command or report identifier in the command or report encapsulated in a packet.
void CrFwPcktSetSeqCnt(CrFwPckt_t pckt, CrFwSeqCnt_t seqCnt)
Set the sequence counter of the command or report encapsulated in a packet.
CrFwCrc_t CrFwPcktComputeCrc(CrFwPckt_t pckt)
Compute the CRC in the command or report encapsulated in a packet.
void CrFwPcktSetDiscriminant(CrFwPckt_t pckt, CrFwDiscriminant_t discriminant)
Set the discriminant of the command or report encapsulated in a packet.
CrFwPcktLength_t CrFwPcktGetParLength(CrFwPckt_t pckt)
Return the length in bytes of the packet's parameter area.
void CrFwPcktSetServType(CrFwPckt_t pckt, CrFwServType_t servType)
Set the service type of the command or report encapsulated in a packet.
CrFwCounterU2_t CrFwPcktGetNOfAllocated()
Return the number of packets which are currently allocated.
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.
void CrFwPcktSetCrc(CrFwPckt_t pckt, CrFwCrc_t crc)
Set the CRC in the command or report encapsulated in a packet.
void CrFwPcktSetSrc(CrFwPckt_t pckt, CrFwDestSrc_t src)
Set the source of the command or report encapsulated in a packet.
void CrFwPcktSetGroup(CrFwPckt_t pckt, CrFwGroup_t group)
Set the group of the command/report encapsulated in a packet.
CrFwPckt_t CrFwPcktMake(CrFwPcktLength_t pcktLength)
Make function for command or report packets.
Interface for reporting an error detected by a framework component.
The CORDET Framework defines an interface for generating error reports (see CrFwRepErr....
Interface through which framework components access the current time.
unsigned char CrFwCounterU1_t
Type used for unsigned integers with a "short" range.
unsigned short CrFwCrc_t
Type used for the CRC field in a packet.
@ crNoAppErr
No application errors have been detected.
CrFwAppErrCode_t CrFwGetAppErrCode()
Return the value of the application error code.
Definition of the utility functions for the CORDET Framework.
Type for the Framework Component Data (FCD).
void * cmpSpecificData
Derived data which are specific to each type of framework component.
Type for the data describing an InReport.
CrFwPckt_t pckt
Packet holding the InReport.