10 #if FW_ENABLE_TEXT_LOGGING 55 if ((this->m_dataBuffer.getSize() + sizeDelta) <= this->m_dataBuffer.getCapacity()) {
57 status = this->m_dataBuffer.serializeFrom(
id);
59 status = this->m_dataBuffer.serializeSize(size);
63 this->m_dataSize += sizeDelta;
81 #if !FW_DIRECT_PORT_CALLS 88 this->m_cmdIn_InputPort[port].
init();
93 this->m_cmdIn_InputPort[port].
setPortNum(port);
95 #if FW_OBJECT_NAMES == 1 99 this->m_objName.toChar(),
102 this->m_cmdIn_InputPort[port].setObjName(portName.
toChar());
107 #if !FW_DIRECT_PORT_CALLS 114 this->m_procRequest_InputPort[port].
init();
119 this->m_procRequest_InputPort[port].
setPortNum(port);
121 #if FW_OBJECT_NAMES == 1 125 this->m_objName.toChar(),
128 this->m_procRequest_InputPort[port].setObjName(portName.
toChar());
133 #if !FW_DIRECT_PORT_CALLS 140 this->m_cmdRegOut_OutputPort[port].
init();
142 #if FW_OBJECT_NAMES == 1 146 this->m_objName.toChar(),
149 this->m_cmdRegOut_OutputPort[port].setObjName(portName.
toChar());
154 #if !FW_DIRECT_PORT_CALLS 161 this->m_cmdResponseOut_OutputPort[port].
init();
163 #if FW_OBJECT_NAMES == 1 167 this->m_objName.toChar(),
170 this->m_cmdResponseOut_OutputPort[port].setObjName(portName.
toChar());
175 #if !FW_DIRECT_PORT_CALLS 182 this->m_dpGet_OutputPort[port].
init();
184 #if FW_OBJECT_NAMES == 1 188 this->m_objName.toChar(),
191 this->m_dpGet_OutputPort[port].setObjName(portName.
toChar());
196 #if !FW_DIRECT_PORT_CALLS 203 this->m_dpSend_OutputPort[port].
init();
205 #if FW_OBJECT_NAMES == 1 209 this->m_objName.toChar(),
212 this->m_dpSend_OutputPort[port].setObjName(portName.
toChar());
217 #if !FW_DIRECT_PORT_CALLS 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());
238 #if !FW_DIRECT_PORT_CALLS && FW_ENABLE_TEXT_LOGGING 242 port < static_cast<FwIndexType>(this->getNum_logTextOut_OutputPorts());
245 this->m_logTextOut_OutputPort[port].
init();
247 #if FW_OBJECT_NAMES == 1 251 this->m_objName.toChar(),
254 this->m_logTextOut_OutputPort[port].setObjName(portName.
toChar());
259 #if !FW_DIRECT_PORT_CALLS 266 this->m_prmGetOut_OutputPort[port].
init();
268 #if FW_OBJECT_NAMES == 1 272 this->m_objName.toChar(),
275 this->m_prmGetOut_OutputPort[port].setObjName(portName.
toChar());
280 #if !FW_DIRECT_PORT_CALLS 287 this->m_prmSetOut_OutputPort[port].
init();
289 #if FW_OBJECT_NAMES == 1 293 this->m_objName.toChar(),
296 this->m_prmSetOut_OutputPort[port].setObjName(portName.
toChar());
301 #if !FW_DIRECT_PORT_CALLS 308 this->m_timeCaller_OutputPort[port].
init();
310 #if FW_OBJECT_NAMES == 1 314 this->m_objName.toChar(),
317 this->m_timeCaller_OutputPort[port].setObjName(portName.
toChar());
322 #if !FW_DIRECT_PORT_CALLS 329 this->m_compressChunk_OutputPort[port].
init();
331 #if FW_OBJECT_NAMES == 1 335 this->m_objName.toChar(),
338 this->m_compressChunk_OutputPort[port].setObjName(portName.
toChar());
344 #if !FW_DIRECT_PORT_CALLS 355 static_cast<FwAssertArgType>(portNum)
358 return &this->m_cmdIn_InputPort[portNum];
363 #if !FW_DIRECT_PORT_CALLS 374 static_cast<FwAssertArgType>(portNum)
377 return &this->m_procRequest_InputPort[portNum];
382 #if !FW_DIRECT_PORT_CALLS 396 static_cast<FwAssertArgType>(portNum)
399 this->m_cmdRegOut_OutputPort[portNum].
addCallPort(port);
410 static_cast<FwAssertArgType>(portNum)
413 this->m_cmdResponseOut_OutputPort[portNum].
addCallPort(port);
424 static_cast<FwAssertArgType>(portNum)
427 this->m_dpGet_OutputPort[portNum].
addCallPort(port);
438 static_cast<FwAssertArgType>(portNum)
441 this->m_dpSend_OutputPort[portNum].
addCallPort(port);
452 static_cast<FwAssertArgType>(portNum)
455 this->m_logOut_OutputPort[portNum].
addCallPort(port);
458 #if FW_ENABLE_TEXT_LOGGING == 1 460 void DpCompressProcComponentBase ::
461 set_logTextOut_OutputPort(
467 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
468 static_cast<FwAssertArgType>(portNum)
471 this->m_logTextOut_OutputPort[portNum].addCallPort(port);
484 static_cast<FwAssertArgType>(portNum)
487 this->m_prmGetOut_OutputPort[portNum].
addCallPort(port);
498 static_cast<FwAssertArgType>(portNum)
501 this->m_prmSetOut_OutputPort[portNum].
addCallPort(port);
512 static_cast<FwAssertArgType>(portNum)
515 this->m_timeCaller_OutputPort[portNum].
addCallPort(port);
520 #if !FW_DIRECT_PORT_CALLS 534 static_cast<FwAssertArgType>(portNum)
537 this->m_compressChunk_OutputPort[portNum].
addCallPort(port);
542 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION 551 Fw::InputSerializePort* port
556 static_cast<FwAssertArgType>(portNum)
559 this->m_cmdRegOut_OutputPort[portNum].registerSerialPort(port);
565 Fw::InputSerializePort* port
570 static_cast<FwAssertArgType>(portNum)
573 this->m_cmdResponseOut_OutputPort[portNum].registerSerialPort(port);
579 Fw::InputSerializePort* port
584 static_cast<FwAssertArgType>(portNum)
587 this->m_dpSend_OutputPort[portNum].registerSerialPort(port);
593 Fw::InputSerializePort* port
598 static_cast<FwAssertArgType>(portNum)
601 this->m_logOut_OutputPort[portNum].registerSerialPort(port);
604 #if FW_ENABLE_TEXT_LOGGING == 1 606 void DpCompressProcComponentBase ::
607 set_logTextOut_OutputPort(
609 Fw::InputSerializePort* port
613 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
614 static_cast<FwAssertArgType>(portNum)
617 this->m_logTextOut_OutputPort[portNum].registerSerialPort(port);
625 Fw::InputSerializePort* port
630 static_cast<FwAssertArgType>(portNum)
633 this->m_prmSetOut_OutputPort[portNum].registerSerialPort(port);
639 Fw::InputSerializePort* port
644 static_cast<FwAssertArgType>(portNum)
647 this->m_timeCaller_OutputPort[portNum].registerSerialPort(port);
699 this->m_param_CHUNK_SIZE_valid = this->prmGetOut_out(
705 this->m_paramLock.
lock();
718 this->m_CHUNK_SIZE = 32768;
721 this->m_paramLock.
unlock();
722 this->
parameterLoaded(PARAMID_CHUNK_SIZE, this->m_param_CHUNK_SIZE_valid);
727 this->m_param_ENABLE_valid = this->prmGetOut_out(
733 this->m_paramLock.
lock();
749 this->m_paramLock.
unlock();
764 this->m_DidNotCompressThrottle = 0;
765 this->m_InvalidHeaderThrottle = 0;
766 this->m_BufferTooSmallForPacketThrottle = 0;
767 this->m_ContainerTooLargeThrottle = 0;
776 #if !FW_DIRECT_PORT_CALLS 787 static_cast<FwAssertArgType>(portNum)
790 return this->m_cmdRegOut_OutputPort[portNum].
isConnected();
798 static_cast<FwAssertArgType>(portNum)
801 return this->m_cmdResponseOut_OutputPort[portNum].
isConnected();
809 static_cast<FwAssertArgType>(portNum)
812 return this->m_dpGet_OutputPort[portNum].
isConnected();
820 static_cast<FwAssertArgType>(portNum)
823 return this->m_dpSend_OutputPort[portNum].
isConnected();
831 static_cast<FwAssertArgType>(portNum)
834 return this->m_logOut_OutputPort[portNum].
isConnected();
837 #if FW_ENABLE_TEXT_LOGGING == 1 839 bool DpCompressProcComponentBase ::
840 isConnected_logTextOut_OutputPort(
FwIndexType portNum)
const 843 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
844 static_cast<FwAssertArgType>(portNum)
847 return this->m_logTextOut_OutputPort[portNum].isConnected();
857 static_cast<FwAssertArgType>(portNum)
860 return this->m_prmGetOut_OutputPort[portNum].
isConnected();
868 static_cast<FwAssertArgType>(portNum)
871 return this->m_prmSetOut_OutputPort[portNum].
isConnected();
879 static_cast<FwAssertArgType>(portNum)
882 return this->m_timeCaller_OutputPort[portNum].
isConnected();
887 #if !FW_DIRECT_PORT_CALLS 898 static_cast<FwAssertArgType>(portNum)
901 return this->m_compressChunk_OutputPort[portNum].
isConnected();
922 FW_ASSERT(opCode >= idBase, static_cast<FwAssertArgType>(opCode), static_cast<FwAssertArgType>(idBase));
925 switch (opCode - idBase) {
986 static_cast<FwAssertArgType>(portNum)
996 #if !FW_DIRECT_PORT_CALLS 1012 static_cast<FwAssertArgType>(portNum)
1016 this->m_compressChunk_OutputPort[portNum].isConnected(),
1017 static_cast<FwAssertArgType>(portNum)
1019 return this->m_compressChunk_OutputPort[portNum].
invoke(
1040 this->cmdResponseOut_out(0, opCode, cmdSeq, response);
1057 this->timeCaller_out(0, _logTime);
1067 #if FW_AMPCS_COMPATIBLE 1072 static_cast<FwAssertArgType>(_status)
1076 #if FW_AMPCS_COMPATIBLE 1083 static_cast<FwAssertArgType>(_status)
1089 static_cast<FwAssertArgType>(_status)
1092 #if FW_AMPCS_COMPATIBLE 1099 static_cast<FwAssertArgType>(_status)
1105 static_cast<FwAssertArgType>(_status)
1108 #if FW_AMPCS_COMPATIBLE 1115 static_cast<FwAssertArgType>(_status)
1121 static_cast<FwAssertArgType>(_status)
1134 #if FW_ENABLE_TEXT_LOGGING 1135 if (this->isConnected_logTextOut_OutputPort(0)) {
1136 #if FW_OBJECT_NAMES == 1 1137 const char* _formatString =
1138 "(%s) %s: Compressed Data Product %" PRIu32
" from %" PRIu64
" to %" PRIu64
" bytes";
1140 const char* _formatString =
1141 "%s: Compressed Data Product %" PRIu32
" from %" PRIu64
" to %" PRIu64
" bytes";
1145 (void) _logString.
format(
1148 this->m_objName.toChar(),
1150 "CompressionComplete ",
1156 this->logTextOut_out(
1178 this->m_DidNotCompressThrottle++;
1184 this->timeCaller_out(0, _logTime);
1194 #if FW_AMPCS_COMPATIBLE 1199 static_cast<FwAssertArgType>(_status)
1203 #if FW_AMPCS_COMPATIBLE 1210 static_cast<FwAssertArgType>(_status)
1216 static_cast<FwAssertArgType>(_status)
1219 #if FW_AMPCS_COMPATIBLE 1226 static_cast<FwAssertArgType>(_status)
1232 static_cast<FwAssertArgType>(_status)
1245 #if FW_ENABLE_TEXT_LOGGING 1246 if (this->isConnected_logTextOut_OutputPort(0)) {
1247 #if FW_OBJECT_NAMES == 1 1248 const char* _formatString =
1249 "(%s) %s: Unable to reduce size of Data Product %" PRIu32
". Uncompressed size %" PRIu64
"";
1251 const char* _formatString =
1252 "%s: Unable to reduce size of Data Product %" PRIu32
". Uncompressed size %" PRIu64
"";
1256 (void) _logString.
format(
1259 this->m_objName.toChar(),
1266 this->logTextOut_out(
1288 this->m_InvalidHeaderThrottle++;
1294 this->timeCaller_out(0, _logTime);
1304 #if FW_AMPCS_COMPATIBLE 1309 static_cast<FwAssertArgType>(_status)
1313 #if FW_AMPCS_COMPATIBLE 1320 static_cast<FwAssertArgType>(_status)
1326 static_cast<FwAssertArgType>(_status)
1329 #if FW_AMPCS_COMPATIBLE 1332 static_cast<U8>(
sizeof(U32))
1336 static_cast<FwAssertArgType>(_status)
1342 static_cast<FwAssertArgType>(_status)
1355 #if FW_ENABLE_TEXT_LOGGING 1356 if (this->isConnected_logTextOut_OutputPort(0)) {
1357 #if FW_OBJECT_NAMES == 1 1358 const char* _formatString =
1359 "(%s) %s: Received buffer of size %" PRIu64
"; deserialization of container header failed with error code %" PRIu32
"";
1361 const char* _formatString =
1362 "%s: Received buffer of size %" PRIu64
"; deserialization of container header failed with error code %" PRIu32
"";
1366 (void) _logString.
format(
1369 this->m_objName.toChar(),
1376 this->logTextOut_out(
1398 this->m_BufferTooSmallForPacketThrottle++;
1404 this->timeCaller_out(0, _logTime);
1414 #if FW_AMPCS_COMPATIBLE 1419 static_cast<FwAssertArgType>(_status)
1423 #if FW_AMPCS_COMPATIBLE 1430 static_cast<FwAssertArgType>(_status)
1436 static_cast<FwAssertArgType>(_status)
1439 #if FW_AMPCS_COMPATIBLE 1446 static_cast<FwAssertArgType>(_status)
1452 static_cast<FwAssertArgType>(_status)
1465 #if FW_ENABLE_TEXT_LOGGING 1466 if (this->isConnected_logTextOut_OutputPort(0)) {
1467 #if FW_OBJECT_NAMES == 1 1468 const char* _formatString =
1469 "(%s) %s: Received buffer has size %" PRIu64
"; minimum required size is %" PRIu64
"";
1471 const char* _formatString =
1472 "%s: Received buffer has size %" PRIu64
"; minimum required size is %" PRIu64
"";
1476 (void) _logString.
format(
1479 this->m_objName.toChar(),
1481 "BufferTooSmallForPacket ",
1486 this->logTextOut_out(
1508 this->m_ContainerTooLargeThrottle++;
1514 this->timeCaller_out(0, _logTime);
1524 #if FW_AMPCS_COMPATIBLE 1529 static_cast<FwAssertArgType>(_status)
1533 #if FW_AMPCS_COMPATIBLE 1540 static_cast<FwAssertArgType>(_status)
1546 static_cast<FwAssertArgType>(_status)
1549 #if FW_AMPCS_COMPATIBLE 1556 static_cast<FwAssertArgType>(_status)
1562 static_cast<FwAssertArgType>(_status)
1575 #if FW_ENABLE_TEXT_LOGGING 1576 if (this->isConnected_logTextOut_OutputPort(0)) {
1577 #if FW_OBJECT_NAMES == 1 1578 const char* _formatString =
1579 "(%s) %s: Data Product %" PRIu32
" has data size %" PRIu64
", too large for a record size field";
1581 const char* _formatString =
1582 "%s: Data Product %" PRIu32
" has data size %" PRIu64
", too large for a record size field";
1586 (void) _logString.
format(
1589 this->m_objName.toChar(),
1591 "ContainerTooLarge ",
1596 this->logTextOut_out(
1615 this->m_DidNotCompressThrottle = 0;
1622 this->m_InvalidHeaderThrottle = 0;
1629 this->m_BufferTooSmallForPacketThrottle = 0;
1636 this->m_ContainerTooLargeThrottle = 0;
1674 this->m_paramLock.
lock();
1675 valid = this->m_param_CHUNK_SIZE_valid;
1677 _local = this->m_CHUNK_SIZE;
1679 this->m_paramLock.
unlock();
1687 this->m_paramLock.
lock();
1688 valid = this->m_param_ENABLE_valid;
1690 _local = this->m_ENABLE;
1692 this->m_paramLock.
unlock();
1718 static_cast<FwAssertArgType>(buffer.
getSize()));
1719 buffer.
setSize(static_cast<U32>(packetSize));
1723 this->dpSend_out(0, container.
getId(), buffer);
1735 this->timeCaller_out(0, _time);
1747 void DpCompressProcComponentBase ::
1770 void DpCompressProcComponentBase ::
1779 compPtr->procRequest_handlerBase(
1785 #if !FW_DIRECT_PORT_CALLS 1791 void DpCompressProcComponentBase ::
1799 static_cast<FwAssertArgType>(portNum)
1803 this->m_cmdRegOut_OutputPort[portNum].isConnected(),
1804 static_cast<FwAssertArgType>(portNum)
1806 this->m_cmdRegOut_OutputPort[portNum].
invoke(
1811 void DpCompressProcComponentBase ::
1821 static_cast<FwAssertArgType>(portNum)
1825 this->m_cmdResponseOut_OutputPort[portNum].isConnected(),
1826 static_cast<FwAssertArgType>(portNum)
1828 this->m_cmdResponseOut_OutputPort[portNum].
invoke(
1845 static_cast<FwAssertArgType>(portNum)
1849 this->m_dpGet_OutputPort[portNum].isConnected(),
1850 static_cast<FwAssertArgType>(portNum)
1852 return this->m_dpGet_OutputPort[portNum].
invoke(
1859 void DpCompressProcComponentBase ::
1868 static_cast<FwAssertArgType>(portNum)
1872 this->m_dpSend_OutputPort[portNum].isConnected(),
1873 static_cast<FwAssertArgType>(portNum)
1875 this->m_dpSend_OutputPort[portNum].
invoke(
1881 void DpCompressProcComponentBase ::
1892 static_cast<FwAssertArgType>(portNum)
1896 this->m_logOut_OutputPort[portNum].isConnected(),
1897 static_cast<FwAssertArgType>(portNum)
1899 this->m_logOut_OutputPort[portNum].
invoke(
1907 #if FW_ENABLE_TEXT_LOGGING 1909 void DpCompressProcComponentBase ::
1919 (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
1920 static_cast<FwAssertArgType>(portNum)
1924 this->m_logTextOut_OutputPort[portNum].isConnected(),
1925 static_cast<FwAssertArgType>(portNum)
1927 this->m_logTextOut_OutputPort[portNum].invoke(
1946 static_cast<FwAssertArgType>(portNum)
1950 this->m_prmGetOut_OutputPort[portNum].isConnected(),
1951 static_cast<FwAssertArgType>(portNum)
1953 return this->m_prmGetOut_OutputPort[portNum].
invoke(
1959 void DpCompressProcComponentBase ::
1968 static_cast<FwAssertArgType>(portNum)
1972 this->m_prmSetOut_OutputPort[portNum].isConnected(),
1973 static_cast<FwAssertArgType>(portNum)
1975 this->m_prmSetOut_OutputPort[portNum].
invoke(
1981 void DpCompressProcComponentBase ::
1989 static_cast<FwAssertArgType>(portNum)
1993 this->m_timeCaller_OutputPort[portNum].isConnected(),
1994 static_cast<FwAssertArgType>(portNum)
1996 this->m_timeCaller_OutputPort[portNum].
invoke(
2017 this->m_paramLock.
lock();
2018 this->m_CHUNK_SIZE = _localVal;
2020 this->m_paramLock.
unlock();
2037 this->m_paramLock.
lock();
2038 this->m_ENABLE = _localVal;
2040 this->m_paramLock.
unlock();
2052 paramSave_CHUNK_SIZE()
2061 this->m_paramLock.
lock();
2065 this->m_paramLock.
unlock();
2070 this->prmSetOut_out(
2089 this->m_paramLock.
lock();
2093 this->m_paramLock.
unlock();
2098 this->prmSetOut_out(
2113 ContainerId::T containerId,
2116 DpContainer& container
2120 const FwDpIdType globalId = baseId + containerId;
2123 const Fw::Success::T status = this->dpGet_out(0, globalId, size, buffer);
2127 container = DpContainer(globalId, buffer, baseId);
2128 container.setPriority(priority);
Serialization/Deserialization operation was successful.
bool isConnected_logOut_OutputPort(FwIndexType portNum) const
void addCallPort(InputTimePort *callPort)
Register an input port.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum) const
void log_WARNING_HI_BufferTooSmallForPacket(FwSizeType buffer_size, FwSizeType min_size)
void setTimeTag(Fw::Time timeTag)
Set the time tag.
FwIdType FwOpcodeType
The type of a command opcode.
static constexpr FwIndexType getNum_dpSend_OutputPorts()
virtual void parametersLoaded()
Called whenever parameters are loaded.
static constexpr FwIndexType getNum_compressChunk_OutputPorts()
void set_compressChunk_OutputPort(FwIndexType portNum, Svc::InputCompressChunkPort *port)
Connect port to compressChunk[portNum].
static constexpr FwIndexType getNum_prmGetOut_OutputPorts()
void init()
Initialization function.
#define FW_PARAM_OK(paramValid)
FwIdType getIdBase() const
PlatformSizeType FwSizeType
U32 FwDpPriorityType
The type of a data product priority.
void log_WARNING_HI_InvalidHeader(FwSizeType buffer_size, U32 error_code)
Throttle reset count for ContainerTooLarge.
void addCallPort(InputDpSendPort *callPort)
Register an input port.
void setSize(FwSizeType size)
bool isConnected_prmGetOut_OutputPort(FwIndexType portNum) const
SerializeStatus deserializeTo(U8 &val, Endianness mode=Endianness::BIG) override
Deserialize an 8-bit unsigned integer value.
FwIdType FwPrmIdType
The type of a parameter identifier.
void addCallPort(InputPrmSetPort *callPort)
Register an input port.
static constexpr FwIndexType getNum_procRequest_InputPorts()
No room left in the buffer to serialize data.
virtual void parameterLoaded(FwPrmIdType id, Fw::ParamValid valid)
Called for each parameter when parameters are loaded.
void dpSend(DpContainer &container, Fw::Time timeTag=Fw::ZERO_TIME)
Send a data product.
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum) const
Number of bytes to use in a compression chunk.
Fw::SerializeStatus serializeRecord_CompressionRecord(const U8 *array, FwSizeType size)
PassiveComponentBase(const char *name)
Named constructor.
bool isConnected_prmSetOut_OutputPort(FwIndexType portNum) const
Error occurred when deserializing the container header.
Opcode to save parameter ENABLE.
Fw::InputCmdPort * get_cmdIn_InputPort(FwIndexType portNum)
Enum representing a command response.
void set_prmGetOut_OutputPort(FwIndexType portNum, Fw::InputPrmGetPort *port)
Connect port to prmGetOut[portNum].
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.
bool isConnected_cmdRegOut_OutputPort(FwIndexType portNum) const
bool isConnected_compressChunk_OutputPort(FwIndexType portNum) const
void init()
Initialization function.
Software diagnostic events.
void addCallPort(InputPrmGetPort *callPort)
Register an input port.
A data product container.
void init()
Object initializer.
void cmdIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
Handler base-class function for input port cmdIn.
SerializeStatus
forward declaration for string
Throttle reset count for InvalidHeader.
virtual SerializeStatus deserializeTo(U8 &val, Endianness mode=Endianness::BIG)=0
Deserialize an 8-bit unsigned integer value.
static constexpr FwIndexType getNum_dpGet_OutputPorts()
void addCallPort(InputCompressChunkPort *callPort)
Register an input port.
Opcode to set parameter ENABLE.
void log_ACTIVITY_LO_DidNotCompress(FwDpIdType dp_id, FwSizeType data_size)
Log event DidNotCompress.
FwIdType FwEventIdType
The type of an event identifier.
void set_logOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to logOut[portNum].
DpCompressProcComponentBase(const char *compName="")
Construct DpCompressProcComponentBase object.
bool isConnected_dpSend_OutputPort(FwIndexType portNum) const
void invoke(FwOpcodeType opCode) const
Invoke a port connection.
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects) ...
Auto-generated base for DpCompressProc component.
void init()
Initialization function.
Data was the wrong format (e.g. wrong packet type)
static constexpr FwIndexType getNum_logOut_OutputPorts()
Less important informational events.
Fw::ParamValid invoke(FwPrmIdType id, Fw::ParamBuffer &val) const
Omit length from serialization.
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
Fw::InputBufferSendPort * get_procRequest_InputPort(FwIndexType portNum)
Svc::CompressionAlgorithm compressChunk_out(FwIndexType portNum, Fw::Buffer &buffer, FwSizeType min_compression, FwSizeType write_offset) const
Invoke output port compressChunk.
static constexpr FwIndexType getNum_cmdIn_InputPorts()
void set_dpGet_OutputPort(FwIndexType portNum, Fw::InputDpGetPort *port)
Connect port to dpGet[portNum].
void procRequest_handlerBase(FwIndexType portNum, Fw::Buffer &fwBuffer)
Handler base-class function for input port procRequest.
void invoke(Fw::Time &time) const
Invoke a port connection.
static constexpr FwIndexType getNum_prmSetOut_OutputPorts()
void set_prmSetOut_OutputPort(FwIndexType portNum, Fw::InputPrmSetPort *port)
Connect port to prmSetOut[portNum].
void invoke(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response) const
Invoke a port connection.
void log_WARNING_HI_ContainerTooLarge_ThrottleClear()
Reset throttle value for ContainerTooLarge.
void invalidateBuffer()
Invalidate the packet buffer.
void log_WARNING_HI_BufferTooSmallForPacket_ThrottleClear()
Reset throttle value for BufferTooSmallForPacket.
Throttle reset count for DidNotCompress.
void log_DIAGNOSTIC_CompressionComplete(FwDpIdType dp_id, FwSizeType initial_size, FwSizeType final_size) const
Log event CompressionComplete.
Opcode to set parameter CHUNK_SIZE.
A serious but recoverable event.
FwSizeType FwSizeStoreType
static constexpr FwSizeType getPacketSizeForDataSize(FwSizeType dataSize)
Get the packet size for a given data size.
const char * toChar() const
Convert to a C-style char*.
Enum representing event severity.
virtual ~DpCompressProcComponentBase()
Destroy DpCompressProcComponentBase object.
FwSizeType getPacketSize() const
Get the packet size corresponding to the data size.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
Fw::Buffer getBuffer() const
Enabled and disabled states.
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
void init()
Initialization function.
Command successfully executed.
void log_ACTIVITY_LO_DidNotCompress_ThrottleClear()
Reset throttle value for DidNotCompress.
DpContainer()
Constructor with default initialization.
uint8_t U8
8-bit unsigned integer
static constexpr FwIndexType getNum_cmdResponseOut_OutputPorts()
Received container is too large for its size to be stored in a record size field. ...
void init()
Initialization function.
FwSizeType getSize() const
void lock()
lock the mutex and assert success
Svc::CompressionAlgorithm invoke(Fw::Buffer &buffer, FwSizeType min_compression, FwSizeType write_offset) const
Command had execution error.
FwIdType FwDpIdType
The type of a data product identifier.
virtual void parameterUpdated(FwPrmIdType id)
Called whenever a parameter is updated.
Throttle reset count for BufferTooSmallForPacket.
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port connection.
Received buffer is too small to hold a data product packet.
FwSizeStoreType paramGet_CHUNK_SIZE(Fw::ParamValid &valid)
Fw::Success invoke(FwDpIdType id, FwSizeType dataSize, Fw::Buffer &buffer) const
PlatformIndexType FwIndexType
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
void addCallPort(InputDpGetPort *callPort)
Register an input port.
void addCallPort(InputLogPort *callPort)
Register an input port.
void init()
Initialization function.
void unlock()
alias for unLock to meet BasicLockable requirements
Command failed validation.
RateGroupDivider component implementation.
bool isConnected_dpGet_OutputPort(FwIndexType portNum) const
Enum representing parameter validity.
void set_dpSend_OutputPort(FwIndexType portNum, Fw::InputDpSendPort *port)
Connect port to dpSend[portNum].
void invoke(FwPrmIdType id, Fw::ParamBuffer &val) const
Invoke a port connection.
virtual void procRequest_handler(FwIndexType portNum, Fw::Buffer &fwBuffer)=0
Handler for input port procRequest.
Implementation of malloc based allocator.
void log_WARNING_HI_ContainerTooLarge(FwDpIdType dp_id, FwSizeType data_size)
void loadParameters()
Load the parameters from a parameter source.
void regCommands()
Register commands with the Command Dispatcher.
void cmdResponse_out(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdResponse response)
Emit command response.
void init()
Initialization function.
void log_WARNING_HI_InvalidHeader_ThrottleClear()
Reset throttle value for InvalidHeader.
Fw::Enabled paramGet_ENABLE(Fw::ParamValid &valid)
void set_cmdRegOut_OutputPort(FwIndexType portNum, Fw::InputCmdRegPort *port)
Connect port to cmdRegOut[portNum].
void init()
Initialization function.
void invoke(FwDpIdType id, const Fw::Buffer &buffer) const
Invoke a port connection.
static constexpr FwIndexType getNum_cmdRegOut_OutputPorts()
void init()
Initialization function.
Chunk size to use when passing data to the compression backend.
Opcode to save parameter CHUNK_SIZE.
PlatformAssertArgType FwAssertArgType
The type of arguments to assert functions.
void addCallPort(InputCmdResponsePort *callPort)
Register an input port.