9 #if FW_ENABLE_TEXT_LOGGING 19 BUFFERSENDIN_BUFFERSEND,
41 class ComponentIpcSerializableBuffer :
51 MAX_DATA_SIZE =
sizeof(BuffUnion),
53 SERIALIZATION_SIZE = DATA_OFFSET + MAX_DATA_SIZE
56 ComponentIpcSerializableBuffer() :
Fw::LinearBufferBase(m_buff, sizeof(m_buff)) {
62 U8 m_buff[SERIALIZATION_SIZE];
80 #if !FW_DIRECT_PORT_CALLS 87 this->m_cmdIn_InputPort[port].
init();
92 this->m_cmdIn_InputPort[port].
setPortNum(port);
94 #if FW_OBJECT_NAMES == 1 98 this->m_objName.toChar(),
101 this->m_cmdIn_InputPort[port].setObjName(portName.
toChar());
106 #if !FW_DIRECT_PORT_CALLS 113 this->m_bufferSendIn_InputPort[port].
init();
118 this->m_bufferSendIn_InputPort[port].
setPortNum(port);
120 #if FW_OBJECT_NAMES == 1 124 this->m_objName.toChar(),
127 this->m_bufferSendIn_InputPort[port].setObjName(portName.
toChar());
132 #if !FW_DIRECT_PORT_CALLS 139 this->m_comIn_InputPort[port].
init();
144 this->m_comIn_InputPort[port].
setPortNum(port);
146 #if FW_OBJECT_NAMES == 1 150 this->m_objName.toChar(),
153 this->m_comIn_InputPort[port].setObjName(portName.
toChar());
158 #if !FW_DIRECT_PORT_CALLS 165 this->m_pingIn_InputPort[port].
init();
170 this->m_pingIn_InputPort[port].
setPortNum(port);
172 #if FW_OBJECT_NAMES == 1 176 this->m_objName.toChar(),
179 this->m_pingIn_InputPort[port].setObjName(portName.
toChar());
184 #if !FW_DIRECT_PORT_CALLS 191 this->m_schedIn_InputPort[port].
init();
196 this->m_schedIn_InputPort[port].
setPortNum(port);
198 #if FW_OBJECT_NAMES == 1 202 this->m_objName.toChar(),
205 this->m_schedIn_InputPort[port].setObjName(portName.
toChar());
210 #if !FW_DIRECT_PORT_CALLS 217 this->m_cmdRegOut_OutputPort[port].
init();
219 #if FW_OBJECT_NAMES == 1 223 this->m_objName.toChar(),
226 this->m_cmdRegOut_OutputPort[port].setObjName(portName.
toChar());
231 #if !FW_DIRECT_PORT_CALLS 238 this->m_cmdResponseOut_OutputPort[port].
init();
240 #if FW_OBJECT_NAMES == 1 244 this->m_objName.toChar(),
247 this->m_cmdResponseOut_OutputPort[port].setObjName(portName.
toChar());
252 #if !FW_DIRECT_PORT_CALLS 259 this->m_eventOut_OutputPort[port].
init();
261 #if FW_OBJECT_NAMES == 1 265 this->m_objName.toChar(),
268 this->m_eventOut_OutputPort[port].setObjName(portName.
toChar());
273 #if !FW_DIRECT_PORT_CALLS && FW_ENABLE_TEXT_LOGGING 277 port < static_cast<FwIndexType>(this->getNum_eventOutText_OutputPorts());
280 this->m_eventOutText_OutputPort[port].
init();
282 #if FW_OBJECT_NAMES == 1 286 this->m_objName.toChar(),
289 this->m_eventOutText_OutputPort[port].setObjName(portName.
toChar());
294 #if !FW_DIRECT_PORT_CALLS 301 this->m_timeCaller_OutputPort[port].
init();
303 #if FW_OBJECT_NAMES == 1 307 this->m_objName.toChar(),
310 this->m_timeCaller_OutputPort[port].setObjName(portName.
toChar());
315 #if !FW_DIRECT_PORT_CALLS 322 this->m_tlmOut_OutputPort[port].
init();
324 #if FW_OBJECT_NAMES == 1 328 this->m_objName.toChar(),
331 this->m_tlmOut_OutputPort[port].setObjName(portName.
toChar());
336 #if !FW_DIRECT_PORT_CALLS 343 this->m_bufferSendOut_OutputPort[port].
init();
345 #if FW_OBJECT_NAMES == 1 349 this->m_objName.toChar(),
352 this->m_bufferSendOut_OutputPort[port].setObjName(portName.
toChar());
357 #if !FW_DIRECT_PORT_CALLS 364 this->m_pingOut_OutputPort[port].
init();
366 #if FW_OBJECT_NAMES == 1 370 this->m_objName.toChar(),
373 this->m_pingOut_OutputPort[port].setObjName(portName.
toChar());
381 static_cast<FwSizeType>(ComponentIpcSerializableBuffer::SERIALIZATION_SIZE)
385 static_cast<FwAssertArgType>(qStat)
389 #if !FW_DIRECT_PORT_CALLS 400 static_cast<FwAssertArgType>(portNum)
403 return &this->m_cmdIn_InputPort[portNum];
408 #if !FW_DIRECT_PORT_CALLS 419 static_cast<FwAssertArgType>(portNum)
422 return &this->m_bufferSendIn_InputPort[portNum];
430 static_cast<FwAssertArgType>(portNum)
433 return &this->m_comIn_InputPort[portNum];
441 static_cast<FwAssertArgType>(portNum)
444 return &this->m_pingIn_InputPort[portNum];
452 static_cast<FwAssertArgType>(portNum)
455 return &this->m_schedIn_InputPort[portNum];
460 #if !FW_DIRECT_PORT_CALLS 474 static_cast<FwAssertArgType>(portNum)
477 this->m_cmdRegOut_OutputPort[portNum].
addCallPort(port);
488 static_cast<FwAssertArgType>(portNum)
491 this->m_cmdResponseOut_OutputPort[portNum].
addCallPort(port);
502 static_cast<FwAssertArgType>(portNum)
505 this->m_eventOut_OutputPort[portNum].
addCallPort(port);
508 #if FW_ENABLE_TEXT_LOGGING == 1 510 void BufferLoggerComponentBase ::
511 set_eventOutText_OutputPort(
517 (0 <= portNum) && (portNum < this->getNum_eventOutText_OutputPorts()),
518 static_cast<FwAssertArgType>(portNum)
521 this->m_eventOutText_OutputPort[portNum].addCallPort(port);
534 static_cast<FwAssertArgType>(portNum)
537 this->m_timeCaller_OutputPort[portNum].
addCallPort(port);
548 static_cast<FwAssertArgType>(portNum)
551 this->m_tlmOut_OutputPort[portNum].
addCallPort(port);
556 #if !FW_DIRECT_PORT_CALLS 570 static_cast<FwAssertArgType>(portNum)
573 this->m_bufferSendOut_OutputPort[portNum].
addCallPort(port);
584 static_cast<FwAssertArgType>(portNum)
587 this->m_pingOut_OutputPort[portNum].
addCallPort(port);
592 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION 601 Fw::InputSerializePort* port
606 static_cast<FwAssertArgType>(portNum)
609 this->m_cmdRegOut_OutputPort[portNum].registerSerialPort(port);
615 Fw::InputSerializePort* port
620 static_cast<FwAssertArgType>(portNum)
623 this->m_cmdResponseOut_OutputPort[portNum].registerSerialPort(port);
629 Fw::InputSerializePort* port
634 static_cast<FwAssertArgType>(portNum)
637 this->m_eventOut_OutputPort[portNum].registerSerialPort(port);
640 #if FW_ENABLE_TEXT_LOGGING == 1 642 void BufferLoggerComponentBase ::
643 set_eventOutText_OutputPort(
645 Fw::InputSerializePort* port
649 (0 <= portNum) && (portNum < this->getNum_eventOutText_OutputPorts()),
650 static_cast<FwAssertArgType>(portNum)
653 this->m_eventOutText_OutputPort[portNum].registerSerialPort(port);
661 Fw::InputSerializePort* port
666 static_cast<FwAssertArgType>(portNum)
669 this->m_timeCaller_OutputPort[portNum].registerSerialPort(port);
675 Fw::InputSerializePort* port
680 static_cast<FwAssertArgType>(portNum)
683 this->m_tlmOut_OutputPort[portNum].registerSerialPort(port);
688 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION 697 Fw::InputSerializePort* port
702 static_cast<FwAssertArgType>(portNum)
705 this->m_bufferSendOut_OutputPort[portNum].registerSerialPort(port);
711 Fw::InputSerializePort* port
716 static_cast<FwAssertArgType>(portNum)
719 this->m_pingOut_OutputPort[portNum].registerSerialPort(port);
760 Fw::ActiveComponentBase(compName)
771 #if !FW_DIRECT_PORT_CALLS 782 static_cast<FwAssertArgType>(portNum)
785 return this->m_cmdRegOut_OutputPort[portNum].
isConnected();
793 static_cast<FwAssertArgType>(portNum)
796 return this->m_cmdResponseOut_OutputPort[portNum].
isConnected();
804 static_cast<FwAssertArgType>(portNum)
807 return this->m_eventOut_OutputPort[portNum].
isConnected();
810 #if FW_ENABLE_TEXT_LOGGING == 1 812 bool BufferLoggerComponentBase ::
813 isConnected_eventOutText_OutputPort(
FwIndexType portNum)
const 816 (0 <= portNum) && (portNum < this->getNum_eventOutText_OutputPorts()),
817 static_cast<FwAssertArgType>(portNum)
820 return this->m_eventOutText_OutputPort[portNum].isConnected();
830 static_cast<FwAssertArgType>(portNum)
833 return this->m_timeCaller_OutputPort[portNum].
isConnected();
841 static_cast<FwAssertArgType>(portNum)
844 return this->m_tlmOut_OutputPort[portNum].
isConnected();
849 #if !FW_DIRECT_PORT_CALLS 860 static_cast<FwAssertArgType>(portNum)
863 return this->m_bufferSendOut_OutputPort[portNum].
isConnected();
871 static_cast<FwAssertArgType>(portNum)
874 return this->m_pingOut_OutputPort[portNum].
isConnected();
895 FW_ASSERT(opCode >= idBase, static_cast<FwAssertArgType>(opCode), static_cast<FwAssertArgType>(idBase));
898 switch (opCode - idBase) {
955 static_cast<FwAssertArgType>(portNum)
963 ComponentIpcSerializableBuffer msg;
967 _status = msg.serializeFrom(
968 static_cast<FwEnumStoreType>(BUFFERSENDIN_BUFFERSEND)
972 static_cast<FwAssertArgType>(_status)
976 _status = msg.serializeFrom(portNum);
979 static_cast<FwAssertArgType>(_status)
983 _status = msg.serializeFrom(fwBuffer);
986 static_cast<FwAssertArgType>(_status)
995 static_cast<FwAssertArgType>(qStatus)
1009 static_cast<FwAssertArgType>(portNum)
1018 ComponentIpcSerializableBuffer msg;
1022 _status = msg.serializeFrom(
1023 static_cast<FwEnumStoreType>(COMIN_COM)
1027 static_cast<FwAssertArgType>(_status)
1031 _status = msg.serializeFrom(portNum);
1034 static_cast<FwAssertArgType>(_status)
1038 _status = msg.serializeFrom(data);
1041 static_cast<FwAssertArgType>(_status)
1045 _status = msg.serializeFrom(context);
1048 static_cast<FwAssertArgType>(_status)
1057 static_cast<FwAssertArgType>(qStatus)
1070 static_cast<FwAssertArgType>(portNum)
1078 ComponentIpcSerializableBuffer msg;
1082 _status = msg.serializeFrom(
1083 static_cast<FwEnumStoreType>(PINGIN_PING)
1087 static_cast<FwAssertArgType>(_status)
1091 _status = msg.serializeFrom(portNum);
1094 static_cast<FwAssertArgType>(_status)
1098 _status = msg.serializeFrom(key);
1101 static_cast<FwAssertArgType>(_status)
1110 static_cast<FwAssertArgType>(qStatus)
1123 static_cast<FwAssertArgType>(portNum)
1131 ComponentIpcSerializableBuffer msg;
1135 _status = msg.serializeFrom(
1136 static_cast<FwEnumStoreType>(SCHEDIN_SCHED)
1140 static_cast<FwAssertArgType>(_status)
1144 _status = msg.serializeFrom(portNum);
1147 static_cast<FwAssertArgType>(_status)
1151 _status = msg.serializeFrom(context);
1154 static_cast<FwAssertArgType>(_status)
1163 static_cast<FwAssertArgType>(qStatus)
1212 #if !FW_DIRECT_PORT_CALLS 1226 static_cast<FwAssertArgType>(portNum)
1230 this->m_bufferSendOut_OutputPort[portNum].isConnected(),
1231 static_cast<FwAssertArgType>(portNum)
1233 this->m_bufferSendOut_OutputPort[portNum].
invoke(
1246 static_cast<FwAssertArgType>(portNum)
1250 this->m_pingOut_OutputPort[portNum].isConnected(),
1251 static_cast<FwAssertArgType>(portNum)
1253 this->m_pingOut_OutputPort[portNum].
invoke(
1272 this->cmdResponseOut_out(0, opCode, cmdSeq, response);
1293 ComponentIpcSerializableBuffer msg;
1297 _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_BL_OPENFILE));
1300 static_cast<FwAssertArgType>(_status)
1306 _status = msg.serializeFrom(port);
1309 static_cast<FwAssertArgType>(_status)
1312 _status = msg.serializeFrom(opCode);
1315 static_cast<FwAssertArgType>(_status)
1318 _status = msg.serializeFrom(cmdSeq);
1321 static_cast<FwAssertArgType>(_status)
1324 _status = msg.serializeFrom(args);
1327 static_cast<FwAssertArgType>(_status)
1336 static_cast<FwAssertArgType>(qStatus)
1352 ComponentIpcSerializableBuffer msg;
1356 _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_BL_CLOSEFILE));
1359 static_cast<FwAssertArgType>(_status)
1365 _status = msg.serializeFrom(port);
1368 static_cast<FwAssertArgType>(_status)
1371 _status = msg.serializeFrom(opCode);
1374 static_cast<FwAssertArgType>(_status)
1377 _status = msg.serializeFrom(cmdSeq);
1380 static_cast<FwAssertArgType>(_status)
1383 _status = msg.serializeFrom(args);
1386 static_cast<FwAssertArgType>(_status)
1395 static_cast<FwAssertArgType>(qStatus)
1411 ComponentIpcSerializableBuffer msg;
1415 _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_BL_SETLOGGING));
1418 static_cast<FwAssertArgType>(_status)
1424 _status = msg.serializeFrom(port);
1427 static_cast<FwAssertArgType>(_status)
1430 _status = msg.serializeFrom(opCode);
1433 static_cast<FwAssertArgType>(_status)
1436 _status = msg.serializeFrom(cmdSeq);
1439 static_cast<FwAssertArgType>(_status)
1442 _status = msg.serializeFrom(args);
1445 static_cast<FwAssertArgType>(_status)
1454 static_cast<FwAssertArgType>(qStatus)
1470 ComponentIpcSerializableBuffer msg;
1474 _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_BL_FLUSHFILE));
1477 static_cast<FwAssertArgType>(_status)
1483 _status = msg.serializeFrom(port);
1486 static_cast<FwAssertArgType>(_status)
1489 _status = msg.serializeFrom(opCode);
1492 static_cast<FwAssertArgType>(_status)
1495 _status = msg.serializeFrom(cmdSeq);
1498 static_cast<FwAssertArgType>(_status)
1501 _status = msg.serializeFrom(args);
1504 static_cast<FwAssertArgType>(_status)
1513 static_cast<FwAssertArgType>(qStatus)
1579 this->timeCaller_out(0, _logTime);
1589 #if FW_AMPCS_COMPATIBLE 1594 static_cast<FwAssertArgType>(_status)
1604 static_cast<FwAssertArgType>(_status)
1617 #if FW_ENABLE_TEXT_LOGGING 1618 if (this->isConnected_eventOutText_OutputPort(0)) {
1619 #if FW_OBJECT_NAMES == 1 1620 const char* _formatString =
1621 "(%s) %s: File %s closed";
1623 const char* _formatString =
1624 "%s: File %s closed";
1628 (void) _logString.
format(
1631 this->m_objName.toChar(),
1633 "BL_LogFileClosed ",
1637 this->eventOutText_out(
1657 this->timeCaller_out(0, _logTime);
1667 #if FW_AMPCS_COMPATIBLE 1672 static_cast<FwAssertArgType>(_status)
1676 #if FW_AMPCS_COMPATIBLE 1679 static_cast<U8>(
sizeof(U32))
1683 static_cast<FwAssertArgType>(_status)
1689 static_cast<FwAssertArgType>(_status)
1698 static_cast<FwAssertArgType>(_status)
1711 #if FW_ENABLE_TEXT_LOGGING 1712 if (this->isConnected_eventOutText_OutputPort(0)) {
1713 #if FW_OBJECT_NAMES == 1 1714 const char* _formatString =
1715 "(%s) %s: Error %" PRIu32
" opening file %s";
1717 const char* _formatString =
1718 "%s: Error %" PRIu32
" opening file %s";
1722 (void) _logString.
format(
1725 this->m_objName.toChar(),
1727 "BL_LogFileOpenError ",
1732 this->eventOutText_out(
1752 this->timeCaller_out(0, _logTime);
1762 #if FW_AMPCS_COMPATIBLE 1767 static_cast<FwAssertArgType>(_status)
1777 static_cast<FwAssertArgType>(_status)
1780 #if FW_AMPCS_COMPATIBLE 1783 static_cast<U8>(
sizeof(U32))
1787 static_cast<FwAssertArgType>(_status)
1793 static_cast<FwAssertArgType>(_status)
1806 #if FW_ENABLE_TEXT_LOGGING 1807 if (this->isConnected_eventOutText_OutputPort(0)) {
1808 #if FW_OBJECT_NAMES == 1 1809 const char* _formatString =
1810 "(%s) %s: Failed creating validation file %s with status %" PRIu32
"";
1812 const char* _formatString =
1813 "%s: Failed creating validation file %s with status %" PRIu32
"";
1817 (void) _logString.
format(
1820 this->m_objName.toChar(),
1822 "BL_LogFileValidationError ",
1827 this->eventOutText_out(
1849 this->timeCaller_out(0, _logTime);
1859 #if FW_AMPCS_COMPATIBLE 1864 static_cast<FwAssertArgType>(_status)
1868 #if FW_AMPCS_COMPATIBLE 1871 static_cast<U8>(
sizeof(U32))
1875 static_cast<FwAssertArgType>(_status)
1881 static_cast<FwAssertArgType>(_status)
1884 #if FW_AMPCS_COMPATIBLE 1887 static_cast<U8>(
sizeof(U32))
1891 static_cast<FwAssertArgType>(_status)
1897 static_cast<FwAssertArgType>(_status)
1900 #if FW_AMPCS_COMPATIBLE 1903 static_cast<U8>(
sizeof(U32))
1907 static_cast<FwAssertArgType>(_status)
1913 static_cast<FwAssertArgType>(_status)
1922 static_cast<FwAssertArgType>(_status)
1935 #if FW_ENABLE_TEXT_LOGGING 1936 if (this->isConnected_eventOutText_OutputPort(0)) {
1937 #if FW_OBJECT_NAMES == 1 1938 const char* _formatString =
1939 "(%s) %s: Error %" PRIu32
" while writing %" PRIu32
" of %" PRIu32
" bytes to %s";
1941 const char* _formatString =
1942 "%s: Error %" PRIu32
" while writing %" PRIu32
" of %" PRIu32
" bytes to %s";
1946 (void) _logString.
format(
1949 this->m_objName.toChar(),
1951 "BL_LogFileWriteError ",
1958 this->eventOutText_out(
1975 this->timeCaller_out(0, _logTime);
1984 #if FW_AMPCS_COMPATIBLE 1990 static_cast<FwAssertArgType>(_status)
2004 #if FW_ENABLE_TEXT_LOGGING 2005 if (this->isConnected_eventOutText_OutputPort(0)) {
2006 #if FW_OBJECT_NAMES == 1 2007 const char* _formatString =
2008 "(%s) %s: Buffer logger was activated";
2010 const char* _formatString =
2011 "%s: Buffer logger was activated";
2015 (void) _logString.
format(
2018 this->m_objName.toChar(),
2023 this->eventOutText_out(
2040 this->timeCaller_out(0, _logTime);
2049 #if FW_AMPCS_COMPATIBLE 2055 static_cast<FwAssertArgType>(_status)
2069 #if FW_ENABLE_TEXT_LOGGING 2070 if (this->isConnected_eventOutText_OutputPort(0)) {
2071 #if FW_OBJECT_NAMES == 1 2072 const char* _formatString =
2073 "(%s) %s: Buffer logger was deactivated";
2075 const char* _formatString =
2076 "%s: Buffer logger was deactivated";
2080 (void) _logString.
format(
2083 this->m_objName.toChar(),
2088 this->eventOutText_out(
2105 this->timeCaller_out(0, _logTime);
2114 #if FW_AMPCS_COMPATIBLE 2120 static_cast<FwAssertArgType>(_status)
2134 #if FW_ENABLE_TEXT_LOGGING 2135 if (this->isConnected_eventOutText_OutputPort(0)) {
2136 #if FW_OBJECT_NAMES == 1 2137 const char* _formatString =
2138 "(%s) %s: No log file open command";
2140 const char* _formatString =
2141 "%s: No log file open command";
2145 (void) _logString.
format(
2148 this->m_objName.toChar(),
2150 "BL_NoLogFileOpenInitError " 2153 this->eventOutText_out(
2170 this->timeCaller_out(0, _logTime);
2180 #if FW_AMPCS_COMPATIBLE 2185 static_cast<FwAssertArgType>(_status)
2189 #if FW_AMPCS_COMPATIBLE 2196 static_cast<FwAssertArgType>(_status)
2202 static_cast<FwAssertArgType>(_status)
2215 #if FW_ENABLE_TEXT_LOGGING 2216 if (this->isConnected_eventOutText_OutputPort(0)) {
2217 #if FW_OBJECT_NAMES == 1 2218 const char* _formatString =
2219 "(%s) %s: Error %s formatting log file name";
2221 const char* _formatString =
2222 "%s: Error %s formatting log file name";
2226 status.toString(statusStr);
2229 (void) _logString.
format(
2232 this->m_objName.toChar(),
2234 "BL_LogFileNameError ",
2238 this->eventOutText_out(
2265 this->timeCaller_out(0, _tlmTime);
2295 static_cast<FwAssertArgType>(_stat)
2315 this->timeCaller_out(0, _time);
2330 ComponentIpcSerializableBuffer _msg;
2340 static_cast<FwAssertArgType>(_msgStatus)
2350 static_cast<FwAssertArgType>(_deserStatus)
2353 MsgTypeEnum _msgType =
static_cast<MsgTypeEnum
>(_desMsg);
2355 if (_msgType == BUFFERLOGGER_COMPONENT_EXIT) {
2360 _deserStatus = _msg.deserializeTo(portNum);
2363 static_cast<FwAssertArgType>(_deserStatus)
2368 case BUFFERSENDIN_BUFFERSEND: {
2371 _deserStatus = _msg.deserializeTo(fwBuffer);
2374 static_cast<FwAssertArgType>(_deserStatus)
2389 _deserStatus = _msg.deserializeTo(data);
2392 static_cast<FwAssertArgType>(_deserStatus)
2397 _deserStatus = _msg.deserializeTo(context);
2400 static_cast<FwAssertArgType>(_deserStatus)
2416 _deserStatus = _msg.deserializeTo(key);
2419 static_cast<FwAssertArgType>(_deserStatus)
2431 case SCHEDIN_SCHED: {
2434 _deserStatus = _msg.deserializeTo(context);
2437 static_cast<FwAssertArgType>(_deserStatus)
2449 case CMD_BL_OPENFILE: {
2452 _deserStatus = _msg.deserializeTo(_opCode);
2455 static_cast<FwAssertArgType>(_deserStatus)
2460 _deserStatus = _msg.deserializeTo(_cmdSeq);
2463 static_cast<FwAssertArgType>(_deserStatus)
2468 _deserStatus = _msg.deserializeTo(args);
2471 static_cast<FwAssertArgType>(_deserStatus)
2494 #if FW_CMD_CHECK_RESIDUAL 2514 case CMD_BL_CLOSEFILE: {
2517 _deserStatus = _msg.deserializeTo(_opCode);
2520 static_cast<FwAssertArgType>(_deserStatus)
2525 _deserStatus = _msg.deserializeTo(_cmdSeq);
2528 static_cast<FwAssertArgType>(_deserStatus)
2533 _deserStatus = _msg.deserializeTo(args);
2536 static_cast<FwAssertArgType>(_deserStatus)
2544 #if FW_CMD_CHECK_RESIDUAL 2561 case CMD_BL_SETLOGGING: {
2564 _deserStatus = _msg.deserializeTo(_opCode);
2567 static_cast<FwAssertArgType>(_deserStatus)
2572 _deserStatus = _msg.deserializeTo(_cmdSeq);
2575 static_cast<FwAssertArgType>(_deserStatus)
2580 _deserStatus = _msg.deserializeTo(args);
2583 static_cast<FwAssertArgType>(_deserStatus)
2606 #if FW_CMD_CHECK_RESIDUAL 2626 case CMD_BL_FLUSHFILE: {
2629 _deserStatus = _msg.deserializeTo(_opCode);
2632 static_cast<FwAssertArgType>(_deserStatus)
2637 _deserStatus = _msg.deserializeTo(_cmdSeq);
2640 static_cast<FwAssertArgType>(_deserStatus)
2645 _deserStatus = _msg.deserializeTo(args);
2648 static_cast<FwAssertArgType>(_deserStatus)
2656 #if FW_CMD_CHECK_RESIDUAL 2683 void BufferLoggerComponentBase ::
2694 compPtr->cmdIn_handlerBase(
2706 void BufferLoggerComponentBase ::
2707 m_p_bufferSendIn_in(
2715 compPtr->bufferSendIn_handlerBase(
2721 void BufferLoggerComponentBase ::
2731 compPtr->comIn_handlerBase(
2738 void BufferLoggerComponentBase ::
2747 compPtr->pingIn_handlerBase(
2753 void BufferLoggerComponentBase ::
2762 compPtr->schedIn_handlerBase(
2768 #if !FW_DIRECT_PORT_CALLS 2774 void BufferLoggerComponentBase ::
2782 static_cast<FwAssertArgType>(portNum)
2786 this->m_cmdRegOut_OutputPort[portNum].isConnected(),
2787 static_cast<FwAssertArgType>(portNum)
2789 this->m_cmdRegOut_OutputPort[portNum].
invoke(
2794 void BufferLoggerComponentBase ::
2804 static_cast<FwAssertArgType>(portNum)
2808 this->m_cmdResponseOut_OutputPort[portNum].isConnected(),
2809 static_cast<FwAssertArgType>(portNum)
2811 this->m_cmdResponseOut_OutputPort[portNum].
invoke(
2818 void BufferLoggerComponentBase ::
2829 static_cast<FwAssertArgType>(portNum)
2833 this->m_eventOut_OutputPort[portNum].isConnected(),
2834 static_cast<FwAssertArgType>(portNum)
2836 this->m_eventOut_OutputPort[portNum].
invoke(
2844 #if FW_ENABLE_TEXT_LOGGING 2846 void BufferLoggerComponentBase ::
2856 (0 <= portNum) && (portNum < this->getNum_eventOutText_OutputPorts()),
2857 static_cast<FwAssertArgType>(portNum)
2861 this->m_eventOutText_OutputPort[portNum].isConnected(),
2862 static_cast<FwAssertArgType>(portNum)
2864 this->m_eventOutText_OutputPort[portNum].invoke(
2874 void BufferLoggerComponentBase ::
2882 static_cast<FwAssertArgType>(portNum)
2886 this->m_timeCaller_OutputPort[portNum].isConnected(),
2887 static_cast<FwAssertArgType>(portNum)
2889 this->m_timeCaller_OutputPort[portNum].
invoke(
2894 void BufferLoggerComponentBase ::
2904 static_cast<FwAssertArgType>(portNum)
2908 this->m_tlmOut_OutputPort[portNum].isConnected(),
2909 static_cast<FwAssertArgType>(portNum)
2911 this->m_tlmOut_OutputPort[portNum].
invoke(
Serialization/Deserialization operation was successful.
void BL_SetLogging_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
void addCallPort(InputTimePort *callPort)
Register an input port.
void regCommands()
Register commands with the Command Dispatcher.
virtual void bufferSendIn_preMsgHook(FwIndexType portNum, Fw::Buffer &fwBuffer)
Pre-message hook for async input port bufferSendIn.
static constexpr FwSizeType CAPACITY
FwIdType FwOpcodeType
The type of a command opcode.
Svc::InputSchedPort * get_schedIn_InputPort(FwIndexType portNum)
void pingOut_out(FwIndexType portNum, U32 key) const
Invoke output port pingOut.
FwIdType getIdBase() const
PlatformSizeType FwSizeType
Channel ID for BufferLogger_NumLoggedBuffers.
Status receive(U8 *destination, FwSizeType capacity, BlockingType blockType, FwSizeType &actualSize, FwQueuePriorityType &priority) override
receive a message from the queue through delegate
Buffer logger was activated.
virtual void schedIn_preMsgHook(FwIndexType portNum, U32 context)
Pre-message hook for async input port schedIn.
static constexpr FwIndexType getNum_pingIn_InputPorts()
Status
status returned from the queue send function
void set_tlmOut_OutputPort(FwIndexType portNum, Fw::InputTlmPort *port)
Connect port to tlmOut[portNum].
message to exit active component task
BYTE pingInPortSize[Svc::PingPortBuffer::CAPACITY]
SerializeStatus deserializeTo(U8 &val, Endianness mode=Endianness::BIG) override
Deserialize an 8-bit unsigned integer value.
void pingIn_handlerBase(FwIndexType portNum, U32 key)
Handler base-class function for input port pingIn.
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum) const
virtual void BL_SetLogging_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command BL_SetLogging.
static constexpr FwSizeType CAPACITY
virtual void BL_CloseFile_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command BL_CloseFile.
void invoke(U32 key) const
Invoke a port connection.
virtual const CHAR * toChar() const =0
Convert to a C-style char*.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum) const
virtual void BL_OpenFile_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command BL_OpenFile.
virtual void BL_FlushFile_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command BL_FlushFile.
virtual void bufferSendIn_handler(FwIndexType portNum, Fw::Buffer &fwBuffer)=0
Handler for input port bufferSendIn.
void BL_OpenFile_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void init()
Initialization function.
void log_DIAGNOSTIC_BL_LogFileClosed(const Fw::StringBase &file) const
Enum representing a command response.
No time base has been established (Required)
SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG) override
Serialize an 8-bit unsigned integer value.
void addCallPort(InputCmdRegPort *callPort)
Register an input port.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
Open a new log file with specified name; also resets unique file counter to 0.
Os::Queue m_queue
queue object for active component
Software diagnostic events.
void addCallPort(InputTlmPort *callPort)
Register an input port.
void bufferSendIn_handlerBase(FwIndexType portNum, Fw::Buffer &fwBuffer)
Handler base-class function for input port bufferSendIn.
void init()
Object initializer.
bool isConnected_cmdRegOut_OutputPort(FwIndexType portNum) const
SerializeStatus
forward declaration for string
virtual void comIn_handler(FwIndexType portNum, Fw::ComBuffer &data, U32 context)=0
Handler for input port comIn.
Message will block until space is available.
void log_WARNING_HI_BL_LogFileOpenError(U32 errornum, const Fw::StringBase &file) const
The Buffer Logger encountered an error formatting a log file name.
void log_ACTIVITY_LO_BL_Activated() const
void set_pingOut_OutputPort(FwIndexType portNum, Svc::InputPingPort *port)
Connect port to pingOut[portNum].
FwIdType FwEventIdType
The type of an event identifier.
virtual void comIn_preMsgHook(FwIndexType portNum, Fw::ComBuffer &data, U32 context)
Pre-message hook for async input port comIn.
static constexpr FwIndexType getNum_schedIn_InputPorts()
void invoke(FwOpcodeType opCode) const
Invoke a port connection.
static constexpr FwIndexType getNum_cmdRegOut_OutputPorts()
static constexpr FwSizeType CAPACITY
void set_bufferSendOut_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to bufferSendOut[portNum].
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) ...
static constexpr FwIndexType getNum_cmdIn_InputPorts()
void init()
Initialization function.
Less important informational events.
Os::Queue::Status createQueue(FwSizeType depth, FwSizeType msgSize)
Sets the volatile logging state.
static constexpr FwSizeType CAPACITY
#define FW_MIN(a, b)
MIN macro (deprecated in C++, use std::min)
void invoke(Fw::Buffer &fwBuffer) const
Invoke a port connection.
void init()
Initialization function.
void tlmWrite_BufferLogger_NumLoggedBuffers(U32 arg, Fw::Time _tlmTime=Fw::Time()) const
void addCallPort(InputBufferSendPort *callPort)
Register an input port.
void invoke(Fw::Time &time) const
Invoke a port connection.
virtual void BL_FlushFile_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
bool isConnected_tlmOut_OutputPort(FwIndexType portNum) const
Serializable::SizeType getDeserializeSizeLeft() const override
Get remaining deserialization buffer size.
void invoke(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response) const
Invoke a port connection.
FwIdType FwChanIdType
The type of a telemetry channel identifier.
void addCallPort(InputPingPort *callPort)
Register an input port.
Status send(const U8 *buffer, FwSizeType size, FwQueuePriorityType priority, BlockingType blockType) override
send a message into the queue through delegate
bool isConnected_bufferSendOut_OutputPort(FwIndexType portNum) const
void BL_CloseFile_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void log_WARNING_HI_BL_LogFileWriteError(U32 errornum, U32 bytesWritten, U32 bytesToWrite, const Fw::StringBase &file) const
void resetDeser() override
Reset deserialization pointer to beginning of buffer.
BufferLoggerComponentBase(const char *compName="")
Construct BufferLoggerComponentBase object.
virtual void schedIn_handler(FwIndexType portNum, U32 context)=0
Handler for input port schedIn.
void log_WARNING_HI_BL_LogFileNameError(const Fw::StringFormatStatus &status) const
A serious but recoverable event.
Errors dispatching messages.
bool isConnected_pingOut_OutputPort(FwIndexType portNum) const
void invoke(FwChanIdType id, Fw::Time &timeTag, Fw::TlmBuffer &val) const
Invoke a port connection.
The Buffer Logger encountered an error writing a validation file.
const char * toChar() const
Convert to a C-style char*.
Enum representing event severity.
Fw::InputBufferSendPort * get_bufferSendIn_InputPort(FwIndexType portNum)
void cmdIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
Handler base-class function for input port cmdIn.
Buffer logger was deactivated.
void bufferSendOut_out(FwIndexType portNum, Fw::Buffer &fwBuffer) const
Invoke output port bufferSendOut.
static constexpr FwIndexType getNum_eventOut_OutputPorts()
virtual void pingIn_preMsgHook(FwIndexType portNum, U32 key)
Pre-message hook for async input port pingIn.
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
void init()
Initialization function.
No log file open command was received by BufferLogger.
void tlmWrite(FwChanIdType id, Fw::TlmBuffer &_tlmBuff, Fw::Time _tlmTime=Fw::Time()) const
bool isConnected_eventOut_OutputPort(FwIndexType portNum) const
uint8_t U8
8-bit unsigned integer
void cmdResponse_out(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdResponse response)
Emit command response.
void log_ACTIVITY_LO_BL_Deactivated() const
Flushes the current open log file to disk; a no-op with fprime's unbuffered file I/O, so always returns success.
Fw::InputComPort * get_comIn_InputPort(FwIndexType portNum)
Command failed to deserialize.
PlatformQueuePriorityType FwQueuePriorityType
The type of queue priorities used.
virtual void BL_SetLogging_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Svc::BufferLogger_LogState &state)=0
void init()
Initialization function.
void comIn_handlerBase(FwIndexType portNum, Fw::ComBuffer &data, U32 context)
Handler base-class function for input port comIn.
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port connection.
virtual void pingIn_handler(FwIndexType portNum, U32 key)=0
Handler for input port pingIn.
static constexpr FwIndexType getNum_bufferSendOut_OutputPorts()
A message was sent requesting an exit of the loop.
virtual ~BufferLoggerComponentBase()
Destroy BufferLoggerComponentBase object.
PlatformIndexType FwIndexType
static constexpr FwIndexType getNum_pingOut_OutputPorts()
static constexpr FwIndexType getNum_tlmOut_OutputPorts()
void addCallPort(InputLogPort *callPort)
Register an input port.
void init()
Initialization function.
RateGroupDivider component implementation.
message sent/received okay
static constexpr FwIndexType getNum_cmdResponseOut_OutputPorts()
Close the currently open log file, if any.
The Buffer Logger encountered an error opening a log file.
void BL_FlushFile_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
The Buffer Logger closed a log file.
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
void set_eventOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to eventOut[portNum].
Message will return with status when space is unavailable.
Implementation of malloc based allocator.
static constexpr FwIndexType getNum_bufferSendIn_InputPorts()
void log_WARNING_HI_BL_NoLogFileOpenInitError() const
Svc::InputPingPort * get_pingIn_InputPort(FwIndexType portNum)
static constexpr FwIndexType getNum_comIn_InputPorts()
void schedIn_handlerBase(FwIndexType portNum, U32 context)
Handler base-class function for input port schedIn.
void init()
Initialization function.
The Buffer Logger encountered an error writing to a log file.
virtual void BL_CloseFile_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
virtual void BL_OpenFile_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &file)=0
static constexpr FwSizeType CAPACITY
void addCallPort(InputCmdResponsePort *callPort)
Register an input port.
void log_WARNING_HI_BL_LogFileValidationError(const Fw::StringBase &validationFile, U32 status) const
SerializeStatus serializeTo(SerialBufferBase &buffer, Endianness mode=Endianness::BIG) const override
Serialize the contents of this object to a buffer.
BYTE cmdPortSize[Fw::CmdPortBuffer::CAPACITY]
void set_cmdRegOut_OutputPort(FwIndexType portNum, Fw::InputCmdRegPort *port)
Connect port to cmdRegOut[portNum].