F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
DpWriterComponentAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title DpWriterComponentAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for DpWriter component base class
5 // ======================================================================
6 
7 #ifndef Svc_DpWriterComponentAc_HPP
8 #define Svc_DpWriterComponentAc_HPP
9 
10 #include <atomic>
11 
13 #include "Fw/Cmd/CmdPortAc.hpp"
14 #include "Fw/Cmd/CmdRegPortAc.hpp"
16 #include "Fw/Cmd/CmdString.hpp"
18 #include "Fw/FPrimeBasicTypes.hpp"
19 #include "Fw/Log/LogPortAc.hpp"
20 #include "Fw/Log/LogString.hpp"
21 #include "Fw/Log/LogTextPortAc.hpp"
22 #if !FW_DIRECT_PORT_CALLS
24 #endif
25 #if !FW_DIRECT_PORT_CALLS
27 #endif
28 #include "Fw/Time/TimePortAc.hpp"
29 #include "Fw/Tlm/TlmPortAc.hpp"
30 #include "Fw/Tlm/TlmString.hpp"
35 
36 namespace Svc {
37 
44  {
45 
46  // ----------------------------------------------------------------------
47  // Friend classes
48  // ----------------------------------------------------------------------
49 
51  friend class DpWriterTesterBase;
53  friend class DpWriterTester;
54 
55  protected:
56 
57  // ----------------------------------------------------------------------
58  // Constants
59  // ----------------------------------------------------------------------
60 
62  enum {
64  };
65 
67  enum {
70  };
71 
73  enum {
80  };
81 
83  enum {
87  };
88 
90  enum {
92  };
93 
95  enum {
104  };
105 
107  enum {
115  };
116 
118  enum {
124  };
125 
126  public:
127 
128  // ----------------------------------------------------------------------
129  // Component initialization
130  // ----------------------------------------------------------------------
131 
133  void init(
134  FwSizeType queueDepth,
135  FwEnumStoreType instance = 0
136  );
137 
138 #if !FW_DIRECT_PORT_CALLS
139 
140  public:
141 
142  // ----------------------------------------------------------------------
143  // Getters for special input ports
144  // ----------------------------------------------------------------------
145 
150  FwIndexType portNum
151  );
152 
153 #endif
154 
155 #if !FW_DIRECT_PORT_CALLS
156 
157  public:
158 
159  // ----------------------------------------------------------------------
160  // Getters for typed input ports
161  // ----------------------------------------------------------------------
162 
167  FwIndexType portNum
168  );
169 
174  FwIndexType portNum
175  );
176 
177 #endif
178 
179 #if !FW_DIRECT_PORT_CALLS
180 
181  public:
182 
183  // ----------------------------------------------------------------------
184  // Connect input ports to special output ports
185  // ----------------------------------------------------------------------
186 
189  FwIndexType portNum,
190  Fw::InputCmdRegPort* port
191  );
192 
195  FwIndexType portNum,
197  );
198 
201  FwIndexType portNum,
202  Fw::InputLogPort* port
203  );
204 
205 #if FW_ENABLE_TEXT_LOGGING == 1
206 
208  void set_textEventOut_OutputPort(
209  FwIndexType portNum,
210  Fw::InputLogTextPort* port
211  );
212 
213 #endif
214 
217  FwIndexType portNum,
218  Fw::InputTimePort* port
219  );
220 
223  FwIndexType portNum,
224  Fw::InputTlmPort* port
225  );
226 
227 #endif
228 
229 #if !FW_DIRECT_PORT_CALLS
230 
231  public:
232 
233  // ----------------------------------------------------------------------
234  // Connect typed input ports to typed output ports
235  // ----------------------------------------------------------------------
236 
239  FwIndexType portNum,
241  );
242 
245  FwIndexType portNum,
247  );
248 
251  FwIndexType portNum,
253  );
254 
255 #endif
256 
257 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
258 
259  public:
260 
261  // ----------------------------------------------------------------------
262  // Connect serial input ports to special output ports
263  // ----------------------------------------------------------------------
264 
267  FwIndexType portNum,
268  Fw::InputSerializePort* port
269  );
270 
273  FwIndexType portNum,
274  Fw::InputSerializePort* port
275  );
276 
279  FwIndexType portNum,
280  Fw::InputSerializePort* port
281  );
282 
283 #if FW_ENABLE_TEXT_LOGGING == 1
284 
286  void set_textEventOut_OutputPort(
287  FwIndexType portNum,
288  Fw::InputSerializePort* port
289  );
290 
291 #endif
292 
295  FwIndexType portNum,
296  Fw::InputSerializePort* port
297  );
298 
301  FwIndexType portNum,
302  Fw::InputSerializePort* port
303  );
304 
305 #endif
306 
307 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
308 
309  public:
310 
311  // ----------------------------------------------------------------------
312  // Connect serial input ports to typed output ports
313  // ----------------------------------------------------------------------
314 
317  FwIndexType portNum,
318  Fw::InputSerializePort* port
319  );
320 
323  FwIndexType portNum,
324  Fw::InputSerializePort* port
325  );
326 
329  FwIndexType portNum,
330  Fw::InputSerializePort* port
331  );
332 
333 #endif
334 
335  public:
336 
337  // ----------------------------------------------------------------------
338  // Command registration
339  // ----------------------------------------------------------------------
340 
344  void regCommands();
345 
346  protected:
347 
348  // ----------------------------------------------------------------------
349  // Component construction and destruction
350  // ----------------------------------------------------------------------
351 
354  const char* compName = ""
355  );
356 
358  virtual ~DpWriterComponentBase();
359 
360  protected:
361 
362  // ----------------------------------------------------------------------
363  // Getters for numbers of special input ports
364  // ----------------------------------------------------------------------
365 
370  return NUM_CMDIN_INPUT_PORTS;
371  }
372 
373  protected:
374 
375  // ----------------------------------------------------------------------
376  // Getters for numbers of typed input ports
377  // ----------------------------------------------------------------------
378 
384  }
385 
391  }
392 
393  protected:
394 
395  // ----------------------------------------------------------------------
396  // Getters for numbers of special output ports
397  // ----------------------------------------------------------------------
398 
404  }
405 
411  }
412 
418  }
419 
420 #if FW_ENABLE_TEXT_LOGGING == 1
421 
425  static constexpr FwIndexType getNum_textEventOut_OutputPorts() {
427  }
428 
429 #endif
430 
436  }
437 
443  }
444 
445  protected:
446 
447  // ----------------------------------------------------------------------
448  // Getters for numbers of typed output ports
449  // ----------------------------------------------------------------------
450 
456  }
457 
463  }
464 
470  }
471 
472  protected:
473 
474  // ----------------------------------------------------------------------
475  // Connection status queries for special output ports
476  // ----------------------------------------------------------------------
477 
482  FwIndexType portNum
483  ) const;
484 
489  FwIndexType portNum
490  ) const;
491 
496  FwIndexType portNum
497  ) const;
498 
499 #if FW_ENABLE_TEXT_LOGGING == 1
500 
504  bool isConnected_textEventOut_OutputPort(
505  FwIndexType portNum
506  ) const;
507 
508 #endif
509 
514  FwIndexType portNum
515  ) const;
516 
521  FwIndexType portNum
522  ) const;
523 
524  protected:
525 
526  // ----------------------------------------------------------------------
527  // Connection status queries for typed output ports
528  // ----------------------------------------------------------------------
529 
534  FwIndexType portNum
535  ) const;
536 
541  FwIndexType portNum
542  ) const;
543 
548  FwIndexType portNum
549  ) const;
550 
551 #if FW_DIRECT_PORT_CALLS
552  public:
553 #else
554  protected:
555 #endif
556 
557  // ----------------------------------------------------------------------
558  // Port handler base-class functions for special input ports
559  //
560  // Call these functions directly to bypass the corresponding ports
561  // ----------------------------------------------------------------------
562 
564  void cmdIn_handlerBase(
565  FwIndexType portNum,
566  FwOpcodeType opCode,
567  U32 cmdSeq,
568  Fw::CmdArgBuffer& args
569  );
570 
571  protected:
572 
573  // ----------------------------------------------------------------------
574  // Handlers to implement for typed input ports
575  // ----------------------------------------------------------------------
576 
578  virtual void bufferSendIn_handler(
579  FwIndexType portNum,
580  Fw::Buffer& fwBuffer
581  ) = 0;
582 
584  virtual void schedIn_handler(
585  FwIndexType portNum,
586  U32 context
587  ) = 0;
588 
589 #if FW_DIRECT_PORT_CALLS
590  public:
591 #else
592  protected:
593 #endif
594 
595  // ----------------------------------------------------------------------
596  // Port handler base-class functions for typed input ports
597  //
598  // Call these functions directly to bypass the corresponding ports
599  // ----------------------------------------------------------------------
600 
603  FwIndexType portNum,
604  Fw::Buffer& fwBuffer
605  );
606 
608  void schedIn_handlerBase(
609  FwIndexType portNum,
610  U32 context
611  );
612 
613  protected:
614 
615  // ----------------------------------------------------------------------
616  // Pre-message hooks for typed async input ports
617  //
618  // Each of these functions is invoked just before processing a message
619  // on the corresponding port. By default, they do nothing. You can
620  // override them to provide specific pre-message behavior.
621  // ----------------------------------------------------------------------
622 
624  virtual void bufferSendIn_preMsgHook(
625  FwIndexType portNum,
626  Fw::Buffer& fwBuffer
627  );
628 
630  virtual void schedIn_preMsgHook(
631  FwIndexType portNum,
632  U32 context
633  );
634 
635  protected:
636 
637  // ----------------------------------------------------------------------
638  // Invocation functions for typed output ports
639  // ----------------------------------------------------------------------
640 
643  FwIndexType portNum,
644  Fw::Buffer& fwBuffer
645  ) const;
646 
648  void dpWrittenOut_out(
649  FwIndexType portNum,
650  const Fw::StringBase& fileName,
651  FwDpPriorityType priority,
652  FwSizeType size
653  ) const;
654 
657  FwIndexType portNum,
658  Fw::Buffer& fwBuffer
659  ) const;
660 
661  protected:
662 
663  // ----------------------------------------------------------------------
664  // Command response
665  // ----------------------------------------------------------------------
666 
668  void cmdResponse_out(
669  FwOpcodeType opCode,
670  U32 cmdSeq,
671  Fw::CmdResponse response
672  );
673 
674  protected:
675 
676  // ----------------------------------------------------------------------
677  // Command handlers to implement
678  // ----------------------------------------------------------------------
679 
683  virtual void CLEAR_EVENT_THROTTLE_cmdHandler(
684  FwOpcodeType opCode,
685  U32 cmdSeq
686  ) = 0;
687 
688  protected:
689 
690  // ----------------------------------------------------------------------
691  // Command handler base-class functions
692  //
693  // Call these functions directly to bypass the command input port
694  // ----------------------------------------------------------------------
695 
700  FwOpcodeType opCode,
701  U32 cmdSeq,
702  Fw::CmdArgBuffer& args
703  );
704 
705  protected:
706 
707  // ----------------------------------------------------------------------
708  // Pre-message hooks for async commands
709  //
710  // Each of these functions is invoked just before processing the
711  // corresponding command. By default they do nothing. You can
712  // override them to provide specific pre-command behavior.
713  // ----------------------------------------------------------------------
714 
716  virtual void CLEAR_EVENT_THROTTLE_preMsgHook(
717  FwOpcodeType opCode,
718  U32 cmdSeq
719  );
720 
721  protected:
722 
723  // ----------------------------------------------------------------------
724  // Event logging functions
725  // ----------------------------------------------------------------------
726 
731 
736  FwSizeType bufferSize,
737  U32 minSize
738  );
739 
744  FwSizeType bufferSize,
745  U32 storedHash,
746  U32 computedHash
747  );
748 
753  FwSizeType bufferSize,
754  U32 errorCode
755  );
756 
761  FwSizeType bufferSize,
762  U32 minSize
763  );
764 
769  U32 status,
770  const Fw::StringBase& file
771  );
772 
777  U32 status,
778  U32 bytesWritten,
779  U32 bytesToWrite,
780  const Fw::StringBase& file
781  );
782 
787  U32 bytes,
788  const Fw::StringBase& file
789  ) const;
790 
791  protected:
792 
793  // ----------------------------------------------------------------------
794  // Event throttle reset functions
795  // ----------------------------------------------------------------------
796 
799 
802 
805 
808 
811 
814 
817 
818  protected:
819 
820  // ----------------------------------------------------------------------
821  // Telemetry serialized write
822  // ----------------------------------------------------------------------
823 
828  void tlmWrite(
829  FwChanIdType id,
830  Fw::TlmBuffer& _tlmBuff,
831  Fw::Time _tlmTime = Fw::Time()
832  ) const;
833 
834  protected:
835 
836  // ----------------------------------------------------------------------
837  // Telemetry write functions
838  // ----------------------------------------------------------------------
839 
844  U32 arg,
845  Fw::Time _tlmTime = Fw::Time()
846  );
847 
852  U64 arg,
853  Fw::Time _tlmTime = Fw::Time()
854  );
855 
860  U32 arg,
861  Fw::Time _tlmTime = Fw::Time()
862  );
863 
868  U32 arg,
869  Fw::Time _tlmTime = Fw::Time()
870  );
871 
875  void tlmWrite_NumErrors(
876  U32 arg,
877  Fw::Time _tlmTime = Fw::Time()
878  );
879 
880  protected:
881 
882  // ----------------------------------------------------------------------
883  // Time
884  // ----------------------------------------------------------------------
885 
889  Fw::Time getTime() const;
890 
891  private:
892 
893  // ----------------------------------------------------------------------
894  // Message dispatch functions
895  // ----------------------------------------------------------------------
896 
898  virtual MsgDispatchStatus doDispatch();
899 
900  private:
901 
902  // ----------------------------------------------------------------------
903  // Calls for messages received on special input ports
904  // ----------------------------------------------------------------------
905 
907  static void m_p_cmdIn_in(
908  Fw::PassiveComponentBase* callComp,
909  FwIndexType portNum,
910  FwOpcodeType opCode,
911  U32 cmdSeq,
912  Fw::CmdArgBuffer& args
913  );
914 
915  private:
916 
917  // ----------------------------------------------------------------------
918  // Calls for messages received on typed input ports
919  // ----------------------------------------------------------------------
920 
922  static void m_p_bufferSendIn_in(
923  Fw::PassiveComponentBase* callComp,
924  FwIndexType portNum,
925  Fw::Buffer& fwBuffer
926  );
927 
929  static void m_p_schedIn_in(
930  Fw::PassiveComponentBase* callComp,
931  FwIndexType portNum,
932  U32 context
933  );
934 
935  private:
936 
937  // ----------------------------------------------------------------------
938  // Invocation functions for special output ports
939  // ----------------------------------------------------------------------
940 
942  void cmdRegIn_out(
943  FwIndexType portNum,
944  FwOpcodeType opCode
945  ) const;
946 
948  void cmdResponseOut_out(
949  FwIndexType portNum,
950  FwOpcodeType opCode,
951  U32 cmdSeq,
952  const Fw::CmdResponse& response
953  ) const;
954 
956  void eventOut_out(
957  FwIndexType portNum,
958  FwEventIdType id,
959  Fw::Time& timeTag,
960  const Fw::LogSeverity& severity,
961  Fw::LogBuffer& args
962  ) const;
963 
964 #if FW_ENABLE_TEXT_LOGGING
965 
967  void textEventOut_out(
968  FwIndexType portNum,
969  FwEventIdType id,
970  Fw::Time& timeTag,
971  const Fw::LogSeverity& severity,
972  Fw::TextLogString& text
973  ) const;
974 
975 #endif
976 
978  void timeGetOut_out(
979  FwIndexType portNum,
980  Fw::Time& time
981  ) const;
982 
984  void tlmOut_out(
985  FwIndexType portNum,
986  FwChanIdType id,
987  Fw::Time& timeTag,
988  Fw::TlmBuffer& val
989  ) const;
990 
991 #if !FW_DIRECT_PORT_CALLS
992 
993  private:
994 
995  // ----------------------------------------------------------------------
996  // Special input ports
997  // ----------------------------------------------------------------------
998 
1000  Fw::InputCmdPort m_cmdIn_InputPort[NUM_CMDIN_INPUT_PORTS];
1001 
1002 #endif
1003 
1004 #if !FW_DIRECT_PORT_CALLS
1005 
1006  private:
1007 
1008  // ----------------------------------------------------------------------
1009  // Typed input ports
1010  // ----------------------------------------------------------------------
1011 
1013  Fw::InputBufferSendPort m_bufferSendIn_InputPort[NUM_BUFFERSENDIN_INPUT_PORTS];
1014 
1016  Svc::InputSchedPort m_schedIn_InputPort[NUM_SCHEDIN_INPUT_PORTS];
1017 
1018 #endif
1019 
1020 #if !FW_DIRECT_PORT_CALLS
1021 
1022  private:
1023 
1024  // ----------------------------------------------------------------------
1025  // Special output ports
1026  // ----------------------------------------------------------------------
1027 
1029  Fw::OutputCmdRegPort m_cmdRegIn_OutputPort[NUM_CMDREGIN_OUTPUT_PORTS];
1030 
1032  Fw::OutputCmdResponsePort m_cmdResponseOut_OutputPort[NUM_CMDRESPONSEOUT_OUTPUT_PORTS];
1033 
1035  Fw::OutputLogPort m_eventOut_OutputPort[NUM_EVENTOUT_OUTPUT_PORTS];
1036 
1037 #if FW_ENABLE_TEXT_LOGGING == 1
1038 
1040  Fw::OutputLogTextPort m_textEventOut_OutputPort[NUM_TEXTEVENTOUT_OUTPUT_PORTS];
1041 
1042 #endif
1043 
1045  Fw::OutputTimePort m_timeGetOut_OutputPort[NUM_TIMEGETOUT_OUTPUT_PORTS];
1046 
1048  Fw::OutputTlmPort m_tlmOut_OutputPort[NUM_TLMOUT_OUTPUT_PORTS];
1049 
1050 #endif
1051 
1052 #if !FW_DIRECT_PORT_CALLS
1053 
1054  private:
1055 
1056  // ----------------------------------------------------------------------
1057  // Typed output ports
1058  // ----------------------------------------------------------------------
1059 
1061  Fw::OutputBufferSendPort m_deallocBufferSendOut_OutputPort[NUM_DEALLOCBUFFERSENDOUT_OUTPUT_PORTS];
1062 
1064  Svc::OutputDpWrittenPort m_dpWrittenOut_OutputPort[NUM_DPWRITTENOUT_OUTPUT_PORTS];
1065 
1067  Fw::OutputBufferSendPort m_procBufferSendOut_OutputPort[NUM_PROCBUFFERSENDOUT_OUTPUT_PORTS];
1068 
1069 #endif
1070 
1071  private:
1072 
1073  // ----------------------------------------------------------------------
1074  // Counter values for event throttling
1075  // ----------------------------------------------------------------------
1076 
1078  std::atomic<FwIndexType> m_InvalidBufferThrottle;
1079 
1081  std::atomic<FwIndexType> m_BufferTooSmallForPacketThrottle;
1082 
1084  std::atomic<FwIndexType> m_InvalidHeaderHashThrottle;
1085 
1087  std::atomic<FwIndexType> m_InvalidHeaderThrottle;
1088 
1090  std::atomic<FwIndexType> m_BufferTooSmallForDataThrottle;
1091 
1093  std::atomic<FwIndexType> m_FileOpenErrorThrottle;
1094 
1096  std::atomic<FwIndexType> m_FileWriteErrorThrottle;
1097 
1098  private:
1099 
1100  // ----------------------------------------------------------------------
1101  // First update flags for telemetry channels
1102  // ----------------------------------------------------------------------
1103 
1105  bool m_first_update_NumBuffersReceived = true;
1106 
1108  bool m_first_update_NumBytesWritten = true;
1109 
1111  bool m_first_update_NumSuccessfulWrites = true;
1112 
1114  bool m_first_update_NumFailedWrites = true;
1115 
1117  bool m_first_update_NumErrors = true;
1118 
1119  private:
1120 
1121  // ----------------------------------------------------------------------
1122  // Last value storage for telemetry channels
1123  // ----------------------------------------------------------------------
1124 
1126  U32 m_last_NumBuffersReceived = {};
1127 
1129  U64 m_last_NumBytesWritten = {};
1130 
1132  U32 m_last_NumSuccessfulWrites = {};
1133 
1135  U32 m_last_NumFailedWrites = {};
1136 
1138  U32 m_last_NumErrors = {};
1139 
1140  };
1141 
1142 }
1143 
1144 #endif
static constexpr FwIndexType getNum_bufferSendIn_InputPorts()
virtual ~DpWriterComponentBase()
Destroy DpWriterComponentBase object.
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum) const
Received buffer is too small to hold the data specified in the header.
FwIdType FwOpcodeType
The type of a command opcode.
void log_WARNING_HI_BufferTooSmallForData(FwSizeType bufferSize, U32 minSize)
void schedIn_handlerBase(FwIndexType portNum, U32 context)
Handler base-class function for input port schedIn.
virtual void CLEAR_EVENT_THROTTLE_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
PlatformSizeType FwSizeType
static constexpr FwIndexType getNum_cmdResponseOut_OutputPorts()
bool isConnected_cmdRegIn_OutputPort(FwIndexType portNum) const
U32 FwDpPriorityType
The type of a data product priority.
I32 FwEnumStoreType
Received buffer is too small to hold a data product packet.
static constexpr FwIndexType getNum_eventOut_OutputPorts()
void set_dpWrittenOut_OutputPort(FwIndexType portNum, Svc::InputDpWrittenPort *port)
Connect port to dpWrittenOut[portNum].
void cmdResponse_out(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdResponse response)
Emit command response.
friend class DpWriterTester
Friend class tester implementation to support white-box testing.
bool isConnected_timeGetOut_OutputPort(FwIndexType portNum) const
Enum representing a command response.
virtual void bufferSendIn_preMsgHook(FwIndexType portNum, Fw::Buffer &fwBuffer)
Pre-message hook for async input port bufferSendIn.
static constexpr FwIndexType getNum_schedIn_InputPorts()
An error occurred when writing to a file.
static constexpr FwIndexType getNum_timeGetOut_OutputPorts()
void cmdIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
Handler base-class function for input port cmdIn.
The received buffer has an invalid header hash.
static constexpr FwIndexType getNum_deallocBufferSendOut_OutputPorts()
void tlmWrite_NumErrors(U32 arg, Fw::Time _tlmTime=Fw::Time())
void init()
Object initializer.
Definition: ObjBase.cpp:24
bool isConnected_dpWrittenOut_OutputPort(FwIndexType portNum) const
Fw::InputBufferSendPort * get_bufferSendIn_InputPort(FwIndexType portNum)
bool isConnected_deallocBufferSendOut_OutputPort(FwIndexType portNum) const
void deallocBufferSendOut_out(FwIndexType portNum, Fw::Buffer &fwBuffer) const
Invoke output port deallocBufferSendOut.
void log_WARNING_HI_InvalidBuffer_ThrottleClear()
Reset throttle value for InvalidBuffer.
FwIdType FwEventIdType
The type of an event identifier.
void tlmWrite_NumFailedWrites(U32 arg, Fw::Time _tlmTime=Fw::Time())
void log_WARNING_HI_FileWriteError_ThrottleClear()
Reset throttle value for FileWriteError.
void CLEAR_EVENT_THROTTLE_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void tlmWrite(FwChanIdType id, Fw::TlmBuffer &_tlmBuff, Fw::Time _tlmTime=Fw::Time()) const
void dpWrittenOut_out(FwIndexType portNum, const Fw::StringBase &fileName, FwDpPriorityType priority, FwSizeType size) const
Invoke output port dpWrittenOut.
Error occurred when deserializing the packet header.
Fw::InputCmdPort * get_cmdIn_InputPort(FwIndexType portNum)
void log_WARNING_HI_InvalidHeaderHash(FwSizeType bufferSize, U32 storedHash, U32 computedHash)
void set_deallocBufferSendOut_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to deallocBufferSendOut[portNum].
FwIdType FwChanIdType
The type of a telemetry channel identifier.
void tlmWrite_NumBuffersReceived(U32 arg, Fw::Time _tlmTime=Fw::Time())
static constexpr FwIndexType getNum_procBufferSendOut_OutputPorts()
void procBufferSendOut_out(FwIndexType portNum, Fw::Buffer &fwBuffer) const
Invoke output port procBufferSendOut.
void log_WARNING_HI_BufferTooSmallForData_ThrottleClear()
Reset throttle value for BufferTooSmallForData.
void log_WARNING_HI_FileOpenError_ThrottleClear()
Reset throttle value for FileOpenError.
static constexpr FwIndexType getNum_tlmOut_OutputPorts()
DpWriterComponentBase(const char *compName="")
Construct DpWriterComponentBase object.
void log_WARNING_HI_FileOpenError(U32 status, const Fw::StringBase &file)
void log_WARNING_HI_InvalidHeader_ThrottleClear()
Reset throttle value for InvalidHeader.
Enum representing event severity.
void log_WARNING_HI_InvalidHeaderHash_ThrottleClear()
Reset throttle value for InvalidHeaderHash.
bool isConnected_procBufferSendOut_OutputPort(FwIndexType portNum) const
void log_WARNING_HI_BufferTooSmallForPacket(FwSizeType bufferSize, U32 minSize)
void regCommands()
Register commands with the Command Dispatcher.
void set_tlmOut_OutputPort(FwIndexType portNum, Fw::InputTlmPort *port)
Connect port to tlmOut[portNum].
bool isConnected_eventOut_OutputPort(FwIndexType portNum) const
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
void log_ACTIVITY_LO_FileWritten(U32 bytes, const Fw::StringBase &file) const
static constexpr FwIndexType getNum_cmdRegIn_OutputPorts()
virtual void CLEAR_EVENT_THROTTLE_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CLEAR_EVENT_THROTTLE.
virtual void schedIn_handler(FwIndexType portNum, U32 context)=0
Handler for input port schedIn.
PlatformIndexType FwIndexType
static constexpr FwIndexType getNum_dpWrittenOut_OutputPorts()
void set_eventOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to eventOut[portNum].
bool isConnected_tlmOut_OutputPort(FwIndexType portNum) const
virtual void bufferSendIn_handler(FwIndexType portNum, Fw::Buffer &fwBuffer)=0
Handler for input port bufferSendIn.
void log_WARNING_HI_FileWriteError(U32 status, U32 bytesWritten, U32 bytesToWrite, const Fw::StringBase &file)
void set_timeGetOut_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeGetOut[portNum].
RateGroupDivider component implementation.
friend class DpWriterTesterBase
Friend class tester to support autocoded test harness.
void bufferSendIn_handlerBase(FwIndexType portNum, Fw::Buffer &fwBuffer)
Handler base-class function for input port bufferSendIn.
void tlmWrite_NumBytesWritten(U64 arg, Fw::Time _tlmTime=Fw::Time())
An error occurred when opening a file.
virtual void schedIn_preMsgHook(FwIndexType portNum, U32 context)
Pre-message hook for async input port schedIn.
void log_WARNING_HI_InvalidHeader(FwSizeType bufferSize, U32 errorCode)
void tlmWrite_NumSuccessfulWrites(U32 arg, Fw::Time _tlmTime=Fw::Time())
void log_WARNING_HI_BufferTooSmallForPacket_ThrottleClear()
Reset throttle value for BufferTooSmallForPacket.
void set_procBufferSendOut_OutputPort(FwIndexType portNum, Fw::InputBufferSendPort *port)
Connect port to procBufferSendOut[portNum].
Svc::InputSchedPort * get_schedIn_InputPort(FwIndexType portNum)
void set_cmdRegIn_OutputPort(FwIndexType portNum, Fw::InputCmdRegPort *port)
Connect port to cmdRegIn[portNum].
Auto-generated base for DpWriter component.
static constexpr FwIndexType getNum_cmdIn_InputPorts()
#define U64(C)
Definition: sha.h:181