F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
EnableSectionPortAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title EnableSectionPortAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for EnableSection port
5 // ======================================================================
6 
7 #ifndef Svc_EnableSectionPortAc_HPP
8 #define Svc_EnableSectionPortAc_HPP
9 
10 #include "Fw/FPrimeBasicTypes.hpp"
14 #if !FW_DIRECT_PORT_CALLS
18 #endif
19 
20 namespace Svc {
21 
26  {
27 
28  public:
29 
30  // ----------------------------------------------------------------------
31  // Public constants for EnableSectionPortBuffer
32  // ----------------------------------------------------------------------
33 
36  static constexpr FwSizeType CAPACITY =
39 
40  public:
41 
42  // ----------------------------------------------------------------------
43  // Public member functions for EnableSectionPortBuffer
44  // ----------------------------------------------------------------------
45 
48 
49  }
50 
51  private:
52 
53  // ----------------------------------------------------------------------
54  // Private member variables
55  // ----------------------------------------------------------------------
56 
57  U8 m_buff[CAPACITY];
58 
59  };
60 
64 
65  public:
66 
67  // ----------------------------------------------------------------------
68  // Public constructors for EnableSectionPortSerializer
69  // ----------------------------------------------------------------------
70 
73 
74  public:
75 
76  // ----------------------------------------------------------------------
77  // Public member functions for EnableSectionPortSerializer
78  // ----------------------------------------------------------------------
79 
82  Fw::SerialBufferBase& _buffer
83  );
84 
85  public:
86 
87  // ----------------------------------------------------------------------
88  // Public static functions for EnableSectionPortSerializer
89  // ----------------------------------------------------------------------
90 
93  const Svc::TelemetrySection& section,
94  const Fw::Enabled& enabled,
95  Fw::SerialBufferBase& _buffer
96  );
97 
98  public:
99 
100  // ----------------------------------------------------------------------
101  // Public member variables for EnableSectionPortSerializer
102  // ----------------------------------------------------------------------
103 
106 
107  };
108 
109 #if !FW_DIRECT_PORT_CALLS
110 
114  public Fw::InputPortBase
115  {
116 
117  public:
118 
119  // ----------------------------------------------------------------------
120  // Public types for InputEnableSectionPort
121  // ----------------------------------------------------------------------
122 
124  typedef void (*CompFuncPtr)(
125  Fw::PassiveComponentBase* callComp,
126  FwIndexType portNum,
127  const Svc::TelemetrySection& section,
128  const Fw::Enabled& enabled
129  );
130 
131  public:
132 
133  // ----------------------------------------------------------------------
134  // Public constructors for InputEnableSectionPort
135  // ----------------------------------------------------------------------
136 
139 
140  public:
141 
142  // ----------------------------------------------------------------------
143  // Public member functions for InputEnableSectionPort
144  // ----------------------------------------------------------------------
145 
147  void init();
148 
150  void addCallComp(
151  Fw::PassiveComponentBase* callComp,
152  CompFuncPtr funcPtr
153  );
154 
156  void invoke(
157  const Svc::TelemetrySection& section,
158  const Fw::Enabled& enabled
159  );
160 
161  private:
162 
163  // ----------------------------------------------------------------------
164  // Private member functions for InputEnableSectionPort
165  // ----------------------------------------------------------------------
166 
167 #if FW_PORT_SERIALIZATION == 1
168 
171  Fw::SerializeStatus invokeSerial(
172  Fw::LinearBufferBase& _buffer
173  );
174 
175 #endif
176 
177  private:
178 
179  // ----------------------------------------------------------------------
180  // Private member variables for InputEnableSectionPort
181  // ----------------------------------------------------------------------
182 
184  CompFuncPtr m_func;
185 
186  };
187 
191  public Fw::OutputPortBase
192  {
193 
194  public:
195 
196  // ----------------------------------------------------------------------
197  // Public constructors for OutputEnableSectionPort
198  // ----------------------------------------------------------------------
199 
202 
203  public:
204 
205  // ----------------------------------------------------------------------
206  // Public member functions for OutputEnableSectionPort
207  // ----------------------------------------------------------------------
208 
210  void init();
211 
213  void addCallPort(
214  InputEnableSectionPort* callPort
215  );
216 
218  void invoke(
219  const Svc::TelemetrySection& section,
220  const Fw::Enabled& enabled
221  ) const;
222 
223  private:
224 
225  // ----------------------------------------------------------------------
226  // Private member variables for OutputEnableSectionPort
227  // ----------------------------------------------------------------------
228 
230  InputEnableSectionPort* m_port;
231 
232  };
233 
234 #endif
235 
236 }
237 
238 #endif
static constexpr FwSizeType CAPACITY
PlatformSizeType FwSizeType
static Fw::SerializeStatus serializePortArgs(const Svc::TelemetrySection &section, const Fw::Enabled &enabled, Fw::SerialBufferBase &_buffer)
Serialize port arguments into a buffer.
SerializeStatus
forward declaration for string
void(* CompFuncPtr)(Fw::PassiveComponentBase *callComp, FwIndexType portNum, const Svc::TelemetrySection &section, const Fw::Enabled &enabled)
The port callback function type.
void init()
Initialization function.
The size of the serial representation.
Enabled and disabled states.
void init()
Initialization function.
uint8_t U8
8-bit unsigned integer
Definition: BasicTypes.h:54
void addCallPort(InputEnableSectionPort *callPort)
Register an input port.
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
PlatformIndexType FwIndexType
void invoke(const Svc::TelemetrySection &section, const Fw::Enabled &enabled) const
Invoke a port connection.
The size of the serial representation.
RateGroupDivider component implementation.
Fw::SerializeStatus deserializePortArgs(Fw::SerialBufferBase &_buffer)
Deserialze port arguments into members.
void invoke(const Svc::TelemetrySection &section, const Fw::Enabled &enabled)
Invoke a port interface.
Implementation of malloc based allocator.