9 #if FW_ENABLE_TEXT_LOGGING 34 this->m_dataIn_InputPort[port].
init();
39 this->m_dataIn_InputPort[port].
setPortNum(port);
41 #if FW_OBJECT_NAMES == 1 45 this->m_objName.toChar(),
48 this->m_dataIn_InputPort[port].setObjName(portName.
toChar());
58 this->m_dataReturnIn_InputPort[port].
init();
63 this->m_dataReturnIn_InputPort[port].
setPortNum(port);
65 #if FW_OBJECT_NAMES == 1 69 this->m_objName.toChar(),
72 this->m_dataReturnIn_InputPort[port].setObjName(portName.
toChar());
82 this->m_logOut_OutputPort[port].
init();
84 #if FW_OBJECT_NAMES == 1 88 this->m_objName.toChar(),
91 this->m_logOut_OutputPort[port].setObjName(portName.
toChar());
95 #if FW_ENABLE_TEXT_LOGGING == 1 99 port < static_cast<FwIndexType>(this->getNum_logTextOut_OutputPorts());
102 this->m_logTextOut_OutputPort[port].
init();
104 #if FW_OBJECT_NAMES == 1 108 this->m_objName.toChar(),
111 this->m_logTextOut_OutputPort[port].setObjName(portName.
toChar());
122 this->m_prmGetOut_OutputPort[port].
init();
124 #if FW_OBJECT_NAMES == 1 128 this->m_objName.toChar(),
131 this->m_prmGetOut_OutputPort[port].setObjName(portName.
toChar());
141 this->m_prmSetOut_OutputPort[port].
init();
143 #if FW_OBJECT_NAMES == 1 147 this->m_objName.toChar(),
150 this->m_prmSetOut_OutputPort[port].setObjName(portName.
toChar());
160 this->m_timeCaller_OutputPort[port].
init();
162 #if FW_OBJECT_NAMES == 1 166 this->m_objName.toChar(),
169 this->m_timeCaller_OutputPort[port].setObjName(portName.
toChar());
179 this->m_tlmOut_OutputPort[port].
init();
181 #if FW_OBJECT_NAMES == 1 185 this->m_objName.toChar(),
188 this->m_tlmOut_OutputPort[port].setObjName(portName.
toChar());
198 this->m_dataOut_OutputPort[port].
init();
200 #if FW_OBJECT_NAMES == 1 204 this->m_objName.toChar(),
207 this->m_dataOut_OutputPort[port].setObjName(portName.
toChar());
217 this->m_dataReturnOut_OutputPort[port].
init();
219 #if FW_OBJECT_NAMES == 1 223 this->m_objName.toChar(),
226 this->m_dataReturnOut_OutputPort[port].setObjName(portName.
toChar());
236 this->m_errorNotify_OutputPort[port].
init();
238 #if FW_OBJECT_NAMES == 1 242 this->m_objName.toChar(),
245 this->m_errorNotify_OutputPort[port].setObjName(portName.
toChar());
255 this->m_validateApidSeqCount_OutputPort[port].
init();
257 #if FW_OBJECT_NAMES == 1 261 this->m_objName.toChar(),
264 this->m_validateApidSeqCount_OutputPort[port].setObjName(portName.
toChar());
278 static_cast<FwAssertArgType>(portNum)
281 return &this->m_dataIn_InputPort[portNum];
289 static_cast<FwAssertArgType>(portNum)
292 return &this->m_dataReturnIn_InputPort[portNum];
307 static_cast<FwAssertArgType>(portNum)
310 this->m_logOut_OutputPort[portNum].
addCallPort(port);
313 #if FW_ENABLE_TEXT_LOGGING == 1 315 void SpacePacketDeframerComponentBase ::
316 set_logTextOut_OutputPort(
322 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
323 static_cast<FwAssertArgType>(portNum)
326 this->m_logTextOut_OutputPort[portNum].addCallPort(port);
339 static_cast<FwAssertArgType>(portNum)
342 this->m_prmGetOut_OutputPort[portNum].
addCallPort(port);
353 static_cast<FwAssertArgType>(portNum)
356 this->m_prmSetOut_OutputPort[portNum].
addCallPort(port);
367 static_cast<FwAssertArgType>(portNum)
370 this->m_timeCaller_OutputPort[portNum].
addCallPort(port);
381 static_cast<FwAssertArgType>(portNum)
384 this->m_tlmOut_OutputPort[portNum].
addCallPort(port);
399 static_cast<FwAssertArgType>(portNum)
402 this->m_dataOut_OutputPort[portNum].
addCallPort(port);
413 static_cast<FwAssertArgType>(portNum)
416 this->m_dataReturnOut_OutputPort[portNum].
addCallPort(port);
427 static_cast<FwAssertArgType>(portNum)
430 this->m_errorNotify_OutputPort[portNum].
addCallPort(port);
441 static_cast<FwAssertArgType>(portNum)
444 this->m_validateApidSeqCount_OutputPort[portNum].
addCallPort(port);
447 #if FW_PORT_SERIALIZATION 456 Fw::InputSerializePort* port
461 static_cast<FwAssertArgType>(portNum)
464 this->m_logOut_OutputPort[portNum].registerSerialPort(port);
467 #if FW_ENABLE_TEXT_LOGGING == 1 469 void SpacePacketDeframerComponentBase ::
470 set_logTextOut_OutputPort(
472 Fw::InputSerializePort* port
476 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
477 static_cast<FwAssertArgType>(portNum)
480 this->m_logTextOut_OutputPort[portNum].registerSerialPort(port);
488 Fw::InputSerializePort* port
493 static_cast<FwAssertArgType>(portNum)
496 this->m_prmSetOut_OutputPort[portNum].registerSerialPort(port);
502 Fw::InputSerializePort* port
507 static_cast<FwAssertArgType>(portNum)
510 this->m_timeCaller_OutputPort[portNum].registerSerialPort(port);
516 Fw::InputSerializePort* port
521 static_cast<FwAssertArgType>(portNum)
524 this->m_tlmOut_OutputPort[portNum].registerSerialPort(port);
529 #if FW_PORT_SERIALIZATION 538 Fw::InputSerializePort* port
543 static_cast<FwAssertArgType>(portNum)
546 this->m_dataOut_OutputPort[portNum].registerSerialPort(port);
552 Fw::InputSerializePort* port
557 static_cast<FwAssertArgType>(portNum)
560 this->m_dataReturnOut_OutputPort[portNum].registerSerialPort(port);
566 Fw::InputSerializePort* port
571 static_cast<FwAssertArgType>(portNum)
574 this->m_errorNotify_OutputPort[portNum].registerSerialPort(port);
585 Fw::PassiveComponentBase(compName)
605 static_cast<FwAssertArgType>(portNum)
608 return this->m_logOut_OutputPort[portNum].
isConnected();
611 #if FW_ENABLE_TEXT_LOGGING == 1 613 bool SpacePacketDeframerComponentBase ::
614 isConnected_logTextOut_OutputPort(
FwIndexType portNum)
617 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
618 static_cast<FwAssertArgType>(portNum)
621 return this->m_logTextOut_OutputPort[portNum].isConnected();
631 static_cast<FwAssertArgType>(portNum)
634 return this->m_prmGetOut_OutputPort[portNum].
isConnected();
642 static_cast<FwAssertArgType>(portNum)
645 return this->m_prmSetOut_OutputPort[portNum].
isConnected();
653 static_cast<FwAssertArgType>(portNum)
656 return this->m_timeCaller_OutputPort[portNum].
isConnected();
664 static_cast<FwAssertArgType>(portNum)
667 return this->m_tlmOut_OutputPort[portNum].
isConnected();
679 static_cast<FwAssertArgType>(portNum)
682 return this->m_dataOut_OutputPort[portNum].
isConnected();
690 static_cast<FwAssertArgType>(portNum)
693 return this->m_dataReturnOut_OutputPort[portNum].
isConnected();
701 static_cast<FwAssertArgType>(portNum)
704 return this->m_errorNotify_OutputPort[portNum].
isConnected();
712 static_cast<FwAssertArgType>(portNum)
715 return this->m_validateApidSeqCount_OutputPort[portNum].
isConnected();
734 static_cast<FwAssertArgType>(portNum)
761 static_cast<FwAssertArgType>(portNum)
785 static_cast<FwAssertArgType>(portNum)
789 this->m_dataOut_OutputPort[portNum].isConnected(),
790 static_cast<FwAssertArgType>(portNum)
792 this->m_dataOut_OutputPort[portNum].
invoke(
807 static_cast<FwAssertArgType>(portNum)
811 this->m_dataReturnOut_OutputPort[portNum].isConnected(),
812 static_cast<FwAssertArgType>(portNum)
814 this->m_dataReturnOut_OutputPort[portNum].
invoke(
828 static_cast<FwAssertArgType>(portNum)
832 this->m_errorNotify_OutputPort[portNum].isConnected(),
833 static_cast<FwAssertArgType>(portNum)
835 this->m_errorNotify_OutputPort[portNum].
invoke(
849 static_cast<FwAssertArgType>(portNum)
853 this->m_validateApidSeqCount_OutputPort[portNum].isConnected(),
854 static_cast<FwAssertArgType>(portNum)
856 return this->m_validateApidSeqCount_OutputPort[portNum].
invoke(
874 if (this->m_timeCaller_OutputPort[0].isConnected()) {
875 this->m_timeCaller_OutputPort[0].
invoke(_logTime);
883 if (this->m_logOut_OutputPort[0].isConnected()) {
887 #if FW_AMPCS_COMPATIBLE 892 static_cast<FwAssertArgType>(_status)
896 #if FW_AMPCS_COMPATIBLE 899 static_cast<U8>(
sizeof(U16))
903 static_cast<FwAssertArgType>(_status)
909 static_cast<FwAssertArgType>(_status)
912 #if FW_AMPCS_COMPATIBLE 919 static_cast<FwAssertArgType>(_status)
925 static_cast<FwAssertArgType>(_status)
928 this->m_logOut_OutputPort[0].
invoke(
937 #if FW_ENABLE_TEXT_LOGGING 938 if (this->m_logTextOut_OutputPort[0].isConnected()) {
939 #if FW_OBJECT_NAMES == 1 940 const char* _formatString =
941 "(%s) %s: Invalid length received. Header specified packet byte size of %" PRIu16
" | Actual received data length: %" PRIu64
"";
943 const char* _formatString =
944 "%s: Invalid length received. Header specified packet byte size of %" PRIu16
" | Actual received data length: %" PRIu64
"";
951 this->m_objName.toChar(),
958 this->m_logTextOut_OutputPort[0].invoke(
975 if (this->m_timeCaller_OutputPort[0].isConnected()) {
977 this->m_timeCaller_OutputPort[0].
invoke(_time);
995 this->m_guardedPortMutex.
lock();
1001 this->m_guardedPortMutex.
unLock();
1008 void SpacePacketDeframerComponentBase ::
1025 void SpacePacketDeframerComponentBase ::
1026 m_p_dataReturnIn_in(
1035 compPtr->dataReturnIn_handlerBase(
bool isConnected_validateApidSeqCount_OutputPort(FwIndexType portNum)
Serialization/Deserialization operation was successful.
void addCallPort(InputTimePort *callPort)
Register an input port.
static constexpr FwIndexType getNum_validateApidSeqCount_OutputPorts()
SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG) override
Serialize an 8-bit unsigned integer value.
Enum representing an error during framing/deframing in the CCSDS protocols.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum)
bool isConnected_dataOut_OutputPort(FwIndexType portNum)
Deframing received an invalid frame length.
FwIdType getIdBase() const
PlatformSizeType FwSizeType
void set_errorNotify_OutputPort(FwIndexType portNum, Svc::Ccsds::InputErrorNotifyPort *port)
Connect port to errorNotify[portNum].
void init()
Initialization function.
void dataReturnIn_handlerBase(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)
Handler base-class function for input port dataReturnIn.
void dataIn_handlerBase(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)
Handler base-class function for input port dataIn.
bool isConnected_dataReturnOut_OutputPort(FwIndexType portNum)
bool isConnected_tlmOut_OutputPort(FwIndexType portNum)
void unLock()
unlock the mutex and assert success
void addCallPort(InputPrmSetPort *callPort)
Register an input port.
virtual void dataReturnIn_handler(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)=0
Handler for input port dataReturnIn.
void log_WARNING_HI_InvalidLength(U16 transmitted, FwSizeType actual) const
Svc::InputComDataWithContextPort * get_dataIn_InputPort(FwIndexType portNum)
void dataReturnOut_out(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)
Invoke output port dataReturnOut.
void init()
Initialization function.
static constexpr FwIndexType getNum_dataReturnOut_OutputPorts()
void init()
Initialization function.
No time base has been established (Required)
void init()
Initialization function.
virtual void dataIn_handler(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)=0
Handler for input port dataIn.
void addCallPort(InputComDataWithContextPort *callPort)
Register an input port.
virtual void lock()
Lock the guarded mutex.
void addCallPort(InputTlmPort *callPort)
Register an input port.
void addCallPort(InputPrmGetPort *callPort)
Register an input port.
void init()
Object initializer.
Svc::InputComDataWithContextPort * get_dataReturnIn_InputPort(FwIndexType portNum)
SerializeStatus
forward declaration for string
void addCallPort(InputErrorNotifyPort *callPort)
Register an input port.
static constexpr FwIndexType getNum_prmSetOut_OutputPorts()
FwIdType FwEventIdType
The type of an event identifier.
void set_dataReturnOut_OutputPort(FwIndexType portNum, Svc::InputComDataWithContextPort *port)
Connect port to dataReturnOut[portNum].
void dataOut_out(FwIndexType portNum, Fw::Buffer &data, const ComCfg::FrameContext &context)
Invoke output port dataOut.
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects) ...
void init()
Initialization function.
static constexpr FwIndexType getNum_dataReturnIn_InputPorts()
void invoke(const Svc::Ccsds::FrameError &errorCode) const
Invoke a port interface.
void set_prmGetOut_OutputPort(FwIndexType portNum, Fw::InputPrmGetPort *port)
Connect port to prmGetOut[portNum].
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
void invoke(Fw::Time &time) const
Invoke a port interface.
const char * toChar() const
Convert to a C-style char*.
SpacePacketDeframerComponentBase(const char *compName="")
Construct SpacePacketDeframerComponentBase object.
void invoke(Fw::Buffer &data, const ComCfg::FrameContext &context) const
Invoke a port interface.
static constexpr FwIndexType getNum_prmGetOut_OutputPorts()
void set_dataOut_OutputPort(FwIndexType portNum, Svc::InputComDataWithContextPort *port)
Connect port to dataOut[portNum].
A serious but recoverable event.
void init()
Initialization function.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
virtual void unLock()
Unlock the guarded mutex.
void errorNotify_out(FwIndexType portNum, const Svc::Ccsds::FrameError &errorCode)
Invoke output port errorNotify.
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
void init()
Initialization function.
static constexpr FwIndexType getNum_tlmOut_OutputPorts()
static constexpr FwIndexType getNum_dataIn_InputPorts()
void init()
Initialization function.
static constexpr FwIndexType getNum_errorNotify_OutputPorts()
void set_prmSetOut_OutputPort(FwIndexType portNum, Fw::InputPrmSetPort *port)
Connect port to prmSetOut[portNum].
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port interface.
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
bool isConnected_prmSetOut_OutputPort(FwIndexType portNum)
bool isConnected_logOut_OutputPort(FwIndexType portNum)
void set_logOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to logOut[portNum].
PlatformIndexType FwIndexType
bool isConnected_errorNotify_OutputPort(FwIndexType portNum)
U16 invoke(const ComCfg::Apid &apid, U16 sequenceCount) const
Invoke a port interface.
void addCallPort(InputLogPort *callPort)
Register an input port.
Type used to pass context info between components during framing/deframing.
void set_validateApidSeqCount_OutputPort(FwIndexType portNum, Svc::Ccsds::InputApidSequenceCountPort *port)
Connect port to validateApidSeqCount[portNum].
RateGroupDivider component implementation.
Auto-generated base for SpacePacketDeframer component.
static constexpr FwIndexType getNum_dataOut_OutputPorts()
static constexpr FwIndexType getNum_logOut_OutputPorts()
Implementation of malloc based allocator.
void init()
Initialization function.
void set_tlmOut_OutputPort(FwIndexType portNum, Fw::InputTlmPort *port)
Connect port to tlmOut[portNum].
bool isConnected_prmGetOut_OutputPort(FwIndexType portNum)
APIDs are 11 bits in the Space Packet protocol, so we use U16. Max value 7FF.
void lock()
lock the mutex and assert success
void addCallPort(InputApidSequenceCountPort *callPort)
Register an input port.
virtual ~SpacePacketDeframerComponentBase()
Destroy SpacePacketDeframerComponentBase object.
U16 validateApidSeqCount_out(FwIndexType portNum, const ComCfg::Apid &apid, U16 sequenceCount)
Invoke output port validateApidSeqCount.