9 #if FW_ENABLE_TEXT_LOGGING 20 VERIFYIN_VERIFYSTATUS,
35 class ComponentIpcSerializableBuffer :
45 MAX_DATA_SIZE =
sizeof(BuffUnion),
47 SERIALIZATION_SIZE = DATA_OFFSET + MAX_DATA_SIZE
50 ComponentIpcSerializableBuffer() :
Fw::LinearBufferBase(m_buff, sizeof(m_buff)) {
56 U8 m_buff[SERIALIZATION_SIZE];
74 #if !FW_DIRECT_PORT_CALLS 81 this->m_cmdIn_InputPort[port].
init();
86 this->m_cmdIn_InputPort[port].
setPortNum(port);
88 #if FW_OBJECT_NAMES == 1 92 this->m_objName.toChar(),
95 this->m_cmdIn_InputPort[port].setObjName(portName.
toChar());
100 #if !FW_DIRECT_PORT_CALLS 107 this->m_cancelIn_InputPort[port].
init();
112 this->m_cancelIn_InputPort[port].
setPortNum(port);
114 #if FW_OBJECT_NAMES == 1 118 this->m_objName.toChar(),
121 this->m_cancelIn_InputPort[port].setObjName(portName.
toChar());
126 #if !FW_DIRECT_PORT_CALLS 133 this->m_readIn_InputPort[port].
init();
138 this->m_readIn_InputPort[port].
setPortNum(port);
140 #if FW_OBJECT_NAMES == 1 144 this->m_objName.toChar(),
147 this->m_readIn_InputPort[port].setObjName(portName.
toChar());
152 #if !FW_DIRECT_PORT_CALLS 159 this->m_verifyIn_InputPort[port].
init();
164 this->m_verifyIn_InputPort[port].
setPortNum(port);
166 #if FW_OBJECT_NAMES == 1 170 this->m_objName.toChar(),
173 this->m_verifyIn_InputPort[port].setObjName(portName.
toChar());
178 #if !FW_DIRECT_PORT_CALLS 185 this->m_writeIn_InputPort[port].
init();
190 this->m_writeIn_InputPort[port].
setPortNum(port);
192 #if FW_OBJECT_NAMES == 1 196 this->m_objName.toChar(),
199 this->m_writeIn_InputPort[port].setObjName(portName.
toChar());
204 #if !FW_DIRECT_PORT_CALLS 211 this->m_cmdRegOut_OutputPort[port].
init();
213 #if FW_OBJECT_NAMES == 1 217 this->m_objName.toChar(),
220 this->m_cmdRegOut_OutputPort[port].setObjName(portName.
toChar());
225 #if !FW_DIRECT_PORT_CALLS 232 this->m_cmdResponseOut_OutputPort[port].
init();
234 #if FW_OBJECT_NAMES == 1 238 this->m_objName.toChar(),
241 this->m_cmdResponseOut_OutputPort[port].setObjName(portName.
toChar());
246 #if !FW_DIRECT_PORT_CALLS 253 this->m_logOut_OutputPort[port].
init();
255 #if FW_OBJECT_NAMES == 1 259 this->m_objName.toChar(),
262 this->m_logOut_OutputPort[port].setObjName(portName.
toChar());
267 #if !FW_DIRECT_PORT_CALLS && FW_ENABLE_TEXT_LOGGING 271 port < static_cast<FwIndexType>(this->getNum_logTextOut_OutputPorts());
274 this->m_logTextOut_OutputPort[port].
init();
276 #if FW_OBJECT_NAMES == 1 280 this->m_objName.toChar(),
283 this->m_logTextOut_OutputPort[port].setObjName(portName.
toChar());
288 #if !FW_DIRECT_PORT_CALLS 295 this->m_prmGetOut_OutputPort[port].
init();
297 #if FW_OBJECT_NAMES == 1 301 this->m_objName.toChar(),
304 this->m_prmGetOut_OutputPort[port].setObjName(portName.
toChar());
309 #if !FW_DIRECT_PORT_CALLS 316 this->m_prmSetOut_OutputPort[port].
init();
318 #if FW_OBJECT_NAMES == 1 322 this->m_objName.toChar(),
325 this->m_prmSetOut_OutputPort[port].setObjName(portName.
toChar());
330 #if !FW_DIRECT_PORT_CALLS 337 this->m_timeCaller_OutputPort[port].
init();
339 #if FW_OBJECT_NAMES == 1 343 this->m_objName.toChar(),
346 this->m_timeCaller_OutputPort[port].setObjName(portName.
toChar());
351 #if !FW_DIRECT_PORT_CALLS 358 this->m_tlmOut_OutputPort[port].
init();
360 #if FW_OBJECT_NAMES == 1 364 this->m_objName.toChar(),
367 this->m_tlmOut_OutputPort[port].setObjName(portName.
toChar());
372 #if !FW_DIRECT_PORT_CALLS 379 this->m_readDoneOut_OutputPort[port].
init();
381 #if FW_OBJECT_NAMES == 1 385 this->m_objName.toChar(),
388 this->m_readDoneOut_OutputPort[port].setObjName(portName.
toChar());
393 #if !FW_DIRECT_PORT_CALLS 400 this->m_verifyDoneOut_OutputPort[port].
init();
402 #if FW_OBJECT_NAMES == 1 406 this->m_objName.toChar(),
409 this->m_verifyDoneOut_OutputPort[port].setObjName(portName.
toChar());
414 #if !FW_DIRECT_PORT_CALLS 421 this->m_writeDoneOut_OutputPort[port].
init();
423 #if FW_OBJECT_NAMES == 1 427 this->m_objName.toChar(),
430 this->m_writeDoneOut_OutputPort[port].setObjName(portName.
toChar());
438 static_cast<FwSizeType>(ComponentIpcSerializableBuffer::SERIALIZATION_SIZE)
442 static_cast<FwAssertArgType>(qStat)
446 #if !FW_DIRECT_PORT_CALLS 457 static_cast<FwAssertArgType>(portNum)
460 return &this->m_cmdIn_InputPort[portNum];
465 #if !FW_DIRECT_PORT_CALLS 476 static_cast<FwAssertArgType>(portNum)
479 return &this->m_cancelIn_InputPort[portNum];
487 static_cast<FwAssertArgType>(portNum)
490 return &this->m_readIn_InputPort[portNum];
498 static_cast<FwAssertArgType>(portNum)
501 return &this->m_verifyIn_InputPort[portNum];
509 static_cast<FwAssertArgType>(portNum)
512 return &this->m_writeIn_InputPort[portNum];
517 #if !FW_DIRECT_PORT_CALLS 531 static_cast<FwAssertArgType>(portNum)
534 this->m_cmdRegOut_OutputPort[portNum].
addCallPort(port);
545 static_cast<FwAssertArgType>(portNum)
548 this->m_cmdResponseOut_OutputPort[portNum].
addCallPort(port);
559 static_cast<FwAssertArgType>(portNum)
562 this->m_logOut_OutputPort[portNum].
addCallPort(port);
565 #if FW_ENABLE_TEXT_LOGGING == 1 567 void FileWorkerComponentBase ::
568 set_logTextOut_OutputPort(
574 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
575 static_cast<FwAssertArgType>(portNum)
578 this->m_logTextOut_OutputPort[portNum].addCallPort(port);
591 static_cast<FwAssertArgType>(portNum)
594 this->m_prmGetOut_OutputPort[portNum].
addCallPort(port);
605 static_cast<FwAssertArgType>(portNum)
608 this->m_prmSetOut_OutputPort[portNum].
addCallPort(port);
619 static_cast<FwAssertArgType>(portNum)
622 this->m_timeCaller_OutputPort[portNum].
addCallPort(port);
633 static_cast<FwAssertArgType>(portNum)
636 this->m_tlmOut_OutputPort[portNum].
addCallPort(port);
641 #if !FW_DIRECT_PORT_CALLS 655 static_cast<FwAssertArgType>(portNum)
658 this->m_readDoneOut_OutputPort[portNum].
addCallPort(port);
669 static_cast<FwAssertArgType>(portNum)
672 this->m_verifyDoneOut_OutputPort[portNum].
addCallPort(port);
683 static_cast<FwAssertArgType>(portNum)
686 this->m_writeDoneOut_OutputPort[portNum].
addCallPort(port);
691 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION 700 Fw::InputSerializePort* port
705 static_cast<FwAssertArgType>(portNum)
708 this->m_cmdRegOut_OutputPort[portNum].registerSerialPort(port);
714 Fw::InputSerializePort* port
719 static_cast<FwAssertArgType>(portNum)
722 this->m_cmdResponseOut_OutputPort[portNum].registerSerialPort(port);
728 Fw::InputSerializePort* port
733 static_cast<FwAssertArgType>(portNum)
736 this->m_logOut_OutputPort[portNum].registerSerialPort(port);
739 #if FW_ENABLE_TEXT_LOGGING == 1 741 void FileWorkerComponentBase ::
742 set_logTextOut_OutputPort(
744 Fw::InputSerializePort* port
748 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
749 static_cast<FwAssertArgType>(portNum)
752 this->m_logTextOut_OutputPort[portNum].registerSerialPort(port);
760 Fw::InputSerializePort* port
765 static_cast<FwAssertArgType>(portNum)
768 this->m_prmSetOut_OutputPort[portNum].registerSerialPort(port);
774 Fw::InputSerializePort* port
779 static_cast<FwAssertArgType>(portNum)
782 this->m_timeCaller_OutputPort[portNum].registerSerialPort(port);
788 Fw::InputSerializePort* port
793 static_cast<FwAssertArgType>(portNum)
796 this->m_tlmOut_OutputPort[portNum].registerSerialPort(port);
801 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION 810 Fw::InputSerializePort* port
815 static_cast<FwAssertArgType>(portNum)
818 this->m_readDoneOut_OutputPort[portNum].registerSerialPort(port);
824 Fw::InputSerializePort* port
829 static_cast<FwAssertArgType>(portNum)
832 this->m_verifyDoneOut_OutputPort[portNum].registerSerialPort(port);
838 Fw::InputSerializePort* port
843 static_cast<FwAssertArgType>(portNum)
846 this->m_writeDoneOut_OutputPort[portNum].registerSerialPort(port);
857 Fw::ActiveComponentBase(compName)
859 this->m_NotInIdleThrottle = 0;
860 this->m_CrcFailedThrottle = 0;
861 this->m_ReadFailedFileSizeThrottle = 0;
862 this->m_OpenFileErrorThrottle = 0;
863 this->m_WriteFileErrorThrottle = 0;
864 this->m_WriteValidationOpenErrorThrottle = 0;
865 this->m_WriteValidationReadErrorThrottle = 0;
867 this->m_NotInIdleThrottleTime =
Fw::Time();
868 this->m_CrcFailedThrottleTime =
Fw::Time();
869 this->m_ReadFailedFileSizeThrottleTime =
Fw::Time();
870 this->m_OpenFileErrorThrottleTime =
Fw::Time();
871 this->m_WriteFileErrorThrottleTime =
Fw::Time();
872 this->m_WriteValidationOpenErrorThrottleTime =
Fw::Time();
873 this->m_WriteValidationReadErrorThrottleTime =
Fw::Time();
882 #if !FW_DIRECT_PORT_CALLS 893 static_cast<FwAssertArgType>(portNum)
896 return this->m_cmdRegOut_OutputPort[portNum].
isConnected();
904 static_cast<FwAssertArgType>(portNum)
907 return this->m_cmdResponseOut_OutputPort[portNum].
isConnected();
915 static_cast<FwAssertArgType>(portNum)
918 return this->m_logOut_OutputPort[portNum].
isConnected();
921 #if FW_ENABLE_TEXT_LOGGING == 1 923 bool FileWorkerComponentBase ::
924 isConnected_logTextOut_OutputPort(
FwIndexType portNum)
const 927 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
928 static_cast<FwAssertArgType>(portNum)
931 return this->m_logTextOut_OutputPort[portNum].isConnected();
941 static_cast<FwAssertArgType>(portNum)
944 return this->m_prmGetOut_OutputPort[portNum].
isConnected();
952 static_cast<FwAssertArgType>(portNum)
955 return this->m_prmSetOut_OutputPort[portNum].
isConnected();
963 static_cast<FwAssertArgType>(portNum)
966 return this->m_timeCaller_OutputPort[portNum].
isConnected();
974 static_cast<FwAssertArgType>(portNum)
977 return this->m_tlmOut_OutputPort[portNum].
isConnected();
982 #if !FW_DIRECT_PORT_CALLS 993 static_cast<FwAssertArgType>(portNum)
996 return this->m_readDoneOut_OutputPort[portNum].
isConnected();
1004 static_cast<FwAssertArgType>(portNum)
1007 return this->m_verifyDoneOut_OutputPort[portNum].
isConnected();
1015 static_cast<FwAssertArgType>(portNum)
1018 return this->m_writeDoneOut_OutputPort[portNum].
isConnected();
1039 FW_ASSERT(opCode >= idBase, static_cast<FwAssertArgType>(opCode), static_cast<FwAssertArgType>(idBase));
1042 switch (opCode - idBase) {
1061 static_cast<FwAssertArgType>(portNum)
1084 static_cast<FwAssertArgType>(portNum)
1093 ComponentIpcSerializableBuffer msg;
1097 _status = msg.serializeFrom(
1098 static_cast<FwEnumStoreType>(READIN_FILEREAD)
1102 static_cast<FwAssertArgType>(_status)
1106 _status = msg.serializeFrom(portNum);
1109 static_cast<FwAssertArgType>(_status)
1116 static_cast<FwAssertArgType>(_status)
1120 _status = msg.serializeFrom(buffer);
1123 static_cast<FwAssertArgType>(_status)
1132 static_cast<FwAssertArgType>(qStatus)
1146 static_cast<FwAssertArgType>(portNum)
1155 ComponentIpcSerializableBuffer msg;
1159 _status = msg.serializeFrom(
1160 static_cast<FwEnumStoreType>(VERIFYIN_VERIFYSTATUS)
1164 static_cast<FwAssertArgType>(_status)
1168 _status = msg.serializeFrom(portNum);
1171 static_cast<FwAssertArgType>(_status)
1178 static_cast<FwAssertArgType>(_status)
1182 _status = msg.serializeFrom(crc);
1185 static_cast<FwAssertArgType>(_status)
1194 static_cast<FwAssertArgType>(qStatus)
1210 static_cast<FwAssertArgType>(portNum)
1221 ComponentIpcSerializableBuffer msg;
1225 _status = msg.serializeFrom(
1226 static_cast<FwEnumStoreType>(WRITEIN_FILEWRITE)
1230 static_cast<FwAssertArgType>(_status)
1234 _status = msg.serializeFrom(portNum);
1237 static_cast<FwAssertArgType>(_status)
1244 static_cast<FwAssertArgType>(_status)
1248 _status = msg.serializeFrom(buffer);
1251 static_cast<FwAssertArgType>(_status)
1255 _status = msg.serializeFrom(offsetBytes);
1258 static_cast<FwAssertArgType>(_status)
1262 _status = msg.serializeFrom(append);
1265 static_cast<FwAssertArgType>(_status)
1274 static_cast<FwAssertArgType>(qStatus)
1318 #if !FW_DIRECT_PORT_CALLS 1333 static_cast<FwAssertArgType>(portNum)
1337 this->m_readDoneOut_OutputPort[portNum].isConnected(),
1338 static_cast<FwAssertArgType>(portNum)
1340 this->m_readDoneOut_OutputPort[portNum].
invoke(
1355 static_cast<FwAssertArgType>(portNum)
1359 this->m_verifyDoneOut_OutputPort[portNum].isConnected(),
1360 static_cast<FwAssertArgType>(portNum)
1362 this->m_verifyDoneOut_OutputPort[portNum].
invoke(
1377 static_cast<FwAssertArgType>(portNum)
1381 this->m_writeDoneOut_OutputPort[portNum].isConnected(),
1382 static_cast<FwAssertArgType>(portNum)
1384 this->m_writeDoneOut_OutputPort[portNum].
invoke(
1402 this->timeCaller_out(0, _logTime);
1415 this->m_NotInIdleThrottle = 0;
1423 if (this->m_NotInIdleThrottle == 0) {
1425 this->m_NotInIdleThrottleTime = _logTime;
1429 this->m_NotInIdleThrottle++;
1437 #if FW_AMPCS_COMPATIBLE 1442 static_cast<FwAssertArgType>(_status)
1446 #if FW_AMPCS_COMPATIBLE 1449 static_cast<U8>(
sizeof(U32))
1453 static_cast<FwAssertArgType>(_status)
1459 static_cast<FwAssertArgType>(_status)
1472 #if FW_ENABLE_TEXT_LOGGING 1473 if (this->isConnected_logTextOut_OutputPort(0)) {
1474 #if FW_OBJECT_NAMES == 1 1475 const char* _formatString =
1476 "(%s) %s: Not in IDLE state, currently in state: %" PRIu32
"";
1478 const char* _formatString =
1479 "%s: Not in IDLE state, currently in state: %" PRIu32
"";
1483 (void) _logString.
format(
1486 this->m_objName.toChar(),
1492 this->logTextOut_out(
1509 this->timeCaller_out(0, _logTime);
1522 this->m_CrcFailedThrottle = 0;
1530 if (this->m_CrcFailedThrottle == 0) {
1532 this->m_CrcFailedThrottleTime = _logTime;
1536 this->m_CrcFailedThrottle++;
1544 #if FW_AMPCS_COMPATIBLE 1549 static_cast<FwAssertArgType>(_status)
1553 #if FW_AMPCS_COMPATIBLE 1556 static_cast<U8>(
sizeof(U32))
1560 static_cast<FwAssertArgType>(_status)
1566 static_cast<FwAssertArgType>(_status)
1579 #if FW_ENABLE_TEXT_LOGGING 1580 if (this->isConnected_logTextOut_OutputPort(0)) {
1581 #if FW_OBJECT_NAMES == 1 1582 const char* _formatString =
1583 "(%s) %s: Failed CRC check with %" PRIu32
" status";
1585 const char* _formatString =
1586 "%s: Failed CRC check with %" PRIu32
" status";
1590 (void) _logString.
format(
1593 this->m_objName.toChar(),
1599 this->logTextOut_out(
1619 this->timeCaller_out(0, _logTime);
1629 #if FW_AMPCS_COMPATIBLE 1634 static_cast<FwAssertArgType>(_status)
1638 #if FW_AMPCS_COMPATIBLE 1641 static_cast<U8>(
sizeof(U32))
1645 static_cast<FwAssertArgType>(_status)
1651 static_cast<FwAssertArgType>(_status)
1654 #if FW_AMPCS_COMPATIBLE 1657 static_cast<U8>(
sizeof(U32))
1661 static_cast<FwAssertArgType>(_status)
1667 static_cast<FwAssertArgType>(_status)
1680 #if FW_ENABLE_TEXT_LOGGING 1681 if (this->isConnected_logTextOut_OutputPort(0)) {
1682 #if FW_OBJECT_NAMES == 1 1683 const char* _formatString =
1684 "(%s) %s: Failed to verify file. Expected CRC %" PRIu32
". Actual CRC %" PRIu32
"";
1686 const char* _formatString =
1687 "%s: Failed to verify file. Expected CRC %" PRIu32
". Actual CRC %" PRIu32
"";
1691 (void) _logString.
format(
1694 this->m_objName.toChar(),
1696 "CrcVerificationError ",
1701 this->logTextOut_out(
1718 this->timeCaller_out(0, _logTime);
1731 this->m_ReadFailedFileSizeThrottle = 0;
1739 if (this->m_ReadFailedFileSizeThrottle == 0) {
1741 this->m_ReadFailedFileSizeThrottleTime = _logTime;
1745 this->m_ReadFailedFileSizeThrottle++;
1753 #if FW_AMPCS_COMPATIBLE 1758 static_cast<FwAssertArgType>(_status)
1762 #if FW_AMPCS_COMPATIBLE 1765 static_cast<U8>(
sizeof(U32))
1769 static_cast<FwAssertArgType>(_status)
1775 static_cast<FwAssertArgType>(_status)
1788 #if FW_ENABLE_TEXT_LOGGING 1789 if (this->isConnected_logTextOut_OutputPort(0)) {
1790 #if FW_OBJECT_NAMES == 1 1791 const char* _formatString =
1792 "(%s) %s: Failed to get filesize with stat %" PRIu32
" in read handler";
1794 const char* _formatString =
1795 "%s: Failed to get filesize with stat %" PRIu32
" in read handler";
1799 (void) _logString.
format(
1802 this->m_objName.toChar(),
1804 "ReadFailedFileSize ",
1808 this->logTextOut_out(
1828 this->timeCaller_out(0, _logTime);
1841 this->m_OpenFileErrorThrottle = 0;
1849 if (this->m_OpenFileErrorThrottle == 0) {
1851 this->m_OpenFileErrorThrottleTime = _logTime;
1855 this->m_OpenFileErrorThrottle++;
1863 #if FW_AMPCS_COMPATIBLE 1868 static_cast<FwAssertArgType>(_status)
1878 static_cast<FwAssertArgType>(_status)
1881 #if FW_AMPCS_COMPATIBLE 1884 static_cast<U8>(
sizeof(U32))
1888 static_cast<FwAssertArgType>(_status)
1894 static_cast<FwAssertArgType>(_status)
1907 #if FW_ENABLE_TEXT_LOGGING 1908 if (this->isConnected_logTextOut_OutputPort(0)) {
1909 #if FW_OBJECT_NAMES == 1 1910 const char* _formatString =
1911 "(%s) %s: Failed to open file %s with stat %" PRIu32
"";
1913 const char* _formatString =
1914 "%s: Failed to open file %s with stat %" PRIu32
"";
1918 (void) _logString.
format(
1921 this->m_objName.toChar(),
1928 this->logTextOut_out(
1948 this->timeCaller_out(0, _logTime);
1958 #if FW_AMPCS_COMPATIBLE 1963 static_cast<FwAssertArgType>(_status)
1967 #if FW_AMPCS_COMPATIBLE 1974 static_cast<FwAssertArgType>(_status)
1980 static_cast<FwAssertArgType>(_status)
1989 static_cast<FwAssertArgType>(_status)
2002 #if FW_ENABLE_TEXT_LOGGING 2003 if (this->isConnected_logTextOut_OutputPort(0)) {
2004 #if FW_OBJECT_NAMES == 1 2005 const char* _formatString =
2006 "(%s) %s: Reading %" PRIu64
" bytes from %s";
2008 const char* _formatString =
2009 "%s: Reading %" PRIu64
" bytes from %s";
2013 (void) _logString.
format(
2016 this->m_objName.toChar(),
2023 this->logTextOut_out(
2043 this->timeCaller_out(0, _logTime);
2053 #if FW_AMPCS_COMPATIBLE 2058 static_cast<FwAssertArgType>(_status)
2062 #if FW_AMPCS_COMPATIBLE 2069 static_cast<FwAssertArgType>(_status)
2075 static_cast<FwAssertArgType>(_status)
2084 static_cast<FwAssertArgType>(_status)
2097 #if FW_ENABLE_TEXT_LOGGING 2098 if (this->isConnected_logTextOut_OutputPort(0)) {
2099 #if FW_OBJECT_NAMES == 1 2100 const char* _formatString =
2101 "(%s) %s: Finished reading %" PRIu64
" bytes from %s";
2103 const char* _formatString =
2104 "%s: Finished reading %" PRIu64
" bytes from %s";
2108 (void) _logString.
format(
2111 this->m_objName.toChar(),
2118 this->logTextOut_out(
2139 this->timeCaller_out(0, _logTime);
2149 #if FW_AMPCS_COMPATIBLE 2154 static_cast<FwAssertArgType>(_status)
2158 #if FW_AMPCS_COMPATIBLE 2165 static_cast<FwAssertArgType>(_status)
2171 static_cast<FwAssertArgType>(_status)
2174 #if FW_AMPCS_COMPATIBLE 2181 static_cast<FwAssertArgType>(_status)
2187 static_cast<FwAssertArgType>(_status)
2196 static_cast<FwAssertArgType>(_status)
2209 #if FW_ENABLE_TEXT_LOGGING 2210 if (this->isConnected_logTextOut_OutputPort(0)) {
2211 #if FW_OBJECT_NAMES == 1 2212 const char* _formatString =
2213 "(%s) %s: Failed after %" PRIu64
" of %" PRIu64
" bytes read to %s";
2215 const char* _formatString =
2216 "%s: Failed after %" PRIu64
" of %" PRIu64
" bytes read to %s";
2220 (void) _logString.
format(
2223 this->m_objName.toChar(),
2231 this->logTextOut_out(
2252 this->timeCaller_out(0, _logTime);
2262 #if FW_AMPCS_COMPATIBLE 2267 static_cast<FwAssertArgType>(_status)
2271 #if FW_AMPCS_COMPATIBLE 2278 static_cast<FwAssertArgType>(_status)
2284 static_cast<FwAssertArgType>(_status)
2287 #if FW_AMPCS_COMPATIBLE 2294 static_cast<FwAssertArgType>(_status)
2300 static_cast<FwAssertArgType>(_status)
2309 static_cast<FwAssertArgType>(_status)
2322 #if FW_ENABLE_TEXT_LOGGING 2323 if (this->isConnected_logTextOut_OutputPort(0)) {
2324 #if FW_OBJECT_NAMES == 1 2325 const char* _formatString =
2326 "(%s) %s: Aborted after %" PRIu64
" of %" PRIu64
" bytes read to %s";
2328 const char* _formatString =
2329 "%s: Aborted after %" PRIu64
" of %" PRIu64
" bytes read to %s";
2333 (void) _logString.
format(
2336 this->m_objName.toChar(),
2344 this->logTextOut_out(
2366 this->timeCaller_out(0, _logTime);
2376 #if FW_AMPCS_COMPATIBLE 2381 static_cast<FwAssertArgType>(_status)
2385 #if FW_AMPCS_COMPATIBLE 2392 static_cast<FwAssertArgType>(_status)
2398 static_cast<FwAssertArgType>(_status)
2401 #if FW_AMPCS_COMPATIBLE 2408 static_cast<FwAssertArgType>(_status)
2414 static_cast<FwAssertArgType>(_status)
2423 static_cast<FwAssertArgType>(_status)
2426 #if FW_AMPCS_COMPATIBLE 2429 static_cast<U8>(
sizeof(U64))
2433 static_cast<FwAssertArgType>(_status)
2439 static_cast<FwAssertArgType>(_status)
2452 #if FW_ENABLE_TEXT_LOGGING 2453 if (this->isConnected_logTextOut_OutputPort(0)) {
2454 #if FW_OBJECT_NAMES == 1 2455 const char* _formatString =
2456 "(%s) %s: Failed after %" PRIu64
" of %" PRIu64
" bytes read to %s after exceeding timeout of %" PRIu64
" microseconds";
2458 const char* _formatString =
2459 "%s: Failed after %" PRIu64
" of %" PRIu64
" bytes read to %s after exceeding timeout of %" PRIu64
" microseconds";
2463 (void) _logString.
format(
2466 this->m_objName.toChar(),
2475 this->logTextOut_out(
2495 this->timeCaller_out(0, _logTime);
2505 #if FW_AMPCS_COMPATIBLE 2510 static_cast<FwAssertArgType>(_status)
2514 #if FW_AMPCS_COMPATIBLE 2521 static_cast<FwAssertArgType>(_status)
2527 static_cast<FwAssertArgType>(_status)
2536 static_cast<FwAssertArgType>(_status)
2549 #if FW_ENABLE_TEXT_LOGGING 2550 if (this->isConnected_logTextOut_OutputPort(0)) {
2551 #if FW_OBJECT_NAMES == 1 2552 const char* _formatString =
2553 "(%s) %s: Beginning write of size %" PRIu64
" to %s";
2555 const char* _formatString =
2556 "%s: Beginning write of size %" PRIu64
" to %s";
2560 (void) _logString.
format(
2563 this->m_objName.toChar(),
2570 this->logTextOut_out(
2590 this->timeCaller_out(0, _logTime);
2600 #if FW_AMPCS_COMPATIBLE 2605 static_cast<FwAssertArgType>(_status)
2609 #if FW_AMPCS_COMPATIBLE 2616 static_cast<FwAssertArgType>(_status)
2622 static_cast<FwAssertArgType>(_status)
2631 static_cast<FwAssertArgType>(_status)
2644 #if FW_ENABLE_TEXT_LOGGING 2645 if (this->isConnected_logTextOut_OutputPort(0)) {
2646 #if FW_OBJECT_NAMES == 1 2647 const char* _formatString =
2648 "(%s) %s: Completed write of size %" PRIu64
" to %s";
2650 const char* _formatString =
2651 "%s: Completed write of size %" PRIu64
" to %s";
2655 (void) _logString.
format(
2658 this->m_objName.toChar(),
2665 this->logTextOut_out(
2687 this->timeCaller_out(0, _logTime);
2700 this->m_WriteFileErrorThrottle = 0;
2708 if (this->m_WriteFileErrorThrottle == 0) {
2710 this->m_WriteFileErrorThrottleTime = _logTime;
2714 this->m_WriteFileErrorThrottle++;
2722 #if FW_AMPCS_COMPATIBLE 2727 static_cast<FwAssertArgType>(_status)
2731 #if FW_AMPCS_COMPATIBLE 2738 static_cast<FwAssertArgType>(_status)
2744 static_cast<FwAssertArgType>(_status)
2747 #if FW_AMPCS_COMPATIBLE 2754 static_cast<FwAssertArgType>(_status)
2760 static_cast<FwAssertArgType>(_status)
2769 static_cast<FwAssertArgType>(_status)
2772 #if FW_AMPCS_COMPATIBLE 2775 static_cast<U8>(
sizeof(I32))
2779 static_cast<FwAssertArgType>(_status)
2785 static_cast<FwAssertArgType>(_status)
2798 #if FW_ENABLE_TEXT_LOGGING 2799 if (this->isConnected_logTextOut_OutputPort(0)) {
2800 #if FW_OBJECT_NAMES == 1 2801 const char* _formatString =
2802 "(%s) %s: Failed after %" PRIu64
" of %" PRIu64
" bytes written to %s with write status %" PRIi32
"";
2804 const char* _formatString =
2805 "%s: Failed after %" PRIu64
" of %" PRIu64
" bytes written to %s with write status %" PRIi32
"";
2809 (void) _logString.
format(
2812 this->m_objName.toChar(),
2821 this->logTextOut_out(
2841 this->timeCaller_out(0, _logTime);
2854 this->m_WriteValidationOpenErrorThrottle = 0;
2862 if (this->m_WriteValidationOpenErrorThrottle == 0) {
2864 this->m_WriteValidationOpenErrorThrottleTime = _logTime;
2868 this->m_WriteValidationOpenErrorThrottle++;
2876 #if FW_AMPCS_COMPATIBLE 2881 static_cast<FwAssertArgType>(_status)
2891 static_cast<FwAssertArgType>(_status)
2894 #if FW_AMPCS_COMPATIBLE 2897 static_cast<U8>(
sizeof(I32))
2901 static_cast<FwAssertArgType>(_status)
2907 static_cast<FwAssertArgType>(_status)
2920 #if FW_ENABLE_TEXT_LOGGING 2921 if (this->isConnected_logTextOut_OutputPort(0)) {
2922 #if FW_OBJECT_NAMES == 1 2923 const char* _formatString =
2924 "(%s) %s: Failed to open validation file %s with status %" PRIi32
"";
2926 const char* _formatString =
2927 "%s: Failed to open validation file %s with status %" PRIi32
"";
2931 (void) _logString.
format(
2934 this->m_objName.toChar(),
2936 "WriteValidationOpenError ",
2941 this->logTextOut_out(
2961 this->timeCaller_out(0, _logTime);
2974 this->m_WriteValidationReadErrorThrottle = 0;
2982 if (this->m_WriteValidationReadErrorThrottle == 0) {
2984 this->m_WriteValidationReadErrorThrottleTime = _logTime;
2988 this->m_WriteValidationReadErrorThrottle++;
2996 #if FW_AMPCS_COMPATIBLE 3001 static_cast<FwAssertArgType>(_status)
3011 static_cast<FwAssertArgType>(_status)
3014 #if FW_AMPCS_COMPATIBLE 3017 static_cast<U8>(
sizeof(I32))
3021 static_cast<FwAssertArgType>(_status)
3027 static_cast<FwAssertArgType>(_status)
3040 #if FW_ENABLE_TEXT_LOGGING 3041 if (this->isConnected_logTextOut_OutputPort(0)) {
3042 #if FW_OBJECT_NAMES == 1 3043 const char* _formatString =
3044 "(%s) %s: Failed to read validation file %s with status %" PRIi32
"";
3046 const char* _formatString =
3047 "%s: Failed to read validation file %s with status %" PRIi32
"";
3051 (void) _logString.
format(
3054 this->m_objName.toChar(),
3056 "WriteValidationReadError ",
3061 this->logTextOut_out(
3082 this->timeCaller_out(0, _logTime);
3092 #if FW_AMPCS_COMPATIBLE 3097 static_cast<FwAssertArgType>(_status)
3107 static_cast<FwAssertArgType>(_status)
3110 #if FW_AMPCS_COMPATIBLE 3117 static_cast<FwAssertArgType>(_status)
3123 static_cast<FwAssertArgType>(_status)
3126 #if FW_AMPCS_COMPATIBLE 3133 static_cast<FwAssertArgType>(_status)
3139 static_cast<FwAssertArgType>(_status)
3152 #if FW_ENABLE_TEXT_LOGGING 3153 if (this->isConnected_logTextOut_OutputPort(0)) {
3154 #if FW_OBJECT_NAMES == 1 3155 const char* _formatString =
3156 "(%s) %s: Failed to create hash file %s. Wrote %" PRIu64
" bytes when expected to write %" PRIu64
" bytes to hash file";
3158 const char* _formatString =
3159 "%s: Failed to create hash file %s. Wrote %" PRIu64
" bytes when expected to write %" PRIu64
" bytes to hash file";
3163 (void) _logString.
format(
3166 this->m_objName.toChar(),
3168 "WriteValidationError ",
3174 this->logTextOut_out(
3196 this->timeCaller_out(0, _logTime);
3206 #if FW_AMPCS_COMPATIBLE 3211 static_cast<FwAssertArgType>(_status)
3215 #if FW_AMPCS_COMPATIBLE 3222 static_cast<FwAssertArgType>(_status)
3228 static_cast<FwAssertArgType>(_status)
3231 #if FW_AMPCS_COMPATIBLE 3238 static_cast<FwAssertArgType>(_status)
3244 static_cast<FwAssertArgType>(_status)
3253 static_cast<FwAssertArgType>(_status)
3256 #if FW_AMPCS_COMPATIBLE 3259 static_cast<U8>(
sizeof(U64))
3263 static_cast<FwAssertArgType>(_status)
3269 static_cast<FwAssertArgType>(_status)
3282 #if FW_ENABLE_TEXT_LOGGING 3283 if (this->isConnected_logTextOut_OutputPort(0)) {
3284 #if FW_OBJECT_NAMES == 1 3285 const char* _formatString =
3286 "(%s) %s: Failed after %" PRIu64
" of %" PRIu64
" bytes written to %s after exceeding timeout of %" PRIu64
" microseconds";
3288 const char* _formatString =
3289 "%s: Failed after %" PRIu64
" of %" PRIu64
" bytes written to %s after exceeding timeout of %" PRIu64
" microseconds";
3293 (void) _logString.
format(
3296 this->m_objName.toChar(),
3305 this->logTextOut_out(
3326 this->timeCaller_out(0, _logTime);
3336 #if FW_AMPCS_COMPATIBLE 3341 static_cast<FwAssertArgType>(_status)
3345 #if FW_AMPCS_COMPATIBLE 3352 static_cast<FwAssertArgType>(_status)
3358 static_cast<FwAssertArgType>(_status)
3361 #if FW_AMPCS_COMPATIBLE 3368 static_cast<FwAssertArgType>(_status)
3374 static_cast<FwAssertArgType>(_status)
3383 static_cast<FwAssertArgType>(_status)
3396 #if FW_ENABLE_TEXT_LOGGING 3397 if (this->isConnected_logTextOut_OutputPort(0)) {
3398 #if FW_OBJECT_NAMES == 1 3399 const char* _formatString =
3400 "(%s) %s: Aborted after %" PRIu64
" of %" PRIu64
" bytes written to %s";
3402 const char* _formatString =
3403 "%s: Aborted after %" PRIu64
" of %" PRIu64
" bytes written to %s";
3407 (void) _logString.
format(
3410 this->m_objName.toChar(),
3418 this->logTextOut_out(
3438 this->timeCaller_out(0, _logTime);
3448 #if FW_AMPCS_COMPATIBLE 3453 static_cast<FwAssertArgType>(_status)
3463 static_cast<FwAssertArgType>(_status)
3472 static_cast<FwAssertArgType>(_status)
3485 #if FW_ENABLE_TEXT_LOGGING 3486 if (this->isConnected_logTextOut_OutputPort(0)) {
3487 #if FW_OBJECT_NAMES == 1 3488 const char* _formatString =
3489 "(%s) %s: Invalid input in %s handler: %s";
3491 const char* _formatString =
3492 "%s: Invalid input in %s handler: %s";
3496 (void) _logString.
format(
3499 this->m_objName.toChar(),
3506 this->logTextOut_out(
3528 this->m_NotInIdleThrottle = 0;
3531 this->m_NotInIdleThrottleTime =
Fw::Time(0, 0);
3542 this->m_CrcFailedThrottle = 0;
3545 this->m_CrcFailedThrottleTime =
Fw::Time(0, 0);
3556 this->m_ReadFailedFileSizeThrottle = 0;
3559 this->m_ReadFailedFileSizeThrottleTime =
Fw::Time(0, 0);
3570 this->m_OpenFileErrorThrottle = 0;
3573 this->m_OpenFileErrorThrottleTime =
Fw::Time(0, 0);
3584 this->m_WriteFileErrorThrottle = 0;
3587 this->m_WriteFileErrorThrottleTime =
Fw::Time(0, 0);
3598 this->m_WriteValidationOpenErrorThrottle = 0;
3601 this->m_WriteValidationOpenErrorThrottleTime =
Fw::Time(0, 0);
3612 this->m_WriteValidationReadErrorThrottle = 0;
3615 this->m_WriteValidationReadErrorThrottleTime =
Fw::Time(0, 0);
3628 this->timeCaller_out(0, _time);
3646 this->m_guardedPortMutex.
lock();
3652 this->m_guardedPortMutex.
unLock();
3662 ComponentIpcSerializableBuffer _msg;
3672 static_cast<FwAssertArgType>(_msgStatus)
3682 static_cast<FwAssertArgType>(_deserStatus)
3685 MsgTypeEnum _msgType =
static_cast<MsgTypeEnum
>(_desMsg);
3687 if (_msgType == FILEWORKER_COMPONENT_EXIT) {
3692 _deserStatus = _msg.deserializeTo(portNum);
3695 static_cast<FwAssertArgType>(_deserStatus)
3700 case READIN_FILEREAD: {
3704 _deserStatus = _msg.deserializeTo(path);
3707 static_cast<FwAssertArgType>(_deserStatus)
3712 _deserStatus = _msg.deserializeTo(buffer);
3715 static_cast<FwAssertArgType>(_deserStatus)
3728 case VERIFYIN_VERIFYSTATUS: {
3732 _deserStatus = _msg.deserializeTo(path);
3735 static_cast<FwAssertArgType>(_deserStatus)
3740 _deserStatus = _msg.deserializeTo(crc);
3743 static_cast<FwAssertArgType>(_deserStatus)
3756 case WRITEIN_FILEWRITE: {
3760 _deserStatus = _msg.deserializeTo(path);
3763 static_cast<FwAssertArgType>(_deserStatus)
3768 _deserStatus = _msg.deserializeTo(buffer);
3771 static_cast<FwAssertArgType>(_deserStatus)
3776 _deserStatus = _msg.deserializeTo(offsetBytes);
3779 static_cast<FwAssertArgType>(_deserStatus)
3784 _deserStatus = _msg.deserializeTo(append);
3787 static_cast<FwAssertArgType>(_deserStatus)
3812 void FileWorkerComponentBase ::
3823 compPtr->cmdIn_handlerBase(
3835 void FileWorkerComponentBase ::
3843 compPtr->cancelIn_handlerBase(portNum);
3846 void FileWorkerComponentBase ::
3856 compPtr->readIn_handlerBase(
3863 void FileWorkerComponentBase ::
3873 compPtr->verifyIn_handlerBase(
3880 void FileWorkerComponentBase ::
3892 compPtr->writeIn_handlerBase(
3901 #if !FW_DIRECT_PORT_CALLS 3907 void FileWorkerComponentBase ::
3918 static_cast<FwAssertArgType>(portNum)
3922 this->m_logOut_OutputPort[portNum].isConnected(),
3923 static_cast<FwAssertArgType>(portNum)
3925 this->m_logOut_OutputPort[portNum].
invoke(
3933 #if FW_ENABLE_TEXT_LOGGING 3935 void FileWorkerComponentBase ::
3945 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
3946 static_cast<FwAssertArgType>(portNum)
3950 this->m_logTextOut_OutputPort[portNum].isConnected(),
3951 static_cast<FwAssertArgType>(portNum)
3953 this->m_logTextOut_OutputPort[portNum].invoke(
3963 void FileWorkerComponentBase ::
3971 static_cast<FwAssertArgType>(portNum)
3975 this->m_timeCaller_OutputPort[portNum].isConnected(),
3976 static_cast<FwAssertArgType>(portNum)
3978 this->m_timeCaller_OutputPort[portNum].
invoke(
Serialization/Deserialization operation was successful.
Reading to file was too slow.
void addCallPort(InputTimePort *callPort)
Register an input port.
static constexpr FwIndexType getNum_verifyIn_InputPorts()
static constexpr FwSizeType CAPACITY
Completed the read operation and will return buffer.
Completed the write operation and will return buffer.
void log_WARNING_HI_ReadFailedFileSize(U32 fsStat)
void set_cmdRegOut_OutputPort(FwIndexType portNum, Fw::InputCmdRegPort *port)
Connect port to cmdRegOut[portNum].
bool isConnected_cmdRegOut_OutputPort(FwIndexType portNum) const
FwIdType FwOpcodeType
The type of a command opcode.
void readIn_handlerBase(FwIndexType portNum, const Fw::StringBase &path, Fw::Buffer &buffer)
Handler base-class function for input port readIn.
Error encountered while opening validation file.
virtual void cancelIn_handler(FwIndexType portNum)=0
Handler for input port cancelIn.
FwIdType getIdBase() const
PlatformSizeType FwSizeType
virtual ~FileWorkerComponentBase()
Destroy FileWorkerComponentBase object.
Status receive(U8 *destination, FwSizeType capacity, BlockingType blockType, FwSizeType &actualSize, FwQueuePriorityType &priority) override
receive a message from the queue through delegate
Status
status returned from the queue send function
void verifyIn_handlerBase(FwIndexType portNum, const Fw::StringBase &path, U32 crc)
Handler base-class function for input port verifyIn.
void log_WARNING_HI_WriteValidationReadError_ThrottleClear()
Reset throttle value for WriteValidationReadError.
message to exit active component task
static constexpr FwIndexType getNum_logOut_OutputPorts()
Svc::InputFileReadPort * get_readIn_InputPort(FwIndexType portNum)
void set_logOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to logOut[portNum].
void set_readDoneOut_OutputPort(FwIndexType portNum, Svc::InputSignalDonePort *port)
Connect port to readDoneOut[portNum].
Error encountered while creating validation file.
void log_WARNING_HI_WriteValidationOpenError(const Fw::StringBase &hashFileName, I32 status)
Completed the write operation and will return buffer.
void unLock()
unlock the mutex and assert success
void addCallPort(InputPrmSetPort *callPort)
Register an input port.
void log_WARNING_HI_WriteTimeout(FwSizeType bytesWritten, FwSizeType writeSize, const Fw::StringBase &fileName, U64 timeout) const
bool isConnected_prmSetOut_OutputPort(FwIndexType portNum) const
Inform we are done reading from file.
virtual const CHAR * toChar() const =0
Convert to a C-style char*.
static constexpr FwSizeType CAPACITY
void log_WARNING_LO_ReadAborted(FwSizeType bytesRead, FwSizeType readSize, const Fw::StringBase &fileName) const
Received a buffer and initiating write operation.
void set_prmSetOut_OutputPort(FwIndexType portNum, Fw::InputPrmSetPort *port)
Connect port to prmSetOut[portNum].
void init()
Initialization function.
bool isConnected_readDoneOut_OutputPort(FwIndexType portNum) const
No time base has been established (Required)
SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG) override
Serialize an 8-bit unsigned integer value.
Throttle reset count for OpenFileError.
void addCallPort(InputCmdRegPort *callPort)
Register an input port.
void log_ACTIVITY_LO_WriteBegin(FwSizeType writeSize, const Fw::StringBase &fileName) const
Throttle reset count for WriteFileError.
static constexpr FwIndexType getNum_cmdRegOut_OutputPorts()
void init()
Initialization function.
static constexpr FwIndexType getNum_readDoneOut_OutputPorts()
Os::Queue m_queue
queue object for active component
Writing to file was too slow.
void addCallPort(InputTlmPort *callPort)
Register an input port.
void addCallPort(InputPrmGetPort *callPort)
Register an input port.
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
void init()
Object initializer.
void log_WARNING_HI_InvalidInput(const Fw::StringBase &handler, const Fw::StringBase &issue) const
bool isConnected_timeCaller_OutputPort(FwIndexType portNum) const
SerializeStatus
forward declaration for string
Message will block until space is available.
virtual void unLock()
Unlock the guarded mutex.
void log_ACTIVITY_LO_ReadCompleted(FwSizeType fileSize, const Fw::StringBase &fileName) const
void writeDoneOut_out(FwIndexType portNum, U32 status, FwSizeType sizeBytes) const
Invoke output port writeDoneOut.
FwIdType FwEventIdType
The type of an event identifier.
Throttle reset count for WriteValidationReadError.
Svc::InputFileWritePort * get_writeIn_InputPort(FwIndexType portNum)
bool isConnected_verifyDoneOut_OutputPort(FwIndexType portNum) const
static constexpr FwIndexType getNum_verifyDoneOut_OutputPorts()
#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_cmdResponseOut_OutputPorts()
Less important informational events.
Os::Queue::Status createQueue(FwSizeType depth, FwSizeType msgSize)
Getting file size failed.
Invalid input arguments received on a port handler.
#define FW_MIN(a, b)
MIN macro (deprecated in C++, use std::min)
Getting file open failed.
A less serious but recoverable event.
virtual void writeIn_handler(FwIndexType portNum, const Fw::StringBase &path, Fw::Buffer &buffer, FwSizeType offsetBytes, bool append)=0
Handler for input port writeIn.
void log_WARNING_HI_OpenFileError(const Fw::StringBase &fileName, U32 fsStat)
Throttle reset count for CrcFailed.
static constexpr FwIndexType getNum_prmSetOut_OutputPorts()
void invoke(Fw::Time &time) const
Invoke a port connection.
static constexpr FwIndexType getNum_readIn_InputPorts()
static constexpr FwIndexType getNum_writeDoneOut_OutputPorts()
void log_ACTIVITY_LO_WriteCompleted(FwSizeType writeSize, const Fw::StringBase &fileName) const
Fw::InputCmdPort * get_cmdIn_InputPort(FwIndexType portNum)
Throttle reset count for WriteValidationOpenError.
Status send(const U8 *buffer, FwSizeType size, FwQueuePriorityType priority, BlockingType blockType) override
send a message into the queue through delegate
virtual void verifyIn_handler(FwIndexType portNum, const Fw::StringBase &path, U32 crc)=0
Handler for input port verifyIn.
Error encountered while reading validation file.
void log_WARNING_HI_CrcFailed_ThrottleClear()
Reset throttle value for CrcFailed.
static constexpr FwIndexType getNum_prmGetOut_OutputPorts()
void verifyDoneOut_out(FwIndexType portNum, U32 status, FwSizeType sizeBytes) const
Invoke output port verifyDoneOut.
A string backed by an external buffer.
A serious but recoverable event.
Svc::InputCancelStatusPort * get_cancelIn_InputPort(FwIndexType portNum)
Errors dispatching messages.
static constexpr FwSizeType CAPACITY
void set_writeDoneOut_OutputPort(FwIndexType portNum, Svc::InputSignalDonePort *port)
Connect port to writeDoneOut[portNum].
const char * toChar() const
Convert to a C-style char*.
virtual void readIn_handler(FwIndexType portNum, const Fw::StringBase &path, Fw::Buffer &buffer)=0
Handler for input port readIn.
Enum representing event severity.
void readDoneOut_out(FwIndexType portNum, U32 status, FwSizeType sizeBytes) const
Invoke output port readDoneOut.
Throttle reset count for NotInIdle.
void cmdIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
Handler base-class function for input port cmdIn.
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
void init()
Initialization function.
void log_WARNING_HI_WriteFileError(FwSizeType bytesWritten, FwSizeType writeSize, const Fw::StringBase &fileName, I32 status)
Error encountered reading to file.
virtual void readIn_preMsgHook(FwIndexType portNum, const Fw::StringBase &path, Fw::Buffer &buffer)
Pre-message hook for async input port readIn.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
uint8_t U8
8-bit unsigned integer
void log_WARNING_HI_NotInIdle(U32 currState)
void log_WARNING_LO_WriteAborted(FwSizeType bytesWritten, FwSizeType writeSize, const Fw::StringBase &fileName) const
void log_ACTIVITY_LO_ReadBegin(FwSizeType fileSize, const Fw::StringBase &fileName) const
void cancelIn_handlerBase(FwIndexType portNum)
Handler base-class function for input port cancelIn.
bool isConnected_tlmOut_OutputPort(FwIndexType portNum) const
void addCallPort(InputSignalDonePort *callPort)
Register an input port.
void log_WARNING_HI_WriteFileError_ThrottleClear()
Reset throttle value for WriteFileError.
void init()
Initialization function.
void set_tlmOut_OutputPort(FwIndexType portNum, Fw::InputTlmPort *port)
Connect port to tlmOut[portNum].
PlatformQueuePriorityType FwQueuePriorityType
The type of queue priorities used.
virtual void lock()
Lock the guarded mutex.
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
void log_WARNING_HI_NotInIdle_ThrottleClear()
Reset throttle value for NotInIdle.
void log_WARNING_HI_WriteValidationReadError(const Fw::StringBase &hashFileName, I32 status)
Inform we are reading from file.
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port connection.
static constexpr FwIndexType getNum_cancelIn_InputPorts()
static constexpr FwSizeType CAPACITY
A message was sent requesting an exit of the loop.
void log_WARNING_HI_CrcFailed(U32 crcStat)
PlatformIndexType FwIndexType
static constexpr FwIndexType getNum_tlmOut_OutputPorts()
locks a mutex within the current scope
void log_WARNING_LO_CrcVerificationError(U32 crcExp, U32 crcCalculated) const
void log_WARNING_HI_WriteValidationOpenError_ThrottleClear()
Reset throttle value for WriteValidationOpenError.
void set_prmGetOut_OutputPort(FwIndexType portNum, Fw::InputPrmGetPort *port)
Connect port to prmGetOut[portNum].
void addCallPort(InputLogPort *callPort)
Register an input port.
void init()
Initialization function.
static constexpr FwIndexType getNum_cmdIn_InputPorts()
RateGroupDivider component implementation.
message sent/received okay
Svc::InputVerifyStatusPort * get_verifyIn_InputPort(FwIndexType portNum)
void invoke(U32 status, FwSizeType sizeBytes) const
Invoke a port connection.
void log_WARNING_LO_WriteValidationError(const Fw::StringBase &hashFileName, FwSizeType bytesWritten, FwSizeType hashSize) const
void writeIn_handlerBase(FwIndexType portNum, const Fw::StringBase &path, Fw::Buffer &buffer, FwSizeType offsetBytes, bool append)
Handler base-class function for input port writeIn.
Throttle reset count for ReadFailedFileSize.
Message will return with status when space is unavailable.
static constexpr FwIndexType getNum_writeIn_InputPorts()
Implementation of malloc based allocator.
virtual void writeIn_preMsgHook(FwIndexType portNum, const Fw::StringBase &path, Fw::Buffer &buffer, FwSizeType offsetBytes, bool append)
Pre-message hook for async input port writeIn.
void set_verifyDoneOut_OutputPort(FwIndexType portNum, Svc::InputSignalDonePort *port)
Connect port to verifyDoneOut[portNum].
static constexpr SizeType BUFFER_SIZE(SizeType maxLength)
Get the size of a null-terminated string buffer.
void init()
Initialization function.
Error encountered writing to file.
void init()
Initialization function.
FileWorkerComponentBase(const char *compName="")
Construct FileWorkerComponentBase object.
bool isConnected_logOut_OutputPort(FwIndexType portNum) const
bool isConnected_prmGetOut_OutputPort(FwIndexType portNum) const
virtual void verifyIn_preMsgHook(FwIndexType portNum, const Fw::StringBase &path, U32 crc)
Pre-message hook for async input port verifyIn.
Notify we are not in IDLE state.
void log_WARNING_HI_ReadError(FwSizeType bytesRead, FwSizeType readSize, const Fw::StringBase &fileName) const
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum) const
void log_WARNING_HI_OpenFileError_ThrottleClear()
Reset throttle value for OpenFileError.
void log_WARNING_HI_ReadTimeout(FwSizeType bytesRead, FwSizeType readSize, const Fw::StringBase &fileName, U64 timeout) const
bool isConnected_writeDoneOut_OutputPort(FwIndexType portNum) const
void log_WARNING_HI_ReadFailedFileSize_ThrottleClear()
Reset throttle value for ReadFailedFileSize.
void addCallPort(InputCmdResponsePort *callPort)
Register an input port.
void lock()
lock the mutex and assert success
SerializeStatus serializeTo(SerialBufferBase &buffer, Endianness mode=Endianness::BIG) const override
Serialize the contents of this object to a buffer.
BYTE cmdPortSize[Fw::CmdPortBuffer::CAPACITY]