F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
AssertFatalAdapterComponentAc.cpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title AssertFatalAdapterComponentAc.cpp
3 // \author Generated by fpp-to-cpp
4 // \brief cpp file for AssertFatalAdapter component base class
5 // ======================================================================
6 
7 #include "Fw/Types/Assert.hpp"
9 #if FW_ENABLE_TEXT_LOGGING
10 #include "Fw/Types/String.hpp"
11 #endif
13 
14 namespace Svc {
15 
16  // ----------------------------------------------------------------------
17  // Component initialization
18  // ----------------------------------------------------------------------
19 
22  {
23  // Initialize base class
25 
26  // Connect output port Log
27  for (
28  FwIndexType port = 0;
29  port < static_cast<FwIndexType>(this->getNum_Log_OutputPorts());
30  port++
31  ) {
32  this->m_Log_OutputPort[port].init();
33 
34 #if FW_OBJECT_NAMES == 1
35  Fw::ObjectName portName;
36  portName.format(
37  "%s_Log_OutputPort[%" PRI_FwIndexType "]",
38  this->m_objName.toChar(),
39  port
40  );
41  this->m_Log_OutputPort[port].setObjName(portName.toChar());
42 #endif
43  }
44 
45 #if FW_ENABLE_TEXT_LOGGING == 1
46  // Connect output port LogText
47  for (
48  FwIndexType port = 0;
49  port < static_cast<FwIndexType>(this->getNum_LogText_OutputPorts());
50  port++
51  ) {
52  this->m_LogText_OutputPort[port].init();
53 
54 #if FW_OBJECT_NAMES == 1
55  Fw::ObjectName portName;
56  portName.format(
57  "%s_LogText_OutputPort[%" PRI_FwIndexType "]",
58  this->m_objName.toChar(),
59  port
60  );
61  this->m_LogText_OutputPort[port].setObjName(portName.toChar());
62 #endif
63  }
64 #endif
65 
66  // Connect output port Time
67  for (
68  FwIndexType port = 0;
69  port < static_cast<FwIndexType>(this->getNum_Time_OutputPorts());
70  port++
71  ) {
72  this->m_Time_OutputPort[port].init();
73 
74 #if FW_OBJECT_NAMES == 1
75  Fw::ObjectName portName;
76  portName.format(
77  "%s_Time_OutputPort[%" PRI_FwIndexType "]",
78  this->m_objName.toChar(),
79  port
80  );
81  this->m_Time_OutputPort[port].setObjName(portName.toChar());
82 #endif
83  }
84  }
85 
86  // ----------------------------------------------------------------------
87  // Connect input ports to special output ports
88  // ----------------------------------------------------------------------
89 
92  FwIndexType portNum,
93  Fw::InputLogPort* port
94  )
95  {
96  FW_ASSERT(
97  (0 <= portNum) && (portNum < this->getNum_Log_OutputPorts()),
98  static_cast<FwAssertArgType>(portNum)
99  );
100 
101  this->m_Log_OutputPort[portNum].addCallPort(port);
102  }
103 
104 #if FW_ENABLE_TEXT_LOGGING == 1
105 
106  void AssertFatalAdapterComponentBase ::
107  set_LogText_OutputPort(
108  FwIndexType portNum,
110  )
111  {
112  FW_ASSERT(
113  (0 <= portNum) && (portNum < this->getNum_LogText_OutputPorts()),
114  static_cast<FwAssertArgType>(portNum)
115  );
116 
117  this->m_LogText_OutputPort[portNum].addCallPort(port);
118  }
119 
120 #endif
121 
124  FwIndexType portNum,
125  Fw::InputTimePort* port
126  )
127  {
128  FW_ASSERT(
129  (0 <= portNum) && (portNum < this->getNum_Time_OutputPorts()),
130  static_cast<FwAssertArgType>(portNum)
131  );
132 
133  this->m_Time_OutputPort[portNum].addCallPort(port);
134  }
135 
136 #if FW_PORT_SERIALIZATION
137 
138  // ----------------------------------------------------------------------
139  // Connect serial input ports to special output ports
140  // ----------------------------------------------------------------------
141 
144  FwIndexType portNum,
145  Fw::InputSerializePort* port
146  )
147  {
148  FW_ASSERT(
149  (0 <= portNum) && (portNum < this->getNum_Log_OutputPorts()),
150  static_cast<FwAssertArgType>(portNum)
151  );
152 
153  this->m_Log_OutputPort[portNum].registerSerialPort(port);
154  }
155 
156 #if FW_ENABLE_TEXT_LOGGING == 1
157 
158  void AssertFatalAdapterComponentBase ::
159  set_LogText_OutputPort(
160  FwIndexType portNum,
161  Fw::InputSerializePort* port
162  )
163  {
164  FW_ASSERT(
165  (0 <= portNum) && (portNum < this->getNum_LogText_OutputPorts()),
166  static_cast<FwAssertArgType>(portNum)
167  );
168 
169  this->m_LogText_OutputPort[portNum].registerSerialPort(port);
170  }
171 
172 #endif
173 
176  FwIndexType portNum,
177  Fw::InputSerializePort* port
178  )
179  {
180  FW_ASSERT(
181  (0 <= portNum) && (portNum < this->getNum_Time_OutputPorts()),
182  static_cast<FwAssertArgType>(portNum)
183  );
184 
185  this->m_Time_OutputPort[portNum].registerSerialPort(port);
186  }
187 
188 #endif
189 
190  // ----------------------------------------------------------------------
191  // Component construction and destruction
192  // ----------------------------------------------------------------------
193 
195  AssertFatalAdapterComponentBase(const char* compName) :
196  Fw::PassiveComponentBase(compName)
197  {
198 
199  }
200 
203  {
204 
205  }
206 
207  // ----------------------------------------------------------------------
208  // Connection status queries for special output ports
209  // ----------------------------------------------------------------------
210 
213  {
214  FW_ASSERT(
215  (0 <= portNum) && (portNum < this->getNum_Log_OutputPorts()),
216  static_cast<FwAssertArgType>(portNum)
217  );
218 
219  return this->m_Log_OutputPort[portNum].isConnected();
220  }
221 
222 #if FW_ENABLE_TEXT_LOGGING == 1
223 
224  bool AssertFatalAdapterComponentBase ::
225  isConnected_LogText_OutputPort(FwIndexType portNum)
226  {
227  FW_ASSERT(
228  (0 <= portNum) && (portNum < this->getNum_LogText_OutputPorts()),
229  static_cast<FwAssertArgType>(portNum)
230  );
231 
232  return this->m_LogText_OutputPort[portNum].isConnected();
233  }
234 
235 #endif
236 
239  {
240  FW_ASSERT(
241  (0 <= portNum) && (portNum < this->getNum_Time_OutputPorts()),
242  static_cast<FwAssertArgType>(portNum)
243  );
244 
245  return this->m_Time_OutputPort[portNum].isConnected();
246  }
247 
248  // ----------------------------------------------------------------------
249  // Event logging functions
250  // ----------------------------------------------------------------------
251 
254  const Fw::StringBase& file,
255  U32 line
256  ) const
257  {
258  // Get the time
259  Fw::Time _logTime;
260  if (this->m_Time_OutputPort[0].isConnected()) {
261  this->m_Time_OutputPort[0].invoke(_logTime);
262  }
263 
264  FwEventIdType _id = static_cast<FwEventIdType>(0);
265 
266  _id = this->getIdBase() + EVENTID_AF_ASSERT_0;
267 
268  // Emit the event on the log port
269  if (this->m_Log_OutputPort[0].isConnected()) {
270  Fw::LogBuffer _logBuff;
272 
273 #if FW_AMPCS_COMPATIBLE
274  // Serialize the number of arguments
275  _status = _logBuff.serializeFrom(static_cast<U8>(2 + 1));
276  FW_ASSERT(
277  _status == Fw::FW_SERIALIZE_OK,
278  static_cast<FwAssertArgType>(_status)
279  );
280 
281  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
282  _status = _logBuff.serializeFrom(static_cast<U8>(4));
283  FW_ASSERT(
284  _status == Fw::FW_SERIALIZE_OK,
285  static_cast<FwAssertArgType>(_status)
286  );
287 
288  _status = _logBuff.serializeFrom(static_cast<U32>(0));
289  FW_ASSERT(
290  _status == Fw::FW_SERIALIZE_OK,
291  static_cast<FwAssertArgType>(_status)
292  );
293 #endif
294 
295  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
296  FW_ASSERT(
297  _status == Fw::FW_SERIALIZE_OK,
298  static_cast<FwAssertArgType>(_status)
299  );
300 
301 #if FW_AMPCS_COMPATIBLE
302  // Serialize the argument size
303  _status = _logBuff.serializeFrom(
304  static_cast<U8>(sizeof(U32))
305  );
306  FW_ASSERT(
307  _status == Fw::FW_SERIALIZE_OK,
308  static_cast<FwAssertArgType>(_status)
309  );
310 #endif
311  _status = _logBuff.serializeFrom(line);
312  FW_ASSERT(
313  _status == Fw::FW_SERIALIZE_OK,
314  static_cast<FwAssertArgType>(_status)
315  );
316 
317  this->m_Log_OutputPort[0].invoke(
318  _id,
319  _logTime,
321  _logBuff
322  );
323  }
324 
325  // Emit the event on the text log port
326 #if FW_ENABLE_TEXT_LOGGING
327  if (this->m_LogText_OutputPort[0].isConnected()) {
328 #if FW_OBJECT_NAMES == 1
329  const char* _formatString =
330  "(%s) %s: Assert in file %s, line %" PRIu32 "";
331 #else
332  const char* _formatString =
333  "%s: Assert in file %s, line %" PRIu32 "";
334 #endif
335 
336  Fw::TextLogString _logString;
337  _logString.format(
338  _formatString,
339 #if FW_OBJECT_NAMES == 1
340  this->m_objName.toChar(),
341 #endif
342  "AF_ASSERT_0 ",
343  file.toChar(),
344  line
345  );
346 
347  this->m_LogText_OutputPort[0].invoke(
348  _id,
349  _logTime,
351  _logString
352  );
353  }
354 #endif
355  }
356 
359  const Fw::StringBase& file,
360  U32 line,
361  U32 arg1
362  ) const
363  {
364  // Get the time
365  Fw::Time _logTime;
366  if (this->m_Time_OutputPort[0].isConnected()) {
367  this->m_Time_OutputPort[0].invoke(_logTime);
368  }
369 
370  FwEventIdType _id = static_cast<FwEventIdType>(0);
371 
372  _id = this->getIdBase() + EVENTID_AF_ASSERT_1;
373 
374  // Emit the event on the log port
375  if (this->m_Log_OutputPort[0].isConnected()) {
376  Fw::LogBuffer _logBuff;
378 
379 #if FW_AMPCS_COMPATIBLE
380  // Serialize the number of arguments
381  _status = _logBuff.serializeFrom(static_cast<U8>(3 + 1));
382  FW_ASSERT(
383  _status == Fw::FW_SERIALIZE_OK,
384  static_cast<FwAssertArgType>(_status)
385  );
386 
387  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
388  _status = _logBuff.serializeFrom(static_cast<U8>(4));
389  FW_ASSERT(
390  _status == Fw::FW_SERIALIZE_OK,
391  static_cast<FwAssertArgType>(_status)
392  );
393 
394  _status = _logBuff.serializeFrom(static_cast<U32>(0));
395  FW_ASSERT(
396  _status == Fw::FW_SERIALIZE_OK,
397  static_cast<FwAssertArgType>(_status)
398  );
399 #endif
400 
401  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
402  FW_ASSERT(
403  _status == Fw::FW_SERIALIZE_OK,
404  static_cast<FwAssertArgType>(_status)
405  );
406 
407 #if FW_AMPCS_COMPATIBLE
408  // Serialize the argument size
409  _status = _logBuff.serializeFrom(
410  static_cast<U8>(sizeof(U32))
411  );
412  FW_ASSERT(
413  _status == Fw::FW_SERIALIZE_OK,
414  static_cast<FwAssertArgType>(_status)
415  );
416 #endif
417  _status = _logBuff.serializeFrom(line);
418  FW_ASSERT(
419  _status == Fw::FW_SERIALIZE_OK,
420  static_cast<FwAssertArgType>(_status)
421  );
422 
423 #if FW_AMPCS_COMPATIBLE
424  // Serialize the argument size
425  _status = _logBuff.serializeFrom(
426  static_cast<U8>(sizeof(U32))
427  );
428  FW_ASSERT(
429  _status == Fw::FW_SERIALIZE_OK,
430  static_cast<FwAssertArgType>(_status)
431  );
432 #endif
433  _status = _logBuff.serializeFrom(arg1);
434  FW_ASSERT(
435  _status == Fw::FW_SERIALIZE_OK,
436  static_cast<FwAssertArgType>(_status)
437  );
438 
439  this->m_Log_OutputPort[0].invoke(
440  _id,
441  _logTime,
443  _logBuff
444  );
445  }
446 
447  // Emit the event on the text log port
448 #if FW_ENABLE_TEXT_LOGGING
449  if (this->m_LogText_OutputPort[0].isConnected()) {
450 #if FW_OBJECT_NAMES == 1
451  const char* _formatString =
452  "(%s) %s: Assert in file %s, line %" PRIu32 ": %" PRIu32 "";
453 #else
454  const char* _formatString =
455  "%s: Assert in file %s, line %" PRIu32 ": %" PRIu32 "";
456 #endif
457 
458  Fw::TextLogString _logString;
459  _logString.format(
460  _formatString,
461 #if FW_OBJECT_NAMES == 1
462  this->m_objName.toChar(),
463 #endif
464  "AF_ASSERT_1 ",
465  file.toChar(),
466  line,
467  arg1
468  );
469 
470  this->m_LogText_OutputPort[0].invoke(
471  _id,
472  _logTime,
474  _logString
475  );
476  }
477 #endif
478  }
479 
482  const Fw::StringBase& file,
483  U32 line,
484  U32 arg1,
485  U32 arg2
486  ) const
487  {
488  // Get the time
489  Fw::Time _logTime;
490  if (this->m_Time_OutputPort[0].isConnected()) {
491  this->m_Time_OutputPort[0].invoke(_logTime);
492  }
493 
494  FwEventIdType _id = static_cast<FwEventIdType>(0);
495 
496  _id = this->getIdBase() + EVENTID_AF_ASSERT_2;
497 
498  // Emit the event on the log port
499  if (this->m_Log_OutputPort[0].isConnected()) {
500  Fw::LogBuffer _logBuff;
502 
503 #if FW_AMPCS_COMPATIBLE
504  // Serialize the number of arguments
505  _status = _logBuff.serializeFrom(static_cast<U8>(4 + 1));
506  FW_ASSERT(
507  _status == Fw::FW_SERIALIZE_OK,
508  static_cast<FwAssertArgType>(_status)
509  );
510 
511  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
512  _status = _logBuff.serializeFrom(static_cast<U8>(4));
513  FW_ASSERT(
514  _status == Fw::FW_SERIALIZE_OK,
515  static_cast<FwAssertArgType>(_status)
516  );
517 
518  _status = _logBuff.serializeFrom(static_cast<U32>(0));
519  FW_ASSERT(
520  _status == Fw::FW_SERIALIZE_OK,
521  static_cast<FwAssertArgType>(_status)
522  );
523 #endif
524 
525  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
526  FW_ASSERT(
527  _status == Fw::FW_SERIALIZE_OK,
528  static_cast<FwAssertArgType>(_status)
529  );
530 
531 #if FW_AMPCS_COMPATIBLE
532  // Serialize the argument size
533  _status = _logBuff.serializeFrom(
534  static_cast<U8>(sizeof(U32))
535  );
536  FW_ASSERT(
537  _status == Fw::FW_SERIALIZE_OK,
538  static_cast<FwAssertArgType>(_status)
539  );
540 #endif
541  _status = _logBuff.serializeFrom(line);
542  FW_ASSERT(
543  _status == Fw::FW_SERIALIZE_OK,
544  static_cast<FwAssertArgType>(_status)
545  );
546 
547 #if FW_AMPCS_COMPATIBLE
548  // Serialize the argument size
549  _status = _logBuff.serializeFrom(
550  static_cast<U8>(sizeof(U32))
551  );
552  FW_ASSERT(
553  _status == Fw::FW_SERIALIZE_OK,
554  static_cast<FwAssertArgType>(_status)
555  );
556 #endif
557  _status = _logBuff.serializeFrom(arg1);
558  FW_ASSERT(
559  _status == Fw::FW_SERIALIZE_OK,
560  static_cast<FwAssertArgType>(_status)
561  );
562 
563 #if FW_AMPCS_COMPATIBLE
564  // Serialize the argument size
565  _status = _logBuff.serializeFrom(
566  static_cast<U8>(sizeof(U32))
567  );
568  FW_ASSERT(
569  _status == Fw::FW_SERIALIZE_OK,
570  static_cast<FwAssertArgType>(_status)
571  );
572 #endif
573  _status = _logBuff.serializeFrom(arg2);
574  FW_ASSERT(
575  _status == Fw::FW_SERIALIZE_OK,
576  static_cast<FwAssertArgType>(_status)
577  );
578 
579  this->m_Log_OutputPort[0].invoke(
580  _id,
581  _logTime,
583  _logBuff
584  );
585  }
586 
587  // Emit the event on the text log port
588 #if FW_ENABLE_TEXT_LOGGING
589  if (this->m_LogText_OutputPort[0].isConnected()) {
590 #if FW_OBJECT_NAMES == 1
591  const char* _formatString =
592  "(%s) %s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 "";
593 #else
594  const char* _formatString =
595  "%s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 "";
596 #endif
597 
598  Fw::TextLogString _logString;
599  _logString.format(
600  _formatString,
601 #if FW_OBJECT_NAMES == 1
602  this->m_objName.toChar(),
603 #endif
604  "AF_ASSERT_2 ",
605  file.toChar(),
606  line,
607  arg1,
608  arg2
609  );
610 
611  this->m_LogText_OutputPort[0].invoke(
612  _id,
613  _logTime,
615  _logString
616  );
617  }
618 #endif
619  }
620 
623  const Fw::StringBase& file,
624  U32 line,
625  U32 arg1,
626  U32 arg2,
627  U32 arg3
628  ) const
629  {
630  // Get the time
631  Fw::Time _logTime;
632  if (this->m_Time_OutputPort[0].isConnected()) {
633  this->m_Time_OutputPort[0].invoke(_logTime);
634  }
635 
636  FwEventIdType _id = static_cast<FwEventIdType>(0);
637 
638  _id = this->getIdBase() + EVENTID_AF_ASSERT_3;
639 
640  // Emit the event on the log port
641  if (this->m_Log_OutputPort[0].isConnected()) {
642  Fw::LogBuffer _logBuff;
644 
645 #if FW_AMPCS_COMPATIBLE
646  // Serialize the number of arguments
647  _status = _logBuff.serializeFrom(static_cast<U8>(5 + 1));
648  FW_ASSERT(
649  _status == Fw::FW_SERIALIZE_OK,
650  static_cast<FwAssertArgType>(_status)
651  );
652 
653  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
654  _status = _logBuff.serializeFrom(static_cast<U8>(4));
655  FW_ASSERT(
656  _status == Fw::FW_SERIALIZE_OK,
657  static_cast<FwAssertArgType>(_status)
658  );
659 
660  _status = _logBuff.serializeFrom(static_cast<U32>(0));
661  FW_ASSERT(
662  _status == Fw::FW_SERIALIZE_OK,
663  static_cast<FwAssertArgType>(_status)
664  );
665 #endif
666 
667  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
668  FW_ASSERT(
669  _status == Fw::FW_SERIALIZE_OK,
670  static_cast<FwAssertArgType>(_status)
671  );
672 
673 #if FW_AMPCS_COMPATIBLE
674  // Serialize the argument size
675  _status = _logBuff.serializeFrom(
676  static_cast<U8>(sizeof(U32))
677  );
678  FW_ASSERT(
679  _status == Fw::FW_SERIALIZE_OK,
680  static_cast<FwAssertArgType>(_status)
681  );
682 #endif
683  _status = _logBuff.serializeFrom(line);
684  FW_ASSERT(
685  _status == Fw::FW_SERIALIZE_OK,
686  static_cast<FwAssertArgType>(_status)
687  );
688 
689 #if FW_AMPCS_COMPATIBLE
690  // Serialize the argument size
691  _status = _logBuff.serializeFrom(
692  static_cast<U8>(sizeof(U32))
693  );
694  FW_ASSERT(
695  _status == Fw::FW_SERIALIZE_OK,
696  static_cast<FwAssertArgType>(_status)
697  );
698 #endif
699  _status = _logBuff.serializeFrom(arg1);
700  FW_ASSERT(
701  _status == Fw::FW_SERIALIZE_OK,
702  static_cast<FwAssertArgType>(_status)
703  );
704 
705 #if FW_AMPCS_COMPATIBLE
706  // Serialize the argument size
707  _status = _logBuff.serializeFrom(
708  static_cast<U8>(sizeof(U32))
709  );
710  FW_ASSERT(
711  _status == Fw::FW_SERIALIZE_OK,
712  static_cast<FwAssertArgType>(_status)
713  );
714 #endif
715  _status = _logBuff.serializeFrom(arg2);
716  FW_ASSERT(
717  _status == Fw::FW_SERIALIZE_OK,
718  static_cast<FwAssertArgType>(_status)
719  );
720 
721 #if FW_AMPCS_COMPATIBLE
722  // Serialize the argument size
723  _status = _logBuff.serializeFrom(
724  static_cast<U8>(sizeof(U32))
725  );
726  FW_ASSERT(
727  _status == Fw::FW_SERIALIZE_OK,
728  static_cast<FwAssertArgType>(_status)
729  );
730 #endif
731  _status = _logBuff.serializeFrom(arg3);
732  FW_ASSERT(
733  _status == Fw::FW_SERIALIZE_OK,
734  static_cast<FwAssertArgType>(_status)
735  );
736 
737  this->m_Log_OutputPort[0].invoke(
738  _id,
739  _logTime,
741  _logBuff
742  );
743  }
744 
745  // Emit the event on the text log port
746 #if FW_ENABLE_TEXT_LOGGING
747  if (this->m_LogText_OutputPort[0].isConnected()) {
748 #if FW_OBJECT_NAMES == 1
749  const char* _formatString =
750  "(%s) %s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 "";
751 #else
752  const char* _formatString =
753  "%s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 "";
754 #endif
755 
756  Fw::TextLogString _logString;
757  _logString.format(
758  _formatString,
759 #if FW_OBJECT_NAMES == 1
760  this->m_objName.toChar(),
761 #endif
762  "AF_ASSERT_3 ",
763  file.toChar(),
764  line,
765  arg1,
766  arg2,
767  arg3
768  );
769 
770  this->m_LogText_OutputPort[0].invoke(
771  _id,
772  _logTime,
774  _logString
775  );
776  }
777 #endif
778  }
779 
782  const Fw::StringBase& file,
783  U32 line,
784  U32 arg1,
785  U32 arg2,
786  U32 arg3,
787  U32 arg4
788  ) const
789  {
790  // Get the time
791  Fw::Time _logTime;
792  if (this->m_Time_OutputPort[0].isConnected()) {
793  this->m_Time_OutputPort[0].invoke(_logTime);
794  }
795 
796  FwEventIdType _id = static_cast<FwEventIdType>(0);
797 
798  _id = this->getIdBase() + EVENTID_AF_ASSERT_4;
799 
800  // Emit the event on the log port
801  if (this->m_Log_OutputPort[0].isConnected()) {
802  Fw::LogBuffer _logBuff;
804 
805 #if FW_AMPCS_COMPATIBLE
806  // Serialize the number of arguments
807  _status = _logBuff.serializeFrom(static_cast<U8>(6 + 1));
808  FW_ASSERT(
809  _status == Fw::FW_SERIALIZE_OK,
810  static_cast<FwAssertArgType>(_status)
811  );
812 
813  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
814  _status = _logBuff.serializeFrom(static_cast<U8>(4));
815  FW_ASSERT(
816  _status == Fw::FW_SERIALIZE_OK,
817  static_cast<FwAssertArgType>(_status)
818  );
819 
820  _status = _logBuff.serializeFrom(static_cast<U32>(0));
821  FW_ASSERT(
822  _status == Fw::FW_SERIALIZE_OK,
823  static_cast<FwAssertArgType>(_status)
824  );
825 #endif
826 
827  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
828  FW_ASSERT(
829  _status == Fw::FW_SERIALIZE_OK,
830  static_cast<FwAssertArgType>(_status)
831  );
832 
833 #if FW_AMPCS_COMPATIBLE
834  // Serialize the argument size
835  _status = _logBuff.serializeFrom(
836  static_cast<U8>(sizeof(U32))
837  );
838  FW_ASSERT(
839  _status == Fw::FW_SERIALIZE_OK,
840  static_cast<FwAssertArgType>(_status)
841  );
842 #endif
843  _status = _logBuff.serializeFrom(line);
844  FW_ASSERT(
845  _status == Fw::FW_SERIALIZE_OK,
846  static_cast<FwAssertArgType>(_status)
847  );
848 
849 #if FW_AMPCS_COMPATIBLE
850  // Serialize the argument size
851  _status = _logBuff.serializeFrom(
852  static_cast<U8>(sizeof(U32))
853  );
854  FW_ASSERT(
855  _status == Fw::FW_SERIALIZE_OK,
856  static_cast<FwAssertArgType>(_status)
857  );
858 #endif
859  _status = _logBuff.serializeFrom(arg1);
860  FW_ASSERT(
861  _status == Fw::FW_SERIALIZE_OK,
862  static_cast<FwAssertArgType>(_status)
863  );
864 
865 #if FW_AMPCS_COMPATIBLE
866  // Serialize the argument size
867  _status = _logBuff.serializeFrom(
868  static_cast<U8>(sizeof(U32))
869  );
870  FW_ASSERT(
871  _status == Fw::FW_SERIALIZE_OK,
872  static_cast<FwAssertArgType>(_status)
873  );
874 #endif
875  _status = _logBuff.serializeFrom(arg2);
876  FW_ASSERT(
877  _status == Fw::FW_SERIALIZE_OK,
878  static_cast<FwAssertArgType>(_status)
879  );
880 
881 #if FW_AMPCS_COMPATIBLE
882  // Serialize the argument size
883  _status = _logBuff.serializeFrom(
884  static_cast<U8>(sizeof(U32))
885  );
886  FW_ASSERT(
887  _status == Fw::FW_SERIALIZE_OK,
888  static_cast<FwAssertArgType>(_status)
889  );
890 #endif
891  _status = _logBuff.serializeFrom(arg3);
892  FW_ASSERT(
893  _status == Fw::FW_SERIALIZE_OK,
894  static_cast<FwAssertArgType>(_status)
895  );
896 
897 #if FW_AMPCS_COMPATIBLE
898  // Serialize the argument size
899  _status = _logBuff.serializeFrom(
900  static_cast<U8>(sizeof(U32))
901  );
902  FW_ASSERT(
903  _status == Fw::FW_SERIALIZE_OK,
904  static_cast<FwAssertArgType>(_status)
905  );
906 #endif
907  _status = _logBuff.serializeFrom(arg4);
908  FW_ASSERT(
909  _status == Fw::FW_SERIALIZE_OK,
910  static_cast<FwAssertArgType>(_status)
911  );
912 
913  this->m_Log_OutputPort[0].invoke(
914  _id,
915  _logTime,
917  _logBuff
918  );
919  }
920 
921  // Emit the event on the text log port
922 #if FW_ENABLE_TEXT_LOGGING
923  if (this->m_LogText_OutputPort[0].isConnected()) {
924 #if FW_OBJECT_NAMES == 1
925  const char* _formatString =
926  "(%s) %s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 "";
927 #else
928  const char* _formatString =
929  "%s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 "";
930 #endif
931 
932  Fw::TextLogString _logString;
933  _logString.format(
934  _formatString,
935 #if FW_OBJECT_NAMES == 1
936  this->m_objName.toChar(),
937 #endif
938  "AF_ASSERT_4 ",
939  file.toChar(),
940  line,
941  arg1,
942  arg2,
943  arg3,
944  arg4
945  );
946 
947  this->m_LogText_OutputPort[0].invoke(
948  _id,
949  _logTime,
951  _logString
952  );
953  }
954 #endif
955  }
956 
959  const Fw::StringBase& file,
960  U32 line,
961  U32 arg1,
962  U32 arg2,
963  U32 arg3,
964  U32 arg4,
965  U32 arg5
966  ) const
967  {
968  // Get the time
969  Fw::Time _logTime;
970  if (this->m_Time_OutputPort[0].isConnected()) {
971  this->m_Time_OutputPort[0].invoke(_logTime);
972  }
973 
974  FwEventIdType _id = static_cast<FwEventIdType>(0);
975 
976  _id = this->getIdBase() + EVENTID_AF_ASSERT_5;
977 
978  // Emit the event on the log port
979  if (this->m_Log_OutputPort[0].isConnected()) {
980  Fw::LogBuffer _logBuff;
982 
983 #if FW_AMPCS_COMPATIBLE
984  // Serialize the number of arguments
985  _status = _logBuff.serializeFrom(static_cast<U8>(7 + 1));
986  FW_ASSERT(
987  _status == Fw::FW_SERIALIZE_OK,
988  static_cast<FwAssertArgType>(_status)
989  );
990 
991  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
992  _status = _logBuff.serializeFrom(static_cast<U8>(4));
993  FW_ASSERT(
994  _status == Fw::FW_SERIALIZE_OK,
995  static_cast<FwAssertArgType>(_status)
996  );
997 
998  _status = _logBuff.serializeFrom(static_cast<U32>(0));
999  FW_ASSERT(
1000  _status == Fw::FW_SERIALIZE_OK,
1001  static_cast<FwAssertArgType>(_status)
1002  );
1003 #endif
1004 
1005  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
1006  FW_ASSERT(
1007  _status == Fw::FW_SERIALIZE_OK,
1008  static_cast<FwAssertArgType>(_status)
1009  );
1010 
1011 #if FW_AMPCS_COMPATIBLE
1012  // Serialize the argument size
1013  _status = _logBuff.serializeFrom(
1014  static_cast<U8>(sizeof(U32))
1015  );
1016  FW_ASSERT(
1017  _status == Fw::FW_SERIALIZE_OK,
1018  static_cast<FwAssertArgType>(_status)
1019  );
1020 #endif
1021  _status = _logBuff.serializeFrom(line);
1022  FW_ASSERT(
1023  _status == Fw::FW_SERIALIZE_OK,
1024  static_cast<FwAssertArgType>(_status)
1025  );
1026 
1027 #if FW_AMPCS_COMPATIBLE
1028  // Serialize the argument size
1029  _status = _logBuff.serializeFrom(
1030  static_cast<U8>(sizeof(U32))
1031  );
1032  FW_ASSERT(
1033  _status == Fw::FW_SERIALIZE_OK,
1034  static_cast<FwAssertArgType>(_status)
1035  );
1036 #endif
1037  _status = _logBuff.serializeFrom(arg1);
1038  FW_ASSERT(
1039  _status == Fw::FW_SERIALIZE_OK,
1040  static_cast<FwAssertArgType>(_status)
1041  );
1042 
1043 #if FW_AMPCS_COMPATIBLE
1044  // Serialize the argument size
1045  _status = _logBuff.serializeFrom(
1046  static_cast<U8>(sizeof(U32))
1047  );
1048  FW_ASSERT(
1049  _status == Fw::FW_SERIALIZE_OK,
1050  static_cast<FwAssertArgType>(_status)
1051  );
1052 #endif
1053  _status = _logBuff.serializeFrom(arg2);
1054  FW_ASSERT(
1055  _status == Fw::FW_SERIALIZE_OK,
1056  static_cast<FwAssertArgType>(_status)
1057  );
1058 
1059 #if FW_AMPCS_COMPATIBLE
1060  // Serialize the argument size
1061  _status = _logBuff.serializeFrom(
1062  static_cast<U8>(sizeof(U32))
1063  );
1064  FW_ASSERT(
1065  _status == Fw::FW_SERIALIZE_OK,
1066  static_cast<FwAssertArgType>(_status)
1067  );
1068 #endif
1069  _status = _logBuff.serializeFrom(arg3);
1070  FW_ASSERT(
1071  _status == Fw::FW_SERIALIZE_OK,
1072  static_cast<FwAssertArgType>(_status)
1073  );
1074 
1075 #if FW_AMPCS_COMPATIBLE
1076  // Serialize the argument size
1077  _status = _logBuff.serializeFrom(
1078  static_cast<U8>(sizeof(U32))
1079  );
1080  FW_ASSERT(
1081  _status == Fw::FW_SERIALIZE_OK,
1082  static_cast<FwAssertArgType>(_status)
1083  );
1084 #endif
1085  _status = _logBuff.serializeFrom(arg4);
1086  FW_ASSERT(
1087  _status == Fw::FW_SERIALIZE_OK,
1088  static_cast<FwAssertArgType>(_status)
1089  );
1090 
1091 #if FW_AMPCS_COMPATIBLE
1092  // Serialize the argument size
1093  _status = _logBuff.serializeFrom(
1094  static_cast<U8>(sizeof(U32))
1095  );
1096  FW_ASSERT(
1097  _status == Fw::FW_SERIALIZE_OK,
1098  static_cast<FwAssertArgType>(_status)
1099  );
1100 #endif
1101  _status = _logBuff.serializeFrom(arg5);
1102  FW_ASSERT(
1103  _status == Fw::FW_SERIALIZE_OK,
1104  static_cast<FwAssertArgType>(_status)
1105  );
1106 
1107  this->m_Log_OutputPort[0].invoke(
1108  _id,
1109  _logTime,
1111  _logBuff
1112  );
1113  }
1114 
1115  // Emit the event on the text log port
1116 #if FW_ENABLE_TEXT_LOGGING
1117  if (this->m_LogText_OutputPort[0].isConnected()) {
1118 #if FW_OBJECT_NAMES == 1
1119  const char* _formatString =
1120  "(%s) %s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 "";
1121 #else
1122  const char* _formatString =
1123  "%s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 "";
1124 #endif
1125 
1126  Fw::TextLogString _logString;
1127  _logString.format(
1128  _formatString,
1129 #if FW_OBJECT_NAMES == 1
1130  this->m_objName.toChar(),
1131 #endif
1132  "AF_ASSERT_5 ",
1133  file.toChar(),
1134  line,
1135  arg1,
1136  arg2,
1137  arg3,
1138  arg4,
1139  arg5
1140  );
1141 
1142  this->m_LogText_OutputPort[0].invoke(
1143  _id,
1144  _logTime,
1146  _logString
1147  );
1148  }
1149 #endif
1150  }
1151 
1154  const Fw::StringBase& file,
1155  U32 line,
1156  U32 arg1,
1157  U32 arg2,
1158  U32 arg3,
1159  U32 arg4,
1160  U32 arg5,
1161  U32 arg6
1162  ) const
1163  {
1164  // Get the time
1165  Fw::Time _logTime;
1166  if (this->m_Time_OutputPort[0].isConnected()) {
1167  this->m_Time_OutputPort[0].invoke(_logTime);
1168  }
1169 
1170  FwEventIdType _id = static_cast<FwEventIdType>(0);
1171 
1172  _id = this->getIdBase() + EVENTID_AF_ASSERT_6;
1173 
1174  // Emit the event on the log port
1175  if (this->m_Log_OutputPort[0].isConnected()) {
1176  Fw::LogBuffer _logBuff;
1178 
1179 #if FW_AMPCS_COMPATIBLE
1180  // Serialize the number of arguments
1181  _status = _logBuff.serializeFrom(static_cast<U8>(8 + 1));
1182  FW_ASSERT(
1183  _status == Fw::FW_SERIALIZE_OK,
1184  static_cast<FwAssertArgType>(_status)
1185  );
1186 
1187  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
1188  _status = _logBuff.serializeFrom(static_cast<U8>(4));
1189  FW_ASSERT(
1190  _status == Fw::FW_SERIALIZE_OK,
1191  static_cast<FwAssertArgType>(_status)
1192  );
1193 
1194  _status = _logBuff.serializeFrom(static_cast<U32>(0));
1195  FW_ASSERT(
1196  _status == Fw::FW_SERIALIZE_OK,
1197  static_cast<FwAssertArgType>(_status)
1198  );
1199 #endif
1200 
1201  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
1202  FW_ASSERT(
1203  _status == Fw::FW_SERIALIZE_OK,
1204  static_cast<FwAssertArgType>(_status)
1205  );
1206 
1207 #if FW_AMPCS_COMPATIBLE
1208  // Serialize the argument size
1209  _status = _logBuff.serializeFrom(
1210  static_cast<U8>(sizeof(U32))
1211  );
1212  FW_ASSERT(
1213  _status == Fw::FW_SERIALIZE_OK,
1214  static_cast<FwAssertArgType>(_status)
1215  );
1216 #endif
1217  _status = _logBuff.serializeFrom(line);
1218  FW_ASSERT(
1219  _status == Fw::FW_SERIALIZE_OK,
1220  static_cast<FwAssertArgType>(_status)
1221  );
1222 
1223 #if FW_AMPCS_COMPATIBLE
1224  // Serialize the argument size
1225  _status = _logBuff.serializeFrom(
1226  static_cast<U8>(sizeof(U32))
1227  );
1228  FW_ASSERT(
1229  _status == Fw::FW_SERIALIZE_OK,
1230  static_cast<FwAssertArgType>(_status)
1231  );
1232 #endif
1233  _status = _logBuff.serializeFrom(arg1);
1234  FW_ASSERT(
1235  _status == Fw::FW_SERIALIZE_OK,
1236  static_cast<FwAssertArgType>(_status)
1237  );
1238 
1239 #if FW_AMPCS_COMPATIBLE
1240  // Serialize the argument size
1241  _status = _logBuff.serializeFrom(
1242  static_cast<U8>(sizeof(U32))
1243  );
1244  FW_ASSERT(
1245  _status == Fw::FW_SERIALIZE_OK,
1246  static_cast<FwAssertArgType>(_status)
1247  );
1248 #endif
1249  _status = _logBuff.serializeFrom(arg2);
1250  FW_ASSERT(
1251  _status == Fw::FW_SERIALIZE_OK,
1252  static_cast<FwAssertArgType>(_status)
1253  );
1254 
1255 #if FW_AMPCS_COMPATIBLE
1256  // Serialize the argument size
1257  _status = _logBuff.serializeFrom(
1258  static_cast<U8>(sizeof(U32))
1259  );
1260  FW_ASSERT(
1261  _status == Fw::FW_SERIALIZE_OK,
1262  static_cast<FwAssertArgType>(_status)
1263  );
1264 #endif
1265  _status = _logBuff.serializeFrom(arg3);
1266  FW_ASSERT(
1267  _status == Fw::FW_SERIALIZE_OK,
1268  static_cast<FwAssertArgType>(_status)
1269  );
1270 
1271 #if FW_AMPCS_COMPATIBLE
1272  // Serialize the argument size
1273  _status = _logBuff.serializeFrom(
1274  static_cast<U8>(sizeof(U32))
1275  );
1276  FW_ASSERT(
1277  _status == Fw::FW_SERIALIZE_OK,
1278  static_cast<FwAssertArgType>(_status)
1279  );
1280 #endif
1281  _status = _logBuff.serializeFrom(arg4);
1282  FW_ASSERT(
1283  _status == Fw::FW_SERIALIZE_OK,
1284  static_cast<FwAssertArgType>(_status)
1285  );
1286 
1287 #if FW_AMPCS_COMPATIBLE
1288  // Serialize the argument size
1289  _status = _logBuff.serializeFrom(
1290  static_cast<U8>(sizeof(U32))
1291  );
1292  FW_ASSERT(
1293  _status == Fw::FW_SERIALIZE_OK,
1294  static_cast<FwAssertArgType>(_status)
1295  );
1296 #endif
1297  _status = _logBuff.serializeFrom(arg5);
1298  FW_ASSERT(
1299  _status == Fw::FW_SERIALIZE_OK,
1300  static_cast<FwAssertArgType>(_status)
1301  );
1302 
1303 #if FW_AMPCS_COMPATIBLE
1304  // Serialize the argument size
1305  _status = _logBuff.serializeFrom(
1306  static_cast<U8>(sizeof(U32))
1307  );
1308  FW_ASSERT(
1309  _status == Fw::FW_SERIALIZE_OK,
1310  static_cast<FwAssertArgType>(_status)
1311  );
1312 #endif
1313  _status = _logBuff.serializeFrom(arg6);
1314  FW_ASSERT(
1315  _status == Fw::FW_SERIALIZE_OK,
1316  static_cast<FwAssertArgType>(_status)
1317  );
1318 
1319  this->m_Log_OutputPort[0].invoke(
1320  _id,
1321  _logTime,
1323  _logBuff
1324  );
1325  }
1326 
1327  // Emit the event on the text log port
1328 #if FW_ENABLE_TEXT_LOGGING
1329  if (this->m_LogText_OutputPort[0].isConnected()) {
1330 #if FW_OBJECT_NAMES == 1
1331  const char* _formatString =
1332  "(%s) %s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 "";
1333 #else
1334  const char* _formatString =
1335  "%s: Assert in file %s, line %" PRIu32 ": %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 " %" PRIu32 "";
1336 #endif
1337 
1338  Fw::TextLogString _logString;
1339  _logString.format(
1340  _formatString,
1341 #if FW_OBJECT_NAMES == 1
1342  this->m_objName.toChar(),
1343 #endif
1344  "AF_ASSERT_6 ",
1345  file.toChar(),
1346  line,
1347  arg1,
1348  arg2,
1349  arg3,
1350  arg4,
1351  arg5,
1352  arg6
1353  );
1354 
1355  this->m_LogText_OutputPort[0].invoke(
1356  _id,
1357  _logTime,
1359  _logString
1360  );
1361  }
1362 #endif
1363  }
1364 
1367  const Fw::StringBase& file,
1368  U32 line,
1369  U32 numArgs
1370  ) const
1371  {
1372  // Get the time
1373  Fw::Time _logTime;
1374  if (this->m_Time_OutputPort[0].isConnected()) {
1375  this->m_Time_OutputPort[0].invoke(_logTime);
1376  }
1377 
1378  FwEventIdType _id = static_cast<FwEventIdType>(0);
1379 
1380  _id = this->getIdBase() + EVENTID_AF_UNEXPECTED_ASSERT;
1381 
1382  // Emit the event on the log port
1383  if (this->m_Log_OutputPort[0].isConnected()) {
1384  Fw::LogBuffer _logBuff;
1386 
1387 #if FW_AMPCS_COMPATIBLE
1388  // Serialize the number of arguments
1389  _status = _logBuff.serializeFrom(static_cast<U8>(3 + 1));
1390  FW_ASSERT(
1391  _status == Fw::FW_SERIALIZE_OK,
1392  static_cast<FwAssertArgType>(_status)
1393  );
1394 
1395  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
1396  _status = _logBuff.serializeFrom(static_cast<U8>(4));
1397  FW_ASSERT(
1398  _status == Fw::FW_SERIALIZE_OK,
1399  static_cast<FwAssertArgType>(_status)
1400  );
1401 
1402  _status = _logBuff.serializeFrom(static_cast<U32>(0));
1403  FW_ASSERT(
1404  _status == Fw::FW_SERIALIZE_OK,
1405  static_cast<FwAssertArgType>(_status)
1406  );
1407 #endif
1408 
1409  _status = file.serializeTo(_logBuff, FW_MIN(FW_LOG_STRING_MAX_SIZE, 200));
1410  FW_ASSERT(
1411  _status == Fw::FW_SERIALIZE_OK,
1412  static_cast<FwAssertArgType>(_status)
1413  );
1414 
1415 #if FW_AMPCS_COMPATIBLE
1416  // Serialize the argument size
1417  _status = _logBuff.serializeFrom(
1418  static_cast<U8>(sizeof(U32))
1419  );
1420  FW_ASSERT(
1421  _status == Fw::FW_SERIALIZE_OK,
1422  static_cast<FwAssertArgType>(_status)
1423  );
1424 #endif
1425  _status = _logBuff.serializeFrom(line);
1426  FW_ASSERT(
1427  _status == Fw::FW_SERIALIZE_OK,
1428  static_cast<FwAssertArgType>(_status)
1429  );
1430 
1431 #if FW_AMPCS_COMPATIBLE
1432  // Serialize the argument size
1433  _status = _logBuff.serializeFrom(
1434  static_cast<U8>(sizeof(U32))
1435  );
1436  FW_ASSERT(
1437  _status == Fw::FW_SERIALIZE_OK,
1438  static_cast<FwAssertArgType>(_status)
1439  );
1440 #endif
1441  _status = _logBuff.serializeFrom(numArgs);
1442  FW_ASSERT(
1443  _status == Fw::FW_SERIALIZE_OK,
1444  static_cast<FwAssertArgType>(_status)
1445  );
1446 
1447  this->m_Log_OutputPort[0].invoke(
1448  _id,
1449  _logTime,
1451  _logBuff
1452  );
1453  }
1454 
1455  // Emit the event on the text log port
1456 #if FW_ENABLE_TEXT_LOGGING
1457  if (this->m_LogText_OutputPort[0].isConnected()) {
1458 #if FW_OBJECT_NAMES == 1
1459  const char* _formatString =
1460  "(%s) %s: Unexpected assert in file %s, line %" PRIu32 ", args %" PRIu32 "";
1461 #else
1462  const char* _formatString =
1463  "%s: Unexpected assert in file %s, line %" PRIu32 ", args %" PRIu32 "";
1464 #endif
1465 
1466  Fw::TextLogString _logString;
1467  _logString.format(
1468  _formatString,
1469 #if FW_OBJECT_NAMES == 1
1470  this->m_objName.toChar(),
1471 #endif
1472  "AF_UNEXPECTED_ASSERT ",
1473  file.toChar(),
1474  line,
1475  numArgs
1476  );
1477 
1478  this->m_LogText_OutputPort[0].invoke(
1479  _id,
1480  _logTime,
1482  _logString
1483  );
1484  }
1485 #endif
1486  }
1487 
1488  // ----------------------------------------------------------------------
1489  // Time
1490  // ----------------------------------------------------------------------
1491 
1493  getTime() const
1494  {
1495  if (this->m_Time_OutputPort[0].isConnected()) {
1496  Fw::Time _time;
1497  this->m_Time_OutputPort[0].invoke(_time);
1498  return _time;
1499  }
1500  else {
1501  return Fw::Time(TimeBase::TB_NONE, 0, 0);
1502  }
1503  }
1504 
1505 }
void log_FATAL_AF_UNEXPECTED_ASSERT(const Fw::StringBase &file, U32 line, U32 numArgs) const
Serialization/Deserialization operation was successful.
void log_FATAL_AF_ASSERT_1(const Fw::StringBase &file, U32 line, U32 arg1) const
void addCallPort(InputTimePort *callPort)
Register an input port.
Definition: TimePortAc.cpp:134
SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG) override
Serialize an 8-bit unsigned integer value.
void log_FATAL_AF_ASSERT_3(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3) const
I32 FwEnumStoreType
virtual const CHAR * toChar() const =0
Convert to a C-style char*.
AssertFatalAdapterComponentBase(const char *compName="")
Construct AssertFatalAdapterComponentBase object.
No time base has been established (Required)
void log_FATAL_AF_ASSERT_2(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2) const
void init()
Object initializer.
Definition: ObjBase.cpp:24
SerializeStatus
forward declaration for string
FwIdType FwEventIdType
The type of an event identifier.
void log_FATAL_AF_ASSERT_5(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3, U32 arg4, U32 arg5) const
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects) ...
Definition: FpConfig.h:26
void init()
Initialization function.
Definition: TimePortAc.cpp:128
#define FW_MIN(a, b)
MIN macro.
Definition: BasicTypes.h:92
void set_Log_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to Log[portNum].
void log_FATAL_AF_ASSERT_4(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3, U32 arg4) const
void invoke(Fw::Time &time) const
Invoke a port interface.
Definition: TimePortAc.cpp:147
const char * toChar() const
Convert to a C-style char*.
Definition: ObjectName.hpp:50
void log_FATAL_AF_ASSERT_0(const Fw::StringBase &file, U32 line) const
void set_Time_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to Time[portNum].
bool isConnected() const
Definition: PortBase.cpp:38
#define PRI_FwIndexType
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
Definition: StringBase.cpp:39
void init()
Initialization function.
Definition: LogPortAc.cpp:151
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port interface.
Definition: LogPortAc.cpp:170
virtual ~AssertFatalAdapterComponentBase()
Destroy AssertFatalAdapterComponentBase object.
PlatformIndexType FwIndexType
A fatal non-recoverable event.
void addCallPort(InputLogPort *callPort)
Register an input port.
Definition: LogPortAc.cpp:157
RateGroupDivider component implementation.
static constexpr FwIndexType getNum_Time_OutputPorts()
Implementation of malloc based allocator.
static constexpr FwIndexType getNum_Log_OutputPorts()
#define FW_ASSERT(...)
Definition: Assert.hpp:14
void log_FATAL_AF_ASSERT_6(const Fw::StringBase &file, U32 line, U32 arg1, U32 arg2, U32 arg3, U32 arg4, U32 arg5, U32 arg6) const
SerializeStatus serializeTo(SerialBufferBase &buffer, Endianness mode=Endianness::BIG) const override
Serialize the contents of this object to a buffer.