9 #if FW_ENABLE_TEXT_LOGGING 26 #if !FW_DIRECT_PORT_CALLS 33 this->m_comStatusIn_InputPort[port].
init();
38 this->m_comStatusIn_InputPort[port].
setPortNum(port);
40 #if FW_OBJECT_NAMES == 1 44 this->m_objName.toChar(),
47 this->m_comStatusIn_InputPort[port].setObjName(portName.
toChar());
52 #if !FW_DIRECT_PORT_CALLS 59 this->m_dataIn_InputPort[port].
init();
64 this->m_dataIn_InputPort[port].
setPortNum(port);
66 #if FW_OBJECT_NAMES == 1 70 this->m_objName.toChar(),
73 this->m_dataIn_InputPort[port].setObjName(portName.
toChar());
78 #if !FW_DIRECT_PORT_CALLS 85 this->m_dataReturnIn_InputPort[port].
init();
90 this->m_dataReturnIn_InputPort[port].
setPortNum(port);
92 #if FW_OBJECT_NAMES == 1 96 this->m_objName.toChar(),
99 this->m_dataReturnIn_InputPort[port].setObjName(portName.
toChar());
104 #if !FW_DIRECT_PORT_CALLS 111 this->m_logOut_OutputPort[port].
init();
113 #if FW_OBJECT_NAMES == 1 117 this->m_objName.toChar(),
120 this->m_logOut_OutputPort[port].setObjName(portName.
toChar());
125 #if !FW_DIRECT_PORT_CALLS && FW_ENABLE_TEXT_LOGGING 129 port < static_cast<FwIndexType>(this->getNum_logTextOut_OutputPorts());
132 this->m_logTextOut_OutputPort[port].
init();
134 #if FW_OBJECT_NAMES == 1 138 this->m_objName.toChar(),
141 this->m_logTextOut_OutputPort[port].setObjName(portName.
toChar());
146 #if !FW_DIRECT_PORT_CALLS 153 this->m_timeCaller_OutputPort[port].
init();
155 #if FW_OBJECT_NAMES == 1 159 this->m_objName.toChar(),
162 this->m_timeCaller_OutputPort[port].setObjName(portName.
toChar());
167 #if !FW_DIRECT_PORT_CALLS 174 this->m_bufferAllocate_OutputPort[port].
init();
176 #if FW_OBJECT_NAMES == 1 180 this->m_objName.toChar(),
183 this->m_bufferAllocate_OutputPort[port].setObjName(portName.
toChar());
188 #if !FW_DIRECT_PORT_CALLS 195 this->m_bufferDeallocate_OutputPort[port].
init();
197 #if FW_OBJECT_NAMES == 1 201 this->m_objName.toChar(),
204 this->m_bufferDeallocate_OutputPort[port].setObjName(portName.
toChar());
209 #if !FW_DIRECT_PORT_CALLS 216 this->m_comStatusOut_OutputPort[port].
init();
218 #if FW_OBJECT_NAMES == 1 222 this->m_objName.toChar(),
225 this->m_comStatusOut_OutputPort[port].setObjName(portName.
toChar());
230 #if !FW_DIRECT_PORT_CALLS 237 this->m_dataOut_OutputPort[port].
init();
239 #if FW_OBJECT_NAMES == 1 243 this->m_objName.toChar(),
246 this->m_dataOut_OutputPort[port].setObjName(portName.
toChar());
251 #if !FW_DIRECT_PORT_CALLS 258 this->m_dataReturnOut_OutputPort[port].
init();
260 #if FW_OBJECT_NAMES == 1 264 this->m_objName.toChar(),
267 this->m_dataReturnOut_OutputPort[port].setObjName(portName.
toChar());
273 #if !FW_DIRECT_PORT_CALLS 284 static_cast<FwAssertArgType>(portNum)
287 return &this->m_comStatusIn_InputPort[portNum];
295 static_cast<FwAssertArgType>(portNum)
298 return &this->m_dataIn_InputPort[portNum];
306 static_cast<FwAssertArgType>(portNum)
309 return &this->m_dataReturnIn_InputPort[portNum];
314 #if !FW_DIRECT_PORT_CALLS 328 static_cast<FwAssertArgType>(portNum)
331 this->m_logOut_OutputPort[portNum].
addCallPort(port);
334 #if FW_ENABLE_TEXT_LOGGING == 1 336 void FprimeFramerComponentBase ::
337 set_logTextOut_OutputPort(
343 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
344 static_cast<FwAssertArgType>(portNum)
347 this->m_logTextOut_OutputPort[portNum].addCallPort(port);
360 static_cast<FwAssertArgType>(portNum)
363 this->m_timeCaller_OutputPort[portNum].
addCallPort(port);
368 #if !FW_DIRECT_PORT_CALLS 382 static_cast<FwAssertArgType>(portNum)
385 this->m_bufferAllocate_OutputPort[portNum].
addCallPort(port);
396 static_cast<FwAssertArgType>(portNum)
399 this->m_bufferDeallocate_OutputPort[portNum].
addCallPort(port);
410 static_cast<FwAssertArgType>(portNum)
413 this->m_comStatusOut_OutputPort[portNum].
addCallPort(port);
424 static_cast<FwAssertArgType>(portNum)
427 this->m_dataOut_OutputPort[portNum].
addCallPort(port);
438 static_cast<FwAssertArgType>(portNum)
441 this->m_dataReturnOut_OutputPort[portNum].
addCallPort(port);
446 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION 455 Fw::InputSerializePort* port
460 static_cast<FwAssertArgType>(portNum)
463 this->m_logOut_OutputPort[portNum].registerSerialPort(port);
466 #if FW_ENABLE_TEXT_LOGGING == 1 468 void FprimeFramerComponentBase ::
469 set_logTextOut_OutputPort(
471 Fw::InputSerializePort* port
475 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
476 static_cast<FwAssertArgType>(portNum)
479 this->m_logTextOut_OutputPort[portNum].registerSerialPort(port);
487 Fw::InputSerializePort* port
492 static_cast<FwAssertArgType>(portNum)
495 this->m_timeCaller_OutputPort[portNum].registerSerialPort(port);
500 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION 509 Fw::InputSerializePort* port
514 static_cast<FwAssertArgType>(portNum)
517 this->m_bufferDeallocate_OutputPort[portNum].registerSerialPort(port);
523 Fw::InputSerializePort* port
528 static_cast<FwAssertArgType>(portNum)
531 this->m_comStatusOut_OutputPort[portNum].registerSerialPort(port);
537 Fw::InputSerializePort* port
542 static_cast<FwAssertArgType>(portNum)
545 this->m_dataOut_OutputPort[portNum].registerSerialPort(port);
551 Fw::InputSerializePort* port
556 static_cast<FwAssertArgType>(portNum)
559 this->m_dataReturnOut_OutputPort[portNum].registerSerialPort(port);
570 Fw::PassiveComponentBase(compName)
572 this->m_NoBufferAvailableThrottle = 0;
581 #if !FW_DIRECT_PORT_CALLS 592 static_cast<FwAssertArgType>(portNum)
595 return this->m_logOut_OutputPort[portNum].
isConnected();
598 #if FW_ENABLE_TEXT_LOGGING == 1 600 bool FprimeFramerComponentBase ::
601 isConnected_logTextOut_OutputPort(
FwIndexType portNum)
const 604 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
605 static_cast<FwAssertArgType>(portNum)
608 return this->m_logTextOut_OutputPort[portNum].isConnected();
618 static_cast<FwAssertArgType>(portNum)
621 return this->m_timeCaller_OutputPort[portNum].
isConnected();
626 #if !FW_DIRECT_PORT_CALLS 637 static_cast<FwAssertArgType>(portNum)
640 return this->m_bufferAllocate_OutputPort[portNum].
isConnected();
648 static_cast<FwAssertArgType>(portNum)
651 return this->m_bufferDeallocate_OutputPort[portNum].
isConnected();
659 static_cast<FwAssertArgType>(portNum)
662 return this->m_comStatusOut_OutputPort[portNum].
isConnected();
670 static_cast<FwAssertArgType>(portNum)
673 return this->m_dataOut_OutputPort[portNum].
isConnected();
681 static_cast<FwAssertArgType>(portNum)
684 return this->m_dataReturnOut_OutputPort[portNum].
isConnected();
704 static_cast<FwAssertArgType>(portNum)
724 static_cast<FwAssertArgType>(portNum)
745 static_cast<FwAssertArgType>(portNum)
756 #if !FW_DIRECT_PORT_CALLS 770 static_cast<FwAssertArgType>(portNum)
774 this->m_bufferAllocate_OutputPort[portNum].isConnected(),
775 static_cast<FwAssertArgType>(portNum)
777 return this->m_bufferAllocate_OutputPort[portNum].
invoke(
790 static_cast<FwAssertArgType>(portNum)
794 this->m_bufferDeallocate_OutputPort[portNum].isConnected(),
795 static_cast<FwAssertArgType>(portNum)
797 this->m_bufferDeallocate_OutputPort[portNum].
invoke(
810 static_cast<FwAssertArgType>(portNum)
814 this->m_comStatusOut_OutputPort[portNum].isConnected(),
815 static_cast<FwAssertArgType>(portNum)
817 this->m_comStatusOut_OutputPort[portNum].
invoke(
831 static_cast<FwAssertArgType>(portNum)
835 this->m_dataOut_OutputPort[portNum].isConnected(),
836 static_cast<FwAssertArgType>(portNum)
838 this->m_dataOut_OutputPort[portNum].
invoke(
853 static_cast<FwAssertArgType>(portNum)
857 this->m_dataReturnOut_OutputPort[portNum].isConnected(),
858 static_cast<FwAssertArgType>(portNum)
860 this->m_dataReturnOut_OutputPort[portNum].
invoke(
880 this->m_NoBufferAvailableThrottle++;
886 this->timeCaller_out(0, _logTime);
895 #if FW_AMPCS_COMPATIBLE 901 static_cast<FwAssertArgType>(_status)
915 #if FW_ENABLE_TEXT_LOGGING 916 if (this->isConnected_logTextOut_OutputPort(0)) {
917 #if FW_OBJECT_NAMES == 1 918 const char* _formatString =
919 "(%s) %s: Failed to allocate a frame buffer: frame dropped";
921 const char* _formatString =
922 "%s: Failed to allocate a frame buffer: frame dropped";
929 this->m_objName.toChar(),
934 this->logTextOut_out(
953 this->m_NoBufferAvailableThrottle = 0;
965 this->timeCaller_out(0, _time);
977 void FprimeFramerComponentBase ::
992 void FprimeFramerComponentBase ::
1002 compPtr->dataIn_handlerBase(
1009 void FprimeFramerComponentBase ::
1010 m_p_dataReturnIn_in(
1019 compPtr->dataReturnIn_handlerBase(
1026 #if !FW_DIRECT_PORT_CALLS 1032 void FprimeFramerComponentBase ::
1043 static_cast<FwAssertArgType>(portNum)
1047 this->m_logOut_OutputPort[portNum].isConnected(),
1048 static_cast<FwAssertArgType>(portNum)
1050 this->m_logOut_OutputPort[portNum].
invoke(
1058 #if FW_ENABLE_TEXT_LOGGING 1060 void FprimeFramerComponentBase ::
1070 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
1071 static_cast<FwAssertArgType>(portNum)
1075 this->m_logTextOut_OutputPort[portNum].isConnected(),
1076 static_cast<FwAssertArgType>(portNum)
1078 this->m_logTextOut_OutputPort[portNum].invoke(
1088 void FprimeFramerComponentBase ::
1096 static_cast<FwAssertArgType>(portNum)
1100 this->m_timeCaller_OutputPort[portNum].isConnected(),
1101 static_cast<FwAssertArgType>(portNum)
1103 this->m_timeCaller_OutputPort[portNum].
invoke(
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
Serialization/Deserialization operation was successful.
void log_WARNING_HI_NoBufferAvailable()
bool isConnected_dataReturnOut_OutputPort(FwIndexType portNum) const
void dataOut_out(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context) const
Invoke output port dataOut.
void addCallPort(InputTimePort *callPort)
Register an input port.
virtual void comStatusIn_handler(FwIndexType portNum, Fw::Success &condition)=0
Handler for input port comStatusIn.
FwIdType getIdBase() const
PlatformSizeType FwSizeType
bool isConnected_dataOut_OutputPort(FwIndexType portNum) const
Auto-generated base for FprimeFramer component.
void set_comStatusOut_OutputPort(FwIndexType portNum, Fw::InputSuccessConditionPort *port)
Connect port to comStatusOut[portNum].
void set_logOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to logOut[portNum].
void log_WARNING_HI_NoBufferAvailable_ThrottleClear()
Reset throttle value for NoBufferAvailable.
void comStatusIn_handlerBase(FwIndexType portNum, Fw::Success &condition)
Handler base-class function for input port comStatusIn.
void dataIn_handlerBase(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)
Handler base-class function for input port dataIn.
static constexpr FwIndexType getNum_comStatusIn_InputPorts()
static constexpr FwIndexType getNum_dataReturnOut_OutputPorts()
No time base has been established (Required)
SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG) override
Serialize an 8-bit unsigned integer value.
static constexpr FwIndexType getNum_logOut_OutputPorts()
bool isConnected_bufferDeallocate_OutputPort(FwIndexType portNum) const
void addCallPort(InputSuccessConditionPort *callPort)
Register an input port.
Svc::InputComDataWithContextPort * get_dataReturnIn_InputPort(FwIndexType portNum)
Fw::InputSuccessConditionPort * get_comStatusIn_InputPort(FwIndexType portNum)
Svc::InputComDataWithContextPort * get_dataIn_InputPort(FwIndexType portNum)
void addCallPort(InputComDataWithContextPort *callPort)
Register an input port.
void init()
Object initializer.
SerializeStatus
forward declaration for string
void addCallPort(InputBufferGetPort *callPort)
Register an input port.
void set_dataOut_OutputPort(FwIndexType portNum, Svc::InputComDataWithContextPort *port)
Connect port to dataOut[portNum].
Fw::Buffer bufferAllocate_out(FwIndexType portNum, FwSizeType size) const
Invoke output port bufferAllocate.
FwIdType FwEventIdType
The type of an event identifier.
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects) ...
void init()
Initialization function.
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
void dataReturnOut_out(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context) const
Invoke output port dataReturnOut.
void set_bufferDeallocate_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to bufferDeallocate[portNum].
void invoke(Fw::Buffer &fwBuffer) const
Invoke a port connection.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum) const
virtual ~FprimeFramerComponentBase()
Destroy FprimeFramerComponentBase object.
void comStatusOut_out(FwIndexType portNum, Fw::Success &condition) const
Invoke output port comStatusOut.
void addCallPort(InputBufferSendPort *callPort)
Register an input port.
void invoke(Fw::Time &time) const
Invoke a port connection.
void set_bufferAllocate_OutputPort(FwIndexType portNum, Fw::InputBufferGetPort *port)
Connect port to bufferAllocate[portNum].
static constexpr FwIndexType getNum_dataReturnIn_InputPorts()
bool isConnected_logOut_OutputPort(FwIndexType portNum) const
void invoke(Fw::Success &condition) const
Invoke a port connection.
void invoke(Fw::Buffer &data, const ComCfg::FrameContext &context) const
Invoke a port connection.
virtual void dataReturnIn_handler(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)=0
Handler for input port dataReturnIn.
A serious but recoverable event.
void init()
Initialization function.
static constexpr FwIndexType getNum_comStatusOut_OutputPorts()
const char * toChar() const
Convert to a C-style char*.
Enum representing event severity.
bool isConnected_bufferAllocate_OutputPort(FwIndexType portNum) const
void dataReturnIn_handlerBase(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)
Handler base-class function for input port dataReturnIn.
static constexpr FwIndexType getNum_bufferAllocate_OutputPorts()
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
void init()
Initialization function.
Throttle reset count for NoBufferAvailable.
void set_dataReturnOut_OutputPort(FwIndexType portNum, Svc::InputComDataWithContextPort *port)
Connect port to dataReturnOut[portNum].
Fw::Buffer invoke(FwSizeType size) const
void init()
Initialization function.
void init()
Initialization function.
No buffer was available to hold the frame, which was dropped.
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port connection.
FprimeFramerComponentBase(const char *compName="")
Construct FprimeFramerComponentBase object.
PlatformIndexType FwIndexType
static constexpr FwIndexType getNum_dataOut_OutputPorts()
void addCallPort(InputLogPort *callPort)
Register an input port.
static constexpr FwIndexType getNum_bufferDeallocate_OutputPorts()
Type used to pass context info between components during framing/deframing.
void init()
Initialization function.
RateGroupDivider component implementation.
virtual void dataIn_handler(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)=0
Handler for input port dataIn.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
void bufferDeallocate_out(FwIndexType portNum, Fw::Buffer &fwBuffer) const
Invoke output port bufferDeallocate.
Implementation of malloc based allocator.
void init()
Initialization function.
bool isConnected_comStatusOut_OutputPort(FwIndexType portNum) const
static constexpr FwIndexType getNum_dataIn_InputPorts()