9 #if FW_ENABLE_TEXT_LOGGING 19 SEQDONEIN_CMDRESPONSE,
37 class ComponentIpcSerializableBuffer :
47 MAX_DATA_SIZE =
sizeof(BuffUnion),
49 SERIALIZATION_SIZE = DATA_OFFSET + MAX_DATA_SIZE
53 return sizeof(m_buff);
60 const U8* getBuffAddr()
const {
66 U8 m_buff[SERIALIZATION_SIZE];
90 this->m_cmdIn_InputPort[port].
init();
95 this->m_cmdIn_InputPort[port].
setPortNum(port);
97 #if FW_OBJECT_NAMES == 1 101 this->m_objName.toChar(),
104 this->m_cmdIn_InputPort[port].setObjName(portName.
toChar());
114 this->m_seqDoneIn_InputPort[port].
init();
119 this->m_seqDoneIn_InputPort[port].
setPortNum(port);
121 #if FW_OBJECT_NAMES == 1 125 this->m_objName.toChar(),
128 this->m_seqDoneIn_InputPort[port].setObjName(portName.
toChar());
138 this->m_seqRunIn_InputPort[port].
init();
143 this->m_seqRunIn_InputPort[port].
setPortNum(port);
145 #if FW_OBJECT_NAMES == 1 149 this->m_objName.toChar(),
152 this->m_seqRunIn_InputPort[port].setObjName(portName.
toChar());
162 this->m_seqStartIn_InputPort[port].
init();
167 this->m_seqStartIn_InputPort[port].
setPortNum(port);
169 #if FW_OBJECT_NAMES == 1 173 this->m_objName.toChar(),
176 this->m_seqStartIn_InputPort[port].setObjName(portName.
toChar());
186 this->m_cmdRegOut_OutputPort[port].
init();
188 #if FW_OBJECT_NAMES == 1 192 this->m_objName.toChar(),
195 this->m_cmdRegOut_OutputPort[port].setObjName(portName.
toChar());
205 this->m_cmdResponseOut_OutputPort[port].
init();
207 #if FW_OBJECT_NAMES == 1 211 this->m_objName.toChar(),
214 this->m_cmdResponseOut_OutputPort[port].setObjName(portName.
toChar());
224 this->m_logOut_OutputPort[port].
init();
226 #if FW_OBJECT_NAMES == 1 230 this->m_objName.toChar(),
233 this->m_logOut_OutputPort[port].setObjName(portName.
toChar());
237 #if FW_ENABLE_TEXT_LOGGING == 1 241 port < static_cast<FwIndexType>(this->getNum_logTextOut_OutputPorts());
244 this->m_logTextOut_OutputPort[port].
init();
246 #if FW_OBJECT_NAMES == 1 250 this->m_objName.toChar(),
253 this->m_logTextOut_OutputPort[port].setObjName(portName.
toChar());
264 this->m_timeCaller_OutputPort[port].
init();
266 #if FW_OBJECT_NAMES == 1 270 this->m_objName.toChar(),
273 this->m_timeCaller_OutputPort[port].setObjName(portName.
toChar());
283 this->m_tlmOut_OutputPort[port].
init();
285 #if FW_OBJECT_NAMES == 1 289 this->m_objName.toChar(),
292 this->m_tlmOut_OutputPort[port].setObjName(portName.
toChar());
302 this->m_seqRunOut_OutputPort[port].
init();
304 #if FW_OBJECT_NAMES == 1 308 this->m_objName.toChar(),
311 this->m_seqRunOut_OutputPort[port].setObjName(portName.
toChar());
318 static_cast<FwSizeType>(ComponentIpcSerializableBuffer::SERIALIZATION_SIZE)
322 static_cast<FwAssertArgType>(qStat)
335 static_cast<FwAssertArgType>(portNum)
338 return &this->m_cmdIn_InputPort[portNum];
350 static_cast<FwAssertArgType>(portNum)
353 return &this->m_seqDoneIn_InputPort[portNum];
361 static_cast<FwAssertArgType>(portNum)
364 return &this->m_seqRunIn_InputPort[portNum];
372 static_cast<FwAssertArgType>(portNum)
375 return &this->m_seqStartIn_InputPort[portNum];
390 static_cast<FwAssertArgType>(portNum)
393 this->m_cmdRegOut_OutputPort[portNum].
addCallPort(port);
404 static_cast<FwAssertArgType>(portNum)
407 this->m_cmdResponseOut_OutputPort[portNum].
addCallPort(port);
418 static_cast<FwAssertArgType>(portNum)
421 this->m_logOut_OutputPort[portNum].
addCallPort(port);
424 #if FW_ENABLE_TEXT_LOGGING == 1 426 void SeqDispatcherComponentBase ::
427 set_logTextOut_OutputPort(
433 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
434 static_cast<FwAssertArgType>(portNum)
437 this->m_logTextOut_OutputPort[portNum].addCallPort(port);
450 static_cast<FwAssertArgType>(portNum)
453 this->m_timeCaller_OutputPort[portNum].
addCallPort(port);
464 static_cast<FwAssertArgType>(portNum)
467 this->m_tlmOut_OutputPort[portNum].
addCallPort(port);
482 static_cast<FwAssertArgType>(portNum)
485 this->m_seqRunOut_OutputPort[portNum].
addCallPort(port);
488 #if FW_PORT_SERIALIZATION 497 Fw::InputSerializePort* port
502 static_cast<FwAssertArgType>(portNum)
505 this->m_cmdRegOut_OutputPort[portNum].registerSerialPort(port);
511 Fw::InputSerializePort* port
516 static_cast<FwAssertArgType>(portNum)
519 this->m_cmdResponseOut_OutputPort[portNum].registerSerialPort(port);
525 Fw::InputSerializePort* port
530 static_cast<FwAssertArgType>(portNum)
533 this->m_logOut_OutputPort[portNum].registerSerialPort(port);
536 #if FW_ENABLE_TEXT_LOGGING == 1 538 void SeqDispatcherComponentBase ::
539 set_logTextOut_OutputPort(
541 Fw::InputSerializePort* port
545 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
546 static_cast<FwAssertArgType>(portNum)
549 this->m_logTextOut_OutputPort[portNum].registerSerialPort(port);
557 Fw::InputSerializePort* port
562 static_cast<FwAssertArgType>(portNum)
565 this->m_timeCaller_OutputPort[portNum].registerSerialPort(port);
571 Fw::InputSerializePort* port
576 static_cast<FwAssertArgType>(portNum)
579 this->m_tlmOut_OutputPort[portNum].registerSerialPort(port);
584 #if FW_PORT_SERIALIZATION 593 Fw::InputSerializePort* port
598 static_cast<FwAssertArgType>(portNum)
601 this->m_seqRunOut_OutputPort[portNum].registerSerialPort(port);
613 FW_ASSERT(this->m_cmdRegOut_OutputPort[0].isConnected());
615 this->m_cmdRegOut_OutputPort[0].
invoke(
619 this->m_cmdRegOut_OutputPort[0].
invoke(
630 Fw::ActiveComponentBase(compName)
650 static_cast<FwAssertArgType>(portNum)
653 return this->m_cmdRegOut_OutputPort[portNum].
isConnected();
661 static_cast<FwAssertArgType>(portNum)
664 return this->m_cmdResponseOut_OutputPort[portNum].
isConnected();
672 static_cast<FwAssertArgType>(portNum)
675 return this->m_logOut_OutputPort[portNum].
isConnected();
678 #if FW_ENABLE_TEXT_LOGGING == 1 680 bool SeqDispatcherComponentBase ::
681 isConnected_logTextOut_OutputPort(
FwIndexType portNum)
684 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
685 static_cast<FwAssertArgType>(portNum)
688 return this->m_logTextOut_OutputPort[portNum].isConnected();
698 static_cast<FwAssertArgType>(portNum)
701 return this->m_timeCaller_OutputPort[portNum].
isConnected();
709 static_cast<FwAssertArgType>(portNum)
712 return this->m_tlmOut_OutputPort[portNum].
isConnected();
724 static_cast<FwAssertArgType>(portNum)
727 return this->m_seqRunOut_OutputPort[portNum].
isConnected();
747 static_cast<FwAssertArgType>(portNum)
757 ComponentIpcSerializableBuffer msg;
761 _status = msg.serializeFrom(
762 static_cast<FwEnumStoreType>(SEQDONEIN_CMDRESPONSE)
766 static_cast<FwAssertArgType>(_status)
770 _status = msg.serializeFrom(portNum);
773 static_cast<FwAssertArgType>(_status)
777 _status = msg.serializeFrom(opCode);
780 static_cast<FwAssertArgType>(_status)
784 _status = msg.serializeFrom(cmdSeq);
787 static_cast<FwAssertArgType>(_status)
791 _status = msg.serializeFrom(response);
794 static_cast<FwAssertArgType>(_status)
803 static_cast<FwAssertArgType>(qStatus)
816 static_cast<FwAssertArgType>(portNum)
824 ComponentIpcSerializableBuffer msg;
828 _status = msg.serializeFrom(
829 static_cast<FwEnumStoreType>(SEQRUNIN_CMDSEQIN)
833 static_cast<FwAssertArgType>(_status)
837 _status = msg.serializeFrom(portNum);
840 static_cast<FwAssertArgType>(_status)
847 static_cast<FwAssertArgType>(_status)
856 static_cast<FwAssertArgType>(qStatus)
869 static_cast<FwAssertArgType>(portNum)
877 ComponentIpcSerializableBuffer msg;
881 _status = msg.serializeFrom(
882 static_cast<FwEnumStoreType>(SEQSTARTIN_CMDSEQIN)
886 static_cast<FwAssertArgType>(_status)
890 _status = msg.serializeFrom(portNum);
893 static_cast<FwAssertArgType>(_status)
900 static_cast<FwAssertArgType>(_status)
909 static_cast<FwAssertArgType>(qStatus)
962 static_cast<FwAssertArgType>(portNum)
966 this->m_seqRunOut_OutputPort[portNum].isConnected(),
967 static_cast<FwAssertArgType>(portNum)
969 this->m_seqRunOut_OutputPort[portNum].
invoke(
985 FW_ASSERT(this->m_cmdResponseOut_OutputPort[0].isConnected());
986 this->m_cmdResponseOut_OutputPort[0].
invoke(opCode, cmdSeq, response);
1007 ComponentIpcSerializableBuffer msg;
1011 _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_RUN));
1014 static_cast<FwAssertArgType>(_status)
1020 _status = msg.serializeFrom(port);
1023 static_cast<FwAssertArgType>(_status)
1026 _status = msg.serializeFrom(opCode);
1029 static_cast<FwAssertArgType>(_status)
1032 _status = msg.serializeFrom(cmdSeq);
1035 static_cast<FwAssertArgType>(_status)
1038 _status = msg.serializeFrom(args);
1041 static_cast<FwAssertArgType>(_status)
1050 static_cast<FwAssertArgType>(qStatus)
1066 ComponentIpcSerializableBuffer msg;
1070 _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_LOG_STATUS));
1073 static_cast<FwAssertArgType>(_status)
1079 _status = msg.serializeFrom(port);
1082 static_cast<FwAssertArgType>(_status)
1085 _status = msg.serializeFrom(opCode);
1088 static_cast<FwAssertArgType>(_status)
1091 _status = msg.serializeFrom(cmdSeq);
1094 static_cast<FwAssertArgType>(_status)
1097 _status = msg.serializeFrom(args);
1100 static_cast<FwAssertArgType>(_status)
1109 static_cast<FwAssertArgType>(qStatus)
1152 if (this->m_timeCaller_OutputPort[0].isConnected()) {
1153 this->m_timeCaller_OutputPort[0].
invoke(_logTime);
1161 if (this->m_logOut_OutputPort[0].isConnected()) {
1165 #if FW_AMPCS_COMPATIBLE 1170 static_cast<FwAssertArgType>(_status)
1174 #if FW_AMPCS_COMPATIBLE 1177 static_cast<U8>(
sizeof(U16))
1181 static_cast<FwAssertArgType>(_status)
1187 static_cast<FwAssertArgType>(_status)
1190 this->m_logOut_OutputPort[0].
invoke(
1199 #if FW_ENABLE_TEXT_LOGGING 1200 if (this->m_logTextOut_OutputPort[0].isConnected()) {
1201 #if FW_OBJECT_NAMES == 1 1202 const char* _formatString =
1203 "(%s) %s: Invalid sequence index %" PRIu16
"";
1205 const char* _formatString =
1206 "%s: Invalid sequence index %" PRIu16
"";
1213 this->m_objName.toChar(),
1215 "InvalidSequencer ",
1219 this->m_logTextOut_OutputPort[0].invoke(
1234 if (this->m_timeCaller_OutputPort[0].isConnected()) {
1235 this->m_timeCaller_OutputPort[0].
invoke(_logTime);
1243 if (this->m_logOut_OutputPort[0].isConnected()) {
1246 #if FW_AMPCS_COMPATIBLE 1252 static_cast<FwAssertArgType>(_status)
1256 this->m_logOut_OutputPort[0].
invoke(
1265 #if FW_ENABLE_TEXT_LOGGING 1266 if (this->m_logTextOut_OutputPort[0].isConnected()) {
1267 #if FW_OBJECT_NAMES == 1 1268 const char* _formatString =
1269 "(%s) %s: No available cmd sequencers to dispatch a sequence to";
1271 const char* _formatString =
1272 "%s: No available cmd sequencers to dispatch a sequence to";
1279 this->m_objName.toChar(),
1281 "NoAvailableSequencers " 1284 this->m_logTextOut_OutputPort[0].invoke(
1299 if (this->m_timeCaller_OutputPort[0].isConnected()) {
1300 this->m_timeCaller_OutputPort[0].
invoke(_logTime);
1308 if (this->m_logOut_OutputPort[0].isConnected()) {
1312 #if FW_AMPCS_COMPATIBLE 1317 static_cast<FwAssertArgType>(_status)
1321 #if FW_AMPCS_COMPATIBLE 1324 static_cast<U8>(
sizeof(U16))
1328 static_cast<FwAssertArgType>(_status)
1334 static_cast<FwAssertArgType>(_status)
1337 this->m_logOut_OutputPort[0].
invoke(
1346 #if FW_ENABLE_TEXT_LOGGING 1347 if (this->m_logTextOut_OutputPort[0].isConnected()) {
1348 #if FW_OBJECT_NAMES == 1 1349 const char* _formatString =
1350 "(%s) %s: Sequencer %" PRIu16
" completed a sequence with no matching start notification";
1352 const char* _formatString =
1353 "%s: Sequencer %" PRIu16
" completed a sequence with no matching start notification";
1360 this->m_objName.toChar(),
1362 "UnknownSequenceFinished ",
1366 this->m_logTextOut_OutputPort[0].invoke(
1385 if (this->m_timeCaller_OutputPort[0].isConnected()) {
1386 this->m_timeCaller_OutputPort[0].
invoke(_logTime);
1394 if (this->m_logOut_OutputPort[0].isConnected()) {
1398 #if FW_AMPCS_COMPATIBLE 1403 static_cast<FwAssertArgType>(_status)
1407 #if FW_AMPCS_COMPATIBLE 1410 static_cast<U8>(
sizeof(U16))
1414 static_cast<FwAssertArgType>(_status)
1420 static_cast<FwAssertArgType>(_status)
1426 static_cast<FwAssertArgType>(_status)
1432 static_cast<FwAssertArgType>(_status)
1435 this->m_logOut_OutputPort[0].
invoke(
1444 #if FW_ENABLE_TEXT_LOGGING 1445 if (this->m_logTextOut_OutputPort[0].isConnected()) {
1446 #if FW_OBJECT_NAMES == 1 1447 const char* _formatString =
1448 "(%s) %s: Sequencer %" PRIu16
" started a sequence %s while still running %s";
1450 const char* _formatString =
1451 "%s: Sequencer %" PRIu16
" started a sequence %s while still running %s";
1458 this->m_objName.toChar(),
1460 "ConflictingSequenceStarted ",
1463 sequenceInInternalState.
toChar()
1466 this->m_logTextOut_OutputPort[0].invoke(
1484 if (this->m_timeCaller_OutputPort[0].isConnected()) {
1485 this->m_timeCaller_OutputPort[0].
invoke(_logTime);
1493 if (this->m_logOut_OutputPort[0].isConnected()) {
1497 #if FW_AMPCS_COMPATIBLE 1502 static_cast<FwAssertArgType>(_status)
1506 #if FW_AMPCS_COMPATIBLE 1509 static_cast<U8>(
sizeof(U16))
1513 static_cast<FwAssertArgType>(_status)
1519 static_cast<FwAssertArgType>(_status)
1525 static_cast<FwAssertArgType>(_status)
1528 this->m_logOut_OutputPort[0].
invoke(
1537 #if FW_ENABLE_TEXT_LOGGING 1538 if (this->m_logTextOut_OutputPort[0].isConnected()) {
1539 #if FW_OBJECT_NAMES == 1 1540 const char* _formatString =
1541 "(%s) %s: Sequencer %" PRIu16
" was externally commanded to start a sequence %s";
1543 const char* _formatString =
1544 "%s: Sequencer %" PRIu16
" was externally commanded to start a sequence %s";
1551 this->m_objName.toChar(),
1553 "UnexpectedSequenceStarted ",
1558 this->m_logTextOut_OutputPort[0].invoke(
1577 if (this->m_timeCaller_OutputPort[0].isConnected()) {
1578 this->m_timeCaller_OutputPort[0].
invoke(_logTime);
1586 if (this->m_logOut_OutputPort[0].isConnected()) {
1590 #if FW_AMPCS_COMPATIBLE 1595 static_cast<FwAssertArgType>(_status)
1599 #if FW_AMPCS_COMPATIBLE 1602 static_cast<U8>(
sizeof(U16))
1606 static_cast<FwAssertArgType>(_status)
1612 static_cast<FwAssertArgType>(_status)
1615 #if FW_AMPCS_COMPATIBLE 1622 static_cast<FwAssertArgType>(_status)
1628 static_cast<FwAssertArgType>(_status)
1634 static_cast<FwAssertArgType>(_status)
1637 this->m_logOut_OutputPort[0].
invoke(
1646 #if FW_ENABLE_TEXT_LOGGING 1647 if (this->m_logTextOut_OutputPort[0].isConnected()) {
1648 #if FW_OBJECT_NAMES == 1 1649 const char* _formatString =
1650 "(%s) %s: Sequencer %" PRIu16
" with state %s is running file %s";
1652 const char* _formatString =
1653 "%s: Sequencer %" PRIu16
" with state %s is running file %s";
1657 state.toString(stateStr);
1663 this->m_objName.toChar(),
1665 "LogSequencerStatus ",
1671 this->m_logTextOut_OutputPort[0].invoke(
1691 if (this->m_tlmOut_OutputPort[0].isConnected()) {
1693 this->m_timeCaller_OutputPort[0].isConnected() &&
1696 this->m_timeCaller_OutputPort[0].
invoke(_tlmTime);
1703 static_cast<FwAssertArgType>(_stat)
1710 this->m_tlmOut_OutputPort[0].
invoke(
1724 if (this->m_tlmOut_OutputPort[0].isConnected()) {
1726 this->m_timeCaller_OutputPort[0].isConnected() &&
1729 this->m_timeCaller_OutputPort[0].
invoke(_tlmTime);
1736 static_cast<FwAssertArgType>(_stat)
1743 this->m_tlmOut_OutputPort[0].
invoke(
1757 if (this->m_tlmOut_OutputPort[0].isConnected()) {
1759 this->m_timeCaller_OutputPort[0].isConnected() &&
1762 this->m_timeCaller_OutputPort[0].
invoke(_tlmTime);
1769 static_cast<FwAssertArgType>(_stat)
1776 this->m_tlmOut_OutputPort[0].
invoke(
1791 if (this->m_timeCaller_OutputPort[0].isConnected()) {
1793 this->m_timeCaller_OutputPort[0].
invoke(_time);
1808 ComponentIpcSerializableBuffer _msg;
1818 static_cast<FwAssertArgType>(_msgStatus)
1828 static_cast<FwAssertArgType>(_deserStatus)
1831 MsgTypeEnum _msgType =
static_cast<MsgTypeEnum
>(_desMsg);
1833 if (_msgType == SEQDISPATCHER_COMPONENT_EXIT) {
1838 _deserStatus = _msg.deserializeTo(portNum);
1841 static_cast<FwAssertArgType>(_deserStatus)
1846 case SEQDONEIN_CMDRESPONSE: {
1849 _deserStatus = _msg.deserializeTo(opCode);
1852 static_cast<FwAssertArgType>(_deserStatus)
1857 _deserStatus = _msg.deserializeTo(cmdSeq);
1860 static_cast<FwAssertArgType>(_deserStatus)
1865 _deserStatus = _msg.deserializeTo(response);
1868 static_cast<FwAssertArgType>(_deserStatus)
1882 case SEQRUNIN_CMDSEQIN: {
1885 Fw::ExternalString filename(__fprime_ac_filename_buffer,
sizeof __fprime_ac_filename_buffer);
1886 _deserStatus = _msg.deserializeTo(filename);
1889 static_cast<FwAssertArgType>(_deserStatus)
1901 case SEQSTARTIN_CMDSEQIN: {
1904 Fw::ExternalString filename(__fprime_ac_filename_buffer,
sizeof __fprime_ac_filename_buffer);
1905 _deserStatus = _msg.deserializeTo(filename);
1908 static_cast<FwAssertArgType>(_deserStatus)
1923 _deserStatus = _msg.deserializeTo(_opCode);
1926 static_cast<FwAssertArgType>(_deserStatus)
1931 _deserStatus = _msg.deserializeTo(_cmdSeq);
1934 static_cast<FwAssertArgType>(_deserStatus)
1939 _deserStatus = _msg.deserializeTo(args);
1942 static_cast<FwAssertArgType>(_deserStatus)
1952 if (this->m_cmdResponseOut_OutputPort[0].isConnected()) {
1967 if (this->m_cmdResponseOut_OutputPort[0].isConnected()) {
1980 #if FW_CMD_CHECK_RESIDUAL 1982 if (this->m_cmdResponseOut_OutputPort[0].isConnected()) {
2001 case CMD_LOG_STATUS: {
2004 _deserStatus = _msg.deserializeTo(_opCode);
2007 static_cast<FwAssertArgType>(_deserStatus)
2012 _deserStatus = _msg.deserializeTo(_cmdSeq);
2015 static_cast<FwAssertArgType>(_deserStatus)
2020 _deserStatus = _msg.deserializeTo(args);
2023 static_cast<FwAssertArgType>(_deserStatus)
2031 #if FW_CMD_CHECK_RESIDUAL 2033 if (this->m_cmdResponseOut_OutputPort[0].isConnected()) {
2058 void SeqDispatcherComponentBase ::
2070 const U32 idBase = callComp->
getIdBase();
2071 FW_ASSERT(opCode >= idBase, static_cast<FwAssertArgType>(opCode), static_cast<FwAssertArgType>(idBase));
2074 switch (opCode - idBase) {
2076 compPtr->RUN_cmdHandlerBase(
2085 compPtr->LOG_STATUS_cmdHandlerBase(
2099 void SeqDispatcherComponentBase ::
2110 compPtr->seqDoneIn_handlerBase(
2118 void SeqDispatcherComponentBase ::
2127 compPtr->seqRunIn_handlerBase(
2133 void SeqDispatcherComponentBase ::
2142 compPtr->seqStartIn_handlerBase(
Serialization/Deserialization operation was successful.
Fw::InputCmdResponsePort * get_seqDoneIn_InputPort(FwIndexType portNum)
virtual void seqDoneIn_preMsgHook(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response)
Pre-message hook for async input port seqDoneIn.
void addCallPort(InputTimePort *callPort)
Register an input port.
void tlmWrite_sequencersAvailable(U32 arg, Fw::Time _tlmTime=Fw::Time()) const
virtual void LOG_STATUS_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command LOG_STATUS.
void tlmWrite_errorCount(U32 arg, Fw::Time _tlmTime=Fw::Time()) const
The size of the serial representation.
void seqRunIn_handlerBase(FwIndexType portNum, const Fw::StringBase &filename)
Handler base-class function for input port seqRunIn.
FwIdType FwOpcodeType
The type of a command opcode.
Channel ID for errorCount.
SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG) override
Serialize an 8-bit unsigned integer value.
FwIdType getIdBase() const
PlatformSizeType FwSizeType
Svc::InputCmdSeqInPort * get_seqRunIn_InputPort(FwIndexType portNum)
Status receive(U8 *destination, FwSizeType capacity, BlockingType blockType, FwSizeType &actualSize, FwQueuePriorityType &priority) override
receive a message from the queue through delegate
Wait or don't wait for something.
virtual void RUN_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command RUN.
Status
status returned from the queue send function
static constexpr FwIndexType getNum_seqDoneIn_InputPorts()
Svc::InputCmdSeqInPort * get_seqStartIn_InputPort(FwIndexType portNum)
const char * toChar() const
Convert to a C-style char*.
void init()
Initialization function.
bool isConnected_cmdRegOut_OutputPort(FwIndexType portNum)
virtual const CHAR * toChar() const =0
Convert to a C-style char*.
Logs via Events the state of each connected command sequencer.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum)
void init()
Initialization function.
Enum representing a command response.
void set_tlmOut_OutputPort(FwIndexType portNum, Fw::InputTlmPort *port)
Connect port to tlmOut[portNum].
void regCommands()
Register commands with the Command Dispatcher.
No time base has been established (Required)
void addCallPort(InputCmdRegPort *callPort)
Register an input port.
virtual void seqRunIn_preMsgHook(FwIndexType portNum, const Fw::StringBase &filename)
Pre-message hook for async input port seqRunIn.
void seqDoneIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response)
Handler base-class function for input port seqDoneIn.
void set_logOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to logOut[portNum].
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
Os::Queue m_queue
queue object for active component
static constexpr FwIndexType getNum_logOut_OutputPorts()
void addCallPort(InputTlmPort *callPort)
Register an input port.
void RUN_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void init()
Object initializer.
SerializeStatus
forward declaration for string
virtual void seqRunIn_handler(FwIndexType portNum, const Fw::StringBase &filename)=0
Handler for input port seqRunIn.
static constexpr FwIndexType getNum_cmdRegOut_OutputPorts()
virtual void seqStartIn_handler(FwIndexType portNum, const Fw::StringBase &filename)=0
Handler for input port seqStartIn.
virtual void LOG_STATUS_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
Message will block until space is available.
void log_WARNING_LO_UnknownSequenceFinished(U16 idx) const
Log event UnknownSequenceFinished.
virtual ~SeqDispatcherComponentBase()
Destroy SeqDispatcherComponentBase object.
FwIdType FwEventIdType
The type of an event identifier.
static constexpr FwIndexType getNum_seqRunOut_OutputPorts()
void invoke(FwOpcodeType opCode) const
Invoke a port interface.
void log_ACTIVITY_LO_LogSequencerStatus(U16 idx, Svc::SeqDispatcher_CmdSequencerState state, const Fw::StringBase &filename) const
Log event LogSequencerStatus.
Fw::InputCmdPort * get_cmdIn_InputPort(FwIndexType portNum)
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects) ...
void init()
Initialization function.
Less important informational events.
Os::Queue::Status createQueue(FwSizeType depth, FwSizeType msgSize)
Dispatches a sequence to the first available sequencer.
#define FW_MIN(a, b)
MIN macro.
A less serious but recoverable event.
void set_seqRunOut_OutputPort(FwIndexType portNum, Svc::InputCmdSeqInPort *port)
Connect port to seqRunOut[portNum].
void invoke(Fw::Time &time) const
Invoke a port interface.
Serializable::SizeType getDeserializeSizeLeft() const override
Get remaining deserialization buffer size.
const char * toChar() const
Convert to a C-style char*.
void invoke(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response) const
Invoke a port interface.
FwIdType FwChanIdType
The type of a telemetry channel identifier.
SeqDispatcherComponentBase(const char *compName="")
Construct SeqDispatcherComponentBase object.
virtual void RUN_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName, Fw::Wait block)=0
Status send(const U8 *buffer, FwSizeType size, FwQueuePriorityType priority, BlockingType blockType) override
send a message into the queue through delegate
static constexpr FwIndexType getNum_cmdIn_InputPorts()
static constexpr FwIndexType getNum_cmdResponseOut_OutputPorts()
void resetDeser() override
Reset deserialization pointer to beginning of buffer.
A string backed by an external buffer.
A serious but recoverable event.
Errors dispatching messages.
void log_WARNING_LO_UnexpectedSequenceStarted(U16 idx, const Fw::StringBase &newSequence) const
Log event UnexpectedSequenceStarted.
void invoke(FwChanIdType id, Fw::Time &timeTag, Fw::TlmBuffer &val) const
Invoke a port interface.
void invoke(const Fw::StringBase &filename) const
Invoke a port interface.
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
void init()
Initialization function.
bool isConnected_logOut_OutputPort(FwIndexType portNum)
uint8_t U8
8-bit unsigned integer
Command failed to deserialize.
void log_WARNING_HI_NoAvailableSequencers() const
Log event NoAvailableSequencers.
void seqStartIn_handlerBase(FwIndexType portNum, const Fw::StringBase &filename)
Handler base-class function for input port seqStartIn.
PlatformQueuePriorityType FwQueuePriorityType
The type of queue priorities used.
void seqRunOut_out(FwIndexType portNum, const Fw::StringBase &filename)
Invoke output port seqRunOut.
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port interface.
Channel ID for dispatchedCount.
bool isConnected_seqRunOut_OutputPort(FwIndexType portNum)
A message was sent requesting an exit of the loop.
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum)
PlatformIndexType FwIndexType
bool isConnected_tlmOut_OutputPort(FwIndexType portNum)
void addCallPort(InputLogPort *callPort)
Register an input port.
void addCallPort(InputCmdSeqInPort *callPort)
Register an input port.
static constexpr FwIndexType getNum_tlmOut_OutputPorts()
void init()
Initialization function.
virtual void seqDoneIn_handler(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response)=0
Handler for input port seqDoneIn.
void LOG_STATUS_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
RateGroupDivider component implementation.
Channel ID for sequencersAvailable.
message sent/received okay
SerializeStatus deserializeTo(U8 &val, Endianness mode=Endianness::BIG) override
Deserialize an 8-bit unsigned integer value.
void log_WARNING_HI_InvalidSequencer(U16 idx) const
Log event InvalidSequencer.
void set_cmdRegOut_OutputPort(FwIndexType portNum, Fw::InputCmdRegPort *port)
Connect port to cmdRegOut[portNum].
message to exit active component task
static constexpr FwIndexType getNum_seqRunIn_InputPorts()
Message will return with status when space is unavailable.
Implementation of malloc based allocator.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
static constexpr SizeType BUFFER_SIZE(SizeType maxLength)
Get the size of a null-terminated string buffer.
void init()
Initialization function.
void cmdResponse_out(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdResponse response)
Emit command response.
virtual void seqStartIn_preMsgHook(FwIndexType portNum, const Fw::StringBase &filename)
Pre-message hook for async input port seqStartIn.
void log_WARNING_HI_ConflictingSequenceStarted(U16 idx, const Fw::StringBase &newSequence, const Fw::StringBase &sequenceInInternalState) const
Log event ConflictingSequenceStarted.
static constexpr FwIndexType getNum_seqStartIn_InputPorts()
void tlmWrite_dispatchedCount(U32 arg, Fw::Time _tlmTime=Fw::Time()) const
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
void addCallPort(InputCmdResponsePort *callPort)
Register an input port.
SerializeStatus serializeTo(SerialBufferBase &buffer, Endianness mode=Endianness::BIG) const override
Serialize the contents of this object to a buffer.