F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
SignalPortAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title SignalPortAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for Signal port
5 // ======================================================================
6 
7 #ifndef Fw_SignalPortAc_HPP
8 #define Fw_SignalPortAc_HPP
9 
10 #include "Fw/FPrimeBasicTypes.hpp"
12 #if !FW_DIRECT_PORT_CALLS
16 #endif
17 
18 namespace Fw {
19 
24  {
25 
26  public:
27 
28  // ----------------------------------------------------------------------
29  // Public constants for SignalPortBuffer
30  // ----------------------------------------------------------------------
31 
34  static constexpr FwSizeType CAPACITY =
35  0;
36 
37  public:
38 
39  // ----------------------------------------------------------------------
40  // Public member functions for SignalPortBuffer
41  // ----------------------------------------------------------------------
42 
45 
46  }
47 
48  };
49 
50 #if !FW_DIRECT_PORT_CALLS
51 
55  public Fw::InputPortBase
56  {
57 
58  public:
59 
60  // ----------------------------------------------------------------------
61  // Public types for InputSignalPort
62  // ----------------------------------------------------------------------
63 
65  typedef void (*CompFuncPtr)(
66  Fw::PassiveComponentBase* callComp,
67  FwIndexType portNum
68  );
69 
70  public:
71 
72  // ----------------------------------------------------------------------
73  // Public constructors for InputSignalPort
74  // ----------------------------------------------------------------------
75 
78 
79  public:
80 
81  // ----------------------------------------------------------------------
82  // Public member functions for InputSignalPort
83  // ----------------------------------------------------------------------
84 
86  void init();
87 
89  void addCallComp(
90  Fw::PassiveComponentBase* callComp,
91  CompFuncPtr funcPtr
92  );
93 
95  void invoke();
96 
97  private:
98 
99  // ----------------------------------------------------------------------
100  // Private member functions for InputSignalPort
101  // ----------------------------------------------------------------------
102 
103 #if FW_PORT_SERIALIZATION == 1
104 
107  Fw::SerializeStatus invokeSerial(
108  Fw::LinearBufferBase& _buffer
109  );
110 
111 #endif
112 
113  private:
114 
115  // ----------------------------------------------------------------------
116  // Private member variables for InputSignalPort
117  // ----------------------------------------------------------------------
118 
120  CompFuncPtr m_func;
121 
122  };
123 
127  public Fw::OutputPortBase
128  {
129 
130  public:
131 
132  // ----------------------------------------------------------------------
133  // Public constructors for OutputSignalPort
134  // ----------------------------------------------------------------------
135 
138 
139  public:
140 
141  // ----------------------------------------------------------------------
142  // Public member functions for OutputSignalPort
143  // ----------------------------------------------------------------------
144 
146  void init();
147 
149  void addCallPort(
150  InputSignalPort* callPort
151  );
152 
154  void invoke() const;
155 
156  private:
157 
158  // ----------------------------------------------------------------------
159  // Private member variables for OutputSignalPort
160  // ----------------------------------------------------------------------
161 
163  InputSignalPort* m_port;
164 
165  };
166 
167 #endif
168 
169 }
170 
171 #endif
SignalPortBuffer()
Constructor.
PlatformSizeType FwSizeType
SerializeStatus
forward declaration for string
OutputSignalPort()
Constructor.
void invoke()
Invoke a port interface.
void init()
Initialization function.
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
void(* CompFuncPtr)(Fw::PassiveComponentBase *callComp, FwIndexType portNum)
The port callback function type.
void init()
Initialization function.
void invoke() const
Invoke a port connection.
void addCallPort(InputSignalPort *callPort)
Register an input port.
PlatformIndexType FwIndexType
InputSignalPort()
Constructor.
Implementation of malloc based allocator.
static constexpr FwSizeType CAPACITY