F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
FpySequencerComponentAc.cpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title FpySequencerComponentAc.cpp
3 // \author Generated by fpp-to-cpp
4 // \brief cpp file for FpySequencer 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  namespace {
17 
18  // Constant definitions for the state machine signal buffer
19  namespace SmSignalBuffer {
20 
21  // Union for computing the max size of a signal type
22  union SignalTypeUnion {
23  BYTE size_of_Svc_FpySequencer_BreakpointArgs[Svc::FpySequencer_BreakpointArgs::SERIALIZED_SIZE];
24  BYTE size_of_Svc_FpySequencer_SequenceExecutionArgs[Svc::FpySequencer_SequenceExecutionArgs::SERIALIZED_SIZE];
25  };
26 
27  // The serialized size
28  static constexpr FwSizeType SERIALIZED_SIZE =
29  2 * sizeof(FwEnumStoreType) +
30  sizeof(SignalTypeUnion);
31 
32  }
33 
34  enum MsgTypeEnum {
35  FPYSEQUENCER_COMPONENT_EXIT = Fw::ActiveComponentBase::ACTIVE_COMPONENT_EXIT,
36  CHECKTIMERS_SCHED,
37  CMDRESPONSEIN_CMDRESPONSE,
38  PINGIN_PING,
39  SEQCANCELIN_CMDSEQCANCEL,
40  SEQRUNIN_CMDSEQIN,
41  TLMWRITE_SCHED,
42  CMD_RUN,
43  CMD_RUN_ARGS,
44  CMD_VALIDATE,
45  CMD_VALIDATE_ARGS,
46  CMD_RUN_VALIDATED,
47  CMD_CANCEL,
48  CMD_SET_BREAKPOINT,
49  CMD_BREAK,
50  CMD_CONTINUE,
51  CMD_CLEAR_BREAKPOINT,
52  CMD_STEP,
53  CMD_DUMP_STACK_TO_FILE,
54  INT_IF_DIRECTIVE_ALLOCATE,
55  INT_IF_DIRECTIVE_CALL,
56  INT_IF_DIRECTIVE_CONSTCMD,
57  INT_IF_DIRECTIVE_DISCARD,
58  INT_IF_DIRECTIVE_EXIT,
59  INT_IF_DIRECTIVE_GETFIELD,
60  INT_IF_DIRECTIVE_GOTO,
61  INT_IF_DIRECTIVE_IF,
62  INT_IF_DIRECTIVE_LOADABS,
63  INT_IF_DIRECTIVE_LOADREL,
64  INT_IF_DIRECTIVE_MEMCMP,
65  INT_IF_DIRECTIVE_NOOP,
66  INT_IF_DIRECTIVE_PEEK,
67  INT_IF_DIRECTIVE_POPEVENT,
68  INT_IF_DIRECTIVE_POPSERIALIZABLE,
69  INT_IF_DIRECTIVE_PUSHPRM,
70  INT_IF_DIRECTIVE_PUSHRAND,
71  INT_IF_DIRECTIVE_PUSHTIME,
72  INT_IF_DIRECTIVE_PUSHTLMVAL,
73  INT_IF_DIRECTIVE_PUSHTLMVALANDTIME,
74  INT_IF_DIRECTIVE_PUSHVAL,
75  INT_IF_DIRECTIVE_RETURN,
76  INT_IF_DIRECTIVE_SETSEED,
77  INT_IF_DIRECTIVE_STACKCMD,
78  INT_IF_DIRECTIVE_STACKOP,
79  INT_IF_DIRECTIVE_STOREABS,
80  INT_IF_DIRECTIVE_STOREABSCONSTOFFSET,
81  INT_IF_DIRECTIVE_STOREREL,
82  INT_IF_DIRECTIVE_STORERELCONSTOFFSET,
83  INT_IF_DIRECTIVE_WAITABS,
84  INT_IF_DIRECTIVE_WAITREL,
85  INTERNAL_STATE_MACHINE_SIGNAL,
86  };
87 
88  // Get the max size by constructing a union of the async input, command, and
89  // internal port serialization sizes
90  union BuffUnion {
91  BYTE checkTimersPortSize[Svc::SchedPortBuffer::CAPACITY];
92  BYTE cmdResponseInPortSize[Fw::CmdResponsePortBuffer::CAPACITY];
94  BYTE seqRunInPortSize[Svc::CmdSeqInPortBuffer::CAPACITY];
95  BYTE tlmWritePortSize[Svc::SchedPortBuffer::CAPACITY];
97  // Size of directive_allocate argument list
98  BYTE directive_allocateIntIfSize[
100  ];
101  // Size of directive_call argument list
102  BYTE directive_callIntIfSize[
104  ];
105  // Size of directive_constCmd argument list
106  BYTE directive_constCmdIntIfSize[
108  ];
109  // Size of directive_discard argument list
110  BYTE directive_discardIntIfSize[
112  ];
113  // Size of directive_exit argument list
114  BYTE directive_exitIntIfSize[
116  ];
117  // Size of directive_getField argument list
118  BYTE directive_getFieldIntIfSize[
120  ];
121  // Size of directive_goto argument list
122  BYTE directive_gotoIntIfSize[
124  ];
125  // Size of directive_if argument list
126  BYTE directive_ifIntIfSize[
128  ];
129  // Size of directive_loadAbs argument list
130  BYTE directive_loadAbsIntIfSize[
132  ];
133  // Size of directive_loadRel argument list
134  BYTE directive_loadRelIntIfSize[
136  ];
137  // Size of directive_memCmp argument list
138  BYTE directive_memCmpIntIfSize[
140  ];
141  // Size of directive_noOp argument list
142  BYTE directive_noOpIntIfSize[
144  ];
145  // Size of directive_peek argument list
146  BYTE directive_peekIntIfSize[
148  ];
149  // Size of directive_popEvent argument list
150  BYTE directive_popEventIntIfSize[
152  ];
153  // Size of directive_popSerializable argument list
154  BYTE directive_popSerializableIntIfSize[
156  ];
157  // Size of directive_pushPrm argument list
158  BYTE directive_pushPrmIntIfSize[
160  ];
161  // Size of directive_pushRand argument list
162  BYTE directive_pushRandIntIfSize[
164  ];
165  // Size of directive_pushTime argument list
166  BYTE directive_pushTimeIntIfSize[
168  ];
169  // Size of directive_pushTlmVal argument list
170  BYTE directive_pushTlmValIntIfSize[
172  ];
173  // Size of directive_pushTlmValAndTime argument list
174  BYTE directive_pushTlmValAndTimeIntIfSize[
176  ];
177  // Size of directive_pushVal argument list
178  BYTE directive_pushValIntIfSize[
180  ];
181  // Size of directive_return argument list
182  BYTE directive_returnIntIfSize[
184  ];
185  // Size of directive_setSeed argument list
186  BYTE directive_setSeedIntIfSize[
188  ];
189  // Size of directive_stackCmd argument list
190  BYTE directive_stackCmdIntIfSize[
192  ];
193  // Size of directive_stackOp argument list
194  BYTE directive_stackOpIntIfSize[
196  ];
197  // Size of directive_storeAbs argument list
198  BYTE directive_storeAbsIntIfSize[
200  ];
201  // Size of directive_storeAbsConstOffset argument list
202  BYTE directive_storeAbsConstOffsetIntIfSize[
204  ];
205  // Size of directive_storeRel argument list
206  BYTE directive_storeRelIntIfSize[
208  ];
209  // Size of directive_storeRelConstOffset argument list
210  BYTE directive_storeRelConstOffsetIntIfSize[
212  ];
213  // Size of directive_waitAbs argument list
214  BYTE directive_waitAbsIntIfSize[
216  ];
217  // Size of directive_waitRel argument list
218  BYTE directive_waitRelIntIfSize[
220  ];
221  // Size of buffer for internal state machine signals
222  // The internal SmSignalBuffer stores the state machine id, the
223  // signal id, and the signal data
224  BYTE internalSmBufferSize[SmSignalBuffer::SERIALIZED_SIZE];
225  };
226 
227  // Define a message buffer class large enough to handle all the
228  // asynchronous inputs to the component
229  class ComponentIpcSerializableBuffer :
230  public Fw::LinearBufferBase
231  {
232 
233  public:
234 
235  enum {
236  // Offset into data in buffer: Size of message ID and port number
237  DATA_OFFSET = sizeof(FwEnumStoreType) + sizeof(FwIndexType),
238  // Max data size
239  MAX_DATA_SIZE = sizeof(BuffUnion),
240  // Max message size: Size of message id + size of port + max data size
241  SERIALIZATION_SIZE = DATA_OFFSET + MAX_DATA_SIZE
242  };
243 
244  ComponentIpcSerializableBuffer() : Fw::LinearBufferBase(m_buff, sizeof(m_buff)) {
245 
246  }
247 
248  private:
249  // Should be the max of all the input ports serialized sizes...
250  U8 m_buff[SERIALIZATION_SIZE];
251 
252  };
253  }
254 
255  // ----------------------------------------------------------------------
256  // Types for internal state machines
257  // ----------------------------------------------------------------------
258 
261  m_component(component)
262  {
263 
264  }
265 
268  {
269  this->initBase(static_cast<FwEnumStoreType>(smId));
270  }
271 
273  getId() const
274  {
275  return static_cast<FpySequencerComponentBase::SmId>(this->m_id);
276  }
277 
278  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
279  action_signalEntered(Signal signal)
280  {
281  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_signalEntered(this->getId(), signal);
282  }
283 
284  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
285  action_setSequenceFilePath(
286  Signal signal,
288  )
289  {
290  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setSequenceFilePath(this->getId(), signal, value);
291  }
292 
293  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
294  action_setSequenceBlockState(
295  Signal signal,
297  )
298  {
299  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setSequenceBlockState(this->getId(), signal, value);
300  }
301 
302  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
303  action_setSequenceArguments(
304  Signal signal,
306  )
307  {
308  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setSequenceArguments(this->getId(), signal, value);
309  }
310 
311  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
312  action_validate(Signal signal)
313  {
314  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_validate(this->getId(), signal);
315  }
316 
317  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
318  action_report_seqSucceeded(Signal signal)
319  {
320  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_report_seqSucceeded(this->getId(), signal);
321  }
322 
323  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
324  action_report_seqCancelled(Signal signal)
325  {
326  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_report_seqCancelled(this->getId(), signal);
327  }
328 
329  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
330  action_report_seqFailed(Signal signal)
331  {
332  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_report_seqFailed(this->getId(), signal);
333  }
334 
335  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
336  action_report_seqStarted(Signal signal)
337  {
338  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_report_seqStarted(this->getId(), signal);
339  }
340 
341  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
342  action_setGoalState_RUNNING(Signal signal)
343  {
344  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setGoalState_RUNNING(this->getId(), signal);
345  }
346 
347  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
348  action_setGoalState_VALID(Signal signal)
349  {
350  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setGoalState_VALID(this->getId(), signal);
351  }
352 
353  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
354  action_setGoalState_IDLE(Signal signal)
355  {
356  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setGoalState_IDLE(this->getId(), signal);
357  }
358 
359  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
360  action_sendCmdResponse_OK(Signal signal)
361  {
362  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_sendCmdResponse_OK(this->getId(), signal);
363  }
364 
365  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
366  action_sendCmdResponse_EXECUTION_ERROR(Signal signal)
367  {
368  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_sendCmdResponse_EXECUTION_ERROR(this->getId(), signal);
369  }
370 
371  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
372  action_clearSequenceFile(Signal signal)
373  {
374  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_clearSequenceFile(this->getId(), signal);
375  }
376 
377  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
378  action_clearBreakpoint(Signal signal)
379  {
380  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_clearBreakpoint(this->getId(), signal);
381  }
382 
383  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
384  action_clearSequenceArguments(Signal signal)
385  {
386  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_clearSequenceArguments(this->getId(), signal);
387  }
388 
389  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
390  action_checkShouldWake(Signal signal)
391  {
392  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_checkShouldWake(this->getId(), signal);
393  }
394 
395  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
396  action_dispatchStatement(Signal signal)
397  {
398  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_dispatchStatement(this->getId(), signal);
399  }
400 
401  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
402  action_resetRuntime(Signal signal)
403  {
404  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_resetRuntime(this->getId(), signal);
405  }
406 
407  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
408  action_checkStatementTimeout(Signal signal)
409  {
410  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_checkStatementTimeout(this->getId(), signal);
411  }
412 
413  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
414  action_incrementSequenceCounter(Signal signal)
415  {
416  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_incrementSequenceCounter(this->getId(), signal);
417  }
418 
419  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
420  action_pushArgsToStack(Signal signal)
421  {
422  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_pushArgsToStack(this->getId(), signal);
423  }
424 
425  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
426  action_report_seqBroken(Signal signal)
427  {
428  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_report_seqBroken(this->getId(), signal);
429  }
430 
431  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
432  action_setBreakpoint(
433  Signal signal,
435  )
436  {
437  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setBreakpoint(this->getId(), signal, value);
438  }
439 
440  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
441  action_setBreakBeforeNextLine(Signal signal)
442  {
443  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_setBreakBeforeNextLine(this->getId(), signal);
444  }
445 
446  void FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
447  action_clearBreakBeforeNextLine(Signal signal)
448  {
449  this->m_component.Svc_FpySequencer_SequencerStateMachine_action_clearBreakBeforeNextLine(this->getId(), signal);
450  }
451 
452  bool FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
453  guard_goalStateIs_RUNNING(Signal signal) const
454  {
455  return this->m_component.Svc_FpySequencer_SequencerStateMachine_guard_goalStateIs_RUNNING(this->getId(), signal);
456  }
457 
458  bool FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
459  guard_shouldBreak(Signal signal) const
460  {
461  return this->m_component.Svc_FpySequencer_SequencerStateMachine_guard_shouldBreak(this->getId(), signal);
462  }
463 
464  bool FpySequencerComponentBase::Svc_FpySequencer_SequencerStateMachine ::
465  guard_breakOnce(Signal signal) const
466  {
467  return this->m_component.Svc_FpySequencer_SequencerStateMachine_guard_breakOnce(this->getId(), signal);
468  }
469 
470  // ----------------------------------------------------------------------
471  // Component initialization
472  // ----------------------------------------------------------------------
473 
476  FwSizeType queueDepth,
477  FwEnumStoreType instance
478  )
479  {
480  // Initialize base class
482 
483  // Initialize state machine instances
484  this->m_stateMachine_sequencer.init(SmId::sequencer);
485 
486 #if !FW_DIRECT_PORT_CALLS
487  // Connect input port cmdIn
488  for (
489  FwIndexType port = 0;
490  port < static_cast<FwIndexType>(this->getNum_cmdIn_InputPorts());
491  port++
492  ) {
493  this->m_cmdIn_InputPort[port].init();
494  this->m_cmdIn_InputPort[port].addCallComp(
495  this,
496  m_p_cmdIn_in
497  );
498  this->m_cmdIn_InputPort[port].setPortNum(port);
499 
500 #if FW_OBJECT_NAMES == 1
501  Fw::ObjectName portName;
502  portName.format(
503  "%s_cmdIn_InputPort[%" PRI_FwIndexType "]",
504  this->m_objName.toChar(),
505  port
506  );
507  this->m_cmdIn_InputPort[port].setObjName(portName.toChar());
508 #endif
509  }
510 #endif
511 
512 #if !FW_DIRECT_PORT_CALLS
513  // Connect input port checkTimers
514  for (
515  FwIndexType port = 0;
516  port < static_cast<FwIndexType>(this->getNum_checkTimers_InputPorts());
517  port++
518  ) {
519  this->m_checkTimers_InputPort[port].init();
520  this->m_checkTimers_InputPort[port].addCallComp(
521  this,
522  m_p_checkTimers_in
523  );
524  this->m_checkTimers_InputPort[port].setPortNum(port);
525 
526 #if FW_OBJECT_NAMES == 1
527  Fw::ObjectName portName;
528  portName.format(
529  "%s_checkTimers_InputPort[%" PRI_FwIndexType "]",
530  this->m_objName.toChar(),
531  port
532  );
533  this->m_checkTimers_InputPort[port].setObjName(portName.toChar());
534 #endif
535  }
536 #endif
537 
538 #if !FW_DIRECT_PORT_CALLS
539  // Connect input port cmdResponseIn
540  for (
541  FwIndexType port = 0;
542  port < static_cast<FwIndexType>(this->getNum_cmdResponseIn_InputPorts());
543  port++
544  ) {
545  this->m_cmdResponseIn_InputPort[port].init();
546  this->m_cmdResponseIn_InputPort[port].addCallComp(
547  this,
548  m_p_cmdResponseIn_in
549  );
550  this->m_cmdResponseIn_InputPort[port].setPortNum(port);
551 
552 #if FW_OBJECT_NAMES == 1
553  Fw::ObjectName portName;
554  portName.format(
555  "%s_cmdResponseIn_InputPort[%" PRI_FwIndexType "]",
556  this->m_objName.toChar(),
557  port
558  );
559  this->m_cmdResponseIn_InputPort[port].setObjName(portName.toChar());
560 #endif
561  }
562 #endif
563 
564 #if !FW_DIRECT_PORT_CALLS
565  // Connect input port pingIn
566  for (
567  FwIndexType port = 0;
568  port < static_cast<FwIndexType>(this->getNum_pingIn_InputPorts());
569  port++
570  ) {
571  this->m_pingIn_InputPort[port].init();
572  this->m_pingIn_InputPort[port].addCallComp(
573  this,
574  m_p_pingIn_in
575  );
576  this->m_pingIn_InputPort[port].setPortNum(port);
577 
578 #if FW_OBJECT_NAMES == 1
579  Fw::ObjectName portName;
580  portName.format(
581  "%s_pingIn_InputPort[%" PRI_FwIndexType "]",
582  this->m_objName.toChar(),
583  port
584  );
585  this->m_pingIn_InputPort[port].setObjName(portName.toChar());
586 #endif
587  }
588 #endif
589 
590 #if !FW_DIRECT_PORT_CALLS
591  // Connect input port seqCancelIn
592  for (
593  FwIndexType port = 0;
594  port < static_cast<FwIndexType>(this->getNum_seqCancelIn_InputPorts());
595  port++
596  ) {
597  this->m_seqCancelIn_InputPort[port].init();
598  this->m_seqCancelIn_InputPort[port].addCallComp(
599  this,
600  m_p_seqCancelIn_in
601  );
602  this->m_seqCancelIn_InputPort[port].setPortNum(port);
603 
604 #if FW_OBJECT_NAMES == 1
605  Fw::ObjectName portName;
606  portName.format(
607  "%s_seqCancelIn_InputPort[%" PRI_FwIndexType "]",
608  this->m_objName.toChar(),
609  port
610  );
611  this->m_seqCancelIn_InputPort[port].setObjName(portName.toChar());
612 #endif
613  }
614 #endif
615 
616 #if !FW_DIRECT_PORT_CALLS
617  // Connect input port seqRunIn
618  for (
619  FwIndexType port = 0;
620  port < static_cast<FwIndexType>(this->getNum_seqRunIn_InputPorts());
621  port++
622  ) {
623  this->m_seqRunIn_InputPort[port].init();
624  this->m_seqRunIn_InputPort[port].addCallComp(
625  this,
626  m_p_seqRunIn_in
627  );
628  this->m_seqRunIn_InputPort[port].setPortNum(port);
629 
630 #if FW_OBJECT_NAMES == 1
631  Fw::ObjectName portName;
632  portName.format(
633  "%s_seqRunIn_InputPort[%" PRI_FwIndexType "]",
634  this->m_objName.toChar(),
635  port
636  );
637  this->m_seqRunIn_InputPort[port].setObjName(portName.toChar());
638 #endif
639  }
640 #endif
641 
642 #if !FW_DIRECT_PORT_CALLS
643  // Connect input port tlmWrite
644  for (
645  FwIndexType port = 0;
646  port < static_cast<FwIndexType>(this->getNum_tlmWrite_InputPorts());
647  port++
648  ) {
649  this->m_tlmWrite_InputPort[port].init();
650  this->m_tlmWrite_InputPort[port].addCallComp(
651  this,
652  m_p_tlmWrite_in
653  );
654  this->m_tlmWrite_InputPort[port].setPortNum(port);
655 
656 #if FW_OBJECT_NAMES == 1
657  Fw::ObjectName portName;
658  portName.format(
659  "%s_tlmWrite_InputPort[%" PRI_FwIndexType "]",
660  this->m_objName.toChar(),
661  port
662  );
663  this->m_tlmWrite_InputPort[port].setObjName(portName.toChar());
664 #endif
665  }
666 #endif
667 
668 #if !FW_DIRECT_PORT_CALLS
669  // Connect output port cmdRegOut
670  for (
671  FwIndexType port = 0;
672  port < static_cast<FwIndexType>(this->getNum_cmdRegOut_OutputPorts());
673  port++
674  ) {
675  this->m_cmdRegOut_OutputPort[port].init();
676 
677 #if FW_OBJECT_NAMES == 1
678  Fw::ObjectName portName;
679  portName.format(
680  "%s_cmdRegOut_OutputPort[%" PRI_FwIndexType "]",
681  this->m_objName.toChar(),
682  port
683  );
684  this->m_cmdRegOut_OutputPort[port].setObjName(portName.toChar());
685 #endif
686  }
687 #endif
688 
689 #if !FW_DIRECT_PORT_CALLS
690  // Connect output port cmdResponseOut
691  for (
692  FwIndexType port = 0;
693  port < static_cast<FwIndexType>(this->getNum_cmdResponseOut_OutputPorts());
694  port++
695  ) {
696  this->m_cmdResponseOut_OutputPort[port].init();
697 
698 #if FW_OBJECT_NAMES == 1
699  Fw::ObjectName portName;
700  portName.format(
701  "%s_cmdResponseOut_OutputPort[%" PRI_FwIndexType "]",
702  this->m_objName.toChar(),
703  port
704  );
705  this->m_cmdResponseOut_OutputPort[port].setObjName(portName.toChar());
706 #endif
707  }
708 #endif
709 
710 #if !FW_DIRECT_PORT_CALLS
711  // Connect output port logOut
712  for (
713  FwIndexType port = 0;
714  port < static_cast<FwIndexType>(this->getNum_logOut_OutputPorts());
715  port++
716  ) {
717  this->m_logOut_OutputPort[port].init();
718 
719 #if FW_OBJECT_NAMES == 1
720  Fw::ObjectName portName;
721  portName.format(
722  "%s_logOut_OutputPort[%" PRI_FwIndexType "]",
723  this->m_objName.toChar(),
724  port
725  );
726  this->m_logOut_OutputPort[port].setObjName(portName.toChar());
727 #endif
728  }
729 #endif
730 
731 #if !FW_DIRECT_PORT_CALLS && FW_ENABLE_TEXT_LOGGING
732  // Connect output port logTextOut
733  for (
734  FwIndexType port = 0;
735  port < static_cast<FwIndexType>(this->getNum_logTextOut_OutputPorts());
736  port++
737  ) {
738  this->m_logTextOut_OutputPort[port].init();
739 
740 #if FW_OBJECT_NAMES == 1
741  Fw::ObjectName portName;
742  portName.format(
743  "%s_logTextOut_OutputPort[%" PRI_FwIndexType "]",
744  this->m_objName.toChar(),
745  port
746  );
747  this->m_logTextOut_OutputPort[port].setObjName(portName.toChar());
748 #endif
749  }
750 #endif
751 
752 #if !FW_DIRECT_PORT_CALLS
753  // Connect output port prmGet
754  for (
755  FwIndexType port = 0;
756  port < static_cast<FwIndexType>(this->getNum_prmGet_OutputPorts());
757  port++
758  ) {
759  this->m_prmGet_OutputPort[port].init();
760 
761 #if FW_OBJECT_NAMES == 1
762  Fw::ObjectName portName;
763  portName.format(
764  "%s_prmGet_OutputPort[%" PRI_FwIndexType "]",
765  this->m_objName.toChar(),
766  port
767  );
768  this->m_prmGet_OutputPort[port].setObjName(portName.toChar());
769 #endif
770  }
771 #endif
772 
773 #if !FW_DIRECT_PORT_CALLS
774  // Connect output port prmSet
775  for (
776  FwIndexType port = 0;
777  port < static_cast<FwIndexType>(this->getNum_prmSet_OutputPorts());
778  port++
779  ) {
780  this->m_prmSet_OutputPort[port].init();
781 
782 #if FW_OBJECT_NAMES == 1
783  Fw::ObjectName portName;
784  portName.format(
785  "%s_prmSet_OutputPort[%" PRI_FwIndexType "]",
786  this->m_objName.toChar(),
787  port
788  );
789  this->m_prmSet_OutputPort[port].setObjName(portName.toChar());
790 #endif
791  }
792 #endif
793 
794 #if !FW_DIRECT_PORT_CALLS
795  // Connect output port timeCaller
796  for (
797  FwIndexType port = 0;
798  port < static_cast<FwIndexType>(this->getNum_timeCaller_OutputPorts());
799  port++
800  ) {
801  this->m_timeCaller_OutputPort[port].init();
802 
803 #if FW_OBJECT_NAMES == 1
804  Fw::ObjectName portName;
805  portName.format(
806  "%s_timeCaller_OutputPort[%" PRI_FwIndexType "]",
807  this->m_objName.toChar(),
808  port
809  );
810  this->m_timeCaller_OutputPort[port].setObjName(portName.toChar());
811 #endif
812  }
813 #endif
814 
815 #if !FW_DIRECT_PORT_CALLS
816  // Connect output port tlmOut
817  for (
818  FwIndexType port = 0;
819  port < static_cast<FwIndexType>(this->getNum_tlmOut_OutputPorts());
820  port++
821  ) {
822  this->m_tlmOut_OutputPort[port].init();
823 
824 #if FW_OBJECT_NAMES == 1
825  Fw::ObjectName portName;
826  portName.format(
827  "%s_tlmOut_OutputPort[%" PRI_FwIndexType "]",
828  this->m_objName.toChar(),
829  port
830  );
831  this->m_tlmOut_OutputPort[port].setObjName(portName.toChar());
832 #endif
833  }
834 #endif
835 
836 #if !FW_DIRECT_PORT_CALLS
837  // Connect output port cmdOut
838  for (
839  FwIndexType port = 0;
840  port < static_cast<FwIndexType>(this->getNum_cmdOut_OutputPorts());
841  port++
842  ) {
843  this->m_cmdOut_OutputPort[port].init();
844 
845 #if FW_OBJECT_NAMES == 1
846  Fw::ObjectName portName;
847  portName.format(
848  "%s_cmdOut_OutputPort[%" PRI_FwIndexType "]",
849  this->m_objName.toChar(),
850  port
851  );
852  this->m_cmdOut_OutputPort[port].setObjName(portName.toChar());
853 #endif
854  }
855 #endif
856 
857 #if !FW_DIRECT_PORT_CALLS
858  // Connect output port getParam
859  for (
860  FwIndexType port = 0;
861  port < static_cast<FwIndexType>(this->getNum_getParam_OutputPorts());
862  port++
863  ) {
864  this->m_getParam_OutputPort[port].init();
865 
866 #if FW_OBJECT_NAMES == 1
867  Fw::ObjectName portName;
868  portName.format(
869  "%s_getParam_OutputPort[%" PRI_FwIndexType "]",
870  this->m_objName.toChar(),
871  port
872  );
873  this->m_getParam_OutputPort[port].setObjName(portName.toChar());
874 #endif
875  }
876 #endif
877 
878 #if !FW_DIRECT_PORT_CALLS
879  // Connect output port getTlmChan
880  for (
881  FwIndexType port = 0;
882  port < static_cast<FwIndexType>(this->getNum_getTlmChan_OutputPorts());
883  port++
884  ) {
885  this->m_getTlmChan_OutputPort[port].init();
886 
887 #if FW_OBJECT_NAMES == 1
888  Fw::ObjectName portName;
889  portName.format(
890  "%s_getTlmChan_OutputPort[%" PRI_FwIndexType "]",
891  this->m_objName.toChar(),
892  port
893  );
894  this->m_getTlmChan_OutputPort[port].setObjName(portName.toChar());
895 #endif
896  }
897 #endif
898 
899 #if !FW_DIRECT_PORT_CALLS
900  // Connect output port pingOut
901  for (
902  FwIndexType port = 0;
903  port < static_cast<FwIndexType>(this->getNum_pingOut_OutputPorts());
904  port++
905  ) {
906  this->m_pingOut_OutputPort[port].init();
907 
908 #if FW_OBJECT_NAMES == 1
909  Fw::ObjectName portName;
910  portName.format(
911  "%s_pingOut_OutputPort[%" PRI_FwIndexType "]",
912  this->m_objName.toChar(),
913  port
914  );
915  this->m_pingOut_OutputPort[port].setObjName(portName.toChar());
916 #endif
917  }
918 #endif
919 
920 #if !FW_DIRECT_PORT_CALLS
921  // Connect output port seqDoneOut
922  for (
923  FwIndexType port = 0;
924  port < static_cast<FwIndexType>(this->getNum_seqDoneOut_OutputPorts());
925  port++
926  ) {
927  this->m_seqDoneOut_OutputPort[port].init();
928 
929 #if FW_OBJECT_NAMES == 1
930  Fw::ObjectName portName;
931  portName.format(
932  "%s_seqDoneOut_OutputPort[%" PRI_FwIndexType "]",
933  this->m_objName.toChar(),
934  port
935  );
936  this->m_seqDoneOut_OutputPort[port].setObjName(portName.toChar());
937 #endif
938  }
939 #endif
940 
941 #if !FW_DIRECT_PORT_CALLS
942  // Connect output port seqStartOut
943  for (
944  FwIndexType port = 0;
945  port < static_cast<FwIndexType>(this->getNum_seqStartOut_OutputPorts());
946  port++
947  ) {
948  this->m_seqStartOut_OutputPort[port].init();
949 
950 #if FW_OBJECT_NAMES == 1
951  Fw::ObjectName portName;
952  portName.format(
953  "%s_seqStartOut_OutputPort[%" PRI_FwIndexType "]",
954  this->m_objName.toChar(),
955  port
956  );
957  this->m_seqStartOut_OutputPort[port].setObjName(portName.toChar());
958 #endif
959  }
960 #endif
961 
962 #if !FW_DIRECT_PORT_CALLS
963  // Connect output port serialOut
964  for (
965  FwIndexType port = 0;
966  port < static_cast<FwIndexType>(this->getNum_serialOut_OutputPorts());
967  port++
968  ) {
969  this->m_serialOut_OutputPort[port].init();
970 
971 #if FW_OBJECT_NAMES == 1
972  Fw::ObjectName portName;
973  portName.format(
974  "%s_serialOut_OutputPort[%" PRI_FwIndexType "]",
975  this->m_objName.toChar(),
976  port
977  );
978  this->m_serialOut_OutputPort[port].setObjName(portName.toChar());
979 #endif
980  }
981 #endif
982 
983  // Create the queue
984  Os::Queue::Status qStat = this->createQueue(
985  queueDepth,
986  static_cast<FwSizeType>(ComponentIpcSerializableBuffer::SERIALIZATION_SIZE)
987  );
988  FW_ASSERT(
989  Os::Queue::Status::OP_OK == qStat,
990  static_cast<FwAssertArgType>(qStat)
991  );
992  }
993 
994 #if !FW_DIRECT_PORT_CALLS
995 
996  // ----------------------------------------------------------------------
997  // Getters for special input ports
998  // ----------------------------------------------------------------------
999 
1002  {
1003  FW_ASSERT(
1004  (0 <= portNum) && (portNum < this->getNum_cmdIn_InputPorts()),
1005  static_cast<FwAssertArgType>(portNum)
1006  );
1007 
1008  return &this->m_cmdIn_InputPort[portNum];
1009  }
1010 
1011 #endif
1012 
1013 #if !FW_DIRECT_PORT_CALLS
1014 
1015  // ----------------------------------------------------------------------
1016  // Getters for typed input ports
1017  // ----------------------------------------------------------------------
1018 
1021  {
1022  FW_ASSERT(
1023  (0 <= portNum) && (portNum < this->getNum_checkTimers_InputPorts()),
1024  static_cast<FwAssertArgType>(portNum)
1025  );
1026 
1027  return &this->m_checkTimers_InputPort[portNum];
1028  }
1029 
1032  {
1033  FW_ASSERT(
1034  (0 <= portNum) && (portNum < this->getNum_cmdResponseIn_InputPorts()),
1035  static_cast<FwAssertArgType>(portNum)
1036  );
1037 
1038  return &this->m_cmdResponseIn_InputPort[portNum];
1039  }
1040 
1043  {
1044  FW_ASSERT(
1045  (0 <= portNum) && (portNum < this->getNum_pingIn_InputPorts()),
1046  static_cast<FwAssertArgType>(portNum)
1047  );
1048 
1049  return &this->m_pingIn_InputPort[portNum];
1050  }
1051 
1054  {
1055  FW_ASSERT(
1056  (0 <= portNum) && (portNum < this->getNum_seqCancelIn_InputPorts()),
1057  static_cast<FwAssertArgType>(portNum)
1058  );
1059 
1060  return &this->m_seqCancelIn_InputPort[portNum];
1061  }
1062 
1065  {
1066  FW_ASSERT(
1067  (0 <= portNum) && (portNum < this->getNum_seqRunIn_InputPorts()),
1068  static_cast<FwAssertArgType>(portNum)
1069  );
1070 
1071  return &this->m_seqRunIn_InputPort[portNum];
1072  }
1073 
1076  {
1077  FW_ASSERT(
1078  (0 <= portNum) && (portNum < this->getNum_tlmWrite_InputPorts()),
1079  static_cast<FwAssertArgType>(portNum)
1080  );
1081 
1082  return &this->m_tlmWrite_InputPort[portNum];
1083  }
1084 
1085 #endif
1086 
1087 #if !FW_DIRECT_PORT_CALLS
1088 
1089  // ----------------------------------------------------------------------
1090  // Connect input ports to special output ports
1091  // ----------------------------------------------------------------------
1092 
1095  FwIndexType portNum,
1096  Fw::InputCmdRegPort* port
1097  )
1098  {
1099  FW_ASSERT(
1100  (0 <= portNum) && (portNum < this->getNum_cmdRegOut_OutputPorts()),
1101  static_cast<FwAssertArgType>(portNum)
1102  );
1103 
1104  this->m_cmdRegOut_OutputPort[portNum].addCallPort(port);
1105  }
1106 
1109  FwIndexType portNum,
1111  )
1112  {
1113  FW_ASSERT(
1114  (0 <= portNum) && (portNum < this->getNum_cmdResponseOut_OutputPorts()),
1115  static_cast<FwAssertArgType>(portNum)
1116  );
1117 
1118  this->m_cmdResponseOut_OutputPort[portNum].addCallPort(port);
1119  }
1120 
1123  FwIndexType portNum,
1124  Fw::InputLogPort* port
1125  )
1126  {
1127  FW_ASSERT(
1128  (0 <= portNum) && (portNum < this->getNum_logOut_OutputPorts()),
1129  static_cast<FwAssertArgType>(portNum)
1130  );
1131 
1132  this->m_logOut_OutputPort[portNum].addCallPort(port);
1133  }
1134 
1135 #if FW_ENABLE_TEXT_LOGGING == 1
1136 
1137  void FpySequencerComponentBase ::
1138  set_logTextOut_OutputPort(
1139  FwIndexType portNum,
1140  Fw::InputLogTextPort* port
1141  )
1142  {
1143  FW_ASSERT(
1144  (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
1145  static_cast<FwAssertArgType>(portNum)
1146  );
1147 
1148  this->m_logTextOut_OutputPort[portNum].addCallPort(port);
1149  }
1150 
1151 #endif
1152 
1155  FwIndexType portNum,
1156  Fw::InputPrmGetPort* port
1157  )
1158  {
1159  FW_ASSERT(
1160  (0 <= portNum) && (portNum < this->getNum_prmGet_OutputPorts()),
1161  static_cast<FwAssertArgType>(portNum)
1162  );
1163 
1164  this->m_prmGet_OutputPort[portNum].addCallPort(port);
1165  }
1166 
1169  FwIndexType portNum,
1170  Fw::InputPrmSetPort* port
1171  )
1172  {
1173  FW_ASSERT(
1174  (0 <= portNum) && (portNum < this->getNum_prmSet_OutputPorts()),
1175  static_cast<FwAssertArgType>(portNum)
1176  );
1177 
1178  this->m_prmSet_OutputPort[portNum].addCallPort(port);
1179  }
1180 
1183  FwIndexType portNum,
1184  Fw::InputTimePort* port
1185  )
1186  {
1187  FW_ASSERT(
1188  (0 <= portNum) && (portNum < this->getNum_timeCaller_OutputPorts()),
1189  static_cast<FwAssertArgType>(portNum)
1190  );
1191 
1192  this->m_timeCaller_OutputPort[portNum].addCallPort(port);
1193  }
1194 
1197  FwIndexType portNum,
1198  Fw::InputTlmPort* port
1199  )
1200  {
1201  FW_ASSERT(
1202  (0 <= portNum) && (portNum < this->getNum_tlmOut_OutputPorts()),
1203  static_cast<FwAssertArgType>(portNum)
1204  );
1205 
1206  this->m_tlmOut_OutputPort[portNum].addCallPort(port);
1207  }
1208 
1209 #endif
1210 
1211 #if !FW_DIRECT_PORT_CALLS
1212 
1213  // ----------------------------------------------------------------------
1214  // Connect typed input ports to typed output ports
1215  // ----------------------------------------------------------------------
1216 
1219  FwIndexType portNum,
1220  Fw::InputComPort* port
1221  )
1222  {
1223  FW_ASSERT(
1224  (0 <= portNum) && (portNum < this->getNum_cmdOut_OutputPorts()),
1225  static_cast<FwAssertArgType>(portNum)
1226  );
1227 
1228  this->m_cmdOut_OutputPort[portNum].addCallPort(port);
1229  }
1230 
1233  FwIndexType portNum,
1234  Fw::InputPrmGetPort* port
1235  )
1236  {
1237  FW_ASSERT(
1238  (0 <= portNum) && (portNum < this->getNum_getParam_OutputPorts()),
1239  static_cast<FwAssertArgType>(portNum)
1240  );
1241 
1242  this->m_getParam_OutputPort[portNum].addCallPort(port);
1243  }
1244 
1247  FwIndexType portNum,
1248  Fw::InputTlmGetPort* port
1249  )
1250  {
1251  FW_ASSERT(
1252  (0 <= portNum) && (portNum < this->getNum_getTlmChan_OutputPorts()),
1253  static_cast<FwAssertArgType>(portNum)
1254  );
1255 
1256  this->m_getTlmChan_OutputPort[portNum].addCallPort(port);
1257  }
1258 
1261  FwIndexType portNum,
1262  Svc::InputPingPort* port
1263  )
1264  {
1265  FW_ASSERT(
1266  (0 <= portNum) && (portNum < this->getNum_pingOut_OutputPorts()),
1267  static_cast<FwAssertArgType>(portNum)
1268  );
1269 
1270  this->m_pingOut_OutputPort[portNum].addCallPort(port);
1271  }
1272 
1275  FwIndexType portNum,
1277  )
1278  {
1279  FW_ASSERT(
1280  (0 <= portNum) && (portNum < this->getNum_seqDoneOut_OutputPorts()),
1281  static_cast<FwAssertArgType>(portNum)
1282  );
1283 
1284  this->m_seqDoneOut_OutputPort[portNum].addCallPort(port);
1285  }
1286 
1289  FwIndexType portNum,
1291  )
1292  {
1293  FW_ASSERT(
1294  (0 <= portNum) && (portNum < this->getNum_seqStartOut_OutputPorts()),
1295  static_cast<FwAssertArgType>(portNum)
1296  );
1297 
1298  this->m_seqStartOut_OutputPort[portNum].addCallPort(port);
1299  }
1300 
1301 #endif
1302 
1303 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
1304 
1305  // ----------------------------------------------------------------------
1306  // Connect serial input ports to special output ports
1307  // ----------------------------------------------------------------------
1308 
1311  FwIndexType portNum,
1312  Fw::InputSerializePort* port
1313  )
1314  {
1315  FW_ASSERT(
1316  (0 <= portNum) && (portNum < this->getNum_cmdRegOut_OutputPorts()),
1317  static_cast<FwAssertArgType>(portNum)
1318  );
1319 
1320  this->m_cmdRegOut_OutputPort[portNum].registerSerialPort(port);
1321  }
1322 
1325  FwIndexType portNum,
1326  Fw::InputSerializePort* port
1327  )
1328  {
1329  FW_ASSERT(
1330  (0 <= portNum) && (portNum < this->getNum_cmdResponseOut_OutputPorts()),
1331  static_cast<FwAssertArgType>(portNum)
1332  );
1333 
1334  this->m_cmdResponseOut_OutputPort[portNum].registerSerialPort(port);
1335  }
1336 
1339  FwIndexType portNum,
1340  Fw::InputSerializePort* port
1341  )
1342  {
1343  FW_ASSERT(
1344  (0 <= portNum) && (portNum < this->getNum_logOut_OutputPorts()),
1345  static_cast<FwAssertArgType>(portNum)
1346  );
1347 
1348  this->m_logOut_OutputPort[portNum].registerSerialPort(port);
1349  }
1350 
1351 #if FW_ENABLE_TEXT_LOGGING == 1
1352 
1353  void FpySequencerComponentBase ::
1354  set_logTextOut_OutputPort(
1355  FwIndexType portNum,
1356  Fw::InputSerializePort* port
1357  )
1358  {
1359  FW_ASSERT(
1360  (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
1361  static_cast<FwAssertArgType>(portNum)
1362  );
1363 
1364  this->m_logTextOut_OutputPort[portNum].registerSerialPort(port);
1365  }
1366 
1367 #endif
1368 
1371  FwIndexType portNum,
1372  Fw::InputSerializePort* port
1373  )
1374  {
1375  FW_ASSERT(
1376  (0 <= portNum) && (portNum < this->getNum_prmSet_OutputPorts()),
1377  static_cast<FwAssertArgType>(portNum)
1378  );
1379 
1380  this->m_prmSet_OutputPort[portNum].registerSerialPort(port);
1381  }
1382 
1385  FwIndexType portNum,
1386  Fw::InputSerializePort* port
1387  )
1388  {
1389  FW_ASSERT(
1390  (0 <= portNum) && (portNum < this->getNum_timeCaller_OutputPorts()),
1391  static_cast<FwAssertArgType>(portNum)
1392  );
1393 
1394  this->m_timeCaller_OutputPort[portNum].registerSerialPort(port);
1395  }
1396 
1399  FwIndexType portNum,
1400  Fw::InputSerializePort* port
1401  )
1402  {
1403  FW_ASSERT(
1404  (0 <= portNum) && (portNum < this->getNum_tlmOut_OutputPorts()),
1405  static_cast<FwAssertArgType>(portNum)
1406  );
1407 
1408  this->m_tlmOut_OutputPort[portNum].registerSerialPort(port);
1409  }
1410 
1411 #endif
1412 
1413 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
1414 
1415  // ----------------------------------------------------------------------
1416  // Connect serial input ports to typed output ports
1417  // ----------------------------------------------------------------------
1418 
1421  FwIndexType portNum,
1422  Fw::InputSerializePort* port
1423  )
1424  {
1425  FW_ASSERT(
1426  (0 <= portNum) && (portNum < this->getNum_cmdOut_OutputPorts()),
1427  static_cast<FwAssertArgType>(portNum)
1428  );
1429 
1430  this->m_cmdOut_OutputPort[portNum].registerSerialPort(port);
1431  }
1432 
1435  FwIndexType portNum,
1436  Fw::InputSerializePort* port
1437  )
1438  {
1439  FW_ASSERT(
1440  (0 <= portNum) && (portNum < this->getNum_pingOut_OutputPorts()),
1441  static_cast<FwAssertArgType>(portNum)
1442  );
1443 
1444  this->m_pingOut_OutputPort[portNum].registerSerialPort(port);
1445  }
1446 
1449  FwIndexType portNum,
1450  Fw::InputSerializePort* port
1451  )
1452  {
1453  FW_ASSERT(
1454  (0 <= portNum) && (portNum < this->getNum_seqDoneOut_OutputPorts()),
1455  static_cast<FwAssertArgType>(portNum)
1456  );
1457 
1458  this->m_seqDoneOut_OutputPort[portNum].registerSerialPort(port);
1459  }
1460 
1463  FwIndexType portNum,
1464  Fw::InputSerializePort* port
1465  )
1466  {
1467  FW_ASSERT(
1468  (0 <= portNum) && (portNum < this->getNum_seqStartOut_OutputPorts()),
1469  static_cast<FwAssertArgType>(portNum)
1470  );
1471 
1472  this->m_seqStartOut_OutputPort[portNum].registerSerialPort(port);
1473  }
1474 
1475 #endif
1476 
1477 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
1478 
1479  // ----------------------------------------------------------------------
1480  // Connect typed and serial input ports to serial output ports
1481  // ----------------------------------------------------------------------
1482 
1483  void FpySequencerComponentBase ::
1484  set_serialOut_OutputPort(
1485  FwIndexType portNum,
1486  Fw::InputPortBase* port
1487  )
1488  {
1489  FW_ASSERT(
1490  (0 <= portNum) && (portNum < this->getNum_serialOut_OutputPorts()),
1491  static_cast<FwAssertArgType>(portNum)
1492  );
1493 
1494  this->m_serialOut_OutputPort[portNum].registerSerialPort(port);
1495  }
1496 
1497 #endif
1498 
1499  // ----------------------------------------------------------------------
1500  // Command registration
1501  // ----------------------------------------------------------------------
1502 
1505  {
1507 
1508  this->cmdRegOut_out(
1509  0,
1510  this->getIdBase() + OPCODE_RUN
1511  );
1512 
1513  this->cmdRegOut_out(
1514  0,
1515  this->getIdBase() + OPCODE_RUN_ARGS
1516  );
1517 
1518  this->cmdRegOut_out(
1519  0,
1520  this->getIdBase() + OPCODE_VALIDATE
1521  );
1522 
1523  this->cmdRegOut_out(
1524  0,
1526  );
1527 
1528  this->cmdRegOut_out(
1529  0,
1531  );
1532 
1533  this->cmdRegOut_out(
1534  0,
1535  this->getIdBase() + OPCODE_CANCEL
1536  );
1537 
1538  this->cmdRegOut_out(
1539  0,
1541  );
1542 
1543  this->cmdRegOut_out(
1544  0,
1545  this->getIdBase() + OPCODE_BREAK
1546  );
1547 
1548  this->cmdRegOut_out(
1549  0,
1550  this->getIdBase() + OPCODE_CONTINUE
1551  );
1552 
1553  this->cmdRegOut_out(
1554  0,
1556  );
1557 
1558  this->cmdRegOut_out(
1559  0,
1560  this->getIdBase() + OPCODE_STEP
1561  );
1562 
1563  this->cmdRegOut_out(
1564  0,
1566  );
1567 
1568  this->cmdRegOut_out(
1569  0,
1571  );
1572 
1573  this->cmdRegOut_out(
1574  0,
1576  );
1577 
1578  this->cmdRegOut_out(
1579  0,
1581  );
1582 
1583  this->cmdRegOut_out(
1584  0,
1586  );
1587  }
1588 
1589  // ----------------------------------------------------------------------
1590  // Parameter loading
1591  // ----------------------------------------------------------------------
1592 
1595  {
1597  const FwPrmIdType _baseId = static_cast<FwPrmIdType>(this->getIdBase());
1599 
1600  FwPrmIdType _id{};
1601  Fw::ParamBuffer _paramBuffer;
1602 
1603  _id = _baseId + PARAMID_STATEMENT_TIMEOUT_SECS;
1604 
1605  // Get serialized parameter STATEMENT_TIMEOUT_SECS
1606  this->m_param_STATEMENT_TIMEOUT_SECS_valid = this->prmGet_out(
1607  0,
1608  _id,
1609  _paramBuffer
1610  );
1611 
1612  this->m_paramLock.lock();
1613 
1614  // Deserialize parameter or use default value
1615  if (this->m_param_STATEMENT_TIMEOUT_SECS_valid == Fw::ParamValid::VALID) {
1616  _stat = _paramBuffer.deserializeTo(this->m_STATEMENT_TIMEOUT_SECS);
1617  if (_stat != Fw::FW_SERIALIZE_OK) {
1618  this->m_param_STATEMENT_TIMEOUT_SECS_valid = Fw::ParamValid::DEFAULT;
1619  }
1620  }
1621  else {
1622  this->m_param_STATEMENT_TIMEOUT_SECS_valid = Fw::ParamValid::DEFAULT;
1623  }
1624  if (this->m_param_STATEMENT_TIMEOUT_SECS_valid == Fw::ParamValid::DEFAULT) {
1625  this->m_STATEMENT_TIMEOUT_SECS = 0.0f;
1626  }
1627 
1628  this->m_paramLock.unlock();
1629 
1630  _id = _baseId + PARAMID_SEQ_BASE_DIR;
1631 
1632  // Get serialized parameter SEQ_BASE_DIR
1633  this->m_param_SEQ_BASE_DIR_valid = this->prmGet_out(
1634  0,
1635  _id,
1636  _paramBuffer
1637  );
1638 
1639  this->m_paramLock.lock();
1640 
1641  // Deserialize parameter or use default value
1642  if (this->m_param_SEQ_BASE_DIR_valid == Fw::ParamValid::VALID) {
1643  _stat = _paramBuffer.deserializeTo(this->m_SEQ_BASE_DIR);
1644  if (_stat != Fw::FW_SERIALIZE_OK) {
1645  this->m_param_SEQ_BASE_DIR_valid = Fw::ParamValid::DEFAULT;
1646  }
1647  }
1648  else {
1649  this->m_param_SEQ_BASE_DIR_valid = Fw::ParamValid::DEFAULT;
1650  }
1651  if (this->m_param_SEQ_BASE_DIR_valid == Fw::ParamValid::DEFAULT) {
1652  this->m_SEQ_BASE_DIR = Fw::String("");
1653  }
1654 
1655  this->m_paramLock.unlock();
1656 
1657  // Call notifier
1658  this->parametersLoaded();
1659  }
1660 
1661  // ----------------------------------------------------------------------
1662  // Component construction and destruction
1663  // ----------------------------------------------------------------------
1664 
1666  FpySequencerComponentBase(const char* compName) :
1667  Fw::ActiveComponentBase(compName),
1668  m_stateMachine_sequencer(*this)
1669  {
1670 
1671  }
1672 
1675  {
1676 
1677  }
1678 
1679 #if !FW_DIRECT_PORT_CALLS
1680 
1681  // ----------------------------------------------------------------------
1682  // Connection status queries for special output ports
1683  // ----------------------------------------------------------------------
1684 
1687  {
1688  FW_ASSERT(
1689  (0 <= portNum) && (portNum < this->getNum_cmdRegOut_OutputPorts()),
1690  static_cast<FwAssertArgType>(portNum)
1691  );
1692 
1693  return this->m_cmdRegOut_OutputPort[portNum].isConnected();
1694  }
1695 
1698  {
1699  FW_ASSERT(
1700  (0 <= portNum) && (portNum < this->getNum_cmdResponseOut_OutputPorts()),
1701  static_cast<FwAssertArgType>(portNum)
1702  );
1703 
1704  return this->m_cmdResponseOut_OutputPort[portNum].isConnected();
1705  }
1706 
1709  {
1710  FW_ASSERT(
1711  (0 <= portNum) && (portNum < this->getNum_logOut_OutputPorts()),
1712  static_cast<FwAssertArgType>(portNum)
1713  );
1714 
1715  return this->m_logOut_OutputPort[portNum].isConnected();
1716  }
1717 
1718 #if FW_ENABLE_TEXT_LOGGING == 1
1719 
1720  bool FpySequencerComponentBase ::
1721  isConnected_logTextOut_OutputPort(FwIndexType portNum) const
1722  {
1723  FW_ASSERT(
1724  (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
1725  static_cast<FwAssertArgType>(portNum)
1726  );
1727 
1728  return this->m_logTextOut_OutputPort[portNum].isConnected();
1729  }
1730 
1731 #endif
1732 
1735  {
1736  FW_ASSERT(
1737  (0 <= portNum) && (portNum < this->getNum_prmGet_OutputPorts()),
1738  static_cast<FwAssertArgType>(portNum)
1739  );
1740 
1741  return this->m_prmGet_OutputPort[portNum].isConnected();
1742  }
1743 
1746  {
1747  FW_ASSERT(
1748  (0 <= portNum) && (portNum < this->getNum_prmSet_OutputPorts()),
1749  static_cast<FwAssertArgType>(portNum)
1750  );
1751 
1752  return this->m_prmSet_OutputPort[portNum].isConnected();
1753  }
1754 
1757  {
1758  FW_ASSERT(
1759  (0 <= portNum) && (portNum < this->getNum_timeCaller_OutputPorts()),
1760  static_cast<FwAssertArgType>(portNum)
1761  );
1762 
1763  return this->m_timeCaller_OutputPort[portNum].isConnected();
1764  }
1765 
1768  {
1769  FW_ASSERT(
1770  (0 <= portNum) && (portNum < this->getNum_tlmOut_OutputPorts()),
1771  static_cast<FwAssertArgType>(portNum)
1772  );
1773 
1774  return this->m_tlmOut_OutputPort[portNum].isConnected();
1775  }
1776 
1777 #endif
1778 
1779 #if !FW_DIRECT_PORT_CALLS
1780 
1781  // ----------------------------------------------------------------------
1782  // Connection status queries for typed output ports
1783  // ----------------------------------------------------------------------
1784 
1787  {
1788  FW_ASSERT(
1789  (0 <= portNum) && (portNum < this->getNum_cmdOut_OutputPorts()),
1790  static_cast<FwAssertArgType>(portNum)
1791  );
1792 
1793  return this->m_cmdOut_OutputPort[portNum].isConnected();
1794  }
1795 
1798  {
1799  FW_ASSERT(
1800  (0 <= portNum) && (portNum < this->getNum_getParam_OutputPorts()),
1801  static_cast<FwAssertArgType>(portNum)
1802  );
1803 
1804  return this->m_getParam_OutputPort[portNum].isConnected();
1805  }
1806 
1809  {
1810  FW_ASSERT(
1811  (0 <= portNum) && (portNum < this->getNum_getTlmChan_OutputPorts()),
1812  static_cast<FwAssertArgType>(portNum)
1813  );
1814 
1815  return this->m_getTlmChan_OutputPort[portNum].isConnected();
1816  }
1817 
1820  {
1821  FW_ASSERT(
1822  (0 <= portNum) && (portNum < this->getNum_pingOut_OutputPorts()),
1823  static_cast<FwAssertArgType>(portNum)
1824  );
1825 
1826  return this->m_pingOut_OutputPort[portNum].isConnected();
1827  }
1828 
1831  {
1832  FW_ASSERT(
1833  (0 <= portNum) && (portNum < this->getNum_seqDoneOut_OutputPorts()),
1834  static_cast<FwAssertArgType>(portNum)
1835  );
1836 
1837  return this->m_seqDoneOut_OutputPort[portNum].isConnected();
1838  }
1839 
1842  {
1843  FW_ASSERT(
1844  (0 <= portNum) && (portNum < this->getNum_seqStartOut_OutputPorts()),
1845  static_cast<FwAssertArgType>(portNum)
1846  );
1847 
1848  return this->m_seqStartOut_OutputPort[portNum].isConnected();
1849  }
1850 
1851 #endif
1852 
1853 #if !FW_DIRECT_PORT_CALLS
1854 
1855  // ----------------------------------------------------------------------
1856  // Connection status queries for serial output ports
1857  // ----------------------------------------------------------------------
1858 
1861  {
1862  FW_ASSERT(
1863  (0 <= portNum) && (portNum < this->getNum_serialOut_OutputPorts()),
1864  static_cast<FwAssertArgType>(portNum)
1865  );
1866 
1867  return this->m_serialOut_OutputPort[portNum].isConnected();
1868  }
1869 
1870 #endif
1871 
1872  // ----------------------------------------------------------------------
1873  // Port handler base-class functions for special input ports
1874  //
1875  // Call these functions directly to bypass the corresponding ports
1876  // ----------------------------------------------------------------------
1877 
1880  FwIndexType portNum,
1881  FwOpcodeType opCode,
1882  U32 cmdSeq,
1883  Fw::CmdArgBuffer& args
1884  )
1885  {
1886 
1887  const U32 idBase = this->getIdBase();
1888  FW_ASSERT(opCode >= idBase, static_cast<FwAssertArgType>(opCode), static_cast<FwAssertArgType>(idBase));
1889 
1890  // Select base class function based on opcode
1891  switch (opCode - idBase) {
1892  case OPCODE_RUN: {
1893  this->RUN_cmdHandlerBase(
1894  opCode,
1895  cmdSeq,
1896  args
1897  );
1898  break;
1899  }
1900 
1901  case OPCODE_RUN_ARGS: {
1903  opCode,
1904  cmdSeq,
1905  args
1906  );
1907  break;
1908  }
1909 
1910  case OPCODE_VALIDATE: {
1912  opCode,
1913  cmdSeq,
1914  args
1915  );
1916  break;
1917  }
1918 
1919  case OPCODE_VALIDATE_ARGS: {
1921  opCode,
1922  cmdSeq,
1923  args
1924  );
1925  break;
1926  }
1927 
1928  case OPCODE_RUN_VALIDATED: {
1930  opCode,
1931  cmdSeq,
1932  args
1933  );
1934  break;
1935  }
1936 
1937  case OPCODE_CANCEL: {
1938  this->CANCEL_cmdHandlerBase(
1939  opCode,
1940  cmdSeq,
1941  args
1942  );
1943  break;
1944  }
1945 
1946  case OPCODE_SET_BREAKPOINT: {
1948  opCode,
1949  cmdSeq,
1950  args
1951  );
1952  break;
1953  }
1954 
1955  case OPCODE_BREAK: {
1956  this->BREAK_cmdHandlerBase(
1957  opCode,
1958  cmdSeq,
1959  args
1960  );
1961  break;
1962  }
1963 
1964  case OPCODE_CONTINUE: {
1966  opCode,
1967  cmdSeq,
1968  args
1969  );
1970  break;
1971  }
1972 
1973  case OPCODE_CLEAR_BREAKPOINT: {
1975  opCode,
1976  cmdSeq,
1977  args
1978  );
1979  break;
1980  }
1981 
1982  case OPCODE_STEP: {
1983  this->STEP_cmdHandlerBase(
1984  opCode,
1985  cmdSeq,
1986  args
1987  );
1988  break;
1989  }
1990 
1993  opCode,
1994  cmdSeq,
1995  args
1996  );
1997  break;
1998  }
1999 
2001  Fw::CmdResponse _cstat = this->paramSet_STATEMENT_TIMEOUT_SECS(args);
2002  this->cmdResponse_out(
2003  opCode,
2004  cmdSeq,
2005  _cstat
2006  );
2007  break;
2008  }
2009 
2011  Fw::CmdResponse _cstat = this->paramSave_STATEMENT_TIMEOUT_SECS();
2012  this->cmdResponse_out(
2013  opCode,
2014  cmdSeq,
2015  _cstat
2016  );
2017  break;
2018  }
2019 
2020  case OPCODE_SEQ_BASE_DIR_SET: {
2021  Fw::CmdResponse _cstat = this->paramSet_SEQ_BASE_DIR(args);
2022  this->cmdResponse_out(
2023  opCode,
2024  cmdSeq,
2025  _cstat
2026  );
2027  break;
2028  }
2029 
2030  case OPCODE_SEQ_BASE_DIR_SAVE: {
2031  Fw::CmdResponse _cstat = this->paramSave_SEQ_BASE_DIR();
2032  this->cmdResponse_out(
2033  opCode,
2034  cmdSeq,
2035  _cstat
2036  );
2037  break;
2038  }
2039  default:
2040  // Unknown opcode: ignore it
2041  break;
2042  }
2043  }
2044 
2045  // ----------------------------------------------------------------------
2046  // Port handler base-class functions for typed input ports
2047  //
2048  // Call these functions directly to bypass the corresponding ports
2049  // ----------------------------------------------------------------------
2050 
2053  FwIndexType portNum,
2054  U32 context
2055  )
2056  {
2057  // Make sure port number is valid
2058  FW_ASSERT(
2059  (0 <= portNum) && (portNum < this->getNum_checkTimers_InputPorts()),
2060  static_cast<FwAssertArgType>(portNum)
2061  );
2062 
2063  // Call pre-message hook
2065  portNum,
2066  context
2067  );
2068  ComponentIpcSerializableBuffer msg;
2070 
2071  // Serialize message ID
2072  _status = msg.serializeFrom(
2073  static_cast<FwEnumStoreType>(CHECKTIMERS_SCHED)
2074  );
2075  FW_ASSERT(
2076  _status == Fw::FW_SERIALIZE_OK,
2077  static_cast<FwAssertArgType>(_status)
2078  );
2079 
2080  // Serialize port number
2081  _status = msg.serializeFrom(portNum);
2082  FW_ASSERT(
2083  _status == Fw::FW_SERIALIZE_OK,
2084  static_cast<FwAssertArgType>(_status)
2085  );
2086 
2087  // Serialize argument context
2088  _status = msg.serializeFrom(context);
2089  FW_ASSERT(
2090  _status == Fw::FW_SERIALIZE_OK,
2091  static_cast<FwAssertArgType>(_status)
2092  );
2093 
2094  // Send message
2096  Os::Queue::Status qStatus = this->m_queue.send(msg, 4, _block);
2097 
2098  FW_ASSERT(
2099  qStatus == Os::Queue::OP_OK,
2100  static_cast<FwAssertArgType>(qStatus)
2101  );
2102  }
2103 
2106  FwIndexType portNum,
2107  FwOpcodeType opCode,
2108  U32 cmdSeq,
2109  const Fw::CmdResponse& response
2110  )
2111  {
2112  // Make sure port number is valid
2113  FW_ASSERT(
2114  (0 <= portNum) && (portNum < this->getNum_cmdResponseIn_InputPorts()),
2115  static_cast<FwAssertArgType>(portNum)
2116  );
2117 
2118  // Call pre-message hook
2120  portNum,
2121  opCode,
2122  cmdSeq,
2123  response
2124  );
2125  ComponentIpcSerializableBuffer msg;
2127 
2128  // Serialize message ID
2129  _status = msg.serializeFrom(
2130  static_cast<FwEnumStoreType>(CMDRESPONSEIN_CMDRESPONSE)
2131  );
2132  FW_ASSERT(
2133  _status == Fw::FW_SERIALIZE_OK,
2134  static_cast<FwAssertArgType>(_status)
2135  );
2136 
2137  // Serialize port number
2138  _status = msg.serializeFrom(portNum);
2139  FW_ASSERT(
2140  _status == Fw::FW_SERIALIZE_OK,
2141  static_cast<FwAssertArgType>(_status)
2142  );
2143 
2144  // Serialize argument opCode
2145  _status = msg.serializeFrom(opCode);
2146  FW_ASSERT(
2147  _status == Fw::FW_SERIALIZE_OK,
2148  static_cast<FwAssertArgType>(_status)
2149  );
2150 
2151  // Serialize argument cmdSeq
2152  _status = msg.serializeFrom(cmdSeq);
2153  FW_ASSERT(
2154  _status == Fw::FW_SERIALIZE_OK,
2155  static_cast<FwAssertArgType>(_status)
2156  );
2157 
2158  // Serialize argument response
2159  _status = msg.serializeFrom(response);
2160  FW_ASSERT(
2161  _status == Fw::FW_SERIALIZE_OK,
2162  static_cast<FwAssertArgType>(_status)
2163  );
2164 
2165  // Send message
2167  Os::Queue::Status qStatus = this->m_queue.send(msg, 5, _block);
2168 
2169  FW_ASSERT(
2170  qStatus == Os::Queue::OP_OK,
2171  static_cast<FwAssertArgType>(qStatus)
2172  );
2173  }
2174 
2177  FwIndexType portNum,
2178  U32 key
2179  )
2180  {
2181  // Make sure port number is valid
2182  FW_ASSERT(
2183  (0 <= portNum) && (portNum < this->getNum_pingIn_InputPorts()),
2184  static_cast<FwAssertArgType>(portNum)
2185  );
2186 
2187  // Call pre-message hook
2189  portNum,
2190  key
2191  );
2192  ComponentIpcSerializableBuffer msg;
2194 
2195  // Serialize message ID
2196  _status = msg.serializeFrom(
2197  static_cast<FwEnumStoreType>(PINGIN_PING)
2198  );
2199  FW_ASSERT(
2200  _status == Fw::FW_SERIALIZE_OK,
2201  static_cast<FwAssertArgType>(_status)
2202  );
2203 
2204  // Serialize port number
2205  _status = msg.serializeFrom(portNum);
2206  FW_ASSERT(
2207  _status == Fw::FW_SERIALIZE_OK,
2208  static_cast<FwAssertArgType>(_status)
2209  );
2210 
2211  // Serialize argument key
2212  _status = msg.serializeFrom(key);
2213  FW_ASSERT(
2214  _status == Fw::FW_SERIALIZE_OK,
2215  static_cast<FwAssertArgType>(_status)
2216  );
2217 
2218  // Send message
2220  Os::Queue::Status qStatus = this->m_queue.send(msg, 10, _block);
2221 
2222  FW_ASSERT(
2223  qStatus == Os::Queue::OP_OK,
2224  static_cast<FwAssertArgType>(qStatus)
2225  );
2226  }
2227 
2230  {
2231  // Make sure port number is valid
2232  FW_ASSERT(
2233  (0 <= portNum) && (portNum < this->getNum_seqCancelIn_InputPorts()),
2234  static_cast<FwAssertArgType>(portNum)
2235  );
2236 
2237  // Call pre-message hook
2238  seqCancelIn_preMsgHook(portNum);
2239  ComponentIpcSerializableBuffer msg;
2241 
2242  // Serialize message ID
2243  _status = msg.serializeFrom(
2244  static_cast<FwEnumStoreType>(SEQCANCELIN_CMDSEQCANCEL)
2245  );
2246  FW_ASSERT(
2247  _status == Fw::FW_SERIALIZE_OK,
2248  static_cast<FwAssertArgType>(_status)
2249  );
2250 
2251  // Serialize port number
2252  _status = msg.serializeFrom(portNum);
2253  FW_ASSERT(
2254  _status == Fw::FW_SERIALIZE_OK,
2255  static_cast<FwAssertArgType>(_status)
2256  );
2257 
2258  // Send message
2260  Os::Queue::Status qStatus = this->m_queue.send(msg, 8, _block);
2261 
2262  FW_ASSERT(
2263  qStatus == Os::Queue::OP_OK,
2264  static_cast<FwAssertArgType>(qStatus)
2265  );
2266  }
2267 
2270  FwIndexType portNum,
2271  const Fw::StringBase& filename,
2272  const Svc::SeqArgs& args
2273  )
2274  {
2275  // Make sure port number is valid
2276  FW_ASSERT(
2277  (0 <= portNum) && (portNum < this->getNum_seqRunIn_InputPorts()),
2278  static_cast<FwAssertArgType>(portNum)
2279  );
2280 
2281  // Call pre-message hook
2283  portNum,
2284  filename,
2285  args
2286  );
2287  ComponentIpcSerializableBuffer msg;
2289 
2290  // Serialize message ID
2291  _status = msg.serializeFrom(
2292  static_cast<FwEnumStoreType>(SEQRUNIN_CMDSEQIN)
2293  );
2294  FW_ASSERT(
2295  _status == Fw::FW_SERIALIZE_OK,
2296  static_cast<FwAssertArgType>(_status)
2297  );
2298 
2299  // Serialize port number
2300  _status = msg.serializeFrom(portNum);
2301  FW_ASSERT(
2302  _status == Fw::FW_SERIALIZE_OK,
2303  static_cast<FwAssertArgType>(_status)
2304  );
2305 
2306  // Serialize argument filename
2307  _status = filename.serializeTo(msg, 240);
2308  FW_ASSERT(
2309  _status == Fw::FW_SERIALIZE_OK,
2310  static_cast<FwAssertArgType>(_status)
2311  );
2312 
2313  // Serialize argument args
2314  _status = msg.serializeFrom(args);
2315  FW_ASSERT(
2316  _status == Fw::FW_SERIALIZE_OK,
2317  static_cast<FwAssertArgType>(_status)
2318  );
2319 
2320  // Send message
2322  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
2323 
2324  FW_ASSERT(
2325  qStatus == Os::Queue::OP_OK,
2326  static_cast<FwAssertArgType>(qStatus)
2327  );
2328  }
2329 
2332  FwIndexType portNum,
2333  U32 context
2334  )
2335  {
2336  // Make sure port number is valid
2337  FW_ASSERT(
2338  (0 <= portNum) && (portNum < this->getNum_tlmWrite_InputPorts()),
2339  static_cast<FwAssertArgType>(portNum)
2340  );
2341 
2342  // Call pre-message hook
2344  portNum,
2345  context
2346  );
2347  ComponentIpcSerializableBuffer msg;
2349 
2350  // Serialize message ID
2351  _status = msg.serializeFrom(
2352  static_cast<FwEnumStoreType>(TLMWRITE_SCHED)
2353  );
2354  FW_ASSERT(
2355  _status == Fw::FW_SERIALIZE_OK,
2356  static_cast<FwAssertArgType>(_status)
2357  );
2358 
2359  // Serialize port number
2360  _status = msg.serializeFrom(portNum);
2361  FW_ASSERT(
2362  _status == Fw::FW_SERIALIZE_OK,
2363  static_cast<FwAssertArgType>(_status)
2364  );
2365 
2366  // Serialize argument context
2367  _status = msg.serializeFrom(context);
2368  FW_ASSERT(
2369  _status == Fw::FW_SERIALIZE_OK,
2370  static_cast<FwAssertArgType>(_status)
2371  );
2372 
2373  // Send message
2375  Os::Queue::Status qStatus = this->m_queue.send(msg, 1, _block);
2376 
2377  FW_ASSERT(
2378  qStatus == Os::Queue::OP_OK,
2379  static_cast<FwAssertArgType>(qStatus)
2380  );
2381  }
2382 
2383  // ----------------------------------------------------------------------
2384  // Pre-message hooks for typed async input ports
2385  //
2386  // Each of these functions is invoked just before processing a message
2387  // on the corresponding port. By default, they do nothing. You can
2388  // override them to provide specific pre-message behavior.
2389  // ----------------------------------------------------------------------
2390 
2393  FwIndexType portNum,
2394  U32 context
2395  )
2396  {
2397  // Default: no-op
2398  }
2399 
2402  FwIndexType portNum,
2403  FwOpcodeType opCode,
2404  U32 cmdSeq,
2405  const Fw::CmdResponse& response
2406  )
2407  {
2408  // Default: no-op
2409  }
2410 
2413  FwIndexType portNum,
2414  U32 key
2415  )
2416  {
2417  // Default: no-op
2418  }
2419 
2422  {
2423  // Default: no-op
2424  }
2425 
2428  FwIndexType portNum,
2429  const Fw::StringBase& filename,
2430  const Svc::SeqArgs& args
2431  )
2432  {
2433  // Default: no-op
2434  }
2435 
2438  FwIndexType portNum,
2439  U32 context
2440  )
2441  {
2442  // Default: no-op
2443  }
2444 
2445 #if !FW_DIRECT_PORT_CALLS
2446 
2447  // ----------------------------------------------------------------------
2448  // Invocation functions for typed output ports
2449  // ----------------------------------------------------------------------
2450 
2453  FwIndexType portNum,
2454  Fw::ComBuffer& data,
2455  U32 context
2456  ) const
2457  {
2458  FW_ASSERT(
2459  (0 <= portNum) && (portNum < this->getNum_cmdOut_OutputPorts()),
2460  static_cast<FwAssertArgType>(portNum)
2461  );
2462 
2463  FW_ASSERT(
2464  this->m_cmdOut_OutputPort[portNum].isConnected(),
2465  static_cast<FwAssertArgType>(portNum)
2466  );
2467  this->m_cmdOut_OutputPort[portNum].invoke(
2468  data,
2469  context
2470  );
2471  }
2472 
2475  FwIndexType portNum,
2476  FwPrmIdType id,
2477  Fw::ParamBuffer& val
2478  ) const
2479  {
2480  FW_ASSERT(
2481  (0 <= portNum) && (portNum < this->getNum_getParam_OutputPorts()),
2482  static_cast<FwAssertArgType>(portNum)
2483  );
2484 
2485  FW_ASSERT(
2486  this->m_getParam_OutputPort[portNum].isConnected(),
2487  static_cast<FwAssertArgType>(portNum)
2488  );
2489  return this->m_getParam_OutputPort[portNum].invoke(
2490  id,
2491  val
2492  );
2493  }
2494 
2497  FwIndexType portNum,
2498  FwChanIdType id,
2499  Fw::Time& timeTag,
2500  Fw::TlmBuffer& val
2501  ) const
2502  {
2503  FW_ASSERT(
2504  (0 <= portNum) && (portNum < this->getNum_getTlmChan_OutputPorts()),
2505  static_cast<FwAssertArgType>(portNum)
2506  );
2507 
2508  FW_ASSERT(
2509  this->m_getTlmChan_OutputPort[portNum].isConnected(),
2510  static_cast<FwAssertArgType>(portNum)
2511  );
2512  return this->m_getTlmChan_OutputPort[portNum].invoke(
2513  id,
2514  timeTag,
2515  val
2516  );
2517  }
2518 
2521  FwIndexType portNum,
2522  U32 key
2523  ) const
2524  {
2525  FW_ASSERT(
2526  (0 <= portNum) && (portNum < this->getNum_pingOut_OutputPorts()),
2527  static_cast<FwAssertArgType>(portNum)
2528  );
2529 
2530  FW_ASSERT(
2531  this->m_pingOut_OutputPort[portNum].isConnected(),
2532  static_cast<FwAssertArgType>(portNum)
2533  );
2534  this->m_pingOut_OutputPort[portNum].invoke(
2535  key
2536  );
2537  }
2538 
2541  FwIndexType portNum,
2542  FwOpcodeType opCode,
2543  U32 cmdSeq,
2544  const Fw::CmdResponse& response
2545  ) const
2546  {
2547  FW_ASSERT(
2548  (0 <= portNum) && (portNum < this->getNum_seqDoneOut_OutputPorts()),
2549  static_cast<FwAssertArgType>(portNum)
2550  );
2551 
2552  FW_ASSERT(
2553  this->m_seqDoneOut_OutputPort[portNum].isConnected(),
2554  static_cast<FwAssertArgType>(portNum)
2555  );
2556  this->m_seqDoneOut_OutputPort[portNum].invoke(
2557  opCode,
2558  cmdSeq,
2559  response
2560  );
2561  }
2562 
2565  FwIndexType portNum,
2566  const Fw::StringBase& filename,
2567  const Svc::SeqArgs& args
2568  ) const
2569  {
2570  FW_ASSERT(
2571  (0 <= portNum) && (portNum < this->getNum_seqStartOut_OutputPorts()),
2572  static_cast<FwAssertArgType>(portNum)
2573  );
2574 
2575  FW_ASSERT(
2576  this->m_seqStartOut_OutputPort[portNum].isConnected(),
2577  static_cast<FwAssertArgType>(portNum)
2578  );
2579  this->m_seqStartOut_OutputPort[portNum].invoke(
2580  filename,
2581  args
2582  );
2583  }
2584 
2585 #endif
2586 
2587 #if !FW_DIRECT_PORT_CALLS
2588 
2589  // ----------------------------------------------------------------------
2590  // Invocation functions for serial output ports
2591  // ----------------------------------------------------------------------
2592 
2595  FwIndexType portNum,
2596  Fw::LinearBufferBase& buffer
2597  )
2598  {
2599  FW_ASSERT(
2600  (0 <= portNum) && (portNum < this->getNum_serialOut_OutputPorts()),
2601  static_cast<FwAssertArgType>(portNum)
2602  );
2603 
2604  FW_ASSERT(
2605  this->m_serialOut_OutputPort[portNum].isConnected(),
2606  static_cast<FwAssertArgType>(portNum)
2607  );
2608  return this->m_serialOut_OutputPort[portNum].invokeSerial(
2609  buffer
2610  );
2611  }
2612 
2613 #endif
2614 
2615  // ----------------------------------------------------------------------
2616  // Internal interface base-class functions
2617  // ----------------------------------------------------------------------
2618 
2621  {
2622  ComponentIpcSerializableBuffer msg;
2624 
2625  // Serialize the message ID
2626  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_ALLOCATE));
2627  FW_ASSERT (
2628  _status == Fw::FW_SERIALIZE_OK,
2629  static_cast<FwAssertArgType>(_status)
2630  );
2631 
2632  // Fake port number to make message dequeue work
2633  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2634  FW_ASSERT (
2635  _status == Fw::FW_SERIALIZE_OK,
2636  static_cast<FwAssertArgType>(_status)
2637  );
2638 
2639  _status = msg.serializeFrom(directive);
2640  FW_ASSERT(
2641  _status == Fw::FW_SERIALIZE_OK,
2642  static_cast<FwAssertArgType>(_status)
2643  );
2644 
2645  // Send message
2647  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2648 
2649  FW_ASSERT(
2650  qStatus == Os::Queue::OP_OK,
2651  static_cast<FwAssertArgType>(qStatus)
2652  );
2653  }
2654 
2657  {
2658  ComponentIpcSerializableBuffer msg;
2660 
2661  // Serialize the message ID
2662  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_CALL));
2663  FW_ASSERT (
2664  _status == Fw::FW_SERIALIZE_OK,
2665  static_cast<FwAssertArgType>(_status)
2666  );
2667 
2668  // Fake port number to make message dequeue work
2669  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2670  FW_ASSERT (
2671  _status == Fw::FW_SERIALIZE_OK,
2672  static_cast<FwAssertArgType>(_status)
2673  );
2674 
2675  _status = msg.serializeFrom(directive);
2676  FW_ASSERT(
2677  _status == Fw::FW_SERIALIZE_OK,
2678  static_cast<FwAssertArgType>(_status)
2679  );
2680 
2681  // Send message
2683  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2684 
2685  FW_ASSERT(
2686  qStatus == Os::Queue::OP_OK,
2687  static_cast<FwAssertArgType>(qStatus)
2688  );
2689  }
2690 
2693  {
2694  ComponentIpcSerializableBuffer msg;
2696 
2697  // Serialize the message ID
2698  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_CONSTCMD));
2699  FW_ASSERT (
2700  _status == Fw::FW_SERIALIZE_OK,
2701  static_cast<FwAssertArgType>(_status)
2702  );
2703 
2704  // Fake port number to make message dequeue work
2705  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2706  FW_ASSERT (
2707  _status == Fw::FW_SERIALIZE_OK,
2708  static_cast<FwAssertArgType>(_status)
2709  );
2710 
2711  _status = msg.serializeFrom(directive);
2712  FW_ASSERT(
2713  _status == Fw::FW_SERIALIZE_OK,
2714  static_cast<FwAssertArgType>(_status)
2715  );
2716 
2717  // Send message
2719  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2720 
2721  FW_ASSERT(
2722  qStatus == Os::Queue::OP_OK,
2723  static_cast<FwAssertArgType>(qStatus)
2724  );
2725  }
2726 
2729  {
2730  ComponentIpcSerializableBuffer msg;
2732 
2733  // Serialize the message ID
2734  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_DISCARD));
2735  FW_ASSERT (
2736  _status == Fw::FW_SERIALIZE_OK,
2737  static_cast<FwAssertArgType>(_status)
2738  );
2739 
2740  // Fake port number to make message dequeue work
2741  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2742  FW_ASSERT (
2743  _status == Fw::FW_SERIALIZE_OK,
2744  static_cast<FwAssertArgType>(_status)
2745  );
2746 
2747  _status = msg.serializeFrom(directive);
2748  FW_ASSERT(
2749  _status == Fw::FW_SERIALIZE_OK,
2750  static_cast<FwAssertArgType>(_status)
2751  );
2752 
2753  // Send message
2755  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2756 
2757  FW_ASSERT(
2758  qStatus == Os::Queue::OP_OK,
2759  static_cast<FwAssertArgType>(qStatus)
2760  );
2761  }
2762 
2765  {
2766  ComponentIpcSerializableBuffer msg;
2768 
2769  // Serialize the message ID
2770  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_EXIT));
2771  FW_ASSERT (
2772  _status == Fw::FW_SERIALIZE_OK,
2773  static_cast<FwAssertArgType>(_status)
2774  );
2775 
2776  // Fake port number to make message dequeue work
2777  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2778  FW_ASSERT (
2779  _status == Fw::FW_SERIALIZE_OK,
2780  static_cast<FwAssertArgType>(_status)
2781  );
2782 
2783  _status = msg.serializeFrom(directive);
2784  FW_ASSERT(
2785  _status == Fw::FW_SERIALIZE_OK,
2786  static_cast<FwAssertArgType>(_status)
2787  );
2788 
2789  // Send message
2791  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2792 
2793  FW_ASSERT(
2794  qStatus == Os::Queue::OP_OK,
2795  static_cast<FwAssertArgType>(qStatus)
2796  );
2797  }
2798 
2801  {
2802  ComponentIpcSerializableBuffer msg;
2804 
2805  // Serialize the message ID
2806  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_GETFIELD));
2807  FW_ASSERT (
2808  _status == Fw::FW_SERIALIZE_OK,
2809  static_cast<FwAssertArgType>(_status)
2810  );
2811 
2812  // Fake port number to make message dequeue work
2813  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2814  FW_ASSERT (
2815  _status == Fw::FW_SERIALIZE_OK,
2816  static_cast<FwAssertArgType>(_status)
2817  );
2818 
2819  _status = msg.serializeFrom(directive);
2820  FW_ASSERT(
2821  _status == Fw::FW_SERIALIZE_OK,
2822  static_cast<FwAssertArgType>(_status)
2823  );
2824 
2825  // Send message
2827  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2828 
2829  FW_ASSERT(
2830  qStatus == Os::Queue::OP_OK,
2831  static_cast<FwAssertArgType>(qStatus)
2832  );
2833  }
2834 
2837  {
2838  ComponentIpcSerializableBuffer msg;
2840 
2841  // Serialize the message ID
2842  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_GOTO));
2843  FW_ASSERT (
2844  _status == Fw::FW_SERIALIZE_OK,
2845  static_cast<FwAssertArgType>(_status)
2846  );
2847 
2848  // Fake port number to make message dequeue work
2849  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2850  FW_ASSERT (
2851  _status == Fw::FW_SERIALIZE_OK,
2852  static_cast<FwAssertArgType>(_status)
2853  );
2854 
2855  _status = msg.serializeFrom(directive);
2856  FW_ASSERT(
2857  _status == Fw::FW_SERIALIZE_OK,
2858  static_cast<FwAssertArgType>(_status)
2859  );
2860 
2861  // Send message
2863  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2864 
2865  FW_ASSERT(
2866  qStatus == Os::Queue::OP_OK,
2867  static_cast<FwAssertArgType>(qStatus)
2868  );
2869  }
2870 
2873  {
2874  ComponentIpcSerializableBuffer msg;
2876 
2877  // Serialize the message ID
2878  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_IF));
2879  FW_ASSERT (
2880  _status == Fw::FW_SERIALIZE_OK,
2881  static_cast<FwAssertArgType>(_status)
2882  );
2883 
2884  // Fake port number to make message dequeue work
2885  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2886  FW_ASSERT (
2887  _status == Fw::FW_SERIALIZE_OK,
2888  static_cast<FwAssertArgType>(_status)
2889  );
2890 
2891  _status = msg.serializeFrom(directive);
2892  FW_ASSERT(
2893  _status == Fw::FW_SERIALIZE_OK,
2894  static_cast<FwAssertArgType>(_status)
2895  );
2896 
2897  // Send message
2899  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2900 
2901  FW_ASSERT(
2902  qStatus == Os::Queue::OP_OK,
2903  static_cast<FwAssertArgType>(qStatus)
2904  );
2905  }
2906 
2909  {
2910  ComponentIpcSerializableBuffer msg;
2912 
2913  // Serialize the message ID
2914  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_LOADABS));
2915  FW_ASSERT (
2916  _status == Fw::FW_SERIALIZE_OK,
2917  static_cast<FwAssertArgType>(_status)
2918  );
2919 
2920  // Fake port number to make message dequeue work
2921  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2922  FW_ASSERT (
2923  _status == Fw::FW_SERIALIZE_OK,
2924  static_cast<FwAssertArgType>(_status)
2925  );
2926 
2927  _status = msg.serializeFrom(directive);
2928  FW_ASSERT(
2929  _status == Fw::FW_SERIALIZE_OK,
2930  static_cast<FwAssertArgType>(_status)
2931  );
2932 
2933  // Send message
2935  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2936 
2937  FW_ASSERT(
2938  qStatus == Os::Queue::OP_OK,
2939  static_cast<FwAssertArgType>(qStatus)
2940  );
2941  }
2942 
2945  {
2946  ComponentIpcSerializableBuffer msg;
2948 
2949  // Serialize the message ID
2950  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_LOADREL));
2951  FW_ASSERT (
2952  _status == Fw::FW_SERIALIZE_OK,
2953  static_cast<FwAssertArgType>(_status)
2954  );
2955 
2956  // Fake port number to make message dequeue work
2957  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2958  FW_ASSERT (
2959  _status == Fw::FW_SERIALIZE_OK,
2960  static_cast<FwAssertArgType>(_status)
2961  );
2962 
2963  _status = msg.serializeFrom(directive);
2964  FW_ASSERT(
2965  _status == Fw::FW_SERIALIZE_OK,
2966  static_cast<FwAssertArgType>(_status)
2967  );
2968 
2969  // Send message
2971  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
2972 
2973  FW_ASSERT(
2974  qStatus == Os::Queue::OP_OK,
2975  static_cast<FwAssertArgType>(qStatus)
2976  );
2977  }
2978 
2981  {
2982  ComponentIpcSerializableBuffer msg;
2984 
2985  // Serialize the message ID
2986  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_MEMCMP));
2987  FW_ASSERT (
2988  _status == Fw::FW_SERIALIZE_OK,
2989  static_cast<FwAssertArgType>(_status)
2990  );
2991 
2992  // Fake port number to make message dequeue work
2993  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
2994  FW_ASSERT (
2995  _status == Fw::FW_SERIALIZE_OK,
2996  static_cast<FwAssertArgType>(_status)
2997  );
2998 
2999  _status = msg.serializeFrom(directive);
3000  FW_ASSERT(
3001  _status == Fw::FW_SERIALIZE_OK,
3002  static_cast<FwAssertArgType>(_status)
3003  );
3004 
3005  // Send message
3007  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3008 
3009  FW_ASSERT(
3010  qStatus == Os::Queue::OP_OK,
3011  static_cast<FwAssertArgType>(qStatus)
3012  );
3013  }
3014 
3017  {
3018  ComponentIpcSerializableBuffer msg;
3020 
3021  // Serialize the message ID
3022  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_NOOP));
3023  FW_ASSERT (
3024  _status == Fw::FW_SERIALIZE_OK,
3025  static_cast<FwAssertArgType>(_status)
3026  );
3027 
3028  // Fake port number to make message dequeue work
3029  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3030  FW_ASSERT (
3031  _status == Fw::FW_SERIALIZE_OK,
3032  static_cast<FwAssertArgType>(_status)
3033  );
3034 
3035  _status = msg.serializeFrom(directive);
3036  FW_ASSERT(
3037  _status == Fw::FW_SERIALIZE_OK,
3038  static_cast<FwAssertArgType>(_status)
3039  );
3040 
3041  // Send message
3043  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3044 
3045  FW_ASSERT(
3046  qStatus == Os::Queue::OP_OK,
3047  static_cast<FwAssertArgType>(qStatus)
3048  );
3049  }
3050 
3053  {
3054  ComponentIpcSerializableBuffer msg;
3056 
3057  // Serialize the message ID
3058  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_PEEK));
3059  FW_ASSERT (
3060  _status == Fw::FW_SERIALIZE_OK,
3061  static_cast<FwAssertArgType>(_status)
3062  );
3063 
3064  // Fake port number to make message dequeue work
3065  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3066  FW_ASSERT (
3067  _status == Fw::FW_SERIALIZE_OK,
3068  static_cast<FwAssertArgType>(_status)
3069  );
3070 
3071  _status = msg.serializeFrom(directive);
3072  FW_ASSERT(
3073  _status == Fw::FW_SERIALIZE_OK,
3074  static_cast<FwAssertArgType>(_status)
3075  );
3076 
3077  // Send message
3079  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3080 
3081  FW_ASSERT(
3082  qStatus == Os::Queue::OP_OK,
3083  static_cast<FwAssertArgType>(qStatus)
3084  );
3085  }
3086 
3089  {
3090  ComponentIpcSerializableBuffer msg;
3092 
3093  // Serialize the message ID
3094  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_POPEVENT));
3095  FW_ASSERT (
3096  _status == Fw::FW_SERIALIZE_OK,
3097  static_cast<FwAssertArgType>(_status)
3098  );
3099 
3100  // Fake port number to make message dequeue work
3101  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3102  FW_ASSERT (
3103  _status == Fw::FW_SERIALIZE_OK,
3104  static_cast<FwAssertArgType>(_status)
3105  );
3106 
3107  _status = msg.serializeFrom(directive);
3108  FW_ASSERT(
3109  _status == Fw::FW_SERIALIZE_OK,
3110  static_cast<FwAssertArgType>(_status)
3111  );
3112 
3113  // Send message
3115  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3116 
3117  FW_ASSERT(
3118  qStatus == Os::Queue::OP_OK,
3119  static_cast<FwAssertArgType>(qStatus)
3120  );
3121  }
3122 
3125  {
3126  ComponentIpcSerializableBuffer msg;
3128 
3129  // Serialize the message ID
3130  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_POPSERIALIZABLE));
3131  FW_ASSERT (
3132  _status == Fw::FW_SERIALIZE_OK,
3133  static_cast<FwAssertArgType>(_status)
3134  );
3135 
3136  // Fake port number to make message dequeue work
3137  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3138  FW_ASSERT (
3139  _status == Fw::FW_SERIALIZE_OK,
3140  static_cast<FwAssertArgType>(_status)
3141  );
3142 
3143  _status = msg.serializeFrom(directive);
3144  FW_ASSERT(
3145  _status == Fw::FW_SERIALIZE_OK,
3146  static_cast<FwAssertArgType>(_status)
3147  );
3148 
3149  // Send message
3151  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3152 
3153  FW_ASSERT(
3154  qStatus == Os::Queue::OP_OK,
3155  static_cast<FwAssertArgType>(qStatus)
3156  );
3157  }
3158 
3161  {
3162  ComponentIpcSerializableBuffer msg;
3164 
3165  // Serialize the message ID
3166  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_PUSHPRM));
3167  FW_ASSERT (
3168  _status == Fw::FW_SERIALIZE_OK,
3169  static_cast<FwAssertArgType>(_status)
3170  );
3171 
3172  // Fake port number to make message dequeue work
3173  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3174  FW_ASSERT (
3175  _status == Fw::FW_SERIALIZE_OK,
3176  static_cast<FwAssertArgType>(_status)
3177  );
3178 
3179  _status = msg.serializeFrom(directive);
3180  FW_ASSERT(
3181  _status == Fw::FW_SERIALIZE_OK,
3182  static_cast<FwAssertArgType>(_status)
3183  );
3184 
3185  // Send message
3187  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3188 
3189  FW_ASSERT(
3190  qStatus == Os::Queue::OP_OK,
3191  static_cast<FwAssertArgType>(qStatus)
3192  );
3193  }
3194 
3197  {
3198  ComponentIpcSerializableBuffer msg;
3200 
3201  // Serialize the message ID
3202  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_PUSHRAND));
3203  FW_ASSERT (
3204  _status == Fw::FW_SERIALIZE_OK,
3205  static_cast<FwAssertArgType>(_status)
3206  );
3207 
3208  // Fake port number to make message dequeue work
3209  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3210  FW_ASSERT (
3211  _status == Fw::FW_SERIALIZE_OK,
3212  static_cast<FwAssertArgType>(_status)
3213  );
3214 
3215  _status = msg.serializeFrom(directive);
3216  FW_ASSERT(
3217  _status == Fw::FW_SERIALIZE_OK,
3218  static_cast<FwAssertArgType>(_status)
3219  );
3220 
3221  // Send message
3223  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3224 
3225  FW_ASSERT(
3226  qStatus == Os::Queue::OP_OK,
3227  static_cast<FwAssertArgType>(qStatus)
3228  );
3229  }
3230 
3233  {
3234  ComponentIpcSerializableBuffer msg;
3236 
3237  // Serialize the message ID
3238  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_PUSHTIME));
3239  FW_ASSERT (
3240  _status == Fw::FW_SERIALIZE_OK,
3241  static_cast<FwAssertArgType>(_status)
3242  );
3243 
3244  // Fake port number to make message dequeue work
3245  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3246  FW_ASSERT (
3247  _status == Fw::FW_SERIALIZE_OK,
3248  static_cast<FwAssertArgType>(_status)
3249  );
3250 
3251  _status = msg.serializeFrom(directive);
3252  FW_ASSERT(
3253  _status == Fw::FW_SERIALIZE_OK,
3254  static_cast<FwAssertArgType>(_status)
3255  );
3256 
3257  // Send message
3259  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3260 
3261  FW_ASSERT(
3262  qStatus == Os::Queue::OP_OK,
3263  static_cast<FwAssertArgType>(qStatus)
3264  );
3265  }
3266 
3269  {
3270  ComponentIpcSerializableBuffer msg;
3272 
3273  // Serialize the message ID
3274  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_PUSHTLMVAL));
3275  FW_ASSERT (
3276  _status == Fw::FW_SERIALIZE_OK,
3277  static_cast<FwAssertArgType>(_status)
3278  );
3279 
3280  // Fake port number to make message dequeue work
3281  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3282  FW_ASSERT (
3283  _status == Fw::FW_SERIALIZE_OK,
3284  static_cast<FwAssertArgType>(_status)
3285  );
3286 
3287  _status = msg.serializeFrom(directive);
3288  FW_ASSERT(
3289  _status == Fw::FW_SERIALIZE_OK,
3290  static_cast<FwAssertArgType>(_status)
3291  );
3292 
3293  // Send message
3295  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3296 
3297  FW_ASSERT(
3298  qStatus == Os::Queue::OP_OK,
3299  static_cast<FwAssertArgType>(qStatus)
3300  );
3301  }
3302 
3305  {
3306  ComponentIpcSerializableBuffer msg;
3308 
3309  // Serialize the message ID
3310  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_PUSHTLMVALANDTIME));
3311  FW_ASSERT (
3312  _status == Fw::FW_SERIALIZE_OK,
3313  static_cast<FwAssertArgType>(_status)
3314  );
3315 
3316  // Fake port number to make message dequeue work
3317  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3318  FW_ASSERT (
3319  _status == Fw::FW_SERIALIZE_OK,
3320  static_cast<FwAssertArgType>(_status)
3321  );
3322 
3323  _status = msg.serializeFrom(directive);
3324  FW_ASSERT(
3325  _status == Fw::FW_SERIALIZE_OK,
3326  static_cast<FwAssertArgType>(_status)
3327  );
3328 
3329  // Send message
3331  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3332 
3333  FW_ASSERT(
3334  qStatus == Os::Queue::OP_OK,
3335  static_cast<FwAssertArgType>(qStatus)
3336  );
3337  }
3338 
3341  {
3342  ComponentIpcSerializableBuffer msg;
3344 
3345  // Serialize the message ID
3346  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_PUSHVAL));
3347  FW_ASSERT (
3348  _status == Fw::FW_SERIALIZE_OK,
3349  static_cast<FwAssertArgType>(_status)
3350  );
3351 
3352  // Fake port number to make message dequeue work
3353  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3354  FW_ASSERT (
3355  _status == Fw::FW_SERIALIZE_OK,
3356  static_cast<FwAssertArgType>(_status)
3357  );
3358 
3359  _status = msg.serializeFrom(directive);
3360  FW_ASSERT(
3361  _status == Fw::FW_SERIALIZE_OK,
3362  static_cast<FwAssertArgType>(_status)
3363  );
3364 
3365  // Send message
3367  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3368 
3369  FW_ASSERT(
3370  qStatus == Os::Queue::OP_OK,
3371  static_cast<FwAssertArgType>(qStatus)
3372  );
3373  }
3374 
3377  {
3378  ComponentIpcSerializableBuffer msg;
3380 
3381  // Serialize the message ID
3382  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_RETURN));
3383  FW_ASSERT (
3384  _status == Fw::FW_SERIALIZE_OK,
3385  static_cast<FwAssertArgType>(_status)
3386  );
3387 
3388  // Fake port number to make message dequeue work
3389  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3390  FW_ASSERT (
3391  _status == Fw::FW_SERIALIZE_OK,
3392  static_cast<FwAssertArgType>(_status)
3393  );
3394 
3395  _status = msg.serializeFrom(directive);
3396  FW_ASSERT(
3397  _status == Fw::FW_SERIALIZE_OK,
3398  static_cast<FwAssertArgType>(_status)
3399  );
3400 
3401  // Send message
3403  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3404 
3405  FW_ASSERT(
3406  qStatus == Os::Queue::OP_OK,
3407  static_cast<FwAssertArgType>(qStatus)
3408  );
3409  }
3410 
3413  {
3414  ComponentIpcSerializableBuffer msg;
3416 
3417  // Serialize the message ID
3418  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_SETSEED));
3419  FW_ASSERT (
3420  _status == Fw::FW_SERIALIZE_OK,
3421  static_cast<FwAssertArgType>(_status)
3422  );
3423 
3424  // Fake port number to make message dequeue work
3425  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3426  FW_ASSERT (
3427  _status == Fw::FW_SERIALIZE_OK,
3428  static_cast<FwAssertArgType>(_status)
3429  );
3430 
3431  _status = msg.serializeFrom(directive);
3432  FW_ASSERT(
3433  _status == Fw::FW_SERIALIZE_OK,
3434  static_cast<FwAssertArgType>(_status)
3435  );
3436 
3437  // Send message
3439  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3440 
3441  FW_ASSERT(
3442  qStatus == Os::Queue::OP_OK,
3443  static_cast<FwAssertArgType>(qStatus)
3444  );
3445  }
3446 
3449  {
3450  ComponentIpcSerializableBuffer msg;
3452 
3453  // Serialize the message ID
3454  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_STACKCMD));
3455  FW_ASSERT (
3456  _status == Fw::FW_SERIALIZE_OK,
3457  static_cast<FwAssertArgType>(_status)
3458  );
3459 
3460  // Fake port number to make message dequeue work
3461  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3462  FW_ASSERT (
3463  _status == Fw::FW_SERIALIZE_OK,
3464  static_cast<FwAssertArgType>(_status)
3465  );
3466 
3467  _status = msg.serializeFrom(directive);
3468  FW_ASSERT(
3469  _status == Fw::FW_SERIALIZE_OK,
3470  static_cast<FwAssertArgType>(_status)
3471  );
3472 
3473  // Send message
3475  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3476 
3477  FW_ASSERT(
3478  qStatus == Os::Queue::OP_OK,
3479  static_cast<FwAssertArgType>(qStatus)
3480  );
3481  }
3482 
3485  {
3486  ComponentIpcSerializableBuffer msg;
3488 
3489  // Serialize the message ID
3490  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_STACKOP));
3491  FW_ASSERT (
3492  _status == Fw::FW_SERIALIZE_OK,
3493  static_cast<FwAssertArgType>(_status)
3494  );
3495 
3496  // Fake port number to make message dequeue work
3497  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3498  FW_ASSERT (
3499  _status == Fw::FW_SERIALIZE_OK,
3500  static_cast<FwAssertArgType>(_status)
3501  );
3502 
3503  _status = msg.serializeFrom(directive);
3504  FW_ASSERT(
3505  _status == Fw::FW_SERIALIZE_OK,
3506  static_cast<FwAssertArgType>(_status)
3507  );
3508 
3509  // Send message
3511  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3512 
3513  FW_ASSERT(
3514  qStatus == Os::Queue::OP_OK,
3515  static_cast<FwAssertArgType>(qStatus)
3516  );
3517  }
3518 
3521  {
3522  ComponentIpcSerializableBuffer msg;
3524 
3525  // Serialize the message ID
3526  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_STOREABS));
3527  FW_ASSERT (
3528  _status == Fw::FW_SERIALIZE_OK,
3529  static_cast<FwAssertArgType>(_status)
3530  );
3531 
3532  // Fake port number to make message dequeue work
3533  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3534  FW_ASSERT (
3535  _status == Fw::FW_SERIALIZE_OK,
3536  static_cast<FwAssertArgType>(_status)
3537  );
3538 
3539  _status = msg.serializeFrom(directive);
3540  FW_ASSERT(
3541  _status == Fw::FW_SERIALIZE_OK,
3542  static_cast<FwAssertArgType>(_status)
3543  );
3544 
3545  // Send message
3547  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3548 
3549  FW_ASSERT(
3550  qStatus == Os::Queue::OP_OK,
3551  static_cast<FwAssertArgType>(qStatus)
3552  );
3553  }
3554 
3557  {
3558  ComponentIpcSerializableBuffer msg;
3560 
3561  // Serialize the message ID
3562  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_STOREABSCONSTOFFSET));
3563  FW_ASSERT (
3564  _status == Fw::FW_SERIALIZE_OK,
3565  static_cast<FwAssertArgType>(_status)
3566  );
3567 
3568  // Fake port number to make message dequeue work
3569  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3570  FW_ASSERT (
3571  _status == Fw::FW_SERIALIZE_OK,
3572  static_cast<FwAssertArgType>(_status)
3573  );
3574 
3575  _status = msg.serializeFrom(directive);
3576  FW_ASSERT(
3577  _status == Fw::FW_SERIALIZE_OK,
3578  static_cast<FwAssertArgType>(_status)
3579  );
3580 
3581  // Send message
3583  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3584 
3585  FW_ASSERT(
3586  qStatus == Os::Queue::OP_OK,
3587  static_cast<FwAssertArgType>(qStatus)
3588  );
3589  }
3590 
3593  {
3594  ComponentIpcSerializableBuffer msg;
3596 
3597  // Serialize the message ID
3598  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_STOREREL));
3599  FW_ASSERT (
3600  _status == Fw::FW_SERIALIZE_OK,
3601  static_cast<FwAssertArgType>(_status)
3602  );
3603 
3604  // Fake port number to make message dequeue work
3605  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3606  FW_ASSERT (
3607  _status == Fw::FW_SERIALIZE_OK,
3608  static_cast<FwAssertArgType>(_status)
3609  );
3610 
3611  _status = msg.serializeFrom(directive);
3612  FW_ASSERT(
3613  _status == Fw::FW_SERIALIZE_OK,
3614  static_cast<FwAssertArgType>(_status)
3615  );
3616 
3617  // Send message
3619  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3620 
3621  FW_ASSERT(
3622  qStatus == Os::Queue::OP_OK,
3623  static_cast<FwAssertArgType>(qStatus)
3624  );
3625  }
3626 
3629  {
3630  ComponentIpcSerializableBuffer msg;
3632 
3633  // Serialize the message ID
3634  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_STORERELCONSTOFFSET));
3635  FW_ASSERT (
3636  _status == Fw::FW_SERIALIZE_OK,
3637  static_cast<FwAssertArgType>(_status)
3638  );
3639 
3640  // Fake port number to make message dequeue work
3641  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3642  FW_ASSERT (
3643  _status == Fw::FW_SERIALIZE_OK,
3644  static_cast<FwAssertArgType>(_status)
3645  );
3646 
3647  _status = msg.serializeFrom(directive);
3648  FW_ASSERT(
3649  _status == Fw::FW_SERIALIZE_OK,
3650  static_cast<FwAssertArgType>(_status)
3651  );
3652 
3653  // Send message
3655  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3656 
3657  FW_ASSERT(
3658  qStatus == Os::Queue::OP_OK,
3659  static_cast<FwAssertArgType>(qStatus)
3660  );
3661  }
3662 
3665  {
3666  ComponentIpcSerializableBuffer msg;
3668 
3669  // Serialize the message ID
3670  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_WAITABS));
3671  FW_ASSERT (
3672  _status == Fw::FW_SERIALIZE_OK,
3673  static_cast<FwAssertArgType>(_status)
3674  );
3675 
3676  // Fake port number to make message dequeue work
3677  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3678  FW_ASSERT (
3679  _status == Fw::FW_SERIALIZE_OK,
3680  static_cast<FwAssertArgType>(_status)
3681  );
3682 
3683  _status = msg.serializeFrom(directive);
3684  FW_ASSERT(
3685  _status == Fw::FW_SERIALIZE_OK,
3686  static_cast<FwAssertArgType>(_status)
3687  );
3688 
3689  // Send message
3691  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3692 
3693  FW_ASSERT(
3694  qStatus == Os::Queue::OP_OK,
3695  static_cast<FwAssertArgType>(qStatus)
3696  );
3697  }
3698 
3701  {
3702  ComponentIpcSerializableBuffer msg;
3704 
3705  // Serialize the message ID
3706  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(INT_IF_DIRECTIVE_WAITREL));
3707  FW_ASSERT (
3708  _status == Fw::FW_SERIALIZE_OK,
3709  static_cast<FwAssertArgType>(_status)
3710  );
3711 
3712  // Fake port number to make message dequeue work
3713  _status = msg.serializeFrom(static_cast<FwIndexType>(0));
3714  FW_ASSERT (
3715  _status == Fw::FW_SERIALIZE_OK,
3716  static_cast<FwAssertArgType>(_status)
3717  );
3718 
3719  _status = msg.serializeFrom(directive);
3720  FW_ASSERT(
3721  _status == Fw::FW_SERIALIZE_OK,
3722  static_cast<FwAssertArgType>(_status)
3723  );
3724 
3725  // Send message
3727  Os::Queue::Status qStatus = this->m_queue.send(msg, 6, _block);
3728 
3729  FW_ASSERT(
3730  qStatus == Os::Queue::OP_OK,
3731  static_cast<FwAssertArgType>(qStatus)
3732  );
3733  }
3734 
3735  // ----------------------------------------------------------------------
3736  // State getter functions
3737  // ----------------------------------------------------------------------
3738 
3741  {
3742  return this->m_stateMachine_sequencer.getState();
3743  }
3744 
3745  // ----------------------------------------------------------------------
3746  // Signal send functions
3747  // ----------------------------------------------------------------------
3748 
3751  {
3752  ComponentIpcSerializableBuffer buffer;
3753  // Serialize the message type, port number, state ID, and signal
3754  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_VALIDATE), buffer);
3755  // Serialize the signal data
3756  const Fw::SerializeStatus status = buffer.serializeFrom(value);
3757  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
3758  // Send the message and handle overflow
3759  this->sequencer_sendSignalFinish(buffer);
3760  }
3761 
3764  {
3765  ComponentIpcSerializableBuffer buffer;
3766  // Serialize the message type, port number, state ID, and signal
3767  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_RUN), buffer);
3768  // Serialize the signal data
3769  const Fw::SerializeStatus status = buffer.serializeFrom(value);
3770  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
3771  // Send the message and handle overflow
3772  this->sequencer_sendSignalFinish(buffer);
3773  }
3774 
3777  {
3778  ComponentIpcSerializableBuffer buffer;
3779  // Serialize the message type, port number, state ID, and signal
3780  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_RUN_VALIDATED), buffer);
3781  // Serialize the signal data
3782  const Fw::SerializeStatus status = buffer.serializeFrom(value);
3783  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
3784  // Send the message and handle overflow
3785  this->sequencer_sendSignalFinish(buffer);
3786  }
3787 
3790  {
3791  ComponentIpcSerializableBuffer buffer;
3792  // Serialize the message type, port number, state ID, and signal
3793  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_CANCEL), buffer);
3794  // Send the message and handle overflow
3795  this->sequencer_sendSignalFinish(buffer);
3796  }
3797 
3800  {
3801  ComponentIpcSerializableBuffer buffer;
3802  // Serialize the message type, port number, state ID, and signal
3803  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_SET_BREAKPOINT), buffer);
3804  // Serialize the signal data
3805  const Fw::SerializeStatus status = buffer.serializeFrom(value);
3806  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
3807  // Send the message and handle overflow
3808  this->sequencer_sendSignalFinish(buffer);
3809  }
3810 
3813  {
3814  ComponentIpcSerializableBuffer buffer;
3815  // Serialize the message type, port number, state ID, and signal
3816  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_CLEAR_BREAKPOINT), buffer);
3817  // Send the message and handle overflow
3818  this->sequencer_sendSignalFinish(buffer);
3819  }
3820 
3823  {
3824  ComponentIpcSerializableBuffer buffer;
3825  // Serialize the message type, port number, state ID, and signal
3826  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_failure), buffer);
3827  // Send the message and handle overflow
3828  this->sequencer_sendSignalFinish(buffer);
3829  }
3830 
3833  {
3834  ComponentIpcSerializableBuffer buffer;
3835  // Serialize the message type, port number, state ID, and signal
3836  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_success), buffer);
3837  // Send the message and handle overflow
3838  this->sequencer_sendSignalFinish(buffer);
3839  }
3840 
3843  {
3844  ComponentIpcSerializableBuffer buffer;
3845  // Serialize the message type, port number, state ID, and signal
3846  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::entered), buffer);
3847  // Send the message and handle overflow
3848  this->sequencer_sendSignalFinish(buffer);
3849  }
3850 
3853  {
3854  ComponentIpcSerializableBuffer buffer;
3855  // Serialize the message type, port number, state ID, and signal
3856  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_dispatchStatement_success), buffer);
3857  // Send the message and handle overflow
3858  this->sequencer_sendSignalFinish(buffer);
3859  }
3860 
3863  {
3864  ComponentIpcSerializableBuffer buffer;
3865  // Serialize the message type, port number, state ID, and signal
3866  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_dispatchStatement_failure), buffer);
3867  // Send the message and handle overflow
3868  this->sequencer_sendSignalFinish(buffer);
3869  }
3870 
3873  {
3874  ComponentIpcSerializableBuffer buffer;
3875  // Serialize the message type, port number, state ID, and signal
3876  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_dispatchStatement_noMoreStatements), buffer);
3877  // Send the message and handle overflow
3878  this->sequencer_sendSignalFinish(buffer);
3879  }
3880 
3883  {
3884  ComponentIpcSerializableBuffer buffer;
3885  // Serialize the message type, port number, state ID, and signal
3886  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::checkTimersIn), buffer);
3887  // Send the message and handle overflow
3888  this->sequencer_sendSignalFinish(buffer);
3889  }
3890 
3893  {
3894  ComponentIpcSerializableBuffer buffer;
3895  // Serialize the message type, port number, state ID, and signal
3896  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_checkShouldWake_wakeup), buffer);
3897  // Send the message and handle overflow
3898  this->sequencer_sendSignalFinish(buffer);
3899  }
3900 
3903  {
3904  ComponentIpcSerializableBuffer buffer;
3905  // Serialize the message type, port number, state ID, and signal
3906  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_checkShouldWake_keepSleeping), buffer);
3907  // Send the message and handle overflow
3908  this->sequencer_sendSignalFinish(buffer);
3909  }
3910 
3913  {
3914  ComponentIpcSerializableBuffer buffer;
3915  // Serialize the message type, port number, state ID, and signal
3916  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_timeOpFailed), buffer);
3917  // Send the message and handle overflow
3918  this->sequencer_sendSignalFinish(buffer);
3919  }
3920 
3923  {
3924  ComponentIpcSerializableBuffer buffer;
3925  // Serialize the message type, port number, state ID, and signal
3926  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::stmtResponse_beginSleep), buffer);
3927  // Send the message and handle overflow
3928  this->sequencer_sendSignalFinish(buffer);
3929  }
3930 
3933  {
3934  ComponentIpcSerializableBuffer buffer;
3935  // Serialize the message type, port number, state ID, and signal
3936  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::stmtResponse_success), buffer);
3937  // Send the message and handle overflow
3938  this->sequencer_sendSignalFinish(buffer);
3939  }
3940 
3943  {
3944  ComponentIpcSerializableBuffer buffer;
3945  // Serialize the message type, port number, state ID, and signal
3946  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::stmtResponse_failure), buffer);
3947  // Send the message and handle overflow
3948  this->sequencer_sendSignalFinish(buffer);
3949  }
3950 
3953  {
3954  ComponentIpcSerializableBuffer buffer;
3955  // Serialize the message type, port number, state ID, and signal
3956  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::stmtResponse_unexpected), buffer);
3957  // Send the message and handle overflow
3958  this->sequencer_sendSignalFinish(buffer);
3959  }
3960 
3963  {
3964  ComponentIpcSerializableBuffer buffer;
3965  // Serialize the message type, port number, state ID, and signal
3966  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::stmtResponse_keepWaiting), buffer);
3967  // Send the message and handle overflow
3968  this->sequencer_sendSignalFinish(buffer);
3969  }
3970 
3973  {
3974  ComponentIpcSerializableBuffer buffer;
3975  // Serialize the message type, port number, state ID, and signal
3976  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_checkStatementTimeout_statementTimeout), buffer);
3977  // Send the message and handle overflow
3978  this->sequencer_sendSignalFinish(buffer);
3979  }
3980 
3983  {
3984  ComponentIpcSerializableBuffer buffer;
3985  // Serialize the message type, port number, state ID, and signal
3986  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::result_checkStatementTimeout_noTimeout), buffer);
3987  // Send the message and handle overflow
3988  this->sequencer_sendSignalFinish(buffer);
3989  }
3990 
3993  {
3994  ComponentIpcSerializableBuffer buffer;
3995  // Serialize the message type, port number, state ID, and signal
3996  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_CONTINUE), buffer);
3997  // Send the message and handle overflow
3998  this->sequencer_sendSignalFinish(buffer);
3999  }
4000 
4003  {
4004  ComponentIpcSerializableBuffer buffer;
4005  // Serialize the message type, port number, state ID, and signal
4006  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_BREAK), buffer);
4007  // Send the message and handle overflow
4008  this->sequencer_sendSignalFinish(buffer);
4009  }
4010 
4013  {
4014  ComponentIpcSerializableBuffer buffer;
4015  // Serialize the message type, port number, state ID, and signal
4016  this->sendSignalStart(SmId::sequencer, static_cast<FwEnumStoreType>(Svc_FpySequencer_SequencerStateMachine::Signal::cmd_STEP), buffer);
4017  // Send the message and handle overflow
4018  this->sequencer_sendSignalFinish(buffer);
4019  }
4020 
4021  // ----------------------------------------------------------------------
4022  // Command response
4023  // ----------------------------------------------------------------------
4024 
4027  FwOpcodeType opCode,
4028  U32 cmdSeq,
4029  Fw::CmdResponse response
4030  )
4031  {
4033  this->cmdResponseOut_out(0, opCode, cmdSeq, response);
4034  }
4035 
4036  // ----------------------------------------------------------------------
4037  // Command handler base-class functions
4038  //
4039  // Call these functions directly to bypass the command input port
4040  // ----------------------------------------------------------------------
4041 
4044  FwOpcodeType opCode,
4045  U32 cmdSeq,
4046  Fw::CmdArgBuffer& args
4047  )
4048  {
4049  // Call pre-message hook
4050  this->RUN_preMsgHook(opCode,cmdSeq);
4051 
4052  // Defer deserializing arguments to the message dispatcher
4053  // to avoid deserializing and reserializing just for IPC
4054  ComponentIpcSerializableBuffer msg;
4056 
4057  // Serialize for IPC
4058  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_RUN));
4059  FW_ASSERT (
4060  _status == Fw::FW_SERIALIZE_OK,
4061  static_cast<FwAssertArgType>(_status)
4062  );
4063 
4064  // Fake port number to make message dequeue work
4065  FwIndexType port = 0;
4066 
4067  _status = msg.serializeFrom(port);
4068  FW_ASSERT (
4069  _status == Fw::FW_SERIALIZE_OK,
4070  static_cast<FwAssertArgType>(_status)
4071  );
4072 
4073  _status = msg.serializeFrom(opCode);
4074  FW_ASSERT (
4075  _status == Fw::FW_SERIALIZE_OK,
4076  static_cast<FwAssertArgType>(_status)
4077  );
4078 
4079  _status = msg.serializeFrom(cmdSeq);
4080  FW_ASSERT (
4081  _status == Fw::FW_SERIALIZE_OK,
4082  static_cast<FwAssertArgType>(_status)
4083  );
4084 
4085  _status = msg.serializeFrom(args);
4086  FW_ASSERT (
4087  _status == Fw::FW_SERIALIZE_OK,
4088  static_cast<FwAssertArgType>(_status)
4089  );
4090 
4091  // Send message
4093  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4094 
4095  FW_ASSERT(
4096  qStatus == Os::Queue::OP_OK,
4097  static_cast<FwAssertArgType>(qStatus)
4098  );
4099  }
4100 
4103  FwOpcodeType opCode,
4104  U32 cmdSeq,
4105  Fw::CmdArgBuffer& args
4106  )
4107  {
4108  // Call pre-message hook
4109  this->RUN_ARGS_preMsgHook(opCode,cmdSeq);
4110 
4111  // Defer deserializing arguments to the message dispatcher
4112  // to avoid deserializing and reserializing just for IPC
4113  ComponentIpcSerializableBuffer msg;
4115 
4116  // Serialize for IPC
4117  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_RUN_ARGS));
4118  FW_ASSERT (
4119  _status == Fw::FW_SERIALIZE_OK,
4120  static_cast<FwAssertArgType>(_status)
4121  );
4122 
4123  // Fake port number to make message dequeue work
4124  FwIndexType port = 0;
4125 
4126  _status = msg.serializeFrom(port);
4127  FW_ASSERT (
4128  _status == Fw::FW_SERIALIZE_OK,
4129  static_cast<FwAssertArgType>(_status)
4130  );
4131 
4132  _status = msg.serializeFrom(opCode);
4133  FW_ASSERT (
4134  _status == Fw::FW_SERIALIZE_OK,
4135  static_cast<FwAssertArgType>(_status)
4136  );
4137 
4138  _status = msg.serializeFrom(cmdSeq);
4139  FW_ASSERT (
4140  _status == Fw::FW_SERIALIZE_OK,
4141  static_cast<FwAssertArgType>(_status)
4142  );
4143 
4144  _status = msg.serializeFrom(args);
4145  FW_ASSERT (
4146  _status == Fw::FW_SERIALIZE_OK,
4147  static_cast<FwAssertArgType>(_status)
4148  );
4149 
4150  // Send message
4152  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4153 
4154  FW_ASSERT(
4155  qStatus == Os::Queue::OP_OK,
4156  static_cast<FwAssertArgType>(qStatus)
4157  );
4158  }
4159 
4162  FwOpcodeType opCode,
4163  U32 cmdSeq,
4164  Fw::CmdArgBuffer& args
4165  )
4166  {
4167  // Call pre-message hook
4168  this->VALIDATE_preMsgHook(opCode,cmdSeq);
4169 
4170  // Defer deserializing arguments to the message dispatcher
4171  // to avoid deserializing and reserializing just for IPC
4172  ComponentIpcSerializableBuffer msg;
4174 
4175  // Serialize for IPC
4176  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_VALIDATE));
4177  FW_ASSERT (
4178  _status == Fw::FW_SERIALIZE_OK,
4179  static_cast<FwAssertArgType>(_status)
4180  );
4181 
4182  // Fake port number to make message dequeue work
4183  FwIndexType port = 0;
4184 
4185  _status = msg.serializeFrom(port);
4186  FW_ASSERT (
4187  _status == Fw::FW_SERIALIZE_OK,
4188  static_cast<FwAssertArgType>(_status)
4189  );
4190 
4191  _status = msg.serializeFrom(opCode);
4192  FW_ASSERT (
4193  _status == Fw::FW_SERIALIZE_OK,
4194  static_cast<FwAssertArgType>(_status)
4195  );
4196 
4197  _status = msg.serializeFrom(cmdSeq);
4198  FW_ASSERT (
4199  _status == Fw::FW_SERIALIZE_OK,
4200  static_cast<FwAssertArgType>(_status)
4201  );
4202 
4203  _status = msg.serializeFrom(args);
4204  FW_ASSERT (
4205  _status == Fw::FW_SERIALIZE_OK,
4206  static_cast<FwAssertArgType>(_status)
4207  );
4208 
4209  // Send message
4211  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4212 
4213  FW_ASSERT(
4214  qStatus == Os::Queue::OP_OK,
4215  static_cast<FwAssertArgType>(qStatus)
4216  );
4217  }
4218 
4221  FwOpcodeType opCode,
4222  U32 cmdSeq,
4223  Fw::CmdArgBuffer& args
4224  )
4225  {
4226  // Call pre-message hook
4227  this->VALIDATE_ARGS_preMsgHook(opCode,cmdSeq);
4228 
4229  // Defer deserializing arguments to the message dispatcher
4230  // to avoid deserializing and reserializing just for IPC
4231  ComponentIpcSerializableBuffer msg;
4233 
4234  // Serialize for IPC
4235  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_VALIDATE_ARGS));
4236  FW_ASSERT (
4237  _status == Fw::FW_SERIALIZE_OK,
4238  static_cast<FwAssertArgType>(_status)
4239  );
4240 
4241  // Fake port number to make message dequeue work
4242  FwIndexType port = 0;
4243 
4244  _status = msg.serializeFrom(port);
4245  FW_ASSERT (
4246  _status == Fw::FW_SERIALIZE_OK,
4247  static_cast<FwAssertArgType>(_status)
4248  );
4249 
4250  _status = msg.serializeFrom(opCode);
4251  FW_ASSERT (
4252  _status == Fw::FW_SERIALIZE_OK,
4253  static_cast<FwAssertArgType>(_status)
4254  );
4255 
4256  _status = msg.serializeFrom(cmdSeq);
4257  FW_ASSERT (
4258  _status == Fw::FW_SERIALIZE_OK,
4259  static_cast<FwAssertArgType>(_status)
4260  );
4261 
4262  _status = msg.serializeFrom(args);
4263  FW_ASSERT (
4264  _status == Fw::FW_SERIALIZE_OK,
4265  static_cast<FwAssertArgType>(_status)
4266  );
4267 
4268  // Send message
4270  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4271 
4272  FW_ASSERT(
4273  qStatus == Os::Queue::OP_OK,
4274  static_cast<FwAssertArgType>(qStatus)
4275  );
4276  }
4277 
4280  FwOpcodeType opCode,
4281  U32 cmdSeq,
4282  Fw::CmdArgBuffer& args
4283  )
4284  {
4285  // Call pre-message hook
4286  this->RUN_VALIDATED_preMsgHook(opCode,cmdSeq);
4287 
4288  // Defer deserializing arguments to the message dispatcher
4289  // to avoid deserializing and reserializing just for IPC
4290  ComponentIpcSerializableBuffer msg;
4292 
4293  // Serialize for IPC
4294  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_RUN_VALIDATED));
4295  FW_ASSERT (
4296  _status == Fw::FW_SERIALIZE_OK,
4297  static_cast<FwAssertArgType>(_status)
4298  );
4299 
4300  // Fake port number to make message dequeue work
4301  FwIndexType port = 0;
4302 
4303  _status = msg.serializeFrom(port);
4304  FW_ASSERT (
4305  _status == Fw::FW_SERIALIZE_OK,
4306  static_cast<FwAssertArgType>(_status)
4307  );
4308 
4309  _status = msg.serializeFrom(opCode);
4310  FW_ASSERT (
4311  _status == Fw::FW_SERIALIZE_OK,
4312  static_cast<FwAssertArgType>(_status)
4313  );
4314 
4315  _status = msg.serializeFrom(cmdSeq);
4316  FW_ASSERT (
4317  _status == Fw::FW_SERIALIZE_OK,
4318  static_cast<FwAssertArgType>(_status)
4319  );
4320 
4321  _status = msg.serializeFrom(args);
4322  FW_ASSERT (
4323  _status == Fw::FW_SERIALIZE_OK,
4324  static_cast<FwAssertArgType>(_status)
4325  );
4326 
4327  // Send message
4329  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4330 
4331  FW_ASSERT(
4332  qStatus == Os::Queue::OP_OK,
4333  static_cast<FwAssertArgType>(qStatus)
4334  );
4335  }
4336 
4339  FwOpcodeType opCode,
4340  U32 cmdSeq,
4341  Fw::CmdArgBuffer& args
4342  )
4343  {
4344  // Call pre-message hook
4345  this->CANCEL_preMsgHook(opCode,cmdSeq);
4346 
4347  // Defer deserializing arguments to the message dispatcher
4348  // to avoid deserializing and reserializing just for IPC
4349  ComponentIpcSerializableBuffer msg;
4351 
4352  // Serialize for IPC
4353  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_CANCEL));
4354  FW_ASSERT (
4355  _status == Fw::FW_SERIALIZE_OK,
4356  static_cast<FwAssertArgType>(_status)
4357  );
4358 
4359  // Fake port number to make message dequeue work
4360  FwIndexType port = 0;
4361 
4362  _status = msg.serializeFrom(port);
4363  FW_ASSERT (
4364  _status == Fw::FW_SERIALIZE_OK,
4365  static_cast<FwAssertArgType>(_status)
4366  );
4367 
4368  _status = msg.serializeFrom(opCode);
4369  FW_ASSERT (
4370  _status == Fw::FW_SERIALIZE_OK,
4371  static_cast<FwAssertArgType>(_status)
4372  );
4373 
4374  _status = msg.serializeFrom(cmdSeq);
4375  FW_ASSERT (
4376  _status == Fw::FW_SERIALIZE_OK,
4377  static_cast<FwAssertArgType>(_status)
4378  );
4379 
4380  _status = msg.serializeFrom(args);
4381  FW_ASSERT (
4382  _status == Fw::FW_SERIALIZE_OK,
4383  static_cast<FwAssertArgType>(_status)
4384  );
4385 
4386  // Send message
4388  Os::Queue::Status qStatus = this->m_queue.send(msg, 8, _block);
4389 
4390  FW_ASSERT(
4391  qStatus == Os::Queue::OP_OK,
4392  static_cast<FwAssertArgType>(qStatus)
4393  );
4394  }
4395 
4398  FwOpcodeType opCode,
4399  U32 cmdSeq,
4400  Fw::CmdArgBuffer& args
4401  )
4402  {
4403  // Call pre-message hook
4404  this->SET_BREAKPOINT_preMsgHook(opCode,cmdSeq);
4405 
4406  // Defer deserializing arguments to the message dispatcher
4407  // to avoid deserializing and reserializing just for IPC
4408  ComponentIpcSerializableBuffer msg;
4410 
4411  // Serialize for IPC
4412  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_SET_BREAKPOINT));
4413  FW_ASSERT (
4414  _status == Fw::FW_SERIALIZE_OK,
4415  static_cast<FwAssertArgType>(_status)
4416  );
4417 
4418  // Fake port number to make message dequeue work
4419  FwIndexType port = 0;
4420 
4421  _status = msg.serializeFrom(port);
4422  FW_ASSERT (
4423  _status == Fw::FW_SERIALIZE_OK,
4424  static_cast<FwAssertArgType>(_status)
4425  );
4426 
4427  _status = msg.serializeFrom(opCode);
4428  FW_ASSERT (
4429  _status == Fw::FW_SERIALIZE_OK,
4430  static_cast<FwAssertArgType>(_status)
4431  );
4432 
4433  _status = msg.serializeFrom(cmdSeq);
4434  FW_ASSERT (
4435  _status == Fw::FW_SERIALIZE_OK,
4436  static_cast<FwAssertArgType>(_status)
4437  );
4438 
4439  _status = msg.serializeFrom(args);
4440  FW_ASSERT (
4441  _status == Fw::FW_SERIALIZE_OK,
4442  static_cast<FwAssertArgType>(_status)
4443  );
4444 
4445  // Send message
4447  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4448 
4449  FW_ASSERT(
4450  qStatus == Os::Queue::OP_OK,
4451  static_cast<FwAssertArgType>(qStatus)
4452  );
4453  }
4454 
4457  FwOpcodeType opCode,
4458  U32 cmdSeq,
4459  Fw::CmdArgBuffer& args
4460  )
4461  {
4462  // Call pre-message hook
4463  this->BREAK_preMsgHook(opCode,cmdSeq);
4464 
4465  // Defer deserializing arguments to the message dispatcher
4466  // to avoid deserializing and reserializing just for IPC
4467  ComponentIpcSerializableBuffer msg;
4469 
4470  // Serialize for IPC
4471  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_BREAK));
4472  FW_ASSERT (
4473  _status == Fw::FW_SERIALIZE_OK,
4474  static_cast<FwAssertArgType>(_status)
4475  );
4476 
4477  // Fake port number to make message dequeue work
4478  FwIndexType port = 0;
4479 
4480  _status = msg.serializeFrom(port);
4481  FW_ASSERT (
4482  _status == Fw::FW_SERIALIZE_OK,
4483  static_cast<FwAssertArgType>(_status)
4484  );
4485 
4486  _status = msg.serializeFrom(opCode);
4487  FW_ASSERT (
4488  _status == Fw::FW_SERIALIZE_OK,
4489  static_cast<FwAssertArgType>(_status)
4490  );
4491 
4492  _status = msg.serializeFrom(cmdSeq);
4493  FW_ASSERT (
4494  _status == Fw::FW_SERIALIZE_OK,
4495  static_cast<FwAssertArgType>(_status)
4496  );
4497 
4498  _status = msg.serializeFrom(args);
4499  FW_ASSERT (
4500  _status == Fw::FW_SERIALIZE_OK,
4501  static_cast<FwAssertArgType>(_status)
4502  );
4503 
4504  // Send message
4506  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4507 
4508  FW_ASSERT(
4509  qStatus == Os::Queue::OP_OK,
4510  static_cast<FwAssertArgType>(qStatus)
4511  );
4512  }
4513 
4516  FwOpcodeType opCode,
4517  U32 cmdSeq,
4518  Fw::CmdArgBuffer& args
4519  )
4520  {
4521  // Call pre-message hook
4522  this->CONTINUE_preMsgHook(opCode,cmdSeq);
4523 
4524  // Defer deserializing arguments to the message dispatcher
4525  // to avoid deserializing and reserializing just for IPC
4526  ComponentIpcSerializableBuffer msg;
4528 
4529  // Serialize for IPC
4530  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_CONTINUE));
4531  FW_ASSERT (
4532  _status == Fw::FW_SERIALIZE_OK,
4533  static_cast<FwAssertArgType>(_status)
4534  );
4535 
4536  // Fake port number to make message dequeue work
4537  FwIndexType port = 0;
4538 
4539  _status = msg.serializeFrom(port);
4540  FW_ASSERT (
4541  _status == Fw::FW_SERIALIZE_OK,
4542  static_cast<FwAssertArgType>(_status)
4543  );
4544 
4545  _status = msg.serializeFrom(opCode);
4546  FW_ASSERT (
4547  _status == Fw::FW_SERIALIZE_OK,
4548  static_cast<FwAssertArgType>(_status)
4549  );
4550 
4551  _status = msg.serializeFrom(cmdSeq);
4552  FW_ASSERT (
4553  _status == Fw::FW_SERIALIZE_OK,
4554  static_cast<FwAssertArgType>(_status)
4555  );
4556 
4557  _status = msg.serializeFrom(args);
4558  FW_ASSERT (
4559  _status == Fw::FW_SERIALIZE_OK,
4560  static_cast<FwAssertArgType>(_status)
4561  );
4562 
4563  // Send message
4565  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4566 
4567  FW_ASSERT(
4568  qStatus == Os::Queue::OP_OK,
4569  static_cast<FwAssertArgType>(qStatus)
4570  );
4571  }
4572 
4575  FwOpcodeType opCode,
4576  U32 cmdSeq,
4577  Fw::CmdArgBuffer& args
4578  )
4579  {
4580  // Call pre-message hook
4581  this->CLEAR_BREAKPOINT_preMsgHook(opCode,cmdSeq);
4582 
4583  // Defer deserializing arguments to the message dispatcher
4584  // to avoid deserializing and reserializing just for IPC
4585  ComponentIpcSerializableBuffer msg;
4587 
4588  // Serialize for IPC
4589  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_CLEAR_BREAKPOINT));
4590  FW_ASSERT (
4591  _status == Fw::FW_SERIALIZE_OK,
4592  static_cast<FwAssertArgType>(_status)
4593  );
4594 
4595  // Fake port number to make message dequeue work
4596  FwIndexType port = 0;
4597 
4598  _status = msg.serializeFrom(port);
4599  FW_ASSERT (
4600  _status == Fw::FW_SERIALIZE_OK,
4601  static_cast<FwAssertArgType>(_status)
4602  );
4603 
4604  _status = msg.serializeFrom(opCode);
4605  FW_ASSERT (
4606  _status == Fw::FW_SERIALIZE_OK,
4607  static_cast<FwAssertArgType>(_status)
4608  );
4609 
4610  _status = msg.serializeFrom(cmdSeq);
4611  FW_ASSERT (
4612  _status == Fw::FW_SERIALIZE_OK,
4613  static_cast<FwAssertArgType>(_status)
4614  );
4615 
4616  _status = msg.serializeFrom(args);
4617  FW_ASSERT (
4618  _status == Fw::FW_SERIALIZE_OK,
4619  static_cast<FwAssertArgType>(_status)
4620  );
4621 
4622  // Send message
4624  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4625 
4626  FW_ASSERT(
4627  qStatus == Os::Queue::OP_OK,
4628  static_cast<FwAssertArgType>(qStatus)
4629  );
4630  }
4631 
4634  FwOpcodeType opCode,
4635  U32 cmdSeq,
4636  Fw::CmdArgBuffer& args
4637  )
4638  {
4639  // Call pre-message hook
4640  this->STEP_preMsgHook(opCode,cmdSeq);
4641 
4642  // Defer deserializing arguments to the message dispatcher
4643  // to avoid deserializing and reserializing just for IPC
4644  ComponentIpcSerializableBuffer msg;
4646 
4647  // Serialize for IPC
4648  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_STEP));
4649  FW_ASSERT (
4650  _status == Fw::FW_SERIALIZE_OK,
4651  static_cast<FwAssertArgType>(_status)
4652  );
4653 
4654  // Fake port number to make message dequeue work
4655  FwIndexType port = 0;
4656 
4657  _status = msg.serializeFrom(port);
4658  FW_ASSERT (
4659  _status == Fw::FW_SERIALIZE_OK,
4660  static_cast<FwAssertArgType>(_status)
4661  );
4662 
4663  _status = msg.serializeFrom(opCode);
4664  FW_ASSERT (
4665  _status == Fw::FW_SERIALIZE_OK,
4666  static_cast<FwAssertArgType>(_status)
4667  );
4668 
4669  _status = msg.serializeFrom(cmdSeq);
4670  FW_ASSERT (
4671  _status == Fw::FW_SERIALIZE_OK,
4672  static_cast<FwAssertArgType>(_status)
4673  );
4674 
4675  _status = msg.serializeFrom(args);
4676  FW_ASSERT (
4677  _status == Fw::FW_SERIALIZE_OK,
4678  static_cast<FwAssertArgType>(_status)
4679  );
4680 
4681  // Send message
4683  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4684 
4685  FW_ASSERT(
4686  qStatus == Os::Queue::OP_OK,
4687  static_cast<FwAssertArgType>(qStatus)
4688  );
4689  }
4690 
4693  FwOpcodeType opCode,
4694  U32 cmdSeq,
4695  Fw::CmdArgBuffer& args
4696  )
4697  {
4698  // Call pre-message hook
4699  this->DUMP_STACK_TO_FILE_preMsgHook(opCode,cmdSeq);
4700 
4701  // Defer deserializing arguments to the message dispatcher
4702  // to avoid deserializing and reserializing just for IPC
4703  ComponentIpcSerializableBuffer msg;
4705 
4706  // Serialize for IPC
4707  _status = msg.serializeFrom(static_cast<FwEnumStoreType>(CMD_DUMP_STACK_TO_FILE));
4708  FW_ASSERT (
4709  _status == Fw::FW_SERIALIZE_OK,
4710  static_cast<FwAssertArgType>(_status)
4711  );
4712 
4713  // Fake port number to make message dequeue work
4714  FwIndexType port = 0;
4715 
4716  _status = msg.serializeFrom(port);
4717  FW_ASSERT (
4718  _status == Fw::FW_SERIALIZE_OK,
4719  static_cast<FwAssertArgType>(_status)
4720  );
4721 
4722  _status = msg.serializeFrom(opCode);
4723  FW_ASSERT (
4724  _status == Fw::FW_SERIALIZE_OK,
4725  static_cast<FwAssertArgType>(_status)
4726  );
4727 
4728  _status = msg.serializeFrom(cmdSeq);
4729  FW_ASSERT (
4730  _status == Fw::FW_SERIALIZE_OK,
4731  static_cast<FwAssertArgType>(_status)
4732  );
4733 
4734  _status = msg.serializeFrom(args);
4735  FW_ASSERT (
4736  _status == Fw::FW_SERIALIZE_OK,
4737  static_cast<FwAssertArgType>(_status)
4738  );
4739 
4740  // Send message
4742  Os::Queue::Status qStatus = this->m_queue.send(msg, 7, _block);
4743 
4744  FW_ASSERT(
4745  qStatus == Os::Queue::OP_OK,
4746  static_cast<FwAssertArgType>(qStatus)
4747  );
4748  }
4749 
4750  // ----------------------------------------------------------------------
4751  // Pre-message hooks for async commands
4752  //
4753  // Each of these functions is invoked just before processing the
4754  // corresponding command. By default they do nothing. You can
4755  // override them to provide specific pre-command behavior.
4756  // ----------------------------------------------------------------------
4757 
4760  FwOpcodeType opCode,
4761  U32 cmdSeq
4762  )
4763  {
4764  // Defaults to no-op; can be overridden
4765  (void) opCode;
4766  (void) cmdSeq;
4767  }
4768 
4771  FwOpcodeType opCode,
4772  U32 cmdSeq
4773  )
4774  {
4775  // Defaults to no-op; can be overridden
4776  (void) opCode;
4777  (void) cmdSeq;
4778  }
4779 
4782  FwOpcodeType opCode,
4783  U32 cmdSeq
4784  )
4785  {
4786  // Defaults to no-op; can be overridden
4787  (void) opCode;
4788  (void) cmdSeq;
4789  }
4790 
4793  FwOpcodeType opCode,
4794  U32 cmdSeq
4795  )
4796  {
4797  // Defaults to no-op; can be overridden
4798  (void) opCode;
4799  (void) cmdSeq;
4800  }
4801 
4804  FwOpcodeType opCode,
4805  U32 cmdSeq
4806  )
4807  {
4808  // Defaults to no-op; can be overridden
4809  (void) opCode;
4810  (void) cmdSeq;
4811  }
4812 
4815  FwOpcodeType opCode,
4816  U32 cmdSeq
4817  )
4818  {
4819  // Defaults to no-op; can be overridden
4820  (void) opCode;
4821  (void) cmdSeq;
4822  }
4823 
4826  FwOpcodeType opCode,
4827  U32 cmdSeq
4828  )
4829  {
4830  // Defaults to no-op; can be overridden
4831  (void) opCode;
4832  (void) cmdSeq;
4833  }
4834 
4837  FwOpcodeType opCode,
4838  U32 cmdSeq
4839  )
4840  {
4841  // Defaults to no-op; can be overridden
4842  (void) opCode;
4843  (void) cmdSeq;
4844  }
4845 
4848  FwOpcodeType opCode,
4849  U32 cmdSeq
4850  )
4851  {
4852  // Defaults to no-op; can be overridden
4853  (void) opCode;
4854  (void) cmdSeq;
4855  }
4856 
4859  FwOpcodeType opCode,
4860  U32 cmdSeq
4861  )
4862  {
4863  // Defaults to no-op; can be overridden
4864  (void) opCode;
4865  (void) cmdSeq;
4866  }
4867 
4870  FwOpcodeType opCode,
4871  U32 cmdSeq
4872  )
4873  {
4874  // Defaults to no-op; can be overridden
4875  (void) opCode;
4876  (void) cmdSeq;
4877  }
4878 
4881  FwOpcodeType opCode,
4882  U32 cmdSeq
4883  )
4884  {
4885  // Defaults to no-op; can be overridden
4886  (void) opCode;
4887  (void) cmdSeq;
4888  }
4889 
4890  // ----------------------------------------------------------------------
4891  // Event logging functions
4892  // ----------------------------------------------------------------------
4893 
4896  {
4897  // Get the time
4898  Fw::Time _logTime;
4899  if (this->isConnected_timeCaller_OutputPort(0)) {
4900  this->timeCaller_out(0, _logTime);
4901  }
4902 
4903  const FwEventIdType _id = this->getIdBase() + EVENTID_INVALIDCOMMAND;
4904 
4905  // Emit the event on the log port
4906  if (this->isConnected_logOut_OutputPort(0)) {
4907  Fw::LogBuffer _logBuff;
4909 
4910 #if FW_AMPCS_COMPATIBLE
4911  // Serialize the number of arguments
4912  _status = _logBuff.serializeFrom(static_cast<U8>(1));
4913  FW_ASSERT(
4914  _status == Fw::FW_SERIALIZE_OK,
4915  static_cast<FwAssertArgType>(_status)
4916  );
4917 #endif
4918 
4919 #if FW_AMPCS_COMPATIBLE
4920  // Serialize the argument size
4921  _status = _logBuff.serializeFrom(
4922  static_cast<U8>(sizeof(I32))
4923  );
4924  FW_ASSERT(
4925  _status == Fw::FW_SERIALIZE_OK,
4926  static_cast<FwAssertArgType>(_status)
4927  );
4928 #endif
4929  _status = _logBuff.serializeFrom(state);
4930  FW_ASSERT(
4931  _status == Fw::FW_SERIALIZE_OK,
4932  static_cast<FwAssertArgType>(_status)
4933  );
4934 
4935  this->logOut_out(
4936  0,
4937  _id,
4938  _logTime,
4940  _logBuff
4941  );
4942  }
4943 
4944  // Emit the event on the text log port
4945 #if FW_ENABLE_TEXT_LOGGING
4946  if (this->isConnected_logTextOut_OutputPort(0)) {
4947 #if FW_OBJECT_NAMES == 1
4948  const char* _formatString =
4949  "(%s) %s: Cannot execute command in state %" PRIi32 "";
4950 #else
4951  const char* _formatString =
4952  "%s: Cannot execute command in state %" PRIi32 "";
4953 #endif
4954 
4955  Fw::TextLogString _logString;
4956  (void) _logString.format(
4957  _formatString,
4958 #if FW_OBJECT_NAMES == 1
4959  this->m_objName.toChar(),
4960 #endif
4961  "InvalidCommand ",
4962  state
4963  );
4964 
4965  this->logTextOut_out(
4966  0,
4967  _id,
4968  _logTime,
4970  _logString
4971  );
4972  }
4973 #endif
4974  }
4975 
4978  {
4979  // Get the time
4980  Fw::Time _logTime;
4981  if (this->isConnected_timeCaller_OutputPort(0)) {
4982  this->timeCaller_out(0, _logTime);
4983  }
4984 
4985  const FwEventIdType _id = this->getIdBase() + EVENTID_INVALIDSEQRUNCALL;
4986 
4987  // Emit the event on the log port
4988  if (this->isConnected_logOut_OutputPort(0)) {
4989  Fw::LogBuffer _logBuff;
4991 
4992 #if FW_AMPCS_COMPATIBLE
4993  // Serialize the number of arguments
4994  _status = _logBuff.serializeFrom(static_cast<U8>(1));
4995  FW_ASSERT(
4996  _status == Fw::FW_SERIALIZE_OK,
4997  static_cast<FwAssertArgType>(_status)
4998  );
4999 #endif
5000 
5001 #if FW_AMPCS_COMPATIBLE
5002  // Serialize the argument size
5003  _status = _logBuff.serializeFrom(
5004  static_cast<U8>(sizeof(I32))
5005  );
5006  FW_ASSERT(
5007  _status == Fw::FW_SERIALIZE_OK,
5008  static_cast<FwAssertArgType>(_status)
5009  );
5010 #endif
5011  _status = _logBuff.serializeFrom(state);
5012  FW_ASSERT(
5013  _status == Fw::FW_SERIALIZE_OK,
5014  static_cast<FwAssertArgType>(_status)
5015  );
5016 
5017  this->logOut_out(
5018  0,
5019  _id,
5020  _logTime,
5022  _logBuff
5023  );
5024  }
5025 
5026  // Emit the event on the text log port
5027 #if FW_ENABLE_TEXT_LOGGING
5028  if (this->isConnected_logTextOut_OutputPort(0)) {
5029 #if FW_OBJECT_NAMES == 1
5030  const char* _formatString =
5031  "(%s) %s: Cannot run sequence from a port in state %" PRIi32 "";
5032 #else
5033  const char* _formatString =
5034  "%s: Cannot run sequence from a port in state %" PRIi32 "";
5035 #endif
5036 
5037  Fw::TextLogString _logString;
5038  (void) _logString.format(
5039  _formatString,
5040 #if FW_OBJECT_NAMES == 1
5041  this->m_objName.toChar(),
5042 #endif
5043  "InvalidSeqRunCall ",
5044  state
5045  );
5046 
5047  this->logTextOut_out(
5048  0,
5049  _id,
5050  _logTime,
5052  _logString
5053  );
5054  }
5055 #endif
5056  }
5057 
5060  {
5061  // Get the time
5062  Fw::Time _logTime;
5063  if (this->isConnected_timeCaller_OutputPort(0)) {
5064  this->timeCaller_out(0, _logTime);
5065  }
5066 
5068 
5069  // Emit the event on the log port
5070  if (this->isConnected_logOut_OutputPort(0)) {
5071  Fw::LogBuffer _logBuff;
5073 
5074 #if FW_AMPCS_COMPATIBLE
5075  // Serialize the number of arguments
5076  _status = _logBuff.serializeFrom(static_cast<U8>(1));
5077  FW_ASSERT(
5078  _status == Fw::FW_SERIALIZE_OK,
5079  static_cast<FwAssertArgType>(_status)
5080  );
5081 #endif
5082 
5083 #if FW_AMPCS_COMPATIBLE
5084  // Serialize the argument size
5085  _status = _logBuff.serializeFrom(
5086  static_cast<U8>(sizeof(I32))
5087  );
5088  FW_ASSERT(
5089  _status == Fw::FW_SERIALIZE_OK,
5090  static_cast<FwAssertArgType>(_status)
5091  );
5092 #endif
5093  _status = _logBuff.serializeFrom(state);
5094  FW_ASSERT(
5095  _status == Fw::FW_SERIALIZE_OK,
5096  static_cast<FwAssertArgType>(_status)
5097  );
5098 
5099  this->logOut_out(
5100  0,
5101  _id,
5102  _logTime,
5104  _logBuff
5105  );
5106  }
5107 
5108  // Emit the event on the text log port
5109 #if FW_ENABLE_TEXT_LOGGING
5110  if (this->isConnected_logTextOut_OutputPort(0)) {
5111 #if FW_OBJECT_NAMES == 1
5112  const char* _formatString =
5113  "(%s) %s: Cannot cancel sequence from a port in state %" PRIi32 "";
5114 #else
5115  const char* _formatString =
5116  "%s: Cannot cancel sequence from a port in state %" PRIi32 "";
5117 #endif
5118 
5119  Fw::TextLogString _logString;
5120  (void) _logString.format(
5121  _formatString,
5122 #if FW_OBJECT_NAMES == 1
5123  this->m_objName.toChar(),
5124 #endif
5125  "InvalidSeqCancelCall ",
5126  state
5127  );
5128 
5129  this->logTextOut_out(
5130  0,
5131  _id,
5132  _logTime,
5134  _logString
5135  );
5136  }
5137 #endif
5138  }
5139 
5142  const Fw::StringBase& filePath,
5143  I32 errorCode
5144  ) const
5145  {
5146  // Get the time
5147  Fw::Time _logTime;
5148  if (this->isConnected_timeCaller_OutputPort(0)) {
5149  this->timeCaller_out(0, _logTime);
5150  }
5151 
5152  const FwEventIdType _id = this->getIdBase() + EVENTID_FILEOPENERROR;
5153 
5154  // Emit the event on the log port
5155  if (this->isConnected_logOut_OutputPort(0)) {
5156  Fw::LogBuffer _logBuff;
5158 
5159 #if FW_AMPCS_COMPATIBLE
5160  // Serialize the number of arguments
5161  _status = _logBuff.serializeFrom(static_cast<U8>(2));
5162  FW_ASSERT(
5163  _status == Fw::FW_SERIALIZE_OK,
5164  static_cast<FwAssertArgType>(_status)
5165  );
5166 #endif
5167 
5168  _status = filePath.serializeTo(
5169  _logBuff,
5170  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
5171  );
5172  FW_ASSERT(
5173  _status == Fw::FW_SERIALIZE_OK,
5174  static_cast<FwAssertArgType>(_status)
5175  );
5176 
5177 #if FW_AMPCS_COMPATIBLE
5178  // Serialize the argument size
5179  _status = _logBuff.serializeFrom(
5180  static_cast<U8>(sizeof(I32))
5181  );
5182  FW_ASSERT(
5183  _status == Fw::FW_SERIALIZE_OK,
5184  static_cast<FwAssertArgType>(_status)
5185  );
5186 #endif
5187  _status = _logBuff.serializeFrom(errorCode);
5188  FW_ASSERT(
5189  _status == Fw::FW_SERIALIZE_OK,
5190  static_cast<FwAssertArgType>(_status)
5191  );
5192 
5193  this->logOut_out(
5194  0,
5195  _id,
5196  _logTime,
5198  _logBuff
5199  );
5200  }
5201 
5202  // Emit the event on the text log port
5203 #if FW_ENABLE_TEXT_LOGGING
5204  if (this->isConnected_logTextOut_OutputPort(0)) {
5205 #if FW_OBJECT_NAMES == 1
5206  const char* _formatString =
5207  "(%s) %s: File open error encountered while opening %s: %" PRIi32 "";
5208 #else
5209  const char* _formatString =
5210  "%s: File open error encountered while opening %s: %" PRIi32 "";
5211 #endif
5212 
5213  Fw::TextLogString _logString;
5214  (void) _logString.format(
5215  _formatString,
5216 #if FW_OBJECT_NAMES == 1
5217  this->m_objName.toChar(),
5218 #endif
5219  "FileOpenError ",
5220  filePath.toChar(),
5221  errorCode
5222  );
5223 
5224  this->logTextOut_out(
5225  0,
5226  _id,
5227  _logTime,
5229  _logString
5230  );
5231  }
5232 #endif
5233  }
5234 
5237  FwSizeType writeSize,
5238  const Fw::StringBase& filePath,
5239  I32 errorCode
5240  ) const
5241  {
5242  // Get the time
5243  Fw::Time _logTime;
5244  if (this->isConnected_timeCaller_OutputPort(0)) {
5245  this->timeCaller_out(0, _logTime);
5246  }
5247 
5248  const FwEventIdType _id = this->getIdBase() + EVENTID_FILEWRITEERROR;
5249 
5250  // Emit the event on the log port
5251  if (this->isConnected_logOut_OutputPort(0)) {
5252  Fw::LogBuffer _logBuff;
5254 
5255 #if FW_AMPCS_COMPATIBLE
5256  // Serialize the number of arguments
5257  _status = _logBuff.serializeFrom(static_cast<U8>(3));
5258  FW_ASSERT(
5259  _status == Fw::FW_SERIALIZE_OK,
5260  static_cast<FwAssertArgType>(_status)
5261  );
5262 #endif
5263 
5264 #if FW_AMPCS_COMPATIBLE
5265  // Serialize the argument size
5266  _status = _logBuff.serializeFrom(
5267  static_cast<U8>(sizeof(FwSizeType))
5268  );
5269  FW_ASSERT(
5270  _status == Fw::FW_SERIALIZE_OK,
5271  static_cast<FwAssertArgType>(_status)
5272  );
5273 #endif
5274  _status = _logBuff.serializeFrom(writeSize);
5275  FW_ASSERT(
5276  _status == Fw::FW_SERIALIZE_OK,
5277  static_cast<FwAssertArgType>(_status)
5278  );
5279 
5280  _status = filePath.serializeTo(
5281  _logBuff,
5282  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
5283  );
5284  FW_ASSERT(
5285  _status == Fw::FW_SERIALIZE_OK,
5286  static_cast<FwAssertArgType>(_status)
5287  );
5288 
5289 #if FW_AMPCS_COMPATIBLE
5290  // Serialize the argument size
5291  _status = _logBuff.serializeFrom(
5292  static_cast<U8>(sizeof(I32))
5293  );
5294  FW_ASSERT(
5295  _status == Fw::FW_SERIALIZE_OK,
5296  static_cast<FwAssertArgType>(_status)
5297  );
5298 #endif
5299  _status = _logBuff.serializeFrom(errorCode);
5300  FW_ASSERT(
5301  _status == Fw::FW_SERIALIZE_OK,
5302  static_cast<FwAssertArgType>(_status)
5303  );
5304 
5305  this->logOut_out(
5306  0,
5307  _id,
5308  _logTime,
5310  _logBuff
5311  );
5312  }
5313 
5314  // Emit the event on the text log port
5315 #if FW_ENABLE_TEXT_LOGGING
5316  if (this->isConnected_logTextOut_OutputPort(0)) {
5317 #if FW_OBJECT_NAMES == 1
5318  const char* _formatString =
5319  "(%s) %s: File write error encountered while writing %" PRIu64 " bytes to %s: %" PRIi32 "";
5320 #else
5321  const char* _formatString =
5322  "%s: File write error encountered while writing %" PRIu64 " bytes to %s: %" PRIi32 "";
5323 #endif
5324 
5325  Fw::TextLogString _logString;
5326  (void) _logString.format(
5327  _formatString,
5328 #if FW_OBJECT_NAMES == 1
5329  this->m_objName.toChar(),
5330 #endif
5331  "FileWriteError ",
5332  writeSize,
5333  filePath.toChar(),
5334  errorCode
5335  );
5336 
5337  this->logTextOut_out(
5338  0,
5339  _id,
5340  _logTime,
5342  _logString
5343  );
5344  }
5345 #endif
5346  }
5347 
5350  const Svc::FpySequencer_FileReadStage& readStage,
5351  const Fw::StringBase& filePath,
5352  I32 errorCode
5353  ) const
5354  {
5355  // Get the time
5356  Fw::Time _logTime;
5357  if (this->isConnected_timeCaller_OutputPort(0)) {
5358  this->timeCaller_out(0, _logTime);
5359  }
5360 
5361  const FwEventIdType _id = this->getIdBase() + EVENTID_FILEREADERROR;
5362 
5363  // Emit the event on the log port
5364  if (this->isConnected_logOut_OutputPort(0)) {
5365  Fw::LogBuffer _logBuff;
5367 
5368 #if FW_AMPCS_COMPATIBLE
5369  // Serialize the number of arguments
5370  _status = _logBuff.serializeFrom(static_cast<U8>(3));
5371  FW_ASSERT(
5372  _status == Fw::FW_SERIALIZE_OK,
5373  static_cast<FwAssertArgType>(_status)
5374  );
5375 #endif
5376 
5377 #if FW_AMPCS_COMPATIBLE
5378  // Serialize the argument size
5379  _status = _logBuff.serializeFrom(
5381  );
5382  FW_ASSERT(
5383  _status == Fw::FW_SERIALIZE_OK,
5384  static_cast<FwAssertArgType>(_status)
5385  );
5386 #endif
5387  _status = _logBuff.serializeFrom(readStage);
5388  FW_ASSERT(
5389  _status == Fw::FW_SERIALIZE_OK,
5390  static_cast<FwAssertArgType>(_status)
5391  );
5392 
5393  _status = filePath.serializeTo(
5394  _logBuff,
5395  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
5396  );
5397  FW_ASSERT(
5398  _status == Fw::FW_SERIALIZE_OK,
5399  static_cast<FwAssertArgType>(_status)
5400  );
5401 
5402 #if FW_AMPCS_COMPATIBLE
5403  // Serialize the argument size
5404  _status = _logBuff.serializeFrom(
5405  static_cast<U8>(sizeof(I32))
5406  );
5407  FW_ASSERT(
5408  _status == Fw::FW_SERIALIZE_OK,
5409  static_cast<FwAssertArgType>(_status)
5410  );
5411 #endif
5412  _status = _logBuff.serializeFrom(errorCode);
5413  FW_ASSERT(
5414  _status == Fw::FW_SERIALIZE_OK,
5415  static_cast<FwAssertArgType>(_status)
5416  );
5417 
5418  this->logOut_out(
5419  0,
5420  _id,
5421  _logTime,
5423  _logBuff
5424  );
5425  }
5426 
5427  // Emit the event on the text log port
5428 #if FW_ENABLE_TEXT_LOGGING
5429  if (this->isConnected_logTextOut_OutputPort(0)) {
5430 #if FW_OBJECT_NAMES == 1
5431  const char* _formatString =
5432  "(%s) %s: File read error encountered while reading %s of file %s: %" PRIi32 "";
5433 #else
5434  const char* _formatString =
5435  "%s: File read error encountered while reading %s of file %s: %" PRIi32 "";
5436 #endif
5437 
5438  Fw::String readStageStr;
5439  readStage.toString(readStageStr);
5440 
5441  Fw::TextLogString _logString;
5442  (void) _logString.format(
5443  _formatString,
5444 #if FW_OBJECT_NAMES == 1
5445  this->m_objName.toChar(),
5446 #endif
5447  "FileReadError ",
5448  readStageStr.toChar(),
5449  filePath.toChar(),
5450  errorCode
5451  );
5452 
5453  this->logTextOut_out(
5454  0,
5455  _id,
5456  _logTime,
5458  _logString
5459  );
5460  }
5461 #endif
5462  }
5463 
5466  const Svc::FpySequencer_FileReadStage& readStage,
5467  const Fw::StringBase& filePath
5468  ) const
5469  {
5470  // Get the time
5471  Fw::Time _logTime;
5472  if (this->isConnected_timeCaller_OutputPort(0)) {
5473  this->timeCaller_out(0, _logTime);
5474  }
5475 
5476  const FwEventIdType _id = this->getIdBase() + EVENTID_ENDOFFILEERROR;
5477 
5478  // Emit the event on the log port
5479  if (this->isConnected_logOut_OutputPort(0)) {
5480  Fw::LogBuffer _logBuff;
5482 
5483 #if FW_AMPCS_COMPATIBLE
5484  // Serialize the number of arguments
5485  _status = _logBuff.serializeFrom(static_cast<U8>(2));
5486  FW_ASSERT(
5487  _status == Fw::FW_SERIALIZE_OK,
5488  static_cast<FwAssertArgType>(_status)
5489  );
5490 #endif
5491 
5492 #if FW_AMPCS_COMPATIBLE
5493  // Serialize the argument size
5494  _status = _logBuff.serializeFrom(
5496  );
5497  FW_ASSERT(
5498  _status == Fw::FW_SERIALIZE_OK,
5499  static_cast<FwAssertArgType>(_status)
5500  );
5501 #endif
5502  _status = _logBuff.serializeFrom(readStage);
5503  FW_ASSERT(
5504  _status == Fw::FW_SERIALIZE_OK,
5505  static_cast<FwAssertArgType>(_status)
5506  );
5507 
5508  _status = filePath.serializeTo(
5509  _logBuff,
5510  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
5511  );
5512  FW_ASSERT(
5513  _status == Fw::FW_SERIALIZE_OK,
5514  static_cast<FwAssertArgType>(_status)
5515  );
5516 
5517  this->logOut_out(
5518  0,
5519  _id,
5520  _logTime,
5522  _logBuff
5523  );
5524  }
5525 
5526  // Emit the event on the text log port
5527 #if FW_ENABLE_TEXT_LOGGING
5528  if (this->isConnected_logTextOut_OutputPort(0)) {
5529 #if FW_OBJECT_NAMES == 1
5530  const char* _formatString =
5531  "(%s) %s: End of file encountered unexpectedly while reading %s of file %s";
5532 #else
5533  const char* _formatString =
5534  "%s: End of file encountered unexpectedly while reading %s of file %s";
5535 #endif
5536 
5537  Fw::String readStageStr;
5538  readStage.toString(readStageStr);
5539 
5540  Fw::TextLogString _logString;
5541  (void) _logString.format(
5542  _formatString,
5543 #if FW_OBJECT_NAMES == 1
5544  this->m_objName.toChar(),
5545 #endif
5546  "EndOfFileError ",
5547  readStageStr.toChar(),
5548  filePath.toChar()
5549  );
5550 
5551  this->logTextOut_out(
5552  0,
5553  _id,
5554  _logTime,
5556  _logString
5557  );
5558  }
5559 #endif
5560  }
5561 
5564  const Svc::FpySequencer_FileReadStage& readStage,
5565  const Fw::StringBase& filePath,
5566  I32 errorCode,
5567  U64 buffLeft,
5568  U64 buffLength
5569  ) const
5570  {
5571  // Get the time
5572  Fw::Time _logTime;
5573  if (this->isConnected_timeCaller_OutputPort(0)) {
5574  this->timeCaller_out(0, _logTime);
5575  }
5576 
5578 
5579  // Emit the event on the log port
5580  if (this->isConnected_logOut_OutputPort(0)) {
5581  Fw::LogBuffer _logBuff;
5583 
5584 #if FW_AMPCS_COMPATIBLE
5585  // Serialize the number of arguments
5586  _status = _logBuff.serializeFrom(static_cast<U8>(5));
5587  FW_ASSERT(
5588  _status == Fw::FW_SERIALIZE_OK,
5589  static_cast<FwAssertArgType>(_status)
5590  );
5591 #endif
5592 
5593 #if FW_AMPCS_COMPATIBLE
5594  // Serialize the argument size
5595  _status = _logBuff.serializeFrom(
5597  );
5598  FW_ASSERT(
5599  _status == Fw::FW_SERIALIZE_OK,
5600  static_cast<FwAssertArgType>(_status)
5601  );
5602 #endif
5603  _status = _logBuff.serializeFrom(readStage);
5604  FW_ASSERT(
5605  _status == Fw::FW_SERIALIZE_OK,
5606  static_cast<FwAssertArgType>(_status)
5607  );
5608 
5609  _status = filePath.serializeTo(
5610  _logBuff,
5611  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
5612  );
5613  FW_ASSERT(
5614  _status == Fw::FW_SERIALIZE_OK,
5615  static_cast<FwAssertArgType>(_status)
5616  );
5617 
5618 #if FW_AMPCS_COMPATIBLE
5619  // Serialize the argument size
5620  _status = _logBuff.serializeFrom(
5621  static_cast<U8>(sizeof(I32))
5622  );
5623  FW_ASSERT(
5624  _status == Fw::FW_SERIALIZE_OK,
5625  static_cast<FwAssertArgType>(_status)
5626  );
5627 #endif
5628  _status = _logBuff.serializeFrom(errorCode);
5629  FW_ASSERT(
5630  _status == Fw::FW_SERIALIZE_OK,
5631  static_cast<FwAssertArgType>(_status)
5632  );
5633 
5634 #if FW_AMPCS_COMPATIBLE
5635  // Serialize the argument size
5636  _status = _logBuff.serializeFrom(
5637  static_cast<U8>(sizeof(U64))
5638  );
5639  FW_ASSERT(
5640  _status == Fw::FW_SERIALIZE_OK,
5641  static_cast<FwAssertArgType>(_status)
5642  );
5643 #endif
5644  _status = _logBuff.serializeFrom(buffLeft);
5645  FW_ASSERT(
5646  _status == Fw::FW_SERIALIZE_OK,
5647  static_cast<FwAssertArgType>(_status)
5648  );
5649 
5650 #if FW_AMPCS_COMPATIBLE
5651  // Serialize the argument size
5652  _status = _logBuff.serializeFrom(
5653  static_cast<U8>(sizeof(U64))
5654  );
5655  FW_ASSERT(
5656  _status == Fw::FW_SERIALIZE_OK,
5657  static_cast<FwAssertArgType>(_status)
5658  );
5659 #endif
5660  _status = _logBuff.serializeFrom(buffLength);
5661  FW_ASSERT(
5662  _status == Fw::FW_SERIALIZE_OK,
5663  static_cast<FwAssertArgType>(_status)
5664  );
5665 
5666  this->logOut_out(
5667  0,
5668  _id,
5669  _logTime,
5671  _logBuff
5672  );
5673  }
5674 
5675  // Emit the event on the text log port
5676 #if FW_ENABLE_TEXT_LOGGING
5677  if (this->isConnected_logTextOut_OutputPort(0)) {
5678 #if FW_OBJECT_NAMES == 1
5679  const char* _formatString =
5680  "(%s) %s: Deserialize error encountered while reading %s of file %s: %" PRIi32 " (%" PRIu64 " bytes left out of %" PRIu64 ")";
5681 #else
5682  const char* _formatString =
5683  "%s: Deserialize error encountered while reading %s of file %s: %" PRIi32 " (%" PRIu64 " bytes left out of %" PRIu64 ")";
5684 #endif
5685 
5686  Fw::String readStageStr;
5687  readStage.toString(readStageStr);
5688 
5689  Fw::TextLogString _logString;
5690  (void) _logString.format(
5691  _formatString,
5692 #if FW_OBJECT_NAMES == 1
5693  this->m_objName.toChar(),
5694 #endif
5695  "FileReadDeserializeError ",
5696  readStageStr.toChar(),
5697  filePath.toChar(),
5698  errorCode,
5699  buffLeft,
5700  buffLength
5701  );
5702 
5703  this->logTextOut_out(
5704  0,
5705  _id,
5706  _logTime,
5708  _logString
5709  );
5710  }
5711 #endif
5712  }
5713 
5716  U8 expected,
5717  U8 actual
5718  ) const
5719  {
5720  // Get the time
5721  Fw::Time _logTime;
5722  if (this->isConnected_timeCaller_OutputPort(0)) {
5723  this->timeCaller_out(0, _logTime);
5724  }
5725 
5726  const FwEventIdType _id = this->getIdBase() + EVENTID_WRONGSCHEMAVERSION;
5727 
5728  // Emit the event on the log port
5729  if (this->isConnected_logOut_OutputPort(0)) {
5730  Fw::LogBuffer _logBuff;
5732 
5733 #if FW_AMPCS_COMPATIBLE
5734  // Serialize the number of arguments
5735  _status = _logBuff.serializeFrom(static_cast<U8>(2));
5736  FW_ASSERT(
5737  _status == Fw::FW_SERIALIZE_OK,
5738  static_cast<FwAssertArgType>(_status)
5739  );
5740 #endif
5741 
5742 #if FW_AMPCS_COMPATIBLE
5743  // Serialize the argument size
5744  _status = _logBuff.serializeFrom(
5745  static_cast<U8>(sizeof(U8))
5746  );
5747  FW_ASSERT(
5748  _status == Fw::FW_SERIALIZE_OK,
5749  static_cast<FwAssertArgType>(_status)
5750  );
5751 #endif
5752  _status = _logBuff.serializeFrom(expected);
5753  FW_ASSERT(
5754  _status == Fw::FW_SERIALIZE_OK,
5755  static_cast<FwAssertArgType>(_status)
5756  );
5757 
5758 #if FW_AMPCS_COMPATIBLE
5759  // Serialize the argument size
5760  _status = _logBuff.serializeFrom(
5761  static_cast<U8>(sizeof(U8))
5762  );
5763  FW_ASSERT(
5764  _status == Fw::FW_SERIALIZE_OK,
5765  static_cast<FwAssertArgType>(_status)
5766  );
5767 #endif
5768  _status = _logBuff.serializeFrom(actual);
5769  FW_ASSERT(
5770  _status == Fw::FW_SERIALIZE_OK,
5771  static_cast<FwAssertArgType>(_status)
5772  );
5773 
5774  this->logOut_out(
5775  0,
5776  _id,
5777  _logTime,
5779  _logBuff
5780  );
5781  }
5782 
5783  // Emit the event on the text log port
5784 #if FW_ENABLE_TEXT_LOGGING
5785  if (this->isConnected_logTextOut_OutputPort(0)) {
5786 #if FW_OBJECT_NAMES == 1
5787  const char* _formatString =
5788  "(%s) %s: Expected schema version %" PRIu8 ", found %" PRIu8 "";
5789 #else
5790  const char* _formatString =
5791  "%s: Expected schema version %" PRIu8 ", found %" PRIu8 "";
5792 #endif
5793 
5794  Fw::TextLogString _logString;
5795  (void) _logString.format(
5796  _formatString,
5797 #if FW_OBJECT_NAMES == 1
5798  this->m_objName.toChar(),
5799 #endif
5800  "WrongSchemaVersion ",
5801  expected,
5802  actual
5803  );
5804 
5805  this->logTextOut_out(
5806  0,
5807  _id,
5808  _logTime,
5810  _logString
5811  );
5812  }
5813 #endif
5814  }
5815 
5818  U32 expected,
5819  U32 actual
5820  ) const
5821  {
5822  // Get the time
5823  Fw::Time _logTime;
5824  if (this->isConnected_timeCaller_OutputPort(0)) {
5825  this->timeCaller_out(0, _logTime);
5826  }
5827 
5828  const FwEventIdType _id = this->getIdBase() + EVENTID_WRONGCRC;
5829 
5830  // Emit the event on the log port
5831  if (this->isConnected_logOut_OutputPort(0)) {
5832  Fw::LogBuffer _logBuff;
5834 
5835 #if FW_AMPCS_COMPATIBLE
5836  // Serialize the number of arguments
5837  _status = _logBuff.serializeFrom(static_cast<U8>(2));
5838  FW_ASSERT(
5839  _status == Fw::FW_SERIALIZE_OK,
5840  static_cast<FwAssertArgType>(_status)
5841  );
5842 #endif
5843 
5844 #if FW_AMPCS_COMPATIBLE
5845  // Serialize the argument size
5846  _status = _logBuff.serializeFrom(
5847  static_cast<U8>(sizeof(U32))
5848  );
5849  FW_ASSERT(
5850  _status == Fw::FW_SERIALIZE_OK,
5851  static_cast<FwAssertArgType>(_status)
5852  );
5853 #endif
5854  _status = _logBuff.serializeFrom(expected);
5855  FW_ASSERT(
5856  _status == Fw::FW_SERIALIZE_OK,
5857  static_cast<FwAssertArgType>(_status)
5858  );
5859 
5860 #if FW_AMPCS_COMPATIBLE
5861  // Serialize the argument size
5862  _status = _logBuff.serializeFrom(
5863  static_cast<U8>(sizeof(U32))
5864  );
5865  FW_ASSERT(
5866  _status == Fw::FW_SERIALIZE_OK,
5867  static_cast<FwAssertArgType>(_status)
5868  );
5869 #endif
5870  _status = _logBuff.serializeFrom(actual);
5871  FW_ASSERT(
5872  _status == Fw::FW_SERIALIZE_OK,
5873  static_cast<FwAssertArgType>(_status)
5874  );
5875 
5876  this->logOut_out(
5877  0,
5878  _id,
5879  _logTime,
5881  _logBuff
5882  );
5883  }
5884 
5885  // Emit the event on the text log port
5886 #if FW_ENABLE_TEXT_LOGGING
5887  if (this->isConnected_logTextOut_OutputPort(0)) {
5888 #if FW_OBJECT_NAMES == 1
5889  const char* _formatString =
5890  "(%s) %s: Expected CRC %" PRIu32 ", actual was %" PRIu32 "";
5891 #else
5892  const char* _formatString =
5893  "%s: Expected CRC %" PRIu32 ", actual was %" PRIu32 "";
5894 #endif
5895 
5896  Fw::TextLogString _logString;
5897  (void) _logString.format(
5898  _formatString,
5899 #if FW_OBJECT_NAMES == 1
5900  this->m_objName.toChar(),
5901 #endif
5902  "WrongCRC ",
5903  expected,
5904  actual
5905  );
5906 
5907  this->logTextOut_out(
5908  0,
5909  _id,
5910  _logTime,
5912  _logString
5913  );
5914  }
5915 #endif
5916  }
5917 
5920  {
5921  // Get the time
5922  Fw::Time _logTime;
5923  if (this->isConnected_timeCaller_OutputPort(0)) {
5924  this->timeCaller_out(0, _logTime);
5925  }
5926 
5928 
5929  // Emit the event on the log port
5930  if (this->isConnected_logOut_OutputPort(0)) {
5931  Fw::LogBuffer _logBuff;
5933 
5934 #if FW_AMPCS_COMPATIBLE
5935  // Serialize the number of arguments
5936  _status = _logBuff.serializeFrom(static_cast<U8>(1));
5937  FW_ASSERT(
5938  _status == Fw::FW_SERIALIZE_OK,
5939  static_cast<FwAssertArgType>(_status)
5940  );
5941 #endif
5942 
5943 #if FW_AMPCS_COMPATIBLE
5944  // Serialize the argument size
5945  _status = _logBuff.serializeFrom(
5946  static_cast<U8>(sizeof(FwSizeType))
5947  );
5948  FW_ASSERT(
5949  _status == Fw::FW_SERIALIZE_OK,
5950  static_cast<FwAssertArgType>(_status)
5951  );
5952 #endif
5953  _status = _logBuff.serializeFrom(remaining);
5954  FW_ASSERT(
5955  _status == Fw::FW_SERIALIZE_OK,
5956  static_cast<FwAssertArgType>(_status)
5957  );
5958 
5959  this->logOut_out(
5960  0,
5961  _id,
5962  _logTime,
5964  _logBuff
5965  );
5966  }
5967 
5968  // Emit the event on the text log port
5969 #if FW_ENABLE_TEXT_LOGGING
5970  if (this->isConnected_logTextOut_OutputPort(0)) {
5971 #if FW_OBJECT_NAMES == 1
5972  const char* _formatString =
5973  "(%s) %s: File had %" PRIu64 " extra bytes at the end";
5974 #else
5975  const char* _formatString =
5976  "%s: File had %" PRIu64 " extra bytes at the end";
5977 #endif
5978 
5979  Fw::TextLogString _logString;
5980  (void) _logString.format(
5981  _formatString,
5982 #if FW_OBJECT_NAMES == 1
5983  this->m_objName.toChar(),
5984 #endif
5985  "ExtraBytesInSequence ",
5986  remaining
5987  );
5988 
5989  this->logTextOut_out(
5990  0,
5991  _id,
5992  _logTime,
5994  _logString
5995  );
5996  }
5997 #endif
5998  }
5999 
6002  U64 bufferSize,
6003  const Fw::StringBase& filePath
6004  ) const
6005  {
6006  // Get the time
6007  Fw::Time _logTime;
6008  if (this->isConnected_timeCaller_OutputPort(0)) {
6009  this->timeCaller_out(0, _logTime);
6010  }
6011 
6013 
6014  // Emit the event on the log port
6015  if (this->isConnected_logOut_OutputPort(0)) {
6016  Fw::LogBuffer _logBuff;
6018 
6019 #if FW_AMPCS_COMPATIBLE
6020  // Serialize the number of arguments
6021  _status = _logBuff.serializeFrom(static_cast<U8>(2));
6022  FW_ASSERT(
6023  _status == Fw::FW_SERIALIZE_OK,
6024  static_cast<FwAssertArgType>(_status)
6025  );
6026 #endif
6027 
6028 #if FW_AMPCS_COMPATIBLE
6029  // Serialize the argument size
6030  _status = _logBuff.serializeFrom(
6031  static_cast<U8>(sizeof(U64))
6032  );
6033  FW_ASSERT(
6034  _status == Fw::FW_SERIALIZE_OK,
6035  static_cast<FwAssertArgType>(_status)
6036  );
6037 #endif
6038  _status = _logBuff.serializeFrom(bufferSize);
6039  FW_ASSERT(
6040  _status == Fw::FW_SERIALIZE_OK,
6041  static_cast<FwAssertArgType>(_status)
6042  );
6043 
6044  _status = filePath.serializeTo(
6045  _logBuff,
6046  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6047  );
6048  FW_ASSERT(
6049  _status == Fw::FW_SERIALIZE_OK,
6050  static_cast<FwAssertArgType>(_status)
6051  );
6052 
6053  this->logOut_out(
6054  0,
6055  _id,
6056  _logTime,
6058  _logBuff
6059  );
6060  }
6061 
6062  // Emit the event on the text log port
6063 #if FW_ENABLE_TEXT_LOGGING
6064  if (this->isConnected_logTextOut_OutputPort(0)) {
6065 #if FW_OBJECT_NAMES == 1
6066  const char* _formatString =
6067  "(%s) %s: Buffer capacity of %" PRIu64 " was not big enough for sequence %s";
6068 #else
6069  const char* _formatString =
6070  "%s: Buffer capacity of %" PRIu64 " was not big enough for sequence %s";
6071 #endif
6072 
6073  Fw::TextLogString _logString;
6074  (void) _logString.format(
6075  _formatString,
6076 #if FW_OBJECT_NAMES == 1
6077  this->m_objName.toChar(),
6078 #endif
6079  "InsufficientBufferSpace ",
6080  bufferSize,
6081  filePath.toChar()
6082  );
6083 
6084  this->logTextOut_out(
6085  0,
6086  _id,
6087  _logTime,
6089  _logString
6090  );
6091  }
6092 #endif
6093  }
6094 
6097  const Fw::StringBase& filePath,
6098  I32 errorCode
6099  ) const
6100  {
6101  // Get the time
6102  Fw::Time _logTime;
6103  if (this->isConnected_timeCaller_OutputPort(0)) {
6104  this->timeCaller_out(0, _logTime);
6105  }
6106 
6107  const FwEventIdType _id = this->getIdBase() + EVENTID_FILEAPIERROR;
6108 
6109  // Emit the event on the log port
6110  if (this->isConnected_logOut_OutputPort(0)) {
6111  Fw::LogBuffer _logBuff;
6113 
6114 #if FW_AMPCS_COMPATIBLE
6115  // Serialize the number of arguments
6116  _status = _logBuff.serializeFrom(static_cast<U8>(2));
6117  FW_ASSERT(
6118  _status == Fw::FW_SERIALIZE_OK,
6119  static_cast<FwAssertArgType>(_status)
6120  );
6121 #endif
6122 
6123  _status = filePath.serializeTo(
6124  _logBuff,
6125  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6126  );
6127  FW_ASSERT(
6128  _status == Fw::FW_SERIALIZE_OK,
6129  static_cast<FwAssertArgType>(_status)
6130  );
6131 
6132 #if FW_AMPCS_COMPATIBLE
6133  // Serialize the argument size
6134  _status = _logBuff.serializeFrom(
6135  static_cast<U8>(sizeof(I32))
6136  );
6137  FW_ASSERT(
6138  _status == Fw::FW_SERIALIZE_OK,
6139  static_cast<FwAssertArgType>(_status)
6140  );
6141 #endif
6142  _status = _logBuff.serializeFrom(errorCode);
6143  FW_ASSERT(
6144  _status == Fw::FW_SERIALIZE_OK,
6145  static_cast<FwAssertArgType>(_status)
6146  );
6147 
6148  this->logOut_out(
6149  0,
6150  _id,
6151  _logTime,
6153  _logBuff
6154  );
6155  }
6156 
6157  // Emit the event on the text log port
6158 #if FW_ENABLE_TEXT_LOGGING
6159  if (this->isConnected_logTextOut_OutputPort(0)) {
6160 #if FW_OBJECT_NAMES == 1
6161  const char* _formatString =
6162  "(%s) %s: File system API error encountered while operating on file %s: %" PRIi32 "";
6163 #else
6164  const char* _formatString =
6165  "%s: File system API error encountered while operating on file %s: %" PRIi32 "";
6166 #endif
6167 
6168  Fw::TextLogString _logString;
6169  (void) _logString.format(
6170  _formatString,
6171 #if FW_OBJECT_NAMES == 1
6172  this->m_objName.toChar(),
6173 #endif
6174  "FileApiError ",
6175  filePath.toChar(),
6176  errorCode
6177  );
6178 
6179  this->logTextOut_out(
6180  0,
6181  _id,
6182  _logTime,
6184  _logString
6185  );
6186  }
6187 #endif
6188  }
6189 
6192  const Fw::StringBase& baseDir,
6193  const Fw::StringBase& fileName
6194  ) const
6195  {
6196  // Get the time
6197  Fw::Time _logTime;
6198  if (this->isConnected_timeCaller_OutputPort(0)) {
6199  this->timeCaller_out(0, _logTime);
6200  }
6201 
6203 
6204  // Emit the event on the log port
6205  if (this->isConnected_logOut_OutputPort(0)) {
6206  Fw::LogBuffer _logBuff;
6208 
6209 #if FW_AMPCS_COMPATIBLE
6210  // Serialize the number of arguments
6211  _status = _logBuff.serializeFrom(static_cast<U8>(2));
6212  FW_ASSERT(
6213  _status == Fw::FW_SERIALIZE_OK,
6214  static_cast<FwAssertArgType>(_status)
6215  );
6216 #endif
6217 
6218  _status = baseDir.serializeTo(
6219  _logBuff,
6220  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6221  );
6222  FW_ASSERT(
6223  _status == Fw::FW_SERIALIZE_OK,
6224  static_cast<FwAssertArgType>(_status)
6225  );
6226 
6227  _status = fileName.serializeTo(
6228  _logBuff,
6229  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6230  );
6231  FW_ASSERT(
6232  _status == Fw::FW_SERIALIZE_OK,
6233  static_cast<FwAssertArgType>(_status)
6234  );
6235 
6236  this->logOut_out(
6237  0,
6238  _id,
6239  _logTime,
6241  _logBuff
6242  );
6243  }
6244 
6245  // Emit the event on the text log port
6246 #if FW_ENABLE_TEXT_LOGGING
6247  if (this->isConnected_logTextOut_OutputPort(0)) {
6248 #if FW_OBJECT_NAMES == 1
6249  const char* _formatString =
6250  "(%s) %s: Sequence file path was truncated: base directory %s and file name %s together exceed the maximum path length";
6251 #else
6252  const char* _formatString =
6253  "%s: Sequence file path was truncated: base directory %s and file name %s together exceed the maximum path length";
6254 #endif
6255 
6256  Fw::TextLogString _logString;
6257  (void) _logString.format(
6258  _formatString,
6259 #if FW_OBJECT_NAMES == 1
6260  this->m_objName.toChar(),
6261 #endif
6262  "SequenceFilePathTooLong ",
6263  baseDir.toChar(),
6264  fileName.toChar()
6265  );
6266 
6267  this->logTextOut_out(
6268  0,
6269  _id,
6270  _logTime,
6272  _logString
6273  );
6274  }
6275 #endif
6276  }
6277 
6280  FwOpcodeType opCode,
6281  U32 stmtIdx,
6282  const Fw::StringBase& filePath,
6283  const Fw::CmdResponse& response
6284  ) const
6285  {
6286  // Get the time
6287  Fw::Time _logTime;
6288  if (this->isConnected_timeCaller_OutputPort(0)) {
6289  this->timeCaller_out(0, _logTime);
6290  }
6291 
6292  const FwEventIdType _id = this->getIdBase() + EVENTID_COMMANDFAILED;
6293 
6294  // Emit the event on the log port
6295  if (this->isConnected_logOut_OutputPort(0)) {
6296  Fw::LogBuffer _logBuff;
6298 
6299 #if FW_AMPCS_COMPATIBLE
6300  // Serialize the number of arguments
6301  _status = _logBuff.serializeFrom(static_cast<U8>(4));
6302  FW_ASSERT(
6303  _status == Fw::FW_SERIALIZE_OK,
6304  static_cast<FwAssertArgType>(_status)
6305  );
6306 #endif
6307 
6308 #if FW_AMPCS_COMPATIBLE
6309  // Serialize the argument size
6310  _status = _logBuff.serializeFrom(
6311  static_cast<U8>(sizeof(FwOpcodeType))
6312  );
6313  FW_ASSERT(
6314  _status == Fw::FW_SERIALIZE_OK,
6315  static_cast<FwAssertArgType>(_status)
6316  );
6317 #endif
6318  _status = _logBuff.serializeFrom(opCode);
6319  FW_ASSERT(
6320  _status == Fw::FW_SERIALIZE_OK,
6321  static_cast<FwAssertArgType>(_status)
6322  );
6323 
6324 #if FW_AMPCS_COMPATIBLE
6325  // Serialize the argument size
6326  _status = _logBuff.serializeFrom(
6327  static_cast<U8>(sizeof(U32))
6328  );
6329  FW_ASSERT(
6330  _status == Fw::FW_SERIALIZE_OK,
6331  static_cast<FwAssertArgType>(_status)
6332  );
6333 #endif
6334  _status = _logBuff.serializeFrom(stmtIdx);
6335  FW_ASSERT(
6336  _status == Fw::FW_SERIALIZE_OK,
6337  static_cast<FwAssertArgType>(_status)
6338  );
6339 
6340  _status = filePath.serializeTo(
6341  _logBuff,
6342  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6343  );
6344  FW_ASSERT(
6345  _status == Fw::FW_SERIALIZE_OK,
6346  static_cast<FwAssertArgType>(_status)
6347  );
6348 
6349 #if FW_AMPCS_COMPATIBLE
6350  // Serialize the argument size
6351  _status = _logBuff.serializeFrom(
6352  static_cast<U8>(Fw::CmdResponse::SERIALIZED_SIZE)
6353  );
6354  FW_ASSERT(
6355  _status == Fw::FW_SERIALIZE_OK,
6356  static_cast<FwAssertArgType>(_status)
6357  );
6358 #endif
6359  _status = _logBuff.serializeFrom(response);
6360  FW_ASSERT(
6361  _status == Fw::FW_SERIALIZE_OK,
6362  static_cast<FwAssertArgType>(_status)
6363  );
6364 
6365  this->logOut_out(
6366  0,
6367  _id,
6368  _logTime,
6370  _logBuff
6371  );
6372  }
6373 
6374  // Emit the event on the text log port
6375 #if FW_ENABLE_TEXT_LOGGING
6376  if (this->isConnected_logTextOut_OutputPort(0)) {
6377 #if FW_OBJECT_NAMES == 1
6378  const char* _formatString =
6379  "(%s) %s: Failed to execute command opcode %" PRIu32 " index %" PRIu32 " in sequence file %s: response was %s";
6380 #else
6381  const char* _formatString =
6382  "%s: Failed to execute command opcode %" PRIu32 " index %" PRIu32 " in sequence file %s: response was %s";
6383 #endif
6384 
6385  Fw::String responseStr;
6386  response.toString(responseStr);
6387 
6388  Fw::TextLogString _logString;
6389  (void) _logString.format(
6390  _formatString,
6391 #if FW_OBJECT_NAMES == 1
6392  this->m_objName.toChar(),
6393 #endif
6394  "CommandFailed ",
6395  opCode,
6396  stmtIdx,
6397  filePath.toChar(),
6398  responseStr.toChar()
6399  );
6400 
6401  this->logTextOut_out(
6402  0,
6403  _id,
6404  _logTime,
6406  _logString
6407  );
6408  }
6409 #endif
6410  }
6411 
6414  {
6415  // Get the time
6416  Fw::Time _logTime;
6417  if (this->isConnected_timeCaller_OutputPort(0)) {
6418  this->timeCaller_out(0, _logTime);
6419  }
6420 
6421  const FwEventIdType _id = this->getIdBase() + EVENTID_SEQUENCEDONE;
6422 
6423  // Emit the event on the log port
6424  if (this->isConnected_logOut_OutputPort(0)) {
6425  Fw::LogBuffer _logBuff;
6427 
6428 #if FW_AMPCS_COMPATIBLE
6429  // Serialize the number of arguments
6430  _status = _logBuff.serializeFrom(static_cast<U8>(1));
6431  FW_ASSERT(
6432  _status == Fw::FW_SERIALIZE_OK,
6433  static_cast<FwAssertArgType>(_status)
6434  );
6435 #endif
6436 
6437  _status = filePath.serializeTo(
6438  _logBuff,
6439  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6440  );
6441  FW_ASSERT(
6442  _status == Fw::FW_SERIALIZE_OK,
6443  static_cast<FwAssertArgType>(_status)
6444  );
6445 
6446  this->logOut_out(
6447  0,
6448  _id,
6449  _logTime,
6451  _logBuff
6452  );
6453  }
6454 
6455  // Emit the event on the text log port
6456 #if FW_ENABLE_TEXT_LOGGING
6457  if (this->isConnected_logTextOut_OutputPort(0)) {
6458 #if FW_OBJECT_NAMES == 1
6459  const char* _formatString =
6460  "(%s) %s: Completed sequence file %s";
6461 #else
6462  const char* _formatString =
6463  "%s: Completed sequence file %s";
6464 #endif
6465 
6466  Fw::TextLogString _logString;
6467  (void) _logString.format(
6468  _formatString,
6469 #if FW_OBJECT_NAMES == 1
6470  this->m_objName.toChar(),
6471 #endif
6472  "SequenceDone ",
6473  filePath.toChar()
6474  );
6475 
6476  this->logTextOut_out(
6477  0,
6478  _id,
6479  _logTime,
6481  _logString
6482  );
6483  }
6484 #endif
6485  }
6486 
6489  {
6490  // Get the time
6491  Fw::Time _logTime;
6492  if (this->isConnected_timeCaller_OutputPort(0)) {
6493  this->timeCaller_out(0, _logTime);
6494  }
6495 
6496  const FwEventIdType _id = this->getIdBase() + EVENTID_SEQUENCECANCELLED;
6497 
6498  // Emit the event on the log port
6499  if (this->isConnected_logOut_OutputPort(0)) {
6500  Fw::LogBuffer _logBuff;
6502 
6503 #if FW_AMPCS_COMPATIBLE
6504  // Serialize the number of arguments
6505  _status = _logBuff.serializeFrom(static_cast<U8>(1));
6506  FW_ASSERT(
6507  _status == Fw::FW_SERIALIZE_OK,
6508  static_cast<FwAssertArgType>(_status)
6509  );
6510 #endif
6511 
6512  _status = filePath.serializeTo(
6513  _logBuff,
6514  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6515  );
6516  FW_ASSERT(
6517  _status == Fw::FW_SERIALIZE_OK,
6518  static_cast<FwAssertArgType>(_status)
6519  );
6520 
6521  this->logOut_out(
6522  0,
6523  _id,
6524  _logTime,
6526  _logBuff
6527  );
6528  }
6529 
6530  // Emit the event on the text log port
6531 #if FW_ENABLE_TEXT_LOGGING
6532  if (this->isConnected_logTextOut_OutputPort(0)) {
6533 #if FW_OBJECT_NAMES == 1
6534  const char* _formatString =
6535  "(%s) %s: Cancelled sequence file %s";
6536 #else
6537  const char* _formatString =
6538  "%s: Cancelled sequence file %s";
6539 #endif
6540 
6541  Fw::TextLogString _logString;
6542  (void) _logString.format(
6543  _formatString,
6544 #if FW_OBJECT_NAMES == 1
6545  this->m_objName.toChar(),
6546 #endif
6547  "SequenceCancelled ",
6548  filePath.toChar()
6549  );
6550 
6551  this->logTextOut_out(
6552  0,
6553  _id,
6554  _logTime,
6556  _logString
6557  );
6558  }
6559 #endif
6560  }
6561 
6564  const Fw::StringBase& filePath,
6565  I32 errorCode
6566  ) const
6567  {
6568  // Get the time
6569  Fw::Time _logTime;
6570  if (this->isConnected_timeCaller_OutputPort(0)) {
6571  this->timeCaller_out(0, _logTime);
6572  }
6573 
6575 
6576  // Emit the event on the log port
6577  if (this->isConnected_logOut_OutputPort(0)) {
6578  Fw::LogBuffer _logBuff;
6580 
6581 #if FW_AMPCS_COMPATIBLE
6582  // Serialize the number of arguments
6583  _status = _logBuff.serializeFrom(static_cast<U8>(2));
6584  FW_ASSERT(
6585  _status == Fw::FW_SERIALIZE_OK,
6586  static_cast<FwAssertArgType>(_status)
6587  );
6588 #endif
6589 
6590  _status = filePath.serializeTo(
6591  _logBuff,
6592  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6593  );
6594  FW_ASSERT(
6595  _status == Fw::FW_SERIALIZE_OK,
6596  static_cast<FwAssertArgType>(_status)
6597  );
6598 
6599 #if FW_AMPCS_COMPATIBLE
6600  // Serialize the argument size
6601  _status = _logBuff.serializeFrom(
6602  static_cast<U8>(sizeof(I32))
6603  );
6604  FW_ASSERT(
6605  _status == Fw::FW_SERIALIZE_OK,
6606  static_cast<FwAssertArgType>(_status)
6607  );
6608 #endif
6609  _status = _logBuff.serializeFrom(errorCode);
6610  FW_ASSERT(
6611  _status == Fw::FW_SERIALIZE_OK,
6612  static_cast<FwAssertArgType>(_status)
6613  );
6614 
6615  this->logOut_out(
6616  0,
6617  _id,
6618  _logTime,
6620  _logBuff
6621  );
6622  }
6623 
6624  // Emit the event on the text log port
6625 #if FW_ENABLE_TEXT_LOGGING
6626  if (this->isConnected_logTextOut_OutputPort(0)) {
6627 #if FW_OBJECT_NAMES == 1
6628  const char* _formatString =
6629  "(%s) %s: Sequence %s exited with error code %" PRIi32 "";
6630 #else
6631  const char* _formatString =
6632  "%s: Sequence %s exited with error code %" PRIi32 "";
6633 #endif
6634 
6635  Fw::TextLogString _logString;
6636  (void) _logString.format(
6637  _formatString,
6638 #if FW_OBJECT_NAMES == 1
6639  this->m_objName.toChar(),
6640 #endif
6641  "SequenceExitedWithError ",
6642  filePath.toChar(),
6643  errorCode
6644  );
6645 
6646  this->logTextOut_out(
6647  0,
6648  _id,
6649  _logTime,
6651  _logString
6652  );
6653  }
6654 #endif
6655  }
6656 
6659  U8 opcode,
6660  U32 stmtIdx,
6661  const Fw::StringBase& filePath
6662  ) const
6663  {
6664  // Get the time
6665  Fw::Time _logTime;
6666  if (this->isConnected_timeCaller_OutputPort(0)) {
6667  this->timeCaller_out(0, _logTime);
6668  }
6669 
6671 
6672  // Emit the event on the log port
6673  if (this->isConnected_logOut_OutputPort(0)) {
6674  Fw::LogBuffer _logBuff;
6676 
6677 #if FW_AMPCS_COMPATIBLE
6678  // Serialize the number of arguments
6679  _status = _logBuff.serializeFrom(static_cast<U8>(3));
6680  FW_ASSERT(
6681  _status == Fw::FW_SERIALIZE_OK,
6682  static_cast<FwAssertArgType>(_status)
6683  );
6684 #endif
6685 
6686 #if FW_AMPCS_COMPATIBLE
6687  // Serialize the argument size
6688  _status = _logBuff.serializeFrom(
6689  static_cast<U8>(sizeof(U8))
6690  );
6691  FW_ASSERT(
6692  _status == Fw::FW_SERIALIZE_OK,
6693  static_cast<FwAssertArgType>(_status)
6694  );
6695 #endif
6696  _status = _logBuff.serializeFrom(opcode);
6697  FW_ASSERT(
6698  _status == Fw::FW_SERIALIZE_OK,
6699  static_cast<FwAssertArgType>(_status)
6700  );
6701 
6702 #if FW_AMPCS_COMPATIBLE
6703  // Serialize the argument size
6704  _status = _logBuff.serializeFrom(
6705  static_cast<U8>(sizeof(U32))
6706  );
6707  FW_ASSERT(
6708  _status == Fw::FW_SERIALIZE_OK,
6709  static_cast<FwAssertArgType>(_status)
6710  );
6711 #endif
6712  _status = _logBuff.serializeFrom(stmtIdx);
6713  FW_ASSERT(
6714  _status == Fw::FW_SERIALIZE_OK,
6715  static_cast<FwAssertArgType>(_status)
6716  );
6717 
6718  _status = filePath.serializeTo(
6719  _logBuff,
6720  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
6721  );
6722  FW_ASSERT(
6723  _status == Fw::FW_SERIALIZE_OK,
6724  static_cast<FwAssertArgType>(_status)
6725  );
6726 
6727  this->logOut_out(
6728  0,
6729  _id,
6730  _logTime,
6732  _logBuff
6733  );
6734  }
6735 
6736  // Emit the event on the text log port
6737 #if FW_ENABLE_TEXT_LOGGING
6738  if (this->isConnected_logTextOut_OutputPort(0)) {
6739 #if FW_OBJECT_NAMES == 1
6740  const char* _formatString =
6741  "(%s) %s: Unknown sequencer directive id %" PRIu8 " at index %" PRIu32 " in file %s";
6742 #else
6743  const char* _formatString =
6744  "%s: Unknown sequencer directive id %" PRIu8 " at index %" PRIu32 " in file %s";
6745 #endif
6746 
6747  Fw::TextLogString _logString;
6748  (void) _logString.format(
6749  _formatString,
6750 #if FW_OBJECT_NAMES == 1
6751  this->m_objName.toChar(),
6752 #endif
6753  "UnknownSequencerDirective ",
6754  opcode,
6755  stmtIdx,
6756  filePath.toChar()
6757  );
6758 
6759  this->logTextOut_out(
6760  0,
6761  _id,
6762  _logTime,
6764  _logString
6765  );
6766  }
6767 #endif
6768  }
6769 
6772  I32 state,
6773  FwOpcodeType opcode,
6774  const Fw::CmdResponse& response
6775  ) const
6776  {
6777  // Get the time
6778  Fw::Time _logTime;
6779  if (this->isConnected_timeCaller_OutputPort(0)) {
6780  this->timeCaller_out(0, _logTime);
6781  }
6782 
6784 
6785  // Emit the event on the log port
6786  if (this->isConnected_logOut_OutputPort(0)) {
6787  Fw::LogBuffer _logBuff;
6789 
6790 #if FW_AMPCS_COMPATIBLE
6791  // Serialize the number of arguments
6792  _status = _logBuff.serializeFrom(static_cast<U8>(3));
6793  FW_ASSERT(
6794  _status == Fw::FW_SERIALIZE_OK,
6795  static_cast<FwAssertArgType>(_status)
6796  );
6797 #endif
6798 
6799 #if FW_AMPCS_COMPATIBLE
6800  // Serialize the argument size
6801  _status = _logBuff.serializeFrom(
6802  static_cast<U8>(sizeof(I32))
6803  );
6804  FW_ASSERT(
6805  _status == Fw::FW_SERIALIZE_OK,
6806  static_cast<FwAssertArgType>(_status)
6807  );
6808 #endif
6809  _status = _logBuff.serializeFrom(state);
6810  FW_ASSERT(
6811  _status == Fw::FW_SERIALIZE_OK,
6812  static_cast<FwAssertArgType>(_status)
6813  );
6814 
6815 #if FW_AMPCS_COMPATIBLE
6816  // Serialize the argument size
6817  _status = _logBuff.serializeFrom(
6818  static_cast<U8>(sizeof(FwOpcodeType))
6819  );
6820  FW_ASSERT(
6821  _status == Fw::FW_SERIALIZE_OK,
6822  static_cast<FwAssertArgType>(_status)
6823  );
6824 #endif
6825  _status = _logBuff.serializeFrom(opcode);
6826  FW_ASSERT(
6827  _status == Fw::FW_SERIALIZE_OK,
6828  static_cast<FwAssertArgType>(_status)
6829  );
6830 
6831 #if FW_AMPCS_COMPATIBLE
6832  // Serialize the argument size
6833  _status = _logBuff.serializeFrom(
6834  static_cast<U8>(Fw::CmdResponse::SERIALIZED_SIZE)
6835  );
6836  FW_ASSERT(
6837  _status == Fw::FW_SERIALIZE_OK,
6838  static_cast<FwAssertArgType>(_status)
6839  );
6840 #endif
6841  _status = _logBuff.serializeFrom(response);
6842  FW_ASSERT(
6843  _status == Fw::FW_SERIALIZE_OK,
6844  static_cast<FwAssertArgType>(_status)
6845  );
6846 
6847  this->logOut_out(
6848  0,
6849  _id,
6850  _logTime,
6852  _logBuff
6853  );
6854  }
6855 
6856  // Emit the event on the text log port
6857 #if FW_ENABLE_TEXT_LOGGING
6858  if (this->isConnected_logTextOut_OutputPort(0)) {
6859 #if FW_OBJECT_NAMES == 1
6860  const char* _formatString =
6861  "(%s) %s: Received a command response while not running a sequence (was in state %" PRIi32 " opcode was %" PRIu32 " response code %s)";
6862 #else
6863  const char* _formatString =
6864  "%s: Received a command response while not running a sequence (was in state %" PRIi32 " opcode was %" PRIu32 " response code %s)";
6865 #endif
6866 
6867  Fw::String responseStr;
6868  response.toString(responseStr);
6869 
6870  Fw::TextLogString _logString;
6871  (void) _logString.format(
6872  _formatString,
6873 #if FW_OBJECT_NAMES == 1
6874  this->m_objName.toChar(),
6875 #endif
6876  "CmdResponseWhileNotRunningSequence ",
6877  state,
6878  opcode,
6879  responseStr.toChar()
6880  );
6881 
6882  this->logTextOut_out(
6883  0,
6884  _id,
6885  _logTime,
6887  _logString
6888  );
6889  }
6890 #endif
6891  }
6892 
6895  FwOpcodeType opcode,
6896  const Fw::CmdResponse& response,
6897  U16 oldSequenceIdx,
6898  U16 currentSequenceIdx
6899  ) const
6900  {
6901  // Get the time
6902  Fw::Time _logTime;
6903  if (this->isConnected_timeCaller_OutputPort(0)) {
6904  this->timeCaller_out(0, _logTime);
6905  }
6906 
6908 
6909  // Emit the event on the log port
6910  if (this->isConnected_logOut_OutputPort(0)) {
6911  Fw::LogBuffer _logBuff;
6913 
6914 #if FW_AMPCS_COMPATIBLE
6915  // Serialize the number of arguments
6916  _status = _logBuff.serializeFrom(static_cast<U8>(4));
6917  FW_ASSERT(
6918  _status == Fw::FW_SERIALIZE_OK,
6919  static_cast<FwAssertArgType>(_status)
6920  );
6921 #endif
6922 
6923 #if FW_AMPCS_COMPATIBLE
6924  // Serialize the argument size
6925  _status = _logBuff.serializeFrom(
6926  static_cast<U8>(sizeof(FwOpcodeType))
6927  );
6928  FW_ASSERT(
6929  _status == Fw::FW_SERIALIZE_OK,
6930  static_cast<FwAssertArgType>(_status)
6931  );
6932 #endif
6933  _status = _logBuff.serializeFrom(opcode);
6934  FW_ASSERT(
6935  _status == Fw::FW_SERIALIZE_OK,
6936  static_cast<FwAssertArgType>(_status)
6937  );
6938 
6939 #if FW_AMPCS_COMPATIBLE
6940  // Serialize the argument size
6941  _status = _logBuff.serializeFrom(
6942  static_cast<U8>(Fw::CmdResponse::SERIALIZED_SIZE)
6943  );
6944  FW_ASSERT(
6945  _status == Fw::FW_SERIALIZE_OK,
6946  static_cast<FwAssertArgType>(_status)
6947  );
6948 #endif
6949  _status = _logBuff.serializeFrom(response);
6950  FW_ASSERT(
6951  _status == Fw::FW_SERIALIZE_OK,
6952  static_cast<FwAssertArgType>(_status)
6953  );
6954 
6955 #if FW_AMPCS_COMPATIBLE
6956  // Serialize the argument size
6957  _status = _logBuff.serializeFrom(
6958  static_cast<U8>(sizeof(U16))
6959  );
6960  FW_ASSERT(
6961  _status == Fw::FW_SERIALIZE_OK,
6962  static_cast<FwAssertArgType>(_status)
6963  );
6964 #endif
6965  _status = _logBuff.serializeFrom(oldSequenceIdx);
6966  FW_ASSERT(
6967  _status == Fw::FW_SERIALIZE_OK,
6968  static_cast<FwAssertArgType>(_status)
6969  );
6970 
6971 #if FW_AMPCS_COMPATIBLE
6972  // Serialize the argument size
6973  _status = _logBuff.serializeFrom(
6974  static_cast<U8>(sizeof(U16))
6975  );
6976  FW_ASSERT(
6977  _status == Fw::FW_SERIALIZE_OK,
6978  static_cast<FwAssertArgType>(_status)
6979  );
6980 #endif
6981  _status = _logBuff.serializeFrom(currentSequenceIdx);
6982  FW_ASSERT(
6983  _status == Fw::FW_SERIALIZE_OK,
6984  static_cast<FwAssertArgType>(_status)
6985  );
6986 
6987  this->logOut_out(
6988  0,
6989  _id,
6990  _logTime,
6992  _logBuff
6993  );
6994  }
6995 
6996  // Emit the event on the text log port
6997 #if FW_ENABLE_TEXT_LOGGING
6998  if (this->isConnected_logTextOut_OutputPort(0)) {
6999 #if FW_OBJECT_NAMES == 1
7000  const char* _formatString =
7001  "(%s) %s: Received a response from cmd opcode %" PRIu32 " (response %s), but it was from a previous sequence, not the current one (old idx: %" PRIu16 ", current idx: %" PRIu16 ")";
7002 #else
7003  const char* _formatString =
7004  "%s: Received a response from cmd opcode %" PRIu32 " (response %s), but it was from a previous sequence, not the current one (old idx: %" PRIu16 ", current idx: %" PRIu16 ")";
7005 #endif
7006 
7007  Fw::String responseStr;
7008  response.toString(responseStr);
7009 
7010  Fw::TextLogString _logString;
7011  (void) _logString.format(
7012  _formatString,
7013 #if FW_OBJECT_NAMES == 1
7014  this->m_objName.toChar(),
7015 #endif
7016  "CmdResponseFromOldSequence ",
7017  opcode,
7018  responseStr.toChar(),
7019  oldSequenceIdx,
7020  currentSequenceIdx
7021  );
7022 
7023  this->logTextOut_out(
7024  0,
7025  _id,
7026  _logTime,
7028  _logString
7029  );
7030  }
7031 #endif
7032  }
7033 
7036  FwOpcodeType opcode,
7037  const Fw::CmdResponse& response
7038  ) const
7039  {
7040  // Get the time
7041  Fw::Time _logTime;
7042  if (this->isConnected_timeCaller_OutputPort(0)) {
7043  this->timeCaller_out(0, _logTime);
7044  }
7045 
7047 
7048  // Emit the event on the log port
7049  if (this->isConnected_logOut_OutputPort(0)) {
7050  Fw::LogBuffer _logBuff;
7052 
7053 #if FW_AMPCS_COMPATIBLE
7054  // Serialize the number of arguments
7055  _status = _logBuff.serializeFrom(static_cast<U8>(2));
7056  FW_ASSERT(
7057  _status == Fw::FW_SERIALIZE_OK,
7058  static_cast<FwAssertArgType>(_status)
7059  );
7060 #endif
7061 
7062 #if FW_AMPCS_COMPATIBLE
7063  // Serialize the argument size
7064  _status = _logBuff.serializeFrom(
7065  static_cast<U8>(sizeof(FwOpcodeType))
7066  );
7067  FW_ASSERT(
7068  _status == Fw::FW_SERIALIZE_OK,
7069  static_cast<FwAssertArgType>(_status)
7070  );
7071 #endif
7072  _status = _logBuff.serializeFrom(opcode);
7073  FW_ASSERT(
7074  _status == Fw::FW_SERIALIZE_OK,
7075  static_cast<FwAssertArgType>(_status)
7076  );
7077 
7078 #if FW_AMPCS_COMPATIBLE
7079  // Serialize the argument size
7080  _status = _logBuff.serializeFrom(
7081  static_cast<U8>(Fw::CmdResponse::SERIALIZED_SIZE)
7082  );
7083  FW_ASSERT(
7084  _status == Fw::FW_SERIALIZE_OK,
7085  static_cast<FwAssertArgType>(_status)
7086  );
7087 #endif
7088  _status = _logBuff.serializeFrom(response);
7089  FW_ASSERT(
7090  _status == Fw::FW_SERIALIZE_OK,
7091  static_cast<FwAssertArgType>(_status)
7092  );
7093 
7094  this->logOut_out(
7095  0,
7096  _id,
7097  _logTime,
7099  _logBuff
7100  );
7101  }
7102 
7103  // Emit the event on the text log port
7104 #if FW_ENABLE_TEXT_LOGGING
7105  if (this->isConnected_logTextOut_OutputPort(0)) {
7106 #if FW_OBJECT_NAMES == 1
7107  const char* _formatString =
7108  "(%s) %s: Received a response from cmd opcode %" PRIu32 " (response %s) from this sequence, but was not awaiting a response";
7109 #else
7110  const char* _formatString =
7111  "%s: Received a response from cmd opcode %" PRIu32 " (response %s) from this sequence, but was not awaiting a response";
7112 #endif
7113 
7114  Fw::String responseStr;
7115  response.toString(responseStr);
7116 
7117  Fw::TextLogString _logString;
7118  (void) _logString.format(
7119  _formatString,
7120 #if FW_OBJECT_NAMES == 1
7121  this->m_objName.toChar(),
7122 #endif
7123  "CmdResponseWhileNotAwaiting ",
7124  opcode,
7125  responseStr.toChar()
7126  );
7127 
7128  this->logTextOut_out(
7129  0,
7130  _id,
7131  _logTime,
7133  _logString
7134  );
7135  }
7136 #endif
7137  }
7138 
7141  FwOpcodeType opcode,
7142  const Fw::CmdResponse& response,
7143  U8 expectedDirectiveOpcode
7144  ) const
7145  {
7146  // Get the time
7147  Fw::Time _logTime;
7148  if (this->isConnected_timeCaller_OutputPort(0)) {
7149  this->timeCaller_out(0, _logTime);
7150  }
7151 
7153 
7154  // Emit the event on the log port
7155  if (this->isConnected_logOut_OutputPort(0)) {
7156  Fw::LogBuffer _logBuff;
7158 
7159 #if FW_AMPCS_COMPATIBLE
7160  // Serialize the number of arguments
7161  _status = _logBuff.serializeFrom(static_cast<U8>(3));
7162  FW_ASSERT(
7163  _status == Fw::FW_SERIALIZE_OK,
7164  static_cast<FwAssertArgType>(_status)
7165  );
7166 #endif
7167 
7168 #if FW_AMPCS_COMPATIBLE
7169  // Serialize the argument size
7170  _status = _logBuff.serializeFrom(
7171  static_cast<U8>(sizeof(FwOpcodeType))
7172  );
7173  FW_ASSERT(
7174  _status == Fw::FW_SERIALIZE_OK,
7175  static_cast<FwAssertArgType>(_status)
7176  );
7177 #endif
7178  _status = _logBuff.serializeFrom(opcode);
7179  FW_ASSERT(
7180  _status == Fw::FW_SERIALIZE_OK,
7181  static_cast<FwAssertArgType>(_status)
7182  );
7183 
7184 #if FW_AMPCS_COMPATIBLE
7185  // Serialize the argument size
7186  _status = _logBuff.serializeFrom(
7187  static_cast<U8>(Fw::CmdResponse::SERIALIZED_SIZE)
7188  );
7189  FW_ASSERT(
7190  _status == Fw::FW_SERIALIZE_OK,
7191  static_cast<FwAssertArgType>(_status)
7192  );
7193 #endif
7194  _status = _logBuff.serializeFrom(response);
7195  FW_ASSERT(
7196  _status == Fw::FW_SERIALIZE_OK,
7197  static_cast<FwAssertArgType>(_status)
7198  );
7199 
7200 #if FW_AMPCS_COMPATIBLE
7201  // Serialize the argument size
7202  _status = _logBuff.serializeFrom(
7203  static_cast<U8>(sizeof(U8))
7204  );
7205  FW_ASSERT(
7206  _status == Fw::FW_SERIALIZE_OK,
7207  static_cast<FwAssertArgType>(_status)
7208  );
7209 #endif
7210  _status = _logBuff.serializeFrom(expectedDirectiveOpcode);
7211  FW_ASSERT(
7212  _status == Fw::FW_SERIALIZE_OK,
7213  static_cast<FwAssertArgType>(_status)
7214  );
7215 
7216  this->logOut_out(
7217  0,
7218  _id,
7219  _logTime,
7221  _logBuff
7222  );
7223  }
7224 
7225  // Emit the event on the text log port
7226 #if FW_ENABLE_TEXT_LOGGING
7227  if (this->isConnected_logTextOut_OutputPort(0)) {
7228 #if FW_OBJECT_NAMES == 1
7229  const char* _formatString =
7230  "(%s) %s: Received a response from cmd opcode %" PRIu32 " (response %s) from this sequence, but was awaiting directive opcode %" PRIu8 "";
7231 #else
7232  const char* _formatString =
7233  "%s: Received a response from cmd opcode %" PRIu32 " (response %s) from this sequence, but was awaiting directive opcode %" PRIu8 "";
7234 #endif
7235 
7236  Fw::String responseStr;
7237  response.toString(responseStr);
7238 
7239  Fw::TextLogString _logString;
7240  (void) _logString.format(
7241  _formatString,
7242 #if FW_OBJECT_NAMES == 1
7243  this->m_objName.toChar(),
7244 #endif
7245  "CmdResponseWhileAwaitingDirective ",
7246  opcode,
7247  responseStr.toChar(),
7248  expectedDirectiveOpcode
7249  );
7250 
7251  this->logTextOut_out(
7252  0,
7253  _id,
7254  _logTime,
7256  _logString
7257  );
7258  }
7259 #endif
7260  }
7261 
7264  FwOpcodeType opcode,
7265  const Fw::CmdResponse& response,
7266  FwOpcodeType expectedOpcode
7267  ) const
7268  {
7269  // Get the time
7270  Fw::Time _logTime;
7271  if (this->isConnected_timeCaller_OutputPort(0)) {
7272  this->timeCaller_out(0, _logTime);
7273  }
7274 
7276 
7277  // Emit the event on the log port
7278  if (this->isConnected_logOut_OutputPort(0)) {
7279  Fw::LogBuffer _logBuff;
7281 
7282 #if FW_AMPCS_COMPATIBLE
7283  // Serialize the number of arguments
7284  _status = _logBuff.serializeFrom(static_cast<U8>(3));
7285  FW_ASSERT(
7286  _status == Fw::FW_SERIALIZE_OK,
7287  static_cast<FwAssertArgType>(_status)
7288  );
7289 #endif
7290 
7291 #if FW_AMPCS_COMPATIBLE
7292  // Serialize the argument size
7293  _status = _logBuff.serializeFrom(
7294  static_cast<U8>(sizeof(FwOpcodeType))
7295  );
7296  FW_ASSERT(
7297  _status == Fw::FW_SERIALIZE_OK,
7298  static_cast<FwAssertArgType>(_status)
7299  );
7300 #endif
7301  _status = _logBuff.serializeFrom(opcode);
7302  FW_ASSERT(
7303  _status == Fw::FW_SERIALIZE_OK,
7304  static_cast<FwAssertArgType>(_status)
7305  );
7306 
7307 #if FW_AMPCS_COMPATIBLE
7308  // Serialize the argument size
7309  _status = _logBuff.serializeFrom(
7310  static_cast<U8>(Fw::CmdResponse::SERIALIZED_SIZE)
7311  );
7312  FW_ASSERT(
7313  _status == Fw::FW_SERIALIZE_OK,
7314  static_cast<FwAssertArgType>(_status)
7315  );
7316 #endif
7317  _status = _logBuff.serializeFrom(response);
7318  FW_ASSERT(
7319  _status == Fw::FW_SERIALIZE_OK,
7320  static_cast<FwAssertArgType>(_status)
7321  );
7322 
7323 #if FW_AMPCS_COMPATIBLE
7324  // Serialize the argument size
7325  _status = _logBuff.serializeFrom(
7326  static_cast<U8>(sizeof(FwOpcodeType))
7327  );
7328  FW_ASSERT(
7329  _status == Fw::FW_SERIALIZE_OK,
7330  static_cast<FwAssertArgType>(_status)
7331  );
7332 #endif
7333  _status = _logBuff.serializeFrom(expectedOpcode);
7334  FW_ASSERT(
7335  _status == Fw::FW_SERIALIZE_OK,
7336  static_cast<FwAssertArgType>(_status)
7337  );
7338 
7339  this->logOut_out(
7340  0,
7341  _id,
7342  _logTime,
7344  _logBuff
7345  );
7346  }
7347 
7348  // Emit the event on the text log port
7349 #if FW_ENABLE_TEXT_LOGGING
7350  if (this->isConnected_logTextOut_OutputPort(0)) {
7351 #if FW_OBJECT_NAMES == 1
7352  const char* _formatString =
7353  "(%s) %s: Received a response from cmd opcode %" PRIu32 " (response %s) from this sequence, but was expecting a response from command opcode %" PRIu32 "";
7354 #else
7355  const char* _formatString =
7356  "%s: Received a response from cmd opcode %" PRIu32 " (response %s) from this sequence, but was expecting a response from command opcode %" PRIu32 "";
7357 #endif
7358 
7359  Fw::String responseStr;
7360  response.toString(responseStr);
7361 
7362  Fw::TextLogString _logString;
7363  (void) _logString.format(
7364  _formatString,
7365 #if FW_OBJECT_NAMES == 1
7366  this->m_objName.toChar(),
7367 #endif
7368  "WrongCmdResponseOpcode ",
7369  opcode,
7370  responseStr.toChar(),
7371  expectedOpcode
7372  );
7373 
7374  this->logTextOut_out(
7375  0,
7376  _id,
7377  _logTime,
7379  _logString
7380  );
7381  }
7382 #endif
7383  }
7384 
7387  FwOpcodeType opcode,
7388  const Fw::CmdResponse& response,
7389  U16 actualCmdIdx,
7390  U16 expectedCmdIdx
7391  ) const
7392  {
7393  // Get the time
7394  Fw::Time _logTime;
7395  if (this->isConnected_timeCaller_OutputPort(0)) {
7396  this->timeCaller_out(0, _logTime);
7397  }
7398 
7400 
7401  // Emit the event on the log port
7402  if (this->isConnected_logOut_OutputPort(0)) {
7403  Fw::LogBuffer _logBuff;
7405 
7406 #if FW_AMPCS_COMPATIBLE
7407  // Serialize the number of arguments
7408  _status = _logBuff.serializeFrom(static_cast<U8>(4));
7409  FW_ASSERT(
7410  _status == Fw::FW_SERIALIZE_OK,
7411  static_cast<FwAssertArgType>(_status)
7412  );
7413 #endif
7414 
7415 #if FW_AMPCS_COMPATIBLE
7416  // Serialize the argument size
7417  _status = _logBuff.serializeFrom(
7418  static_cast<U8>(sizeof(FwOpcodeType))
7419  );
7420  FW_ASSERT(
7421  _status == Fw::FW_SERIALIZE_OK,
7422  static_cast<FwAssertArgType>(_status)
7423  );
7424 #endif
7425  _status = _logBuff.serializeFrom(opcode);
7426  FW_ASSERT(
7427  _status == Fw::FW_SERIALIZE_OK,
7428  static_cast<FwAssertArgType>(_status)
7429  );
7430 
7431 #if FW_AMPCS_COMPATIBLE
7432  // Serialize the argument size
7433  _status = _logBuff.serializeFrom(
7434  static_cast<U8>(Fw::CmdResponse::SERIALIZED_SIZE)
7435  );
7436  FW_ASSERT(
7437  _status == Fw::FW_SERIALIZE_OK,
7438  static_cast<FwAssertArgType>(_status)
7439  );
7440 #endif
7441  _status = _logBuff.serializeFrom(response);
7442  FW_ASSERT(
7443  _status == Fw::FW_SERIALIZE_OK,
7444  static_cast<FwAssertArgType>(_status)
7445  );
7446 
7447 #if FW_AMPCS_COMPATIBLE
7448  // Serialize the argument size
7449  _status = _logBuff.serializeFrom(
7450  static_cast<U8>(sizeof(U16))
7451  );
7452  FW_ASSERT(
7453  _status == Fw::FW_SERIALIZE_OK,
7454  static_cast<FwAssertArgType>(_status)
7455  );
7456 #endif
7457  _status = _logBuff.serializeFrom(actualCmdIdx);
7458  FW_ASSERT(
7459  _status == Fw::FW_SERIALIZE_OK,
7460  static_cast<FwAssertArgType>(_status)
7461  );
7462 
7463 #if FW_AMPCS_COMPATIBLE
7464  // Serialize the argument size
7465  _status = _logBuff.serializeFrom(
7466  static_cast<U8>(sizeof(U16))
7467  );
7468  FW_ASSERT(
7469  _status == Fw::FW_SERIALIZE_OK,
7470  static_cast<FwAssertArgType>(_status)
7471  );
7472 #endif
7473  _status = _logBuff.serializeFrom(expectedCmdIdx);
7474  FW_ASSERT(
7475  _status == Fw::FW_SERIALIZE_OK,
7476  static_cast<FwAssertArgType>(_status)
7477  );
7478 
7479  this->logOut_out(
7480  0,
7481  _id,
7482  _logTime,
7484  _logBuff
7485  );
7486  }
7487 
7488  // Emit the event on the text log port
7489 #if FW_ENABLE_TEXT_LOGGING
7490  if (this->isConnected_logTextOut_OutputPort(0)) {
7491 #if FW_OBJECT_NAMES == 1
7492  const char* _formatString =
7493  "(%s) %s: Received a response from the correct cmd (opcode %" PRIu32 " response %s), but it was for a different instance of that opcode in the same sequence (actual idx %" PRIu16 " expected %" PRIu16 ")";
7494 #else
7495  const char* _formatString =
7496  "%s: Received a response from the correct cmd (opcode %" PRIu32 " response %s), but it was for a different instance of that opcode in the same sequence (actual idx %" PRIu16 " expected %" PRIu16 ")";
7497 #endif
7498 
7499  Fw::String responseStr;
7500  response.toString(responseStr);
7501 
7502  Fw::TextLogString _logString;
7503  (void) _logString.format(
7504  _formatString,
7505 #if FW_OBJECT_NAMES == 1
7506  this->m_objName.toChar(),
7507 #endif
7508  "WrongCmdResponseIndex ",
7509  opcode,
7510  responseStr.toChar(),
7511  actualCmdIdx,
7512  expectedCmdIdx
7513  );
7514 
7515  this->logTextOut_out(
7516  0,
7517  _id,
7518  _logTime,
7520  _logString
7521  );
7522  }
7523 #endif
7524  }
7525 
7528  U8 opcode,
7529  U32 stmtIdx,
7530  I32 errorCode,
7531  U64 buffLeft,
7532  U64 buffLength
7533  ) const
7534  {
7535  // Get the time
7536  Fw::Time _logTime;
7537  if (this->isConnected_timeCaller_OutputPort(0)) {
7538  this->timeCaller_out(0, _logTime);
7539  }
7540 
7542 
7543  // Emit the event on the log port
7544  if (this->isConnected_logOut_OutputPort(0)) {
7545  Fw::LogBuffer _logBuff;
7547 
7548 #if FW_AMPCS_COMPATIBLE
7549  // Serialize the number of arguments
7550  _status = _logBuff.serializeFrom(static_cast<U8>(5));
7551  FW_ASSERT(
7552  _status == Fw::FW_SERIALIZE_OK,
7553  static_cast<FwAssertArgType>(_status)
7554  );
7555 #endif
7556 
7557 #if FW_AMPCS_COMPATIBLE
7558  // Serialize the argument size
7559  _status = _logBuff.serializeFrom(
7560  static_cast<U8>(sizeof(U8))
7561  );
7562  FW_ASSERT(
7563  _status == Fw::FW_SERIALIZE_OK,
7564  static_cast<FwAssertArgType>(_status)
7565  );
7566 #endif
7567  _status = _logBuff.serializeFrom(opcode);
7568  FW_ASSERT(
7569  _status == Fw::FW_SERIALIZE_OK,
7570  static_cast<FwAssertArgType>(_status)
7571  );
7572 
7573 #if FW_AMPCS_COMPATIBLE
7574  // Serialize the argument size
7575  _status = _logBuff.serializeFrom(
7576  static_cast<U8>(sizeof(U32))
7577  );
7578  FW_ASSERT(
7579  _status == Fw::FW_SERIALIZE_OK,
7580  static_cast<FwAssertArgType>(_status)
7581  );
7582 #endif
7583  _status = _logBuff.serializeFrom(stmtIdx);
7584  FW_ASSERT(
7585  _status == Fw::FW_SERIALIZE_OK,
7586  static_cast<FwAssertArgType>(_status)
7587  );
7588 
7589 #if FW_AMPCS_COMPATIBLE
7590  // Serialize the argument size
7591  _status = _logBuff.serializeFrom(
7592  static_cast<U8>(sizeof(I32))
7593  );
7594  FW_ASSERT(
7595  _status == Fw::FW_SERIALIZE_OK,
7596  static_cast<FwAssertArgType>(_status)
7597  );
7598 #endif
7599  _status = _logBuff.serializeFrom(errorCode);
7600  FW_ASSERT(
7601  _status == Fw::FW_SERIALIZE_OK,
7602  static_cast<FwAssertArgType>(_status)
7603  );
7604 
7605 #if FW_AMPCS_COMPATIBLE
7606  // Serialize the argument size
7607  _status = _logBuff.serializeFrom(
7608  static_cast<U8>(sizeof(U64))
7609  );
7610  FW_ASSERT(
7611  _status == Fw::FW_SERIALIZE_OK,
7612  static_cast<FwAssertArgType>(_status)
7613  );
7614 #endif
7615  _status = _logBuff.serializeFrom(buffLeft);
7616  FW_ASSERT(
7617  _status == Fw::FW_SERIALIZE_OK,
7618  static_cast<FwAssertArgType>(_status)
7619  );
7620 
7621 #if FW_AMPCS_COMPATIBLE
7622  // Serialize the argument size
7623  _status = _logBuff.serializeFrom(
7624  static_cast<U8>(sizeof(U64))
7625  );
7626  FW_ASSERT(
7627  _status == Fw::FW_SERIALIZE_OK,
7628  static_cast<FwAssertArgType>(_status)
7629  );
7630 #endif
7631  _status = _logBuff.serializeFrom(buffLength);
7632  FW_ASSERT(
7633  _status == Fw::FW_SERIALIZE_OK,
7634  static_cast<FwAssertArgType>(_status)
7635  );
7636 
7637  this->logOut_out(
7638  0,
7639  _id,
7640  _logTime,
7642  _logBuff
7643  );
7644  }
7645 
7646  // Emit the event on the text log port
7647 #if FW_ENABLE_TEXT_LOGGING
7648  if (this->isConnected_logTextOut_OutputPort(0)) {
7649 #if FW_OBJECT_NAMES == 1
7650  const char* _formatString =
7651  "(%s) %s: Deserialize error encountered while reading directive opcode %" PRIu8 " at index %" PRIu32 ": %" PRIi32 " (%" PRIu64 " bytes left out of %" PRIu64 ")";
7652 #else
7653  const char* _formatString =
7654  "%s: Deserialize error encountered while reading directive opcode %" PRIu8 " at index %" PRIu32 ": %" PRIi32 " (%" PRIu64 " bytes left out of %" PRIu64 ")";
7655 #endif
7656 
7657  Fw::TextLogString _logString;
7658  (void) _logString.format(
7659  _formatString,
7660 #if FW_OBJECT_NAMES == 1
7661  this->m_objName.toChar(),
7662 #endif
7663  "DirectiveDeserializeError ",
7664  opcode,
7665  stmtIdx,
7666  errorCode,
7667  buffLeft,
7668  buffLength
7669  );
7670 
7671  this->logTextOut_out(
7672  0,
7673  _id,
7674  _logTime,
7676  _logString
7677  );
7678  }
7679 #endif
7680  }
7681 
7684  I32 internalTimeBase,
7685  I32 otherTimeBase
7686  ) const
7687  {
7688  // Get the time
7689  Fw::Time _logTime;
7690  if (this->isConnected_timeCaller_OutputPort(0)) {
7691  this->timeCaller_out(0, _logTime);
7692  }
7693 
7694  const FwEventIdType _id = this->getIdBase() + EVENTID_MISMATCHEDTIMEBASE;
7695 
7696  // Emit the event on the log port
7697  if (this->isConnected_logOut_OutputPort(0)) {
7698  Fw::LogBuffer _logBuff;
7700 
7701 #if FW_AMPCS_COMPATIBLE
7702  // Serialize the number of arguments
7703  _status = _logBuff.serializeFrom(static_cast<U8>(2));
7704  FW_ASSERT(
7705  _status == Fw::FW_SERIALIZE_OK,
7706  static_cast<FwAssertArgType>(_status)
7707  );
7708 #endif
7709 
7710 #if FW_AMPCS_COMPATIBLE
7711  // Serialize the argument size
7712  _status = _logBuff.serializeFrom(
7713  static_cast<U8>(sizeof(I32))
7714  );
7715  FW_ASSERT(
7716  _status == Fw::FW_SERIALIZE_OK,
7717  static_cast<FwAssertArgType>(_status)
7718  );
7719 #endif
7720  _status = _logBuff.serializeFrom(internalTimeBase);
7721  FW_ASSERT(
7722  _status == Fw::FW_SERIALIZE_OK,
7723  static_cast<FwAssertArgType>(_status)
7724  );
7725 
7726 #if FW_AMPCS_COMPATIBLE
7727  // Serialize the argument size
7728  _status = _logBuff.serializeFrom(
7729  static_cast<U8>(sizeof(I32))
7730  );
7731  FW_ASSERT(
7732  _status == Fw::FW_SERIALIZE_OK,
7733  static_cast<FwAssertArgType>(_status)
7734  );
7735 #endif
7736  _status = _logBuff.serializeFrom(otherTimeBase);
7737  FW_ASSERT(
7738  _status == Fw::FW_SERIALIZE_OK,
7739  static_cast<FwAssertArgType>(_status)
7740  );
7741 
7742  this->logOut_out(
7743  0,
7744  _id,
7745  _logTime,
7747  _logBuff
7748  );
7749  }
7750 
7751  // Emit the event on the text log port
7752 #if FW_ENABLE_TEXT_LOGGING
7753  if (this->isConnected_logTextOut_OutputPort(0)) {
7754 #if FW_OBJECT_NAMES == 1
7755  const char* _formatString =
7756  "(%s) %s: getTime() time base was %" PRIi32 ", but tried to operate on it with time base %" PRIi32 "";
7757 #else
7758  const char* _formatString =
7759  "%s: getTime() time base was %" PRIi32 ", but tried to operate on it with time base %" PRIi32 "";
7760 #endif
7761 
7762  Fw::TextLogString _logString;
7763  (void) _logString.format(
7764  _formatString,
7765 #if FW_OBJECT_NAMES == 1
7766  this->m_objName.toChar(),
7767 #endif
7768  "MismatchedTimeBase ",
7769  internalTimeBase,
7770  otherTimeBase
7771  );
7772 
7773  this->logTextOut_out(
7774  0,
7775  _id,
7776  _logTime,
7778  _logString
7779  );
7780  }
7781 #endif
7782  }
7783 
7786  I32 internalTimeContext,
7787  I32 otherTimeContext
7788  ) const
7789  {
7790  // Get the time
7791  Fw::Time _logTime;
7792  if (this->isConnected_timeCaller_OutputPort(0)) {
7793  this->timeCaller_out(0, _logTime);
7794  }
7795 
7797 
7798  // Emit the event on the log port
7799  if (this->isConnected_logOut_OutputPort(0)) {
7800  Fw::LogBuffer _logBuff;
7802 
7803 #if FW_AMPCS_COMPATIBLE
7804  // Serialize the number of arguments
7805  _status = _logBuff.serializeFrom(static_cast<U8>(2));
7806  FW_ASSERT(
7807  _status == Fw::FW_SERIALIZE_OK,
7808  static_cast<FwAssertArgType>(_status)
7809  );
7810 #endif
7811 
7812 #if FW_AMPCS_COMPATIBLE
7813  // Serialize the argument size
7814  _status = _logBuff.serializeFrom(
7815  static_cast<U8>(sizeof(I32))
7816  );
7817  FW_ASSERT(
7818  _status == Fw::FW_SERIALIZE_OK,
7819  static_cast<FwAssertArgType>(_status)
7820  );
7821 #endif
7822  _status = _logBuff.serializeFrom(internalTimeContext);
7823  FW_ASSERT(
7824  _status == Fw::FW_SERIALIZE_OK,
7825  static_cast<FwAssertArgType>(_status)
7826  );
7827 
7828 #if FW_AMPCS_COMPATIBLE
7829  // Serialize the argument size
7830  _status = _logBuff.serializeFrom(
7831  static_cast<U8>(sizeof(I32))
7832  );
7833  FW_ASSERT(
7834  _status == Fw::FW_SERIALIZE_OK,
7835  static_cast<FwAssertArgType>(_status)
7836  );
7837 #endif
7838  _status = _logBuff.serializeFrom(otherTimeContext);
7839  FW_ASSERT(
7840  _status == Fw::FW_SERIALIZE_OK,
7841  static_cast<FwAssertArgType>(_status)
7842  );
7843 
7844  this->logOut_out(
7845  0,
7846  _id,
7847  _logTime,
7849  _logBuff
7850  );
7851  }
7852 
7853  // Emit the event on the text log port
7854 #if FW_ENABLE_TEXT_LOGGING
7855  if (this->isConnected_logTextOut_OutputPort(0)) {
7856 #if FW_OBJECT_NAMES == 1
7857  const char* _formatString =
7858  "(%s) %s: getTime() time context was %" PRIi32 ", but tried to operate on it with time context %" PRIi32 "";
7859 #else
7860  const char* _formatString =
7861  "%s: getTime() time context was %" PRIi32 ", but tried to operate on it with time context %" PRIi32 "";
7862 #endif
7863 
7864  Fw::TextLogString _logString;
7865  (void) _logString.format(
7866  _formatString,
7867 #if FW_OBJECT_NAMES == 1
7868  this->m_objName.toChar(),
7869 #endif
7870  "MismatchedTimeContext ",
7871  internalTimeContext,
7872  otherTimeContext
7873  );
7874 
7875  this->logTextOut_out(
7876  0,
7877  _id,
7878  _logTime,
7880  _logString
7881  );
7882  }
7883 #endif
7884  }
7885 
7888  FwOpcodeType opCode,
7889  U32 stmtIdx,
7890  const Fw::StringBase& filePath
7891  ) const
7892  {
7893  // Get the time
7894  Fw::Time _logTime;
7895  if (this->isConnected_timeCaller_OutputPort(0)) {
7896  this->timeCaller_out(0, _logTime);
7897  }
7898 
7899  const FwEventIdType _id = this->getIdBase() + EVENTID_COMMANDTIMEDOUT;
7900 
7901  // Emit the event on the log port
7902  if (this->isConnected_logOut_OutputPort(0)) {
7903  Fw::LogBuffer _logBuff;
7905 
7906 #if FW_AMPCS_COMPATIBLE
7907  // Serialize the number of arguments
7908  _status = _logBuff.serializeFrom(static_cast<U8>(3));
7909  FW_ASSERT(
7910  _status == Fw::FW_SERIALIZE_OK,
7911  static_cast<FwAssertArgType>(_status)
7912  );
7913 #endif
7914 
7915 #if FW_AMPCS_COMPATIBLE
7916  // Serialize the argument size
7917  _status = _logBuff.serializeFrom(
7918  static_cast<U8>(sizeof(FwOpcodeType))
7919  );
7920  FW_ASSERT(
7921  _status == Fw::FW_SERIALIZE_OK,
7922  static_cast<FwAssertArgType>(_status)
7923  );
7924 #endif
7925  _status = _logBuff.serializeFrom(opCode);
7926  FW_ASSERT(
7927  _status == Fw::FW_SERIALIZE_OK,
7928  static_cast<FwAssertArgType>(_status)
7929  );
7930 
7931 #if FW_AMPCS_COMPATIBLE
7932  // Serialize the argument size
7933  _status = _logBuff.serializeFrom(
7934  static_cast<U8>(sizeof(U32))
7935  );
7936  FW_ASSERT(
7937  _status == Fw::FW_SERIALIZE_OK,
7938  static_cast<FwAssertArgType>(_status)
7939  );
7940 #endif
7941  _status = _logBuff.serializeFrom(stmtIdx);
7942  FW_ASSERT(
7943  _status == Fw::FW_SERIALIZE_OK,
7944  static_cast<FwAssertArgType>(_status)
7945  );
7946 
7947  _status = filePath.serializeTo(
7948  _logBuff,
7949  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
7950  );
7951  FW_ASSERT(
7952  _status == Fw::FW_SERIALIZE_OK,
7953  static_cast<FwAssertArgType>(_status)
7954  );
7955 
7956  this->logOut_out(
7957  0,
7958  _id,
7959  _logTime,
7961  _logBuff
7962  );
7963  }
7964 
7965  // Emit the event on the text log port
7966 #if FW_ENABLE_TEXT_LOGGING
7967  if (this->isConnected_logTextOut_OutputPort(0)) {
7968 #if FW_OBJECT_NAMES == 1
7969  const char* _formatString =
7970  "(%s) %s: A command opcode %" PRIu32 " at index %" PRIu32 " timed out in sequence %s, causing the sequence to fail";
7971 #else
7972  const char* _formatString =
7973  "%s: A command opcode %" PRIu32 " at index %" PRIu32 " timed out in sequence %s, causing the sequence to fail";
7974 #endif
7975 
7976  Fw::TextLogString _logString;
7977  (void) _logString.format(
7978  _formatString,
7979 #if FW_OBJECT_NAMES == 1
7980  this->m_objName.toChar(),
7981 #endif
7982  "CommandTimedOut ",
7983  opCode,
7984  stmtIdx,
7985  filePath.toChar()
7986  );
7987 
7988  this->logTextOut_out(
7989  0,
7990  _id,
7991  _logTime,
7993  _logString
7994  );
7995  }
7996 #endif
7997  }
7998 
8001  U8 opCode,
8002  U32 stmtIdx,
8003  const Fw::StringBase& filePath
8004  ) const
8005  {
8006  // Get the time
8007  Fw::Time _logTime;
8008  if (this->isConnected_timeCaller_OutputPort(0)) {
8009  this->timeCaller_out(0, _logTime);
8010  }
8011 
8012  const FwEventIdType _id = this->getIdBase() + EVENTID_DIRECTIVETIMEDOUT;
8013 
8014  // Emit the event on the log port
8015  if (this->isConnected_logOut_OutputPort(0)) {
8016  Fw::LogBuffer _logBuff;
8018 
8019 #if FW_AMPCS_COMPATIBLE
8020  // Serialize the number of arguments
8021  _status = _logBuff.serializeFrom(static_cast<U8>(3));
8022  FW_ASSERT(
8023  _status == Fw::FW_SERIALIZE_OK,
8024  static_cast<FwAssertArgType>(_status)
8025  );
8026 #endif
8027 
8028 #if FW_AMPCS_COMPATIBLE
8029  // Serialize the argument size
8030  _status = _logBuff.serializeFrom(
8031  static_cast<U8>(sizeof(U8))
8032  );
8033  FW_ASSERT(
8034  _status == Fw::FW_SERIALIZE_OK,
8035  static_cast<FwAssertArgType>(_status)
8036  );
8037 #endif
8038  _status = _logBuff.serializeFrom(opCode);
8039  FW_ASSERT(
8040  _status == Fw::FW_SERIALIZE_OK,
8041  static_cast<FwAssertArgType>(_status)
8042  );
8043 
8044 #if FW_AMPCS_COMPATIBLE
8045  // Serialize the argument size
8046  _status = _logBuff.serializeFrom(
8047  static_cast<U8>(sizeof(U32))
8048  );
8049  FW_ASSERT(
8050  _status == Fw::FW_SERIALIZE_OK,
8051  static_cast<FwAssertArgType>(_status)
8052  );
8053 #endif
8054  _status = _logBuff.serializeFrom(stmtIdx);
8055  FW_ASSERT(
8056  _status == Fw::FW_SERIALIZE_OK,
8057  static_cast<FwAssertArgType>(_status)
8058  );
8059 
8060  _status = filePath.serializeTo(
8061  _logBuff,
8062  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
8063  );
8064  FW_ASSERT(
8065  _status == Fw::FW_SERIALIZE_OK,
8066  static_cast<FwAssertArgType>(_status)
8067  );
8068 
8069  this->logOut_out(
8070  0,
8071  _id,
8072  _logTime,
8074  _logBuff
8075  );
8076  }
8077 
8078  // Emit the event on the text log port
8079 #if FW_ENABLE_TEXT_LOGGING
8080  if (this->isConnected_logTextOut_OutputPort(0)) {
8081 #if FW_OBJECT_NAMES == 1
8082  const char* _formatString =
8083  "(%s) %s: A directive opcode %" PRIu8 " at index %" PRIu32 " timed out in sequence %s, causing the sequence to fail";
8084 #else
8085  const char* _formatString =
8086  "%s: A directive opcode %" PRIu8 " at index %" PRIu32 " timed out in sequence %s, causing the sequence to fail";
8087 #endif
8088 
8089  Fw::TextLogString _logString;
8090  (void) _logString.format(
8091  _formatString,
8092 #if FW_OBJECT_NAMES == 1
8093  this->m_objName.toChar(),
8094 #endif
8095  "DirectiveTimedOut ",
8096  opCode,
8097  stmtIdx,
8098  filePath.toChar()
8099  );
8100 
8101  this->logTextOut_out(
8102  0,
8103  _id,
8104  _logTime,
8106  _logString
8107  );
8108  }
8109 #endif
8110  }
8111 
8114  U8 count,
8115  U8 max
8116  ) const
8117  {
8118  // Get the time
8119  Fw::Time _logTime;
8120  if (this->isConnected_timeCaller_OutputPort(0)) {
8121  this->timeCaller_out(0, _logTime);
8122  }
8123 
8124  const FwEventIdType _id = this->getIdBase() + EVENTID_TOOMANYSEQUENCEARGS;
8125 
8126  // Emit the event on the log port
8127  if (this->isConnected_logOut_OutputPort(0)) {
8128  Fw::LogBuffer _logBuff;
8130 
8131 #if FW_AMPCS_COMPATIBLE
8132  // Serialize the number of arguments
8133  _status = _logBuff.serializeFrom(static_cast<U8>(2));
8134  FW_ASSERT(
8135  _status == Fw::FW_SERIALIZE_OK,
8136  static_cast<FwAssertArgType>(_status)
8137  );
8138 #endif
8139 
8140 #if FW_AMPCS_COMPATIBLE
8141  // Serialize the argument size
8142  _status = _logBuff.serializeFrom(
8143  static_cast<U8>(sizeof(U8))
8144  );
8145  FW_ASSERT(
8146  _status == Fw::FW_SERIALIZE_OK,
8147  static_cast<FwAssertArgType>(_status)
8148  );
8149 #endif
8150  _status = _logBuff.serializeFrom(count);
8151  FW_ASSERT(
8152  _status == Fw::FW_SERIALIZE_OK,
8153  static_cast<FwAssertArgType>(_status)
8154  );
8155 
8156 #if FW_AMPCS_COMPATIBLE
8157  // Serialize the argument size
8158  _status = _logBuff.serializeFrom(
8159  static_cast<U8>(sizeof(U8))
8160  );
8161  FW_ASSERT(
8162  _status == Fw::FW_SERIALIZE_OK,
8163  static_cast<FwAssertArgType>(_status)
8164  );
8165 #endif
8166  _status = _logBuff.serializeFrom(max);
8167  FW_ASSERT(
8168  _status == Fw::FW_SERIALIZE_OK,
8169  static_cast<FwAssertArgType>(_status)
8170  );
8171 
8172  this->logOut_out(
8173  0,
8174  _id,
8175  _logTime,
8177  _logBuff
8178  );
8179  }
8180 
8181  // Emit the event on the text log port
8182 #if FW_ENABLE_TEXT_LOGGING
8183  if (this->isConnected_logTextOut_OutputPort(0)) {
8184 #if FW_OBJECT_NAMES == 1
8185  const char* _formatString =
8186  "(%s) %s: A sequence specified it had %" PRIu8 " args but the max was %" PRIu8 "";
8187 #else
8188  const char* _formatString =
8189  "%s: A sequence specified it had %" PRIu8 " args but the max was %" PRIu8 "";
8190 #endif
8191 
8192  Fw::TextLogString _logString;
8193  (void) _logString.format(
8194  _formatString,
8195 #if FW_OBJECT_NAMES == 1
8196  this->m_objName.toChar(),
8197 #endif
8198  "TooManySequenceArgs ",
8199  count,
8200  max
8201  );
8202 
8203  this->logTextOut_out(
8204  0,
8205  _id,
8206  _logTime,
8208  _logString
8209  );
8210  }
8211 #endif
8212  }
8213 
8216  U16 count,
8217  U16 max
8218  ) const
8219  {
8220  // Get the time
8221  Fw::Time _logTime;
8222  if (this->isConnected_timeCaller_OutputPort(0)) {
8223  this->timeCaller_out(0, _logTime);
8224  }
8225 
8227 
8228  // Emit the event on the log port
8229  if (this->isConnected_logOut_OutputPort(0)) {
8230  Fw::LogBuffer _logBuff;
8232 
8233 #if FW_AMPCS_COMPATIBLE
8234  // Serialize the number of arguments
8235  _status = _logBuff.serializeFrom(static_cast<U8>(2));
8236  FW_ASSERT(
8237  _status == Fw::FW_SERIALIZE_OK,
8238  static_cast<FwAssertArgType>(_status)
8239  );
8240 #endif
8241 
8242 #if FW_AMPCS_COMPATIBLE
8243  // Serialize the argument size
8244  _status = _logBuff.serializeFrom(
8245  static_cast<U8>(sizeof(U16))
8246  );
8247  FW_ASSERT(
8248  _status == Fw::FW_SERIALIZE_OK,
8249  static_cast<FwAssertArgType>(_status)
8250  );
8251 #endif
8252  _status = _logBuff.serializeFrom(count);
8253  FW_ASSERT(
8254  _status == Fw::FW_SERIALIZE_OK,
8255  static_cast<FwAssertArgType>(_status)
8256  );
8257 
8258 #if FW_AMPCS_COMPATIBLE
8259  // Serialize the argument size
8260  _status = _logBuff.serializeFrom(
8261  static_cast<U8>(sizeof(U16))
8262  );
8263  FW_ASSERT(
8264  _status == Fw::FW_SERIALIZE_OK,
8265  static_cast<FwAssertArgType>(_status)
8266  );
8267 #endif
8268  _status = _logBuff.serializeFrom(max);
8269  FW_ASSERT(
8270  _status == Fw::FW_SERIALIZE_OK,
8271  static_cast<FwAssertArgType>(_status)
8272  );
8273 
8274  this->logOut_out(
8275  0,
8276  _id,
8277  _logTime,
8279  _logBuff
8280  );
8281  }
8282 
8283  // Emit the event on the text log port
8284 #if FW_ENABLE_TEXT_LOGGING
8285  if (this->isConnected_logTextOut_OutputPort(0)) {
8286 #if FW_OBJECT_NAMES == 1
8287  const char* _formatString =
8288  "(%s) %s: A sequence specified it had %" PRIu16 " directives but the max was %" PRIu16 "";
8289 #else
8290  const char* _formatString =
8291  "%s: A sequence specified it had %" PRIu16 " directives but the max was %" PRIu16 "";
8292 #endif
8293 
8294  Fw::TextLogString _logString;
8295  (void) _logString.format(
8296  _formatString,
8297 #if FW_OBJECT_NAMES == 1
8298  this->m_objName.toChar(),
8299 #endif
8300  "TooManySequenceDirectives ",
8301  count,
8302  max
8303  );
8304 
8305  this->logTextOut_out(
8306  0,
8307  _id,
8308  _logTime,
8310  _logString
8311  );
8312  }
8313 #endif
8314  }
8315 
8318  Svc::Fpy::StackSizeType expected,
8319  FwSizeType actual,
8320  const Fw::StringBase& filePath
8321  ) const
8322  {
8323  // Get the time
8324  Fw::Time _logTime;
8325  if (this->isConnected_timeCaller_OutputPort(0)) {
8326  this->timeCaller_out(0, _logTime);
8327  }
8328 
8329  const FwEventIdType _id = this->getIdBase() + EVENTID_ARGSIZEMISMATCH;
8330 
8331  // Emit the event on the log port
8332  if (this->isConnected_logOut_OutputPort(0)) {
8333  Fw::LogBuffer _logBuff;
8335 
8336 #if FW_AMPCS_COMPATIBLE
8337  // Serialize the number of arguments
8338  _status = _logBuff.serializeFrom(static_cast<U8>(3));
8339  FW_ASSERT(
8340  _status == Fw::FW_SERIALIZE_OK,
8341  static_cast<FwAssertArgType>(_status)
8342  );
8343 #endif
8344 
8345 #if FW_AMPCS_COMPATIBLE
8346  // Serialize the argument size
8347  _status = _logBuff.serializeFrom(
8348  static_cast<U8>(sizeof(Svc::Fpy::StackSizeType))
8349  );
8350  FW_ASSERT(
8351  _status == Fw::FW_SERIALIZE_OK,
8352  static_cast<FwAssertArgType>(_status)
8353  );
8354 #endif
8355  _status = _logBuff.serializeFrom(expected);
8356  FW_ASSERT(
8357  _status == Fw::FW_SERIALIZE_OK,
8358  static_cast<FwAssertArgType>(_status)
8359  );
8360 
8361 #if FW_AMPCS_COMPATIBLE
8362  // Serialize the argument size
8363  _status = _logBuff.serializeFrom(
8364  static_cast<U8>(sizeof(FwSizeType))
8365  );
8366  FW_ASSERT(
8367  _status == Fw::FW_SERIALIZE_OK,
8368  static_cast<FwAssertArgType>(_status)
8369  );
8370 #endif
8371  _status = _logBuff.serializeFrom(actual);
8372  FW_ASSERT(
8373  _status == Fw::FW_SERIALIZE_OK,
8374  static_cast<FwAssertArgType>(_status)
8375  );
8376 
8377  _status = filePath.serializeTo(
8378  _logBuff,
8379  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
8380  );
8381  FW_ASSERT(
8382  _status == Fw::FW_SERIALIZE_OK,
8383  static_cast<FwAssertArgType>(_status)
8384  );
8385 
8386  this->logOut_out(
8387  0,
8388  _id,
8389  _logTime,
8391  _logBuff
8392  );
8393  }
8394 
8395  // Emit the event on the text log port
8396 #if FW_ENABLE_TEXT_LOGGING
8397  if (this->isConnected_logTextOut_OutputPort(0)) {
8398 #if FW_OBJECT_NAMES == 1
8399  const char* _formatString =
8400  "(%s) %s: Expected %" PRIu32 " bytes of arguments, but received %" PRIu64 " in sequence file %s";
8401 #else
8402  const char* _formatString =
8403  "%s: Expected %" PRIu32 " bytes of arguments, but received %" PRIu64 " in sequence file %s";
8404 #endif
8405 
8406  Fw::TextLogString _logString;
8407  (void) _logString.format(
8408  _formatString,
8409 #if FW_OBJECT_NAMES == 1
8410  this->m_objName.toChar(),
8411 #endif
8412  "ArgSizeMismatch ",
8413  expected,
8414  actual,
8415  filePath.toChar()
8416  );
8417 
8418  this->logTextOut_out(
8419  0,
8420  _id,
8421  _logTime,
8423  _logString
8424  );
8425  }
8426 #endif
8427  }
8428 
8431  FwSizeType actual,
8432  FwSizeType capacity
8433  ) const
8434  {
8435  // Get the time
8436  Fw::Time _logTime;
8437  if (this->isConnected_timeCaller_OutputPort(0)) {
8438  this->timeCaller_out(0, _logTime);
8439  }
8440 
8442 
8443  // Emit the event on the log port
8444  if (this->isConnected_logOut_OutputPort(0)) {
8445  Fw::LogBuffer _logBuff;
8447 
8448 #if FW_AMPCS_COMPATIBLE
8449  // Serialize the number of arguments
8450  _status = _logBuff.serializeFrom(static_cast<U8>(2));
8451  FW_ASSERT(
8452  _status == Fw::FW_SERIALIZE_OK,
8453  static_cast<FwAssertArgType>(_status)
8454  );
8455 #endif
8456 
8457 #if FW_AMPCS_COMPATIBLE
8458  // Serialize the argument size
8459  _status = _logBuff.serializeFrom(
8460  static_cast<U8>(sizeof(FwSizeType))
8461  );
8462  FW_ASSERT(
8463  _status == Fw::FW_SERIALIZE_OK,
8464  static_cast<FwAssertArgType>(_status)
8465  );
8466 #endif
8467  _status = _logBuff.serializeFrom(actual);
8468  FW_ASSERT(
8469  _status == Fw::FW_SERIALIZE_OK,
8470  static_cast<FwAssertArgType>(_status)
8471  );
8472 
8473 #if FW_AMPCS_COMPATIBLE
8474  // Serialize the argument size
8475  _status = _logBuff.serializeFrom(
8476  static_cast<U8>(sizeof(FwSizeType))
8477  );
8478  FW_ASSERT(
8479  _status == Fw::FW_SERIALIZE_OK,
8480  static_cast<FwAssertArgType>(_status)
8481  );
8482 #endif
8483  _status = _logBuff.serializeFrom(capacity);
8484  FW_ASSERT(
8485  _status == Fw::FW_SERIALIZE_OK,
8486  static_cast<FwAssertArgType>(_status)
8487  );
8488 
8489  this->logOut_out(
8490  0,
8491  _id,
8492  _logTime,
8494  _logBuff
8495  );
8496  }
8497 
8498  // Emit the event on the text log port
8499 #if FW_ENABLE_TEXT_LOGGING
8500  if (this->isConnected_logTextOut_OutputPort(0)) {
8501 #if FW_OBJECT_NAMES == 1
8502  const char* _formatString =
8503  "(%s) %s: Argument size %" PRIu64 " exceeds the %" PRIu64 " byte argument buffer";
8504 #else
8505  const char* _formatString =
8506  "%s: Argument size %" PRIu64 " exceeds the %" PRIu64 " byte argument buffer";
8507 #endif
8508 
8509  Fw::TextLogString _logString;
8510  (void) _logString.format(
8511  _formatString,
8512 #if FW_OBJECT_NAMES == 1
8513  this->m_objName.toChar(),
8514 #endif
8515  "ArgSizeExceedsCapacity ",
8516  actual,
8517  capacity
8518  );
8519 
8520  this->logTextOut_out(
8521  0,
8522  _id,
8523  _logTime,
8525  _logString
8526  );
8527  }
8528 #endif
8529  }
8530 
8533  {
8534  // Get the time
8535  Fw::Time _logTime;
8536  if (this->isConnected_timeCaller_OutputPort(0)) {
8537  this->timeCaller_out(0, _logTime);
8538  }
8539 
8541 
8542  // Emit the event on the log port
8543  if (this->isConnected_logOut_OutputPort(0)) {
8544  Fw::LogBuffer _logBuff;
8546 
8547 #if FW_AMPCS_COMPATIBLE
8548  // Serialize the number of arguments
8549  _status = _logBuff.serializeFrom(static_cast<U8>(1));
8550  FW_ASSERT(
8551  _status == Fw::FW_SERIALIZE_OK,
8552  static_cast<FwAssertArgType>(_status)
8553  );
8554 #endif
8555 
8556 #if FW_AMPCS_COMPATIBLE
8557  // Serialize the argument size
8558  _status = _logBuff.serializeFrom(
8559  static_cast<U8>(sizeof(Svc::Fpy::StackSizeType))
8560  );
8561  FW_ASSERT(
8562  _status == Fw::FW_SERIALIZE_OK,
8563  static_cast<FwAssertArgType>(_status)
8564  );
8565 #endif
8566  _status = _logBuff.serializeFrom(argSize);
8567  FW_ASSERT(
8568  _status == Fw::FW_SERIALIZE_OK,
8569  static_cast<FwAssertArgType>(_status)
8570  );
8571 
8572  this->logOut_out(
8573  0,
8574  _id,
8575  _logTime,
8577  _logBuff
8578  );
8579  }
8580 
8581  // Emit the event on the text log port
8582 #if FW_ENABLE_TEXT_LOGGING
8583  if (this->isConnected_logTextOut_OutputPort(0)) {
8584 #if FW_OBJECT_NAMES == 1
8585  const char* _formatString =
8586  "(%s) %s: Arguments of size %" PRIu32 " would exceed max stack size.";
8587 #else
8588  const char* _formatString =
8589  "%s: Arguments of size %" PRIu32 " would exceed max stack size.";
8590 #endif
8591 
8592  Fw::TextLogString _logString;
8593  (void) _logString.format(
8594  _formatString,
8595 #if FW_OBJECT_NAMES == 1
8596  this->m_objName.toChar(),
8597 #endif
8598  "ArgTotalSizeExceedsStackLimit ",
8599  argSize
8600  );
8601 
8602  this->logTextOut_out(
8603  0,
8604  _id,
8605  _logTime,
8607  _logString
8608  );
8609  }
8610 #endif
8611  }
8612 
8615  {
8616  // Get the time
8617  Fw::Time _logTime;
8618  if (this->isConnected_timeCaller_OutputPort(0)) {
8619  this->timeCaller_out(0, _logTime);
8620  }
8621 
8622  const FwEventIdType _id = this->getIdBase() + EVENTID_SEQUENCEPAUSED;
8623 
8624  // Emit the event on the log port
8625  if (this->isConnected_logOut_OutputPort(0)) {
8626  Fw::LogBuffer _logBuff;
8628 
8629 #if FW_AMPCS_COMPATIBLE
8630  // Serialize the number of arguments
8631  _status = _logBuff.serializeFrom(static_cast<U8>(1));
8632  FW_ASSERT(
8633  _status == Fw::FW_SERIALIZE_OK,
8634  static_cast<FwAssertArgType>(_status)
8635  );
8636 #endif
8637 
8638 #if FW_AMPCS_COMPATIBLE
8639  // Serialize the argument size
8640  _status = _logBuff.serializeFrom(
8641  static_cast<U8>(sizeof(U32))
8642  );
8643  FW_ASSERT(
8644  _status == Fw::FW_SERIALIZE_OK,
8645  static_cast<FwAssertArgType>(_status)
8646  );
8647 #endif
8648  _status = _logBuff.serializeFrom(stmtIdx);
8649  FW_ASSERT(
8650  _status == Fw::FW_SERIALIZE_OK,
8651  static_cast<FwAssertArgType>(_status)
8652  );
8653 
8654  this->logOut_out(
8655  0,
8656  _id,
8657  _logTime,
8659  _logBuff
8660  );
8661  }
8662 
8663  // Emit the event on the text log port
8664 #if FW_ENABLE_TEXT_LOGGING
8665  if (this->isConnected_logTextOut_OutputPort(0)) {
8666 #if FW_OBJECT_NAMES == 1
8667  const char* _formatString =
8668  "(%s) %s: Sequence paused before dispatching directive index %" PRIu32 "";
8669 #else
8670  const char* _formatString =
8671  "%s: Sequence paused before dispatching directive index %" PRIu32 "";
8672 #endif
8673 
8674  Fw::TextLogString _logString;
8675  (void) _logString.format(
8676  _formatString,
8677 #if FW_OBJECT_NAMES == 1
8678  this->m_objName.toChar(),
8679 #endif
8680  "SequencePaused ",
8681  stmtIdx
8682  );
8683 
8684  this->logTextOut_out(
8685  0,
8686  _id,
8687  _logTime,
8689  _logString
8690  );
8691  }
8692 #endif
8693  }
8694 
8697  U32 breakpointIdx,
8698  bool breakOnce
8699  ) const
8700  {
8701  // Get the time
8702  Fw::Time _logTime;
8703  if (this->isConnected_timeCaller_OutputPort(0)) {
8704  this->timeCaller_out(0, _logTime);
8705  }
8706 
8707  const FwEventIdType _id = this->getIdBase() + EVENTID_BREAKPOINTSET;
8708 
8709  // Emit the event on the log port
8710  if (this->isConnected_logOut_OutputPort(0)) {
8711  Fw::LogBuffer _logBuff;
8713 
8714 #if FW_AMPCS_COMPATIBLE
8715  // Serialize the number of arguments
8716  _status = _logBuff.serializeFrom(static_cast<U8>(2));
8717  FW_ASSERT(
8718  _status == Fw::FW_SERIALIZE_OK,
8719  static_cast<FwAssertArgType>(_status)
8720  );
8721 #endif
8722 
8723 #if FW_AMPCS_COMPATIBLE
8724  // Serialize the argument size
8725  _status = _logBuff.serializeFrom(
8726  static_cast<U8>(sizeof(U32))
8727  );
8728  FW_ASSERT(
8729  _status == Fw::FW_SERIALIZE_OK,
8730  static_cast<FwAssertArgType>(_status)
8731  );
8732 #endif
8733  _status = _logBuff.serializeFrom(breakpointIdx);
8734  FW_ASSERT(
8735  _status == Fw::FW_SERIALIZE_OK,
8736  static_cast<FwAssertArgType>(_status)
8737  );
8738 
8739 #if FW_AMPCS_COMPATIBLE
8740  // Serialize the argument size
8741  _status = _logBuff.serializeFrom(
8742  static_cast<U8>(sizeof(U8))
8743  );
8744  FW_ASSERT(
8745  _status == Fw::FW_SERIALIZE_OK,
8746  static_cast<FwAssertArgType>(_status)
8747  );
8748 #endif
8749  _status = _logBuff.serializeFrom(breakOnce);
8750  FW_ASSERT(
8751  _status == Fw::FW_SERIALIZE_OK,
8752  static_cast<FwAssertArgType>(_status)
8753  );
8754 
8755  this->logOut_out(
8756  0,
8757  _id,
8758  _logTime,
8760  _logBuff
8761  );
8762  }
8763 
8764  // Emit the event on the text log port
8765 #if FW_ENABLE_TEXT_LOGGING
8766  if (this->isConnected_logTextOut_OutputPort(0)) {
8767 #if FW_OBJECT_NAMES == 1
8768  const char* _formatString =
8769  "(%s) %s: Breakpoint set before directive index %" PRIu32 ". Will break once: %d";
8770 #else
8771  const char* _formatString =
8772  "%s: Breakpoint set before directive index %" PRIu32 ". Will break once: %d";
8773 #endif
8774 
8775  Fw::TextLogString _logString;
8776  (void) _logString.format(
8777  _formatString,
8778 #if FW_OBJECT_NAMES == 1
8779  this->m_objName.toChar(),
8780 #endif
8781  "BreakpointSet ",
8782  breakpointIdx,
8783  breakOnce
8784  );
8785 
8786  this->logTextOut_out(
8787  0,
8788  _id,
8789  _logTime,
8791  _logString
8792  );
8793  }
8794 #endif
8795  }
8796 
8799  {
8800  // Get the time
8801  Fw::Time _logTime;
8802  if (this->isConnected_timeCaller_OutputPort(0)) {
8803  this->timeCaller_out(0, _logTime);
8804  }
8805 
8806  const FwEventIdType _id = this->getIdBase() + EVENTID_BREAKPOINTCLEARED;
8807 
8808  // Emit the event on the log port
8809  if (this->isConnected_logOut_OutputPort(0)) {
8810  Fw::LogBuffer _logBuff;
8811 
8812 #if FW_AMPCS_COMPATIBLE
8814  // Serialize the number of arguments
8815  _status = _logBuff.serializeFrom(static_cast<U8>(0));
8816  FW_ASSERT(
8817  _status == Fw::FW_SERIALIZE_OK,
8818  static_cast<FwAssertArgType>(_status)
8819  );
8820 #endif
8821 
8822  this->logOut_out(
8823  0,
8824  _id,
8825  _logTime,
8827  _logBuff
8828  );
8829  }
8830 
8831  // Emit the event on the text log port
8832 #if FW_ENABLE_TEXT_LOGGING
8833  if (this->isConnected_logTextOut_OutputPort(0)) {
8834 #if FW_OBJECT_NAMES == 1
8835  const char* _formatString =
8836  "(%s) %s: Breakpoint cleared";
8837 #else
8838  const char* _formatString =
8839  "%s: Breakpoint cleared";
8840 #endif
8841 
8842  Fw::TextLogString _logString;
8843  (void) _logString.format(
8844  _formatString,
8845 #if FW_OBJECT_NAMES == 1
8846  this->m_objName.toChar(),
8847 #endif
8848  "BreakpointCleared "
8849  );
8850 
8851  this->logTextOut_out(
8852  0,
8853  _id,
8854  _logTime,
8856  _logString
8857  );
8858  }
8859 #endif
8860  }
8861 
8864  const Fw::StringBase& filePath,
8865  const Fw::StringBase& message
8866  ) const
8867  {
8868  // Get the time
8869  Fw::Time _logTime;
8870  if (this->isConnected_timeCaller_OutputPort(0)) {
8871  this->timeCaller_out(0, _logTime);
8872  }
8873 
8874  const FwEventIdType _id = this->getIdBase() + EVENTID_LOGFATAL;
8875 
8876  // Emit the event on the log port
8877  if (this->isConnected_logOut_OutputPort(0)) {
8878  Fw::LogBuffer _logBuff;
8880 
8881 #if FW_AMPCS_COMPATIBLE
8882  // Serialize the number of arguments
8883  _status = _logBuff.serializeFrom(static_cast<U8>(2 + 1));
8884  FW_ASSERT(
8885  _status == Fw::FW_SERIALIZE_OK,
8886  static_cast<FwAssertArgType>(_status)
8887  );
8888 
8889  // For FATAL, add stack size of 4 and a dummy entry. No support for stacks yet.
8890  _status = _logBuff.serializeFrom(static_cast<U8>(4));
8891  FW_ASSERT(
8892  _status == Fw::FW_SERIALIZE_OK,
8893  static_cast<FwAssertArgType>(_status)
8894  );
8895 
8896  _status = _logBuff.serializeFrom(static_cast<U32>(0));
8897  FW_ASSERT(
8898  _status == Fw::FW_SERIALIZE_OK,
8899  static_cast<FwAssertArgType>(_status)
8900  );
8901 #endif
8902 
8903  _status = filePath.serializeTo(
8904  _logBuff,
8905  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
8906  );
8907  FW_ASSERT(
8908  _status == Fw::FW_SERIALIZE_OK,
8909  static_cast<FwAssertArgType>(_status)
8910  );
8911 
8912  _status = message.serializeTo(
8913  _logBuff,
8914  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
8915  );
8916  FW_ASSERT(
8917  _status == Fw::FW_SERIALIZE_OK,
8918  static_cast<FwAssertArgType>(_status)
8919  );
8920 
8921  this->logOut_out(
8922  0,
8923  _id,
8924  _logTime,
8926  _logBuff
8927  );
8928  }
8929 
8930  // Emit the event on the text log port
8931 #if FW_ENABLE_TEXT_LOGGING
8932  if (this->isConnected_logTextOut_OutputPort(0)) {
8933 #if FW_OBJECT_NAMES == 1
8934  const char* _formatString =
8935  "(%s) %s: Sequence %s: %s";
8936 #else
8937  const char* _formatString =
8938  "%s: Sequence %s: %s";
8939 #endif
8940 
8941  Fw::TextLogString _logString;
8942  (void) _logString.format(
8943  _formatString,
8944 #if FW_OBJECT_NAMES == 1
8945  this->m_objName.toChar(),
8946 #endif
8947  "LogFatal ",
8948  filePath.toChar(),
8949  message.toChar()
8950  );
8951 
8952  this->logTextOut_out(
8953  0,
8954  _id,
8955  _logTime,
8957  _logString
8958  );
8959  }
8960 #endif
8961  }
8962 
8965  const Fw::StringBase& filePath,
8966  const Fw::StringBase& message
8967  ) const
8968  {
8969  // Get the time
8970  Fw::Time _logTime;
8971  if (this->isConnected_timeCaller_OutputPort(0)) {
8972  this->timeCaller_out(0, _logTime);
8973  }
8974 
8975  const FwEventIdType _id = this->getIdBase() + EVENTID_LOGWARNINGHI;
8976 
8977  // Emit the event on the log port
8978  if (this->isConnected_logOut_OutputPort(0)) {
8979  Fw::LogBuffer _logBuff;
8981 
8982 #if FW_AMPCS_COMPATIBLE
8983  // Serialize the number of arguments
8984  _status = _logBuff.serializeFrom(static_cast<U8>(2));
8985  FW_ASSERT(
8986  _status == Fw::FW_SERIALIZE_OK,
8987  static_cast<FwAssertArgType>(_status)
8988  );
8989 #endif
8990 
8991  _status = filePath.serializeTo(
8992  _logBuff,
8993  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
8994  );
8995  FW_ASSERT(
8996  _status == Fw::FW_SERIALIZE_OK,
8997  static_cast<FwAssertArgType>(_status)
8998  );
8999 
9000  _status = message.serializeTo(
9001  _logBuff,
9002  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9003  );
9004  FW_ASSERT(
9005  _status == Fw::FW_SERIALIZE_OK,
9006  static_cast<FwAssertArgType>(_status)
9007  );
9008 
9009  this->logOut_out(
9010  0,
9011  _id,
9012  _logTime,
9014  _logBuff
9015  );
9016  }
9017 
9018  // Emit the event on the text log port
9019 #if FW_ENABLE_TEXT_LOGGING
9020  if (this->isConnected_logTextOut_OutputPort(0)) {
9021 #if FW_OBJECT_NAMES == 1
9022  const char* _formatString =
9023  "(%s) %s: Sequence %s: %s";
9024 #else
9025  const char* _formatString =
9026  "%s: Sequence %s: %s";
9027 #endif
9028 
9029  Fw::TextLogString _logString;
9030  (void) _logString.format(
9031  _formatString,
9032 #if FW_OBJECT_NAMES == 1
9033  this->m_objName.toChar(),
9034 #endif
9035  "LogWarningHi ",
9036  filePath.toChar(),
9037  message.toChar()
9038  );
9039 
9040  this->logTextOut_out(
9041  0,
9042  _id,
9043  _logTime,
9045  _logString
9046  );
9047  }
9048 #endif
9049  }
9050 
9053  const Fw::StringBase& filePath,
9054  const Fw::StringBase& message
9055  ) const
9056  {
9057  // Get the time
9058  Fw::Time _logTime;
9059  if (this->isConnected_timeCaller_OutputPort(0)) {
9060  this->timeCaller_out(0, _logTime);
9061  }
9062 
9063  const FwEventIdType _id = this->getIdBase() + EVENTID_LOGWARNINGLO;
9064 
9065  // Emit the event on the log port
9066  if (this->isConnected_logOut_OutputPort(0)) {
9067  Fw::LogBuffer _logBuff;
9069 
9070 #if FW_AMPCS_COMPATIBLE
9071  // Serialize the number of arguments
9072  _status = _logBuff.serializeFrom(static_cast<U8>(2));
9073  FW_ASSERT(
9074  _status == Fw::FW_SERIALIZE_OK,
9075  static_cast<FwAssertArgType>(_status)
9076  );
9077 #endif
9078 
9079  _status = filePath.serializeTo(
9080  _logBuff,
9081  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9082  );
9083  FW_ASSERT(
9084  _status == Fw::FW_SERIALIZE_OK,
9085  static_cast<FwAssertArgType>(_status)
9086  );
9087 
9088  _status = message.serializeTo(
9089  _logBuff,
9090  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9091  );
9092  FW_ASSERT(
9093  _status == Fw::FW_SERIALIZE_OK,
9094  static_cast<FwAssertArgType>(_status)
9095  );
9096 
9097  this->logOut_out(
9098  0,
9099  _id,
9100  _logTime,
9102  _logBuff
9103  );
9104  }
9105 
9106  // Emit the event on the text log port
9107 #if FW_ENABLE_TEXT_LOGGING
9108  if (this->isConnected_logTextOut_OutputPort(0)) {
9109 #if FW_OBJECT_NAMES == 1
9110  const char* _formatString =
9111  "(%s) %s: Sequence %s: %s";
9112 #else
9113  const char* _formatString =
9114  "%s: Sequence %s: %s";
9115 #endif
9116 
9117  Fw::TextLogString _logString;
9118  (void) _logString.format(
9119  _formatString,
9120 #if FW_OBJECT_NAMES == 1
9121  this->m_objName.toChar(),
9122 #endif
9123  "LogWarningLo ",
9124  filePath.toChar(),
9125  message.toChar()
9126  );
9127 
9128  this->logTextOut_out(
9129  0,
9130  _id,
9131  _logTime,
9133  _logString
9134  );
9135  }
9136 #endif
9137  }
9138 
9141  const Fw::StringBase& filePath,
9142  const Fw::StringBase& message
9143  ) const
9144  {
9145  // Get the time
9146  Fw::Time _logTime;
9147  if (this->isConnected_timeCaller_OutputPort(0)) {
9148  this->timeCaller_out(0, _logTime);
9149  }
9150 
9151  const FwEventIdType _id = this->getIdBase() + EVENTID_LOGCOMMAND;
9152 
9153  // Emit the event on the log port
9154  if (this->isConnected_logOut_OutputPort(0)) {
9155  Fw::LogBuffer _logBuff;
9157 
9158 #if FW_AMPCS_COMPATIBLE
9159  // Serialize the number of arguments
9160  _status = _logBuff.serializeFrom(static_cast<U8>(2));
9161  FW_ASSERT(
9162  _status == Fw::FW_SERIALIZE_OK,
9163  static_cast<FwAssertArgType>(_status)
9164  );
9165 #endif
9166 
9167  _status = filePath.serializeTo(
9168  _logBuff,
9169  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9170  );
9171  FW_ASSERT(
9172  _status == Fw::FW_SERIALIZE_OK,
9173  static_cast<FwAssertArgType>(_status)
9174  );
9175 
9176  _status = message.serializeTo(
9177  _logBuff,
9178  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9179  );
9180  FW_ASSERT(
9181  _status == Fw::FW_SERIALIZE_OK,
9182  static_cast<FwAssertArgType>(_status)
9183  );
9184 
9185  this->logOut_out(
9186  0,
9187  _id,
9188  _logTime,
9190  _logBuff
9191  );
9192  }
9193 
9194  // Emit the event on the text log port
9195 #if FW_ENABLE_TEXT_LOGGING
9196  if (this->isConnected_logTextOut_OutputPort(0)) {
9197 #if FW_OBJECT_NAMES == 1
9198  const char* _formatString =
9199  "(%s) %s: Sequence %s: %s";
9200 #else
9201  const char* _formatString =
9202  "%s: Sequence %s: %s";
9203 #endif
9204 
9205  Fw::TextLogString _logString;
9206  (void) _logString.format(
9207  _formatString,
9208 #if FW_OBJECT_NAMES == 1
9209  this->m_objName.toChar(),
9210 #endif
9211  "LogCommand ",
9212  filePath.toChar(),
9213  message.toChar()
9214  );
9215 
9216  this->logTextOut_out(
9217  0,
9218  _id,
9219  _logTime,
9221  _logString
9222  );
9223  }
9224 #endif
9225  }
9226 
9229  const Fw::StringBase& filePath,
9230  const Fw::StringBase& message
9231  ) const
9232  {
9233  // Get the time
9234  Fw::Time _logTime;
9235  if (this->isConnected_timeCaller_OutputPort(0)) {
9236  this->timeCaller_out(0, _logTime);
9237  }
9238 
9239  const FwEventIdType _id = this->getIdBase() + EVENTID_LOGACTIVITYHI;
9240 
9241  // Emit the event on the log port
9242  if (this->isConnected_logOut_OutputPort(0)) {
9243  Fw::LogBuffer _logBuff;
9245 
9246 #if FW_AMPCS_COMPATIBLE
9247  // Serialize the number of arguments
9248  _status = _logBuff.serializeFrom(static_cast<U8>(2));
9249  FW_ASSERT(
9250  _status == Fw::FW_SERIALIZE_OK,
9251  static_cast<FwAssertArgType>(_status)
9252  );
9253 #endif
9254 
9255  _status = filePath.serializeTo(
9256  _logBuff,
9257  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9258  );
9259  FW_ASSERT(
9260  _status == Fw::FW_SERIALIZE_OK,
9261  static_cast<FwAssertArgType>(_status)
9262  );
9263 
9264  _status = message.serializeTo(
9265  _logBuff,
9266  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9267  );
9268  FW_ASSERT(
9269  _status == Fw::FW_SERIALIZE_OK,
9270  static_cast<FwAssertArgType>(_status)
9271  );
9272 
9273  this->logOut_out(
9274  0,
9275  _id,
9276  _logTime,
9278  _logBuff
9279  );
9280  }
9281 
9282  // Emit the event on the text log port
9283 #if FW_ENABLE_TEXT_LOGGING
9284  if (this->isConnected_logTextOut_OutputPort(0)) {
9285 #if FW_OBJECT_NAMES == 1
9286  const char* _formatString =
9287  "(%s) %s: Sequence %s: %s";
9288 #else
9289  const char* _formatString =
9290  "%s: Sequence %s: %s";
9291 #endif
9292 
9293  Fw::TextLogString _logString;
9294  (void) _logString.format(
9295  _formatString,
9296 #if FW_OBJECT_NAMES == 1
9297  this->m_objName.toChar(),
9298 #endif
9299  "LogActivityHi ",
9300  filePath.toChar(),
9301  message.toChar()
9302  );
9303 
9304  this->logTextOut_out(
9305  0,
9306  _id,
9307  _logTime,
9309  _logString
9310  );
9311  }
9312 #endif
9313  }
9314 
9317  const Fw::StringBase& filePath,
9318  const Fw::StringBase& message
9319  ) const
9320  {
9321  // Get the time
9322  Fw::Time _logTime;
9323  if (this->isConnected_timeCaller_OutputPort(0)) {
9324  this->timeCaller_out(0, _logTime);
9325  }
9326 
9327  const FwEventIdType _id = this->getIdBase() + EVENTID_LOGACTIVITYLO;
9328 
9329  // Emit the event on the log port
9330  if (this->isConnected_logOut_OutputPort(0)) {
9331  Fw::LogBuffer _logBuff;
9333 
9334 #if FW_AMPCS_COMPATIBLE
9335  // Serialize the number of arguments
9336  _status = _logBuff.serializeFrom(static_cast<U8>(2));
9337  FW_ASSERT(
9338  _status == Fw::FW_SERIALIZE_OK,
9339  static_cast<FwAssertArgType>(_status)
9340  );
9341 #endif
9342 
9343  _status = filePath.serializeTo(
9344  _logBuff,
9345  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9346  );
9347  FW_ASSERT(
9348  _status == Fw::FW_SERIALIZE_OK,
9349  static_cast<FwAssertArgType>(_status)
9350  );
9351 
9352  _status = message.serializeTo(
9353  _logBuff,
9354  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9355  );
9356  FW_ASSERT(
9357  _status == Fw::FW_SERIALIZE_OK,
9358  static_cast<FwAssertArgType>(_status)
9359  );
9360 
9361  this->logOut_out(
9362  0,
9363  _id,
9364  _logTime,
9366  _logBuff
9367  );
9368  }
9369 
9370  // Emit the event on the text log port
9371 #if FW_ENABLE_TEXT_LOGGING
9372  if (this->isConnected_logTextOut_OutputPort(0)) {
9373 #if FW_OBJECT_NAMES == 1
9374  const char* _formatString =
9375  "(%s) %s: Sequence %s: %s";
9376 #else
9377  const char* _formatString =
9378  "%s: Sequence %s: %s";
9379 #endif
9380 
9381  Fw::TextLogString _logString;
9382  (void) _logString.format(
9383  _formatString,
9384 #if FW_OBJECT_NAMES == 1
9385  this->m_objName.toChar(),
9386 #endif
9387  "LogActivityLo ",
9388  filePath.toChar(),
9389  message.toChar()
9390  );
9391 
9392  this->logTextOut_out(
9393  0,
9394  _id,
9395  _logTime,
9397  _logString
9398  );
9399  }
9400 #endif
9401  }
9402 
9405  const Fw::StringBase& filePath,
9406  const Fw::StringBase& message
9407  ) const
9408  {
9409  // Get the time
9410  Fw::Time _logTime;
9411  if (this->isConnected_timeCaller_OutputPort(0)) {
9412  this->timeCaller_out(0, _logTime);
9413  }
9414 
9415  const FwEventIdType _id = this->getIdBase() + EVENTID_LOGDIAGNOSTIC;
9416 
9417  // Emit the event on the log port
9418  if (this->isConnected_logOut_OutputPort(0)) {
9419  Fw::LogBuffer _logBuff;
9421 
9422 #if FW_AMPCS_COMPATIBLE
9423  // Serialize the number of arguments
9424  _status = _logBuff.serializeFrom(static_cast<U8>(2));
9425  FW_ASSERT(
9426  _status == Fw::FW_SERIALIZE_OK,
9427  static_cast<FwAssertArgType>(_status)
9428  );
9429 #endif
9430 
9431  _status = filePath.serializeTo(
9432  _logBuff,
9433  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9434  );
9435  FW_ASSERT(
9436  _status == Fw::FW_SERIALIZE_OK,
9437  static_cast<FwAssertArgType>(_status)
9438  );
9439 
9440  _status = message.serializeTo(
9441  _logBuff,
9442  FW_MIN(static_cast<FwSizeType>(FW_LOG_STRING_MAX_SIZE), static_cast<FwSizeType>(FW_FIXED_LENGTH_STRING_SIZE))
9443  );
9444  FW_ASSERT(
9445  _status == Fw::FW_SERIALIZE_OK,
9446  static_cast<FwAssertArgType>(_status)
9447  );
9448 
9449  this->logOut_out(
9450  0,
9451  _id,
9452  _logTime,
9454  _logBuff
9455  );
9456  }
9457 
9458  // Emit the event on the text log port
9459 #if FW_ENABLE_TEXT_LOGGING
9460  if (this->isConnected_logTextOut_OutputPort(0)) {
9461 #if FW_OBJECT_NAMES == 1
9462  const char* _formatString =
9463  "(%s) %s: Sequence %s: %s";
9464 #else
9465  const char* _formatString =
9466  "%s: Sequence %s: %s";
9467 #endif
9468 
9469  Fw::TextLogString _logString;
9470  (void) _logString.format(
9471  _formatString,
9472 #if FW_OBJECT_NAMES == 1
9473  this->m_objName.toChar(),
9474 #endif
9475  "LogDiagnostic ",
9476  filePath.toChar(),
9477  message.toChar()
9478  );
9479 
9480  this->logTextOut_out(
9481  0,
9482  _id,
9483  _logTime,
9485  _logString
9486  );
9487  }
9488 #endif
9489  }
9490 
9491  // ----------------------------------------------------------------------
9492  // Telemetry serialized write
9493  // ----------------------------------------------------------------------
9494 
9497  FwChanIdType id,
9498  Fw::TlmBuffer& _tlmBuff,
9499  Fw::Time _tlmTime
9500  ) const
9501  {
9502  if (this->isConnected_tlmOut_OutputPort(0)) {
9503  if (
9505  (_tlmTime == Fw::ZERO_TIME)
9506  ) {
9507  this->timeCaller_out(0, _tlmTime);
9508  }
9509 
9510  FwChanIdType _id;
9511  _id = this->getIdBase() + id;
9512 
9513  this->tlmOut_out(
9514  0,
9515  _id,
9516  _tlmTime,
9517  _tlmBuff
9518  );
9519  }
9520  }
9521 
9522  // ----------------------------------------------------------------------
9523  // Telemetry write functions
9524  // ----------------------------------------------------------------------
9525 
9528  FwEnumStoreType arg,
9529  Fw::Time _tlmTime
9530  )
9531  {
9532  // Check to see if it is the first time
9533  if (not this->m_first_update_State) {
9534  // Check to see if value has changed. If not, don't write it.
9535  if (arg == this->m_last_State) {
9536  return;
9537  }
9538  else {
9539  this->m_last_State = arg;
9540  }
9541  }
9542  else {
9543  this->m_first_update_State = false;
9544  this->m_last_State = arg;
9545  }
9546 
9547  if (this->isConnected_tlmOut_OutputPort(0)) {
9548  Fw::TlmBuffer _tlmBuff;
9549  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9550  FW_ASSERT(
9551  _stat == Fw::FW_SERIALIZE_OK,
9552  static_cast<FwAssertArgType>(_stat)
9553  );
9554 
9555  this->tlmWrite(
9557  _tlmBuff,
9558  _tlmTime
9559  );
9560  }
9561  }
9562 
9565  U64 arg,
9566  Fw::Time _tlmTime
9567  )
9568  {
9569  // Check to see if it is the first time
9570  if (not this->m_first_update_SequencesSucceeded) {
9571  // Check to see if value has changed. If not, don't write it.
9572  if (arg == this->m_last_SequencesSucceeded) {
9573  return;
9574  }
9575  else {
9576  this->m_last_SequencesSucceeded = arg;
9577  }
9578  }
9579  else {
9580  this->m_first_update_SequencesSucceeded = false;
9581  this->m_last_SequencesSucceeded = arg;
9582  }
9583 
9584  if (this->isConnected_tlmOut_OutputPort(0)) {
9585  Fw::TlmBuffer _tlmBuff;
9586  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9587  FW_ASSERT(
9588  _stat == Fw::FW_SERIALIZE_OK,
9589  static_cast<FwAssertArgType>(_stat)
9590  );
9591 
9592  this->tlmWrite(
9594  _tlmBuff,
9595  _tlmTime
9596  );
9597  }
9598  }
9599 
9602  U64 arg,
9603  Fw::Time _tlmTime
9604  )
9605  {
9606  // Check to see if it is the first time
9607  if (not this->m_first_update_SequencesFailed) {
9608  // Check to see if value has changed. If not, don't write it.
9609  if (arg == this->m_last_SequencesFailed) {
9610  return;
9611  }
9612  else {
9613  this->m_last_SequencesFailed = arg;
9614  }
9615  }
9616  else {
9617  this->m_first_update_SequencesFailed = false;
9618  this->m_last_SequencesFailed = arg;
9619  }
9620 
9621  if (this->isConnected_tlmOut_OutputPort(0)) {
9622  Fw::TlmBuffer _tlmBuff;
9623  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9624  FW_ASSERT(
9625  _stat == Fw::FW_SERIALIZE_OK,
9626  static_cast<FwAssertArgType>(_stat)
9627  );
9628 
9629  this->tlmWrite(
9631  _tlmBuff,
9632  _tlmTime
9633  );
9634  }
9635  }
9636 
9639  U64 arg,
9640  Fw::Time _tlmTime
9641  )
9642  {
9643  // Check to see if it is the first time
9644  if (not this->m_first_update_SequencesCancelled) {
9645  // Check to see if value has changed. If not, don't write it.
9646  if (arg == this->m_last_SequencesCancelled) {
9647  return;
9648  }
9649  else {
9650  this->m_last_SequencesCancelled = arg;
9651  }
9652  }
9653  else {
9654  this->m_first_update_SequencesCancelled = false;
9655  this->m_last_SequencesCancelled = arg;
9656  }
9657 
9658  if (this->isConnected_tlmOut_OutputPort(0)) {
9659  Fw::TlmBuffer _tlmBuff;
9660  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9661  FW_ASSERT(
9662  _stat == Fw::FW_SERIALIZE_OK,
9663  static_cast<FwAssertArgType>(_stat)
9664  );
9665 
9666  this->tlmWrite(
9668  _tlmBuff,
9669  _tlmTime
9670  );
9671  }
9672  }
9673 
9676  U64 arg,
9677  Fw::Time _tlmTime
9678  )
9679  {
9680  // Check to see if it is the first time
9681  if (not this->m_first_update_StatementsDispatched) {
9682  // Check to see if value has changed. If not, don't write it.
9683  if (arg == this->m_last_StatementsDispatched) {
9684  return;
9685  }
9686  else {
9687  this->m_last_StatementsDispatched = arg;
9688  }
9689  }
9690  else {
9691  this->m_first_update_StatementsDispatched = false;
9692  this->m_last_StatementsDispatched = arg;
9693  }
9694 
9695  if (this->isConnected_tlmOut_OutputPort(0)) {
9696  Fw::TlmBuffer _tlmBuff;
9697  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9698  FW_ASSERT(
9699  _stat == Fw::FW_SERIALIZE_OK,
9700  static_cast<FwAssertArgType>(_stat)
9701  );
9702 
9703  this->tlmWrite(
9705  _tlmBuff,
9706  _tlmTime
9707  );
9708  }
9709  }
9710 
9713  U64 arg,
9714  Fw::Time _tlmTime
9715  )
9716  {
9717  // Check to see if it is the first time
9718  if (not this->m_first_update_StatementsFailed) {
9719  // Check to see if value has changed. If not, don't write it.
9720  if (arg == this->m_last_StatementsFailed) {
9721  return;
9722  }
9723  else {
9724  this->m_last_StatementsFailed = arg;
9725  }
9726  }
9727  else {
9728  this->m_first_update_StatementsFailed = false;
9729  this->m_last_StatementsFailed = arg;
9730  }
9731 
9732  if (this->isConnected_tlmOut_OutputPort(0)) {
9733  Fw::TlmBuffer _tlmBuff;
9734  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9735  FW_ASSERT(
9736  _stat == Fw::FW_SERIALIZE_OK,
9737  static_cast<FwAssertArgType>(_stat)
9738  );
9739 
9740  this->tlmWrite(
9742  _tlmBuff,
9743  _tlmTime
9744  );
9745  }
9746  }
9747 
9750  const Svc::Fpy::DirectiveErrorCode& arg,
9751  Fw::Time _tlmTime
9752  )
9753  {
9754  // Check to see if it is the first time
9755  if (not this->m_first_update_LastDirectiveError) {
9756  // Check to see if value has changed. If not, don't write it.
9757  if (arg == this->m_last_LastDirectiveError) {
9758  return;
9759  }
9760  else {
9761  this->m_last_LastDirectiveError = arg;
9762  }
9763  }
9764  else {
9765  this->m_first_update_LastDirectiveError = false;
9766  this->m_last_LastDirectiveError = arg;
9767  }
9768 
9769  if (this->isConnected_tlmOut_OutputPort(0)) {
9770  Fw::TlmBuffer _tlmBuff;
9771  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9772  FW_ASSERT(
9773  _stat == Fw::FW_SERIALIZE_OK,
9774  static_cast<FwAssertArgType>(_stat)
9775  );
9776 
9777  this->tlmWrite(
9779  _tlmBuff,
9780  _tlmTime
9781  );
9782  }
9783  }
9784 
9787  U64 arg,
9788  Fw::Time _tlmTime
9789  )
9790  {
9791  // Check to see if it is the first time
9792  if (not this->m_first_update_DirectiveErrorIndex) {
9793  // Check to see if value has changed. If not, don't write it.
9794  if (arg == this->m_last_DirectiveErrorIndex) {
9795  return;
9796  }
9797  else {
9798  this->m_last_DirectiveErrorIndex = arg;
9799  }
9800  }
9801  else {
9802  this->m_first_update_DirectiveErrorIndex = false;
9803  this->m_last_DirectiveErrorIndex = arg;
9804  }
9805 
9806  if (this->isConnected_tlmOut_OutputPort(0)) {
9807  Fw::TlmBuffer _tlmBuff;
9808  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9809  FW_ASSERT(
9810  _stat == Fw::FW_SERIALIZE_OK,
9811  static_cast<FwAssertArgType>(_stat)
9812  );
9813 
9814  this->tlmWrite(
9816  _tlmBuff,
9817  _tlmTime
9818  );
9819  }
9820  }
9821 
9824  const Svc::Fpy::DirectiveId& arg,
9825  Fw::Time _tlmTime
9826  )
9827  {
9828  // Check to see if it is the first time
9829  if (not this->m_first_update_DirectiveErrorId) {
9830  // Check to see if value has changed. If not, don't write it.
9831  if (arg == this->m_last_DirectiveErrorId) {
9832  return;
9833  }
9834  else {
9835  this->m_last_DirectiveErrorId = arg;
9836  }
9837  }
9838  else {
9839  this->m_first_update_DirectiveErrorId = false;
9840  this->m_last_DirectiveErrorId = arg;
9841  }
9842 
9843  if (this->isConnected_tlmOut_OutputPort(0)) {
9844  Fw::TlmBuffer _tlmBuff;
9845  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9846  FW_ASSERT(
9847  _stat == Fw::FW_SERIALIZE_OK,
9848  static_cast<FwAssertArgType>(_stat)
9849  );
9850 
9851  this->tlmWrite(
9853  _tlmBuff,
9854  _tlmTime
9855  );
9856  }
9857  }
9858 
9861  const Fw::StringBase& arg,
9862  Fw::Time _tlmTime
9863  )
9864  {
9865  // Check to see if it is the first time
9866  if (not this->m_first_update_SeqPath) {
9867  // Check to see if value has changed. If not, don't write it.
9868  if (arg == this->m_last_SeqPath) {
9869  return;
9870  }
9871  else {
9872  this->m_last_SeqPath = arg;
9873  }
9874  }
9875  else {
9876  this->m_first_update_SeqPath = false;
9877  this->m_last_SeqPath = arg;
9878  }
9879 
9880  if (this->isConnected_tlmOut_OutputPort(0)) {
9881  Fw::TlmBuffer _tlmBuff;
9882  Fw::SerializeStatus _stat = arg.serializeTo(
9883  _tlmBuff,
9884  FW_MIN(static_cast<FwSizeType>(FW_TLM_STRING_MAX_SIZE), 240)
9885  );
9886  FW_ASSERT(
9887  _stat == Fw::FW_SERIALIZE_OK,
9888  static_cast<FwAssertArgType>(_stat)
9889  );
9890 
9891  this->tlmWrite(
9893  _tlmBuff,
9894  _tlmTime
9895  );
9896  }
9897  }
9898 
9901  bool arg,
9902  Fw::Time _tlmTime
9903  )
9904  {
9905  // Check to see if it is the first time
9906  if (not this->m_first_update_Debug_ReachedEndOfFile) {
9907  // Check to see if value has changed. If not, don't write it.
9908  if (arg == this->m_last_Debug_ReachedEndOfFile) {
9909  return;
9910  }
9911  else {
9912  this->m_last_Debug_ReachedEndOfFile = arg;
9913  }
9914  }
9915  else {
9916  this->m_first_update_Debug_ReachedEndOfFile = false;
9917  this->m_last_Debug_ReachedEndOfFile = arg;
9918  }
9919 
9920  if (this->isConnected_tlmOut_OutputPort(0)) {
9921  Fw::TlmBuffer _tlmBuff;
9922  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9923  FW_ASSERT(
9924  _stat == Fw::FW_SERIALIZE_OK,
9925  static_cast<FwAssertArgType>(_stat)
9926  );
9927 
9928  this->tlmWrite(
9930  _tlmBuff,
9931  _tlmTime
9932  );
9933  }
9934  }
9935 
9938  bool arg,
9939  Fw::Time _tlmTime
9940  )
9941  {
9942  // Check to see if it is the first time
9943  if (not this->m_first_update_Debug_NextStatementReadSuccess) {
9944  // Check to see if value has changed. If not, don't write it.
9945  if (arg == this->m_last_Debug_NextStatementReadSuccess) {
9946  return;
9947  }
9948  else {
9949  this->m_last_Debug_NextStatementReadSuccess = arg;
9950  }
9951  }
9952  else {
9953  this->m_first_update_Debug_NextStatementReadSuccess = false;
9954  this->m_last_Debug_NextStatementReadSuccess = arg;
9955  }
9956 
9957  if (this->isConnected_tlmOut_OutputPort(0)) {
9958  Fw::TlmBuffer _tlmBuff;
9959  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9960  FW_ASSERT(
9961  _stat == Fw::FW_SERIALIZE_OK,
9962  static_cast<FwAssertArgType>(_stat)
9963  );
9964 
9965  this->tlmWrite(
9967  _tlmBuff,
9968  _tlmTime
9969  );
9970  }
9971  }
9972 
9975  U8 arg,
9976  Fw::Time _tlmTime
9977  )
9978  {
9979  // Check to see if it is the first time
9980  if (not this->m_first_update_Debug_NextStatementOpcode) {
9981  // Check to see if value has changed. If not, don't write it.
9982  if (arg == this->m_last_Debug_NextStatementOpcode) {
9983  return;
9984  }
9985  else {
9986  this->m_last_Debug_NextStatementOpcode = arg;
9987  }
9988  }
9989  else {
9990  this->m_first_update_Debug_NextStatementOpcode = false;
9991  this->m_last_Debug_NextStatementOpcode = arg;
9992  }
9993 
9994  if (this->isConnected_tlmOut_OutputPort(0)) {
9995  Fw::TlmBuffer _tlmBuff;
9996  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
9997  FW_ASSERT(
9998  _stat == Fw::FW_SERIALIZE_OK,
9999  static_cast<FwAssertArgType>(_stat)
10000  );
10001 
10002  this->tlmWrite(
10004  _tlmBuff,
10005  _tlmTime
10006  );
10007  }
10008  }
10009 
10012  U32 arg,
10013  Fw::Time _tlmTime
10014  )
10015  {
10016  // Check to see if it is the first time
10017  if (not this->m_first_update_Debug_NextStatementIndex) {
10018  // Check to see if value has changed. If not, don't write it.
10019  if (arg == this->m_last_Debug_NextStatementIndex) {
10020  return;
10021  }
10022  else {
10023  this->m_last_Debug_NextStatementIndex = arg;
10024  }
10025  }
10026  else {
10027  this->m_first_update_Debug_NextStatementIndex = false;
10028  this->m_last_Debug_NextStatementIndex = arg;
10029  }
10030 
10031  if (this->isConnected_tlmOut_OutputPort(0)) {
10032  Fw::TlmBuffer _tlmBuff;
10033  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10034  FW_ASSERT(
10035  _stat == Fw::FW_SERIALIZE_OK,
10036  static_cast<FwAssertArgType>(_stat)
10037  );
10038 
10039  this->tlmWrite(
10041  _tlmBuff,
10042  _tlmTime
10043  );
10044  }
10045  }
10046 
10049  FwOpcodeType arg,
10050  Fw::Time _tlmTime
10051  )
10052  {
10053  // Check to see if it is the first time
10054  if (not this->m_first_update_Debug_NextCmdOpcode) {
10055  // Check to see if value has changed. If not, don't write it.
10056  if (arg == this->m_last_Debug_NextCmdOpcode) {
10057  return;
10058  }
10059  else {
10060  this->m_last_Debug_NextCmdOpcode = arg;
10061  }
10062  }
10063  else {
10064  this->m_first_update_Debug_NextCmdOpcode = false;
10065  this->m_last_Debug_NextCmdOpcode = arg;
10066  }
10067 
10068  if (this->isConnected_tlmOut_OutputPort(0)) {
10069  Fw::TlmBuffer _tlmBuff;
10070  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10071  FW_ASSERT(
10072  _stat == Fw::FW_SERIALIZE_OK,
10073  static_cast<FwAssertArgType>(_stat)
10074  );
10075 
10076  this->tlmWrite(
10078  _tlmBuff,
10079  _tlmTime
10080  );
10081  }
10082  }
10083 
10087  Fw::Time _tlmTime
10088  )
10089  {
10090  // Check to see if it is the first time
10091  if (not this->m_first_update_Debug_StackSize) {
10092  // Check to see if value has changed. If not, don't write it.
10093  if (arg == this->m_last_Debug_StackSize) {
10094  return;
10095  }
10096  else {
10097  this->m_last_Debug_StackSize = arg;
10098  }
10099  }
10100  else {
10101  this->m_first_update_Debug_StackSize = false;
10102  this->m_last_Debug_StackSize = arg;
10103  }
10104 
10105  if (this->isConnected_tlmOut_OutputPort(0)) {
10106  Fw::TlmBuffer _tlmBuff;
10107  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10108  FW_ASSERT(
10109  _stat == Fw::FW_SERIALIZE_OK,
10110  static_cast<FwAssertArgType>(_stat)
10111  );
10112 
10113  this->tlmWrite(
10115  _tlmBuff,
10116  _tlmTime
10117  );
10118  }
10119  }
10120 
10123  bool arg,
10124  Fw::Time _tlmTime
10125  )
10126  {
10127  // Check to see if it is the first time
10128  if (not this->m_first_update_BreakpointInUse) {
10129  // Check to see if value has changed. If not, don't write it.
10130  if (arg == this->m_last_BreakpointInUse) {
10131  return;
10132  }
10133  else {
10134  this->m_last_BreakpointInUse = arg;
10135  }
10136  }
10137  else {
10138  this->m_first_update_BreakpointInUse = false;
10139  this->m_last_BreakpointInUse = arg;
10140  }
10141 
10142  if (this->isConnected_tlmOut_OutputPort(0)) {
10143  Fw::TlmBuffer _tlmBuff;
10144  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10145  FW_ASSERT(
10146  _stat == Fw::FW_SERIALIZE_OK,
10147  static_cast<FwAssertArgType>(_stat)
10148  );
10149 
10150  this->tlmWrite(
10152  _tlmBuff,
10153  _tlmTime
10154  );
10155  }
10156  }
10157 
10160  U32 arg,
10161  Fw::Time _tlmTime
10162  )
10163  {
10164  // Check to see if it is the first time
10165  if (not this->m_first_update_BreakpointIndex) {
10166  // Check to see if value has changed. If not, don't write it.
10167  if (arg == this->m_last_BreakpointIndex) {
10168  return;
10169  }
10170  else {
10171  this->m_last_BreakpointIndex = arg;
10172  }
10173  }
10174  else {
10175  this->m_first_update_BreakpointIndex = false;
10176  this->m_last_BreakpointIndex = arg;
10177  }
10178 
10179  if (this->isConnected_tlmOut_OutputPort(0)) {
10180  Fw::TlmBuffer _tlmBuff;
10181  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10182  FW_ASSERT(
10183  _stat == Fw::FW_SERIALIZE_OK,
10184  static_cast<FwAssertArgType>(_stat)
10185  );
10186 
10187  this->tlmWrite(
10189  _tlmBuff,
10190  _tlmTime
10191  );
10192  }
10193  }
10194 
10197  bool arg,
10198  Fw::Time _tlmTime
10199  )
10200  {
10201  // Check to see if it is the first time
10202  if (not this->m_first_update_BreakOnlyOnceOnBreakpoint) {
10203  // Check to see if value has changed. If not, don't write it.
10204  if (arg == this->m_last_BreakOnlyOnceOnBreakpoint) {
10205  return;
10206  }
10207  else {
10208  this->m_last_BreakOnlyOnceOnBreakpoint = arg;
10209  }
10210  }
10211  else {
10212  this->m_first_update_BreakOnlyOnceOnBreakpoint = false;
10213  this->m_last_BreakOnlyOnceOnBreakpoint = arg;
10214  }
10215 
10216  if (this->isConnected_tlmOut_OutputPort(0)) {
10217  Fw::TlmBuffer _tlmBuff;
10218  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10219  FW_ASSERT(
10220  _stat == Fw::FW_SERIALIZE_OK,
10221  static_cast<FwAssertArgType>(_stat)
10222  );
10223 
10224  this->tlmWrite(
10226  _tlmBuff,
10227  _tlmTime
10228  );
10229  }
10230  }
10231 
10234  bool arg,
10235  Fw::Time _tlmTime
10236  )
10237  {
10238  // Check to see if it is the first time
10239  if (not this->m_first_update_BreakBeforeNextLine) {
10240  // Check to see if value has changed. If not, don't write it.
10241  if (arg == this->m_last_BreakBeforeNextLine) {
10242  return;
10243  }
10244  else {
10245  this->m_last_BreakBeforeNextLine = arg;
10246  }
10247  }
10248  else {
10249  this->m_first_update_BreakBeforeNextLine = false;
10250  this->m_last_BreakBeforeNextLine = arg;
10251  }
10252 
10253  if (this->isConnected_tlmOut_OutputPort(0)) {
10254  Fw::TlmBuffer _tlmBuff;
10255  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10256  FW_ASSERT(
10257  _stat == Fw::FW_SERIALIZE_OK,
10258  static_cast<FwAssertArgType>(_stat)
10259  );
10260 
10261  this->tlmWrite(
10263  _tlmBuff,
10264  _tlmTime
10265  );
10266  }
10267  }
10268 
10271  F32 arg,
10272  Fw::Time _tlmTime
10273  )
10274  {
10275  // Check to see if it is the first time
10276  if (not this->m_first_update_PRM_STATEMENT_TIMEOUT_SECS) {
10277  // Check to see if value has changed. If not, don't write it.
10278  if (arg == this->m_last_PRM_STATEMENT_TIMEOUT_SECS) {
10279  return;
10280  }
10281  else {
10282  this->m_last_PRM_STATEMENT_TIMEOUT_SECS = arg;
10283  }
10284  }
10285  else {
10286  this->m_first_update_PRM_STATEMENT_TIMEOUT_SECS = false;
10287  this->m_last_PRM_STATEMENT_TIMEOUT_SECS = arg;
10288  }
10289 
10290  if (this->isConnected_tlmOut_OutputPort(0)) {
10291  Fw::TlmBuffer _tlmBuff;
10292  Fw::SerializeStatus _stat = _tlmBuff.serializeFrom(arg);
10293  FW_ASSERT(
10294  _stat == Fw::FW_SERIALIZE_OK,
10295  static_cast<FwAssertArgType>(_stat)
10296  );
10297 
10298  this->tlmWrite(
10300  _tlmBuff,
10301  _tlmTime
10302  );
10303  }
10304  }
10305 
10308  const Fw::StringBase& arg,
10309  Fw::Time _tlmTime
10310  )
10311  {
10312  // Check to see if it is the first time
10313  if (not this->m_first_update_PRM_SEQ_BASE_DIR) {
10314  // Check to see if value has changed. If not, don't write it.
10315  if (arg == this->m_last_PRM_SEQ_BASE_DIR) {
10316  return;
10317  }
10318  else {
10319  this->m_last_PRM_SEQ_BASE_DIR = arg;
10320  }
10321  }
10322  else {
10323  this->m_first_update_PRM_SEQ_BASE_DIR = false;
10324  this->m_last_PRM_SEQ_BASE_DIR = arg;
10325  }
10326 
10327  if (this->isConnected_tlmOut_OutputPort(0)) {
10328  Fw::TlmBuffer _tlmBuff;
10329  Fw::SerializeStatus _stat = arg.serializeTo(
10330  _tlmBuff,
10331  FW_MIN(static_cast<FwSizeType>(FW_TLM_STRING_MAX_SIZE), 240)
10332  );
10333  FW_ASSERT(
10334  _stat == Fw::FW_SERIALIZE_OK,
10335  static_cast<FwAssertArgType>(_stat)
10336  );
10337 
10338  this->tlmWrite(
10340  _tlmBuff,
10341  _tlmTime
10342  );
10343  }
10344  }
10345 
10346  // ----------------------------------------------------------------------
10347  // Parameter hook functions
10348  // ----------------------------------------------------------------------
10349 
10352  {
10353  // Do nothing by default
10354  }
10355 
10358  {
10359  // Do nothing by default
10360  }
10361 
10362  // ----------------------------------------------------------------------
10363  // Parameter get functions
10364  // ----------------------------------------------------------------------
10365 
10368  {
10369  F32 _local{};
10370  this->m_paramLock.lock();
10371  valid = this->m_param_STATEMENT_TIMEOUT_SECS_valid;
10372  if ((valid == Fw::ParamValid::VALID) || (valid == Fw::ParamValid::DEFAULT)) {
10373  _local = this->m_STATEMENT_TIMEOUT_SECS;
10374  }
10375  this->m_paramLock.unlock();
10376  return _local;
10377  }
10378 
10381  {
10382  Fw::ParamString _local{};
10383  this->m_paramLock.lock();
10384  valid = this->m_param_SEQ_BASE_DIR_valid;
10385  if ((valid == Fw::ParamValid::VALID) || (valid == Fw::ParamValid::DEFAULT)) {
10386  _local = this->m_SEQ_BASE_DIR;
10387  }
10388  this->m_paramLock.unlock();
10389  return _local;
10390  }
10391 
10392  // ----------------------------------------------------------------------
10393  // Time
10394  // ----------------------------------------------------------------------
10395 
10397  getTime() const
10398  {
10399  if (this->isConnected_timeCaller_OutputPort(0)) {
10400  Fw::Time _time;
10401  this->timeCaller_out(0, _time);
10402  return _time;
10403  }
10404  else {
10405  return Fw::Time(TimeBase::TB_NONE, 0, 0);
10406  }
10407  }
10408 
10409  // ----------------------------------------------------------------------
10410  // Message dispatch functions
10411  // ----------------------------------------------------------------------
10412 
10413  Fw::QueuedComponentBase::MsgDispatchStatus FpySequencerComponentBase ::
10414  doDispatch()
10415  {
10416  ComponentIpcSerializableBuffer _msg;
10417  FwQueuePriorityType _priority = 0;
10418 
10419  Os::Queue::Status _msgStatus = this->m_queue.receive(
10420  _msg,
10422  _priority
10423  );
10424  FW_ASSERT(
10425  _msgStatus == Os::Queue::OP_OK,
10426  static_cast<FwAssertArgType>(_msgStatus)
10427  );
10428 
10429  // Reset to beginning of buffer
10430  _msg.resetDeser();
10431 
10432  FwEnumStoreType _desMsg = 0;
10433  Fw::SerializeStatus _deserStatus = _msg.deserializeTo(_desMsg);
10434  FW_ASSERT(
10435  _deserStatus == Fw::FW_SERIALIZE_OK,
10436  static_cast<FwAssertArgType>(_deserStatus)
10437  );
10438 
10439  MsgTypeEnum _msgType = static_cast<MsgTypeEnum>(_desMsg);
10440 
10441  if (_msgType == FPYSEQUENCER_COMPONENT_EXIT) {
10442  return MSG_DISPATCH_EXIT;
10443  }
10444 
10445  FwIndexType portNum = 0;
10446  _deserStatus = _msg.deserializeTo(portNum);
10447  FW_ASSERT(
10448  _deserStatus == Fw::FW_SERIALIZE_OK,
10449  static_cast<FwAssertArgType>(_deserStatus)
10450  );
10451 
10452  switch (_msgType) {
10453  // Handle async input port checkTimers
10454  case CHECKTIMERS_SCHED: {
10455  // Deserialize argument context
10456  U32 context;
10457  _deserStatus = _msg.deserializeTo(context);
10458  FW_ASSERT(
10459  _deserStatus == Fw::FW_SERIALIZE_OK,
10460  static_cast<FwAssertArgType>(_deserStatus)
10461  );
10462  // Call handler function
10463  this->checkTimers_handler(
10464  portNum,
10465  context
10466  );
10467 
10468  break;
10469  }
10470 
10471  // Handle async input port cmdResponseIn
10472  case CMDRESPONSEIN_CMDRESPONSE: {
10473  // Deserialize argument opCode
10474  FwOpcodeType opCode;
10475  _deserStatus = _msg.deserializeTo(opCode);
10476  FW_ASSERT(
10477  _deserStatus == Fw::FW_SERIALIZE_OK,
10478  static_cast<FwAssertArgType>(_deserStatus)
10479  );
10480 
10481  // Deserialize argument cmdSeq
10482  U32 cmdSeq;
10483  _deserStatus = _msg.deserializeTo(cmdSeq);
10484  FW_ASSERT(
10485  _deserStatus == Fw::FW_SERIALIZE_OK,
10486  static_cast<FwAssertArgType>(_deserStatus)
10487  );
10488 
10489  // Deserialize argument response
10490  Fw::CmdResponse response;
10491  _deserStatus = _msg.deserializeTo(response);
10492  FW_ASSERT(
10493  _deserStatus == Fw::FW_SERIALIZE_OK,
10494  static_cast<FwAssertArgType>(_deserStatus)
10495  );
10496  // Call handler function
10497  this->cmdResponseIn_handler(
10498  portNum,
10499  opCode,
10500  cmdSeq,
10501  response
10502  );
10503 
10504  break;
10505  }
10506 
10507  // Handle async input port pingIn
10508  case PINGIN_PING: {
10509  // Deserialize argument key
10510  U32 key;
10511  _deserStatus = _msg.deserializeTo(key);
10512  FW_ASSERT(
10513  _deserStatus == Fw::FW_SERIALIZE_OK,
10514  static_cast<FwAssertArgType>(_deserStatus)
10515  );
10516  // Call handler function
10517  this->pingIn_handler(
10518  portNum,
10519  key
10520  );
10521 
10522  break;
10523  }
10524 
10525  // Handle async input port seqCancelIn
10526  case SEQCANCELIN_CMDSEQCANCEL: {
10527  // Call handler function
10528  this->seqCancelIn_handler(portNum);
10529 
10530  break;
10531  }
10532 
10533  // Handle async input port seqRunIn
10534  case SEQRUNIN_CMDSEQIN: {
10535  // Deserialize argument filename
10536  char __fprime_ac_filename_buffer[Fw::StringBase::BUFFER_SIZE(240)];
10537  Fw::ExternalString filename(__fprime_ac_filename_buffer, sizeof __fprime_ac_filename_buffer);
10538  _deserStatus = _msg.deserializeTo(filename);
10539  FW_ASSERT(
10540  _deserStatus == Fw::FW_SERIALIZE_OK,
10541  static_cast<FwAssertArgType>(_deserStatus)
10542  );
10543 
10544  // Deserialize argument args
10545  Svc::SeqArgs args;
10546  _deserStatus = _msg.deserializeTo(args);
10547  FW_ASSERT(
10548  _deserStatus == Fw::FW_SERIALIZE_OK,
10549  static_cast<FwAssertArgType>(_deserStatus)
10550  );
10551  // Call handler function
10552  this->seqRunIn_handler(
10553  portNum,
10554  filename,
10555  args
10556  );
10557 
10558  break;
10559  }
10560 
10561  // Handle async input port tlmWrite
10562  case TLMWRITE_SCHED: {
10563  // Deserialize argument context
10564  U32 context;
10565  _deserStatus = _msg.deserializeTo(context);
10566  FW_ASSERT(
10567  _deserStatus == Fw::FW_SERIALIZE_OK,
10568  static_cast<FwAssertArgType>(_deserStatus)
10569  );
10570  // Call handler function
10571  this->tlmWrite_handler(
10572  portNum,
10573  context
10574  );
10575 
10576  break;
10577  }
10578 
10579  // Handle command RUN
10580  case CMD_RUN: {
10581  // Deserialize opcode
10582  FwOpcodeType _opCode = 0;
10583  _deserStatus = _msg.deserializeTo(_opCode);
10584  FW_ASSERT (
10585  _deserStatus == Fw::FW_SERIALIZE_OK,
10586  static_cast<FwAssertArgType>(_deserStatus)
10587  );
10588 
10589  // Deserialize command sequence
10590  U32 _cmdSeq = 0;
10591  _deserStatus = _msg.deserializeTo(_cmdSeq);
10592  FW_ASSERT (
10593  _deserStatus == Fw::FW_SERIALIZE_OK,
10594  static_cast<FwAssertArgType>(_deserStatus)
10595  );
10596 
10597  // Deserialize command argument buffer
10598  Fw::CmdArgBuffer args;
10599  _deserStatus = _msg.deserializeTo(args);
10600  FW_ASSERT (
10601  _deserStatus == Fw::FW_SERIALIZE_OK,
10602  static_cast<FwAssertArgType>(_deserStatus)
10603  );
10604 
10605  // Reset buffer
10606  args.resetDeser();
10607 
10608  // Deserialize argument fileName
10609  Fw::CmdStringArg fileName;
10610  _deserStatus = args.deserializeTo(fileName);
10611  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10613  this->cmdResponse_out(
10614  _opCode,
10615  _cmdSeq,
10617  );
10618  }
10619  // Don't crash the task if bad arguments were passed from the ground
10620  break;
10621  }
10622 
10623  // Deserialize argument block
10624  Svc::BlockState block;
10625  _deserStatus = args.deserializeTo(block);
10626  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10628  this->cmdResponse_out(
10629  _opCode,
10630  _cmdSeq,
10632  );
10633  }
10634  // Don't crash the task if bad arguments were passed from the ground
10635  break;
10636  }
10637 
10638  // Make sure there was no data left over.
10639  // That means the argument buffer size was incorrect.
10640 #if FW_CMD_CHECK_RESIDUAL
10641  if (args.getDeserializeSizeLeft() != 0) {
10643  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
10644  }
10645  // Don't crash the task if bad arguments were passed from the ground
10646  break;
10647  }
10648 #endif
10649 
10650  // Call handler function
10651  this->RUN_cmdHandler(
10652  _opCode, _cmdSeq,
10653  fileName,
10654  block
10655  );
10656 
10657  break;
10658  }
10659 
10660  // Handle command RUN_ARGS
10661  case CMD_RUN_ARGS: {
10662  // Deserialize opcode
10663  FwOpcodeType _opCode = 0;
10664  _deserStatus = _msg.deserializeTo(_opCode);
10665  FW_ASSERT (
10666  _deserStatus == Fw::FW_SERIALIZE_OK,
10667  static_cast<FwAssertArgType>(_deserStatus)
10668  );
10669 
10670  // Deserialize command sequence
10671  U32 _cmdSeq = 0;
10672  _deserStatus = _msg.deserializeTo(_cmdSeq);
10673  FW_ASSERT (
10674  _deserStatus == Fw::FW_SERIALIZE_OK,
10675  static_cast<FwAssertArgType>(_deserStatus)
10676  );
10677 
10678  // Deserialize command argument buffer
10679  Fw::CmdArgBuffer args;
10680  _deserStatus = _msg.deserializeTo(args);
10681  FW_ASSERT (
10682  _deserStatus == Fw::FW_SERIALIZE_OK,
10683  static_cast<FwAssertArgType>(_deserStatus)
10684  );
10685 
10686  // Reset buffer
10687  args.resetDeser();
10688 
10689  // Deserialize argument fileName
10690  Fw::CmdStringArg fileName;
10691  _deserStatus = args.deserializeTo(fileName);
10692  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10694  this->cmdResponse_out(
10695  _opCode,
10696  _cmdSeq,
10698  );
10699  }
10700  // Don't crash the task if bad arguments were passed from the ground
10701  break;
10702  }
10703 
10704  // Deserialize argument block
10705  Svc::BlockState block;
10706  _deserStatus = args.deserializeTo(block);
10707  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10709  this->cmdResponse_out(
10710  _opCode,
10711  _cmdSeq,
10713  );
10714  }
10715  // Don't crash the task if bad arguments were passed from the ground
10716  break;
10717  }
10718 
10719  // Deserialize argument buffer
10720  Svc::SeqArgs buffer;
10721  _deserStatus = args.deserializeTo(buffer);
10722  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10724  this->cmdResponse_out(
10725  _opCode,
10726  _cmdSeq,
10728  );
10729  }
10730  // Don't crash the task if bad arguments were passed from the ground
10731  break;
10732  }
10733 
10734  // Make sure there was no data left over.
10735  // That means the argument buffer size was incorrect.
10736 #if FW_CMD_CHECK_RESIDUAL
10737  if (args.getDeserializeSizeLeft() != 0) {
10739  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
10740  }
10741  // Don't crash the task if bad arguments were passed from the ground
10742  break;
10743  }
10744 #endif
10745 
10746  // Call handler function
10747  this->RUN_ARGS_cmdHandler(
10748  _opCode, _cmdSeq,
10749  fileName,
10750  block,
10751  buffer
10752  );
10753 
10754  break;
10755  }
10756 
10757  // Handle command VALIDATE
10758  case CMD_VALIDATE: {
10759  // Deserialize opcode
10760  FwOpcodeType _opCode = 0;
10761  _deserStatus = _msg.deserializeTo(_opCode);
10762  FW_ASSERT (
10763  _deserStatus == Fw::FW_SERIALIZE_OK,
10764  static_cast<FwAssertArgType>(_deserStatus)
10765  );
10766 
10767  // Deserialize command sequence
10768  U32 _cmdSeq = 0;
10769  _deserStatus = _msg.deserializeTo(_cmdSeq);
10770  FW_ASSERT (
10771  _deserStatus == Fw::FW_SERIALIZE_OK,
10772  static_cast<FwAssertArgType>(_deserStatus)
10773  );
10774 
10775  // Deserialize command argument buffer
10776  Fw::CmdArgBuffer args;
10777  _deserStatus = _msg.deserializeTo(args);
10778  FW_ASSERT (
10779  _deserStatus == Fw::FW_SERIALIZE_OK,
10780  static_cast<FwAssertArgType>(_deserStatus)
10781  );
10782 
10783  // Reset buffer
10784  args.resetDeser();
10785 
10786  // Deserialize argument fileName
10787  Fw::CmdStringArg fileName;
10788  _deserStatus = args.deserializeTo(fileName);
10789  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10791  this->cmdResponse_out(
10792  _opCode,
10793  _cmdSeq,
10795  );
10796  }
10797  // Don't crash the task if bad arguments were passed from the ground
10798  break;
10799  }
10800 
10801  // Make sure there was no data left over.
10802  // That means the argument buffer size was incorrect.
10803 #if FW_CMD_CHECK_RESIDUAL
10804  if (args.getDeserializeSizeLeft() != 0) {
10806  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
10807  }
10808  // Don't crash the task if bad arguments were passed from the ground
10809  break;
10810  }
10811 #endif
10812 
10813  // Call handler function
10814  this->VALIDATE_cmdHandler(
10815  _opCode, _cmdSeq,
10816  fileName
10817  );
10818 
10819  break;
10820  }
10821 
10822  // Handle command VALIDATE_ARGS
10823  case CMD_VALIDATE_ARGS: {
10824  // Deserialize opcode
10825  FwOpcodeType _opCode = 0;
10826  _deserStatus = _msg.deserializeTo(_opCode);
10827  FW_ASSERT (
10828  _deserStatus == Fw::FW_SERIALIZE_OK,
10829  static_cast<FwAssertArgType>(_deserStatus)
10830  );
10831 
10832  // Deserialize command sequence
10833  U32 _cmdSeq = 0;
10834  _deserStatus = _msg.deserializeTo(_cmdSeq);
10835  FW_ASSERT (
10836  _deserStatus == Fw::FW_SERIALIZE_OK,
10837  static_cast<FwAssertArgType>(_deserStatus)
10838  );
10839 
10840  // Deserialize command argument buffer
10841  Fw::CmdArgBuffer args;
10842  _deserStatus = _msg.deserializeTo(args);
10843  FW_ASSERT (
10844  _deserStatus == Fw::FW_SERIALIZE_OK,
10845  static_cast<FwAssertArgType>(_deserStatus)
10846  );
10847 
10848  // Reset buffer
10849  args.resetDeser();
10850 
10851  // Deserialize argument fileName
10852  Fw::CmdStringArg fileName;
10853  _deserStatus = args.deserializeTo(fileName);
10854  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10856  this->cmdResponse_out(
10857  _opCode,
10858  _cmdSeq,
10860  );
10861  }
10862  // Don't crash the task if bad arguments were passed from the ground
10863  break;
10864  }
10865 
10866  // Deserialize argument buffer
10867  Svc::SeqArgs buffer;
10868  _deserStatus = args.deserializeTo(buffer);
10869  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10871  this->cmdResponse_out(
10872  _opCode,
10873  _cmdSeq,
10875  );
10876  }
10877  // Don't crash the task if bad arguments were passed from the ground
10878  break;
10879  }
10880 
10881  // Make sure there was no data left over.
10882  // That means the argument buffer size was incorrect.
10883 #if FW_CMD_CHECK_RESIDUAL
10884  if (args.getDeserializeSizeLeft() != 0) {
10886  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
10887  }
10888  // Don't crash the task if bad arguments were passed from the ground
10889  break;
10890  }
10891 #endif
10892 
10893  // Call handler function
10895  _opCode, _cmdSeq,
10896  fileName,
10897  buffer
10898  );
10899 
10900  break;
10901  }
10902 
10903  // Handle command RUN_VALIDATED
10904  case CMD_RUN_VALIDATED: {
10905  // Deserialize opcode
10906  FwOpcodeType _opCode = 0;
10907  _deserStatus = _msg.deserializeTo(_opCode);
10908  FW_ASSERT (
10909  _deserStatus == Fw::FW_SERIALIZE_OK,
10910  static_cast<FwAssertArgType>(_deserStatus)
10911  );
10912 
10913  // Deserialize command sequence
10914  U32 _cmdSeq = 0;
10915  _deserStatus = _msg.deserializeTo(_cmdSeq);
10916  FW_ASSERT (
10917  _deserStatus == Fw::FW_SERIALIZE_OK,
10918  static_cast<FwAssertArgType>(_deserStatus)
10919  );
10920 
10921  // Deserialize command argument buffer
10922  Fw::CmdArgBuffer args;
10923  _deserStatus = _msg.deserializeTo(args);
10924  FW_ASSERT (
10925  _deserStatus == Fw::FW_SERIALIZE_OK,
10926  static_cast<FwAssertArgType>(_deserStatus)
10927  );
10928 
10929  // Reset buffer
10930  args.resetDeser();
10931 
10932  // Deserialize argument block
10933  Svc::BlockState block;
10934  _deserStatus = args.deserializeTo(block);
10935  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
10937  this->cmdResponse_out(
10938  _opCode,
10939  _cmdSeq,
10941  );
10942  }
10943  // Don't crash the task if bad arguments were passed from the ground
10944  break;
10945  }
10946 
10947  // Make sure there was no data left over.
10948  // That means the argument buffer size was incorrect.
10949 #if FW_CMD_CHECK_RESIDUAL
10950  if (args.getDeserializeSizeLeft() != 0) {
10952  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
10953  }
10954  // Don't crash the task if bad arguments were passed from the ground
10955  break;
10956  }
10957 #endif
10958 
10959  // Call handler function
10961  _opCode, _cmdSeq,
10962  block
10963  );
10964 
10965  break;
10966  }
10967 
10968  // Handle command CANCEL
10969  case CMD_CANCEL: {
10970  // Deserialize opcode
10971  FwOpcodeType _opCode = 0;
10972  _deserStatus = _msg.deserializeTo(_opCode);
10973  FW_ASSERT (
10974  _deserStatus == Fw::FW_SERIALIZE_OK,
10975  static_cast<FwAssertArgType>(_deserStatus)
10976  );
10977 
10978  // Deserialize command sequence
10979  U32 _cmdSeq = 0;
10980  _deserStatus = _msg.deserializeTo(_cmdSeq);
10981  FW_ASSERT (
10982  _deserStatus == Fw::FW_SERIALIZE_OK,
10983  static_cast<FwAssertArgType>(_deserStatus)
10984  );
10985 
10986  // Deserialize command argument buffer
10987  Fw::CmdArgBuffer args;
10988  _deserStatus = _msg.deserializeTo(args);
10989  FW_ASSERT (
10990  _deserStatus == Fw::FW_SERIALIZE_OK,
10991  static_cast<FwAssertArgType>(_deserStatus)
10992  );
10993 
10994  // Reset buffer
10995  args.resetDeser();
10996 
10997  // Make sure there was no data left over.
10998  // That means the argument buffer size was incorrect.
10999 #if FW_CMD_CHECK_RESIDUAL
11000  if (args.getDeserializeSizeLeft() != 0) {
11002  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
11003  }
11004  // Don't crash the task if bad arguments were passed from the ground
11005  break;
11006  }
11007 #endif
11008 
11009  // Call handler function
11010  this->CANCEL_cmdHandler(_opCode, _cmdSeq);
11011 
11012  break;
11013  }
11014 
11015  // Handle command SET_BREAKPOINT
11016  case CMD_SET_BREAKPOINT: {
11017  // Deserialize opcode
11018  FwOpcodeType _opCode = 0;
11019  _deserStatus = _msg.deserializeTo(_opCode);
11020  FW_ASSERT (
11021  _deserStatus == Fw::FW_SERIALIZE_OK,
11022  static_cast<FwAssertArgType>(_deserStatus)
11023  );
11024 
11025  // Deserialize command sequence
11026  U32 _cmdSeq = 0;
11027  _deserStatus = _msg.deserializeTo(_cmdSeq);
11028  FW_ASSERT (
11029  _deserStatus == Fw::FW_SERIALIZE_OK,
11030  static_cast<FwAssertArgType>(_deserStatus)
11031  );
11032 
11033  // Deserialize command argument buffer
11034  Fw::CmdArgBuffer args;
11035  _deserStatus = _msg.deserializeTo(args);
11036  FW_ASSERT (
11037  _deserStatus == Fw::FW_SERIALIZE_OK,
11038  static_cast<FwAssertArgType>(_deserStatus)
11039  );
11040 
11041  // Reset buffer
11042  args.resetDeser();
11043 
11044  // Deserialize argument stmtIdx
11045  U32 stmtIdx;
11046  _deserStatus = args.deserializeTo(stmtIdx);
11047  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
11049  this->cmdResponse_out(
11050  _opCode,
11051  _cmdSeq,
11053  );
11054  }
11055  // Don't crash the task if bad arguments were passed from the ground
11056  break;
11057  }
11058 
11059  // Deserialize argument breakOnce
11060  bool breakOnce;
11061  _deserStatus = args.deserializeTo(breakOnce);
11062  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
11064  this->cmdResponse_out(
11065  _opCode,
11066  _cmdSeq,
11068  );
11069  }
11070  // Don't crash the task if bad arguments were passed from the ground
11071  break;
11072  }
11073 
11074  // Make sure there was no data left over.
11075  // That means the argument buffer size was incorrect.
11076 #if FW_CMD_CHECK_RESIDUAL
11077  if (args.getDeserializeSizeLeft() != 0) {
11079  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
11080  }
11081  // Don't crash the task if bad arguments were passed from the ground
11082  break;
11083  }
11084 #endif
11085 
11086  // Call handler function
11088  _opCode, _cmdSeq,
11089  stmtIdx,
11090  breakOnce
11091  );
11092 
11093  break;
11094  }
11095 
11096  // Handle command BREAK
11097  case CMD_BREAK: {
11098  // Deserialize opcode
11099  FwOpcodeType _opCode = 0;
11100  _deserStatus = _msg.deserializeTo(_opCode);
11101  FW_ASSERT (
11102  _deserStatus == Fw::FW_SERIALIZE_OK,
11103  static_cast<FwAssertArgType>(_deserStatus)
11104  );
11105 
11106  // Deserialize command sequence
11107  U32 _cmdSeq = 0;
11108  _deserStatus = _msg.deserializeTo(_cmdSeq);
11109  FW_ASSERT (
11110  _deserStatus == Fw::FW_SERIALIZE_OK,
11111  static_cast<FwAssertArgType>(_deserStatus)
11112  );
11113 
11114  // Deserialize command argument buffer
11115  Fw::CmdArgBuffer args;
11116  _deserStatus = _msg.deserializeTo(args);
11117  FW_ASSERT (
11118  _deserStatus == Fw::FW_SERIALIZE_OK,
11119  static_cast<FwAssertArgType>(_deserStatus)
11120  );
11121 
11122  // Reset buffer
11123  args.resetDeser();
11124 
11125  // Make sure there was no data left over.
11126  // That means the argument buffer size was incorrect.
11127 #if FW_CMD_CHECK_RESIDUAL
11128  if (args.getDeserializeSizeLeft() != 0) {
11130  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
11131  }
11132  // Don't crash the task if bad arguments were passed from the ground
11133  break;
11134  }
11135 #endif
11136 
11137  // Call handler function
11138  this->BREAK_cmdHandler(_opCode, _cmdSeq);
11139 
11140  break;
11141  }
11142 
11143  // Handle command CONTINUE
11144  case CMD_CONTINUE: {
11145  // Deserialize opcode
11146  FwOpcodeType _opCode = 0;
11147  _deserStatus = _msg.deserializeTo(_opCode);
11148  FW_ASSERT (
11149  _deserStatus == Fw::FW_SERIALIZE_OK,
11150  static_cast<FwAssertArgType>(_deserStatus)
11151  );
11152 
11153  // Deserialize command sequence
11154  U32 _cmdSeq = 0;
11155  _deserStatus = _msg.deserializeTo(_cmdSeq);
11156  FW_ASSERT (
11157  _deserStatus == Fw::FW_SERIALIZE_OK,
11158  static_cast<FwAssertArgType>(_deserStatus)
11159  );
11160 
11161  // Deserialize command argument buffer
11162  Fw::CmdArgBuffer args;
11163  _deserStatus = _msg.deserializeTo(args);
11164  FW_ASSERT (
11165  _deserStatus == Fw::FW_SERIALIZE_OK,
11166  static_cast<FwAssertArgType>(_deserStatus)
11167  );
11168 
11169  // Reset buffer
11170  args.resetDeser();
11171 
11172  // Make sure there was no data left over.
11173  // That means the argument buffer size was incorrect.
11174 #if FW_CMD_CHECK_RESIDUAL
11175  if (args.getDeserializeSizeLeft() != 0) {
11177  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
11178  }
11179  // Don't crash the task if bad arguments were passed from the ground
11180  break;
11181  }
11182 #endif
11183 
11184  // Call handler function
11185  this->CONTINUE_cmdHandler(_opCode, _cmdSeq);
11186 
11187  break;
11188  }
11189 
11190  // Handle command CLEAR_BREAKPOINT
11191  case CMD_CLEAR_BREAKPOINT: {
11192  // Deserialize opcode
11193  FwOpcodeType _opCode = 0;
11194  _deserStatus = _msg.deserializeTo(_opCode);
11195  FW_ASSERT (
11196  _deserStatus == Fw::FW_SERIALIZE_OK,
11197  static_cast<FwAssertArgType>(_deserStatus)
11198  );
11199 
11200  // Deserialize command sequence
11201  U32 _cmdSeq = 0;
11202  _deserStatus = _msg.deserializeTo(_cmdSeq);
11203  FW_ASSERT (
11204  _deserStatus == Fw::FW_SERIALIZE_OK,
11205  static_cast<FwAssertArgType>(_deserStatus)
11206  );
11207 
11208  // Deserialize command argument buffer
11209  Fw::CmdArgBuffer args;
11210  _deserStatus = _msg.deserializeTo(args);
11211  FW_ASSERT (
11212  _deserStatus == Fw::FW_SERIALIZE_OK,
11213  static_cast<FwAssertArgType>(_deserStatus)
11214  );
11215 
11216  // Reset buffer
11217  args.resetDeser();
11218 
11219  // Make sure there was no data left over.
11220  // That means the argument buffer size was incorrect.
11221 #if FW_CMD_CHECK_RESIDUAL
11222  if (args.getDeserializeSizeLeft() != 0) {
11224  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
11225  }
11226  // Don't crash the task if bad arguments were passed from the ground
11227  break;
11228  }
11229 #endif
11230 
11231  // Call handler function
11232  this->CLEAR_BREAKPOINT_cmdHandler(_opCode, _cmdSeq);
11233 
11234  break;
11235  }
11236 
11237  // Handle command STEP
11238  case CMD_STEP: {
11239  // Deserialize opcode
11240  FwOpcodeType _opCode = 0;
11241  _deserStatus = _msg.deserializeTo(_opCode);
11242  FW_ASSERT (
11243  _deserStatus == Fw::FW_SERIALIZE_OK,
11244  static_cast<FwAssertArgType>(_deserStatus)
11245  );
11246 
11247  // Deserialize command sequence
11248  U32 _cmdSeq = 0;
11249  _deserStatus = _msg.deserializeTo(_cmdSeq);
11250  FW_ASSERT (
11251  _deserStatus == Fw::FW_SERIALIZE_OK,
11252  static_cast<FwAssertArgType>(_deserStatus)
11253  );
11254 
11255  // Deserialize command argument buffer
11256  Fw::CmdArgBuffer args;
11257  _deserStatus = _msg.deserializeTo(args);
11258  FW_ASSERT (
11259  _deserStatus == Fw::FW_SERIALIZE_OK,
11260  static_cast<FwAssertArgType>(_deserStatus)
11261  );
11262 
11263  // Reset buffer
11264  args.resetDeser();
11265 
11266  // Make sure there was no data left over.
11267  // That means the argument buffer size was incorrect.
11268 #if FW_CMD_CHECK_RESIDUAL
11269  if (args.getDeserializeSizeLeft() != 0) {
11271  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
11272  }
11273  // Don't crash the task if bad arguments were passed from the ground
11274  break;
11275  }
11276 #endif
11277 
11278  // Call handler function
11279  this->STEP_cmdHandler(_opCode, _cmdSeq);
11280 
11281  break;
11282  }
11283 
11284  // Handle command DUMP_STACK_TO_FILE
11285  case CMD_DUMP_STACK_TO_FILE: {
11286  // Deserialize opcode
11287  FwOpcodeType _opCode = 0;
11288  _deserStatus = _msg.deserializeTo(_opCode);
11289  FW_ASSERT (
11290  _deserStatus == Fw::FW_SERIALIZE_OK,
11291  static_cast<FwAssertArgType>(_deserStatus)
11292  );
11293 
11294  // Deserialize command sequence
11295  U32 _cmdSeq = 0;
11296  _deserStatus = _msg.deserializeTo(_cmdSeq);
11297  FW_ASSERT (
11298  _deserStatus == Fw::FW_SERIALIZE_OK,
11299  static_cast<FwAssertArgType>(_deserStatus)
11300  );
11301 
11302  // Deserialize command argument buffer
11303  Fw::CmdArgBuffer args;
11304  _deserStatus = _msg.deserializeTo(args);
11305  FW_ASSERT (
11306  _deserStatus == Fw::FW_SERIALIZE_OK,
11307  static_cast<FwAssertArgType>(_deserStatus)
11308  );
11309 
11310  // Reset buffer
11311  args.resetDeser();
11312 
11313  // Deserialize argument fileName
11314  Fw::CmdStringArg fileName;
11315  _deserStatus = args.deserializeTo(fileName);
11316  if (_deserStatus != Fw::FW_SERIALIZE_OK) {
11318  this->cmdResponse_out(
11319  _opCode,
11320  _cmdSeq,
11322  );
11323  }
11324  // Don't crash the task if bad arguments were passed from the ground
11325  break;
11326  }
11327 
11328  // Make sure there was no data left over.
11329  // That means the argument buffer size was incorrect.
11330 #if FW_CMD_CHECK_RESIDUAL
11331  if (args.getDeserializeSizeLeft() != 0) {
11333  this->cmdResponse_out(_opCode, _cmdSeq, Fw::CmdResponse::FORMAT_ERROR);
11334  }
11335  // Don't crash the task if bad arguments were passed from the ground
11336  break;
11337  }
11338 #endif
11339 
11340  // Call handler function
11342  _opCode, _cmdSeq,
11343  fileName
11344  );
11345 
11346  break;
11347  }
11348 
11349  // Handle internal interface directive_allocate
11350  case INT_IF_DIRECTIVE_ALLOCATE: {
11352  _deserStatus = _msg.deserializeTo(directive);
11353 
11354  // Internal interface should always deserialize
11355  FW_ASSERT(
11356  Fw::FW_SERIALIZE_OK == _deserStatus,
11357  static_cast<FwAssertArgType>(_deserStatus)
11358  );
11359 
11360  // Make sure there was no data left over.
11361  // That means the buffer size was incorrect.
11362  FW_ASSERT(
11363  _msg.getDeserializeSizeLeft() == 0,
11364  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11365  );
11366 
11367  // Call handler function
11369  directive
11370  );
11371 
11372  break;
11373  }
11374 
11375  // Handle internal interface directive_call
11376  case INT_IF_DIRECTIVE_CALL: {
11378  _deserStatus = _msg.deserializeTo(directive);
11379 
11380  // Internal interface should always deserialize
11381  FW_ASSERT(
11382  Fw::FW_SERIALIZE_OK == _deserStatus,
11383  static_cast<FwAssertArgType>(_deserStatus)
11384  );
11385 
11386  // Make sure there was no data left over.
11387  // That means the buffer size was incorrect.
11388  FW_ASSERT(
11389  _msg.getDeserializeSizeLeft() == 0,
11390  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11391  );
11392 
11393  // Call handler function
11395  directive
11396  );
11397 
11398  break;
11399  }
11400 
11401  // Handle internal interface directive_constCmd
11402  case INT_IF_DIRECTIVE_CONSTCMD: {
11404  _deserStatus = _msg.deserializeTo(directive);
11405 
11406  // Internal interface should always deserialize
11407  FW_ASSERT(
11408  Fw::FW_SERIALIZE_OK == _deserStatus,
11409  static_cast<FwAssertArgType>(_deserStatus)
11410  );
11411 
11412  // Make sure there was no data left over.
11413  // That means the buffer size was incorrect.
11414  FW_ASSERT(
11415  _msg.getDeserializeSizeLeft() == 0,
11416  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11417  );
11418 
11419  // Call handler function
11421  directive
11422  );
11423 
11424  break;
11425  }
11426 
11427  // Handle internal interface directive_discard
11428  case INT_IF_DIRECTIVE_DISCARD: {
11430  _deserStatus = _msg.deserializeTo(directive);
11431 
11432  // Internal interface should always deserialize
11433  FW_ASSERT(
11434  Fw::FW_SERIALIZE_OK == _deserStatus,
11435  static_cast<FwAssertArgType>(_deserStatus)
11436  );
11437 
11438  // Make sure there was no data left over.
11439  // That means the buffer size was incorrect.
11440  FW_ASSERT(
11441  _msg.getDeserializeSizeLeft() == 0,
11442  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11443  );
11444 
11445  // Call handler function
11447  directive
11448  );
11449 
11450  break;
11451  }
11452 
11453  // Handle internal interface directive_exit
11454  case INT_IF_DIRECTIVE_EXIT: {
11456  _deserStatus = _msg.deserializeTo(directive);
11457 
11458  // Internal interface should always deserialize
11459  FW_ASSERT(
11460  Fw::FW_SERIALIZE_OK == _deserStatus,
11461  static_cast<FwAssertArgType>(_deserStatus)
11462  );
11463 
11464  // Make sure there was no data left over.
11465  // That means the buffer size was incorrect.
11466  FW_ASSERT(
11467  _msg.getDeserializeSizeLeft() == 0,
11468  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11469  );
11470 
11471  // Call handler function
11473  directive
11474  );
11475 
11476  break;
11477  }
11478 
11479  // Handle internal interface directive_getField
11480  case INT_IF_DIRECTIVE_GETFIELD: {
11482  _deserStatus = _msg.deserializeTo(directive);
11483 
11484  // Internal interface should always deserialize
11485  FW_ASSERT(
11486  Fw::FW_SERIALIZE_OK == _deserStatus,
11487  static_cast<FwAssertArgType>(_deserStatus)
11488  );
11489 
11490  // Make sure there was no data left over.
11491  // That means the buffer size was incorrect.
11492  FW_ASSERT(
11493  _msg.getDeserializeSizeLeft() == 0,
11494  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11495  );
11496 
11497  // Call handler function
11499  directive
11500  );
11501 
11502  break;
11503  }
11504 
11505  // Handle internal interface directive_goto
11506  case INT_IF_DIRECTIVE_GOTO: {
11508  _deserStatus = _msg.deserializeTo(directive);
11509 
11510  // Internal interface should always deserialize
11511  FW_ASSERT(
11512  Fw::FW_SERIALIZE_OK == _deserStatus,
11513  static_cast<FwAssertArgType>(_deserStatus)
11514  );
11515 
11516  // Make sure there was no data left over.
11517  // That means the buffer size was incorrect.
11518  FW_ASSERT(
11519  _msg.getDeserializeSizeLeft() == 0,
11520  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11521  );
11522 
11523  // Call handler function
11525  directive
11526  );
11527 
11528  break;
11529  }
11530 
11531  // Handle internal interface directive_if
11532  case INT_IF_DIRECTIVE_IF: {
11534  _deserStatus = _msg.deserializeTo(directive);
11535 
11536  // Internal interface should always deserialize
11537  FW_ASSERT(
11538  Fw::FW_SERIALIZE_OK == _deserStatus,
11539  static_cast<FwAssertArgType>(_deserStatus)
11540  );
11541 
11542  // Make sure there was no data left over.
11543  // That means the buffer size was incorrect.
11544  FW_ASSERT(
11545  _msg.getDeserializeSizeLeft() == 0,
11546  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11547  );
11548 
11549  // Call handler function
11551  directive
11552  );
11553 
11554  break;
11555  }
11556 
11557  // Handle internal interface directive_loadAbs
11558  case INT_IF_DIRECTIVE_LOADABS: {
11560  _deserStatus = _msg.deserializeTo(directive);
11561 
11562  // Internal interface should always deserialize
11563  FW_ASSERT(
11564  Fw::FW_SERIALIZE_OK == _deserStatus,
11565  static_cast<FwAssertArgType>(_deserStatus)
11566  );
11567 
11568  // Make sure there was no data left over.
11569  // That means the buffer size was incorrect.
11570  FW_ASSERT(
11571  _msg.getDeserializeSizeLeft() == 0,
11572  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11573  );
11574 
11575  // Call handler function
11577  directive
11578  );
11579 
11580  break;
11581  }
11582 
11583  // Handle internal interface directive_loadRel
11584  case INT_IF_DIRECTIVE_LOADREL: {
11586  _deserStatus = _msg.deserializeTo(directive);
11587 
11588  // Internal interface should always deserialize
11589  FW_ASSERT(
11590  Fw::FW_SERIALIZE_OK == _deserStatus,
11591  static_cast<FwAssertArgType>(_deserStatus)
11592  );
11593 
11594  // Make sure there was no data left over.
11595  // That means the buffer size was incorrect.
11596  FW_ASSERT(
11597  _msg.getDeserializeSizeLeft() == 0,
11598  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11599  );
11600 
11601  // Call handler function
11603  directive
11604  );
11605 
11606  break;
11607  }
11608 
11609  // Handle internal interface directive_memCmp
11610  case INT_IF_DIRECTIVE_MEMCMP: {
11612  _deserStatus = _msg.deserializeTo(directive);
11613 
11614  // Internal interface should always deserialize
11615  FW_ASSERT(
11616  Fw::FW_SERIALIZE_OK == _deserStatus,
11617  static_cast<FwAssertArgType>(_deserStatus)
11618  );
11619 
11620  // Make sure there was no data left over.
11621  // That means the buffer size was incorrect.
11622  FW_ASSERT(
11623  _msg.getDeserializeSizeLeft() == 0,
11624  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11625  );
11626 
11627  // Call handler function
11629  directive
11630  );
11631 
11632  break;
11633  }
11634 
11635  // Handle internal interface directive_noOp
11636  case INT_IF_DIRECTIVE_NOOP: {
11638  _deserStatus = _msg.deserializeTo(directive);
11639 
11640  // Internal interface should always deserialize
11641  FW_ASSERT(
11642  Fw::FW_SERIALIZE_OK == _deserStatus,
11643  static_cast<FwAssertArgType>(_deserStatus)
11644  );
11645 
11646  // Make sure there was no data left over.
11647  // That means the buffer size was incorrect.
11648  FW_ASSERT(
11649  _msg.getDeserializeSizeLeft() == 0,
11650  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11651  );
11652 
11653  // Call handler function
11655  directive
11656  );
11657 
11658  break;
11659  }
11660 
11661  // Handle internal interface directive_peek
11662  case INT_IF_DIRECTIVE_PEEK: {
11664  _deserStatus = _msg.deserializeTo(directive);
11665 
11666  // Internal interface should always deserialize
11667  FW_ASSERT(
11668  Fw::FW_SERIALIZE_OK == _deserStatus,
11669  static_cast<FwAssertArgType>(_deserStatus)
11670  );
11671 
11672  // Make sure there was no data left over.
11673  // That means the buffer size was incorrect.
11674  FW_ASSERT(
11675  _msg.getDeserializeSizeLeft() == 0,
11676  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11677  );
11678 
11679  // Call handler function
11681  directive
11682  );
11683 
11684  break;
11685  }
11686 
11687  // Handle internal interface directive_popEvent
11688  case INT_IF_DIRECTIVE_POPEVENT: {
11690  _deserStatus = _msg.deserializeTo(directive);
11691 
11692  // Internal interface should always deserialize
11693  FW_ASSERT(
11694  Fw::FW_SERIALIZE_OK == _deserStatus,
11695  static_cast<FwAssertArgType>(_deserStatus)
11696  );
11697 
11698  // Make sure there was no data left over.
11699  // That means the buffer size was incorrect.
11700  FW_ASSERT(
11701  _msg.getDeserializeSizeLeft() == 0,
11702  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11703  );
11704 
11705  // Call handler function
11707  directive
11708  );
11709 
11710  break;
11711  }
11712 
11713  // Handle internal interface directive_popSerializable
11714  case INT_IF_DIRECTIVE_POPSERIALIZABLE: {
11716  _deserStatus = _msg.deserializeTo(directive);
11717 
11718  // Internal interface should always deserialize
11719  FW_ASSERT(
11720  Fw::FW_SERIALIZE_OK == _deserStatus,
11721  static_cast<FwAssertArgType>(_deserStatus)
11722  );
11723 
11724  // Make sure there was no data left over.
11725  // That means the buffer size was incorrect.
11726  FW_ASSERT(
11727  _msg.getDeserializeSizeLeft() == 0,
11728  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11729  );
11730 
11731  // Call handler function
11733  directive
11734  );
11735 
11736  break;
11737  }
11738 
11739  // Handle internal interface directive_pushPrm
11740  case INT_IF_DIRECTIVE_PUSHPRM: {
11742  _deserStatus = _msg.deserializeTo(directive);
11743 
11744  // Internal interface should always deserialize
11745  FW_ASSERT(
11746  Fw::FW_SERIALIZE_OK == _deserStatus,
11747  static_cast<FwAssertArgType>(_deserStatus)
11748  );
11749 
11750  // Make sure there was no data left over.
11751  // That means the buffer size was incorrect.
11752  FW_ASSERT(
11753  _msg.getDeserializeSizeLeft() == 0,
11754  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11755  );
11756 
11757  // Call handler function
11759  directive
11760  );
11761 
11762  break;
11763  }
11764 
11765  // Handle internal interface directive_pushRand
11766  case INT_IF_DIRECTIVE_PUSHRAND: {
11768  _deserStatus = _msg.deserializeTo(directive);
11769 
11770  // Internal interface should always deserialize
11771  FW_ASSERT(
11772  Fw::FW_SERIALIZE_OK == _deserStatus,
11773  static_cast<FwAssertArgType>(_deserStatus)
11774  );
11775 
11776  // Make sure there was no data left over.
11777  // That means the buffer size was incorrect.
11778  FW_ASSERT(
11779  _msg.getDeserializeSizeLeft() == 0,
11780  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11781  );
11782 
11783  // Call handler function
11785  directive
11786  );
11787 
11788  break;
11789  }
11790 
11791  // Handle internal interface directive_pushTime
11792  case INT_IF_DIRECTIVE_PUSHTIME: {
11794  _deserStatus = _msg.deserializeTo(directive);
11795 
11796  // Internal interface should always deserialize
11797  FW_ASSERT(
11798  Fw::FW_SERIALIZE_OK == _deserStatus,
11799  static_cast<FwAssertArgType>(_deserStatus)
11800  );
11801 
11802  // Make sure there was no data left over.
11803  // That means the buffer size was incorrect.
11804  FW_ASSERT(
11805  _msg.getDeserializeSizeLeft() == 0,
11806  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11807  );
11808 
11809  // Call handler function
11811  directive
11812  );
11813 
11814  break;
11815  }
11816 
11817  // Handle internal interface directive_pushTlmVal
11818  case INT_IF_DIRECTIVE_PUSHTLMVAL: {
11820  _deserStatus = _msg.deserializeTo(directive);
11821 
11822  // Internal interface should always deserialize
11823  FW_ASSERT(
11824  Fw::FW_SERIALIZE_OK == _deserStatus,
11825  static_cast<FwAssertArgType>(_deserStatus)
11826  );
11827 
11828  // Make sure there was no data left over.
11829  // That means the buffer size was incorrect.
11830  FW_ASSERT(
11831  _msg.getDeserializeSizeLeft() == 0,
11832  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11833  );
11834 
11835  // Call handler function
11837  directive
11838  );
11839 
11840  break;
11841  }
11842 
11843  // Handle internal interface directive_pushTlmValAndTime
11844  case INT_IF_DIRECTIVE_PUSHTLMVALANDTIME: {
11846  _deserStatus = _msg.deserializeTo(directive);
11847 
11848  // Internal interface should always deserialize
11849  FW_ASSERT(
11850  Fw::FW_SERIALIZE_OK == _deserStatus,
11851  static_cast<FwAssertArgType>(_deserStatus)
11852  );
11853 
11854  // Make sure there was no data left over.
11855  // That means the buffer size was incorrect.
11856  FW_ASSERT(
11857  _msg.getDeserializeSizeLeft() == 0,
11858  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11859  );
11860 
11861  // Call handler function
11863  directive
11864  );
11865 
11866  break;
11867  }
11868 
11869  // Handle internal interface directive_pushVal
11870  case INT_IF_DIRECTIVE_PUSHVAL: {
11872  _deserStatus = _msg.deserializeTo(directive);
11873 
11874  // Internal interface should always deserialize
11875  FW_ASSERT(
11876  Fw::FW_SERIALIZE_OK == _deserStatus,
11877  static_cast<FwAssertArgType>(_deserStatus)
11878  );
11879 
11880  // Make sure there was no data left over.
11881  // That means the buffer size was incorrect.
11882  FW_ASSERT(
11883  _msg.getDeserializeSizeLeft() == 0,
11884  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11885  );
11886 
11887  // Call handler function
11889  directive
11890  );
11891 
11892  break;
11893  }
11894 
11895  // Handle internal interface directive_return
11896  case INT_IF_DIRECTIVE_RETURN: {
11898  _deserStatus = _msg.deserializeTo(directive);
11899 
11900  // Internal interface should always deserialize
11901  FW_ASSERT(
11902  Fw::FW_SERIALIZE_OK == _deserStatus,
11903  static_cast<FwAssertArgType>(_deserStatus)
11904  );
11905 
11906  // Make sure there was no data left over.
11907  // That means the buffer size was incorrect.
11908  FW_ASSERT(
11909  _msg.getDeserializeSizeLeft() == 0,
11910  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11911  );
11912 
11913  // Call handler function
11915  directive
11916  );
11917 
11918  break;
11919  }
11920 
11921  // Handle internal interface directive_setSeed
11922  case INT_IF_DIRECTIVE_SETSEED: {
11924  _deserStatus = _msg.deserializeTo(directive);
11925 
11926  // Internal interface should always deserialize
11927  FW_ASSERT(
11928  Fw::FW_SERIALIZE_OK == _deserStatus,
11929  static_cast<FwAssertArgType>(_deserStatus)
11930  );
11931 
11932  // Make sure there was no data left over.
11933  // That means the buffer size was incorrect.
11934  FW_ASSERT(
11935  _msg.getDeserializeSizeLeft() == 0,
11936  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11937  );
11938 
11939  // Call handler function
11941  directive
11942  );
11943 
11944  break;
11945  }
11946 
11947  // Handle internal interface directive_stackCmd
11948  case INT_IF_DIRECTIVE_STACKCMD: {
11950  _deserStatus = _msg.deserializeTo(directive);
11951 
11952  // Internal interface should always deserialize
11953  FW_ASSERT(
11954  Fw::FW_SERIALIZE_OK == _deserStatus,
11955  static_cast<FwAssertArgType>(_deserStatus)
11956  );
11957 
11958  // Make sure there was no data left over.
11959  // That means the buffer size was incorrect.
11960  FW_ASSERT(
11961  _msg.getDeserializeSizeLeft() == 0,
11962  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11963  );
11964 
11965  // Call handler function
11967  directive
11968  );
11969 
11970  break;
11971  }
11972 
11973  // Handle internal interface directive_stackOp
11974  case INT_IF_DIRECTIVE_STACKOP: {
11976  _deserStatus = _msg.deserializeTo(directive);
11977 
11978  // Internal interface should always deserialize
11979  FW_ASSERT(
11980  Fw::FW_SERIALIZE_OK == _deserStatus,
11981  static_cast<FwAssertArgType>(_deserStatus)
11982  );
11983 
11984  // Make sure there was no data left over.
11985  // That means the buffer size was incorrect.
11986  FW_ASSERT(
11987  _msg.getDeserializeSizeLeft() == 0,
11988  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
11989  );
11990 
11991  // Call handler function
11993  directive
11994  );
11995 
11996  break;
11997  }
11998 
11999  // Handle internal interface directive_storeAbs
12000  case INT_IF_DIRECTIVE_STOREABS: {
12002  _deserStatus = _msg.deserializeTo(directive);
12003 
12004  // Internal interface should always deserialize
12005  FW_ASSERT(
12006  Fw::FW_SERIALIZE_OK == _deserStatus,
12007  static_cast<FwAssertArgType>(_deserStatus)
12008  );
12009 
12010  // Make sure there was no data left over.
12011  // That means the buffer size was incorrect.
12012  FW_ASSERT(
12013  _msg.getDeserializeSizeLeft() == 0,
12014  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
12015  );
12016 
12017  // Call handler function
12019  directive
12020  );
12021 
12022  break;
12023  }
12024 
12025  // Handle internal interface directive_storeAbsConstOffset
12026  case INT_IF_DIRECTIVE_STOREABSCONSTOFFSET: {
12028  _deserStatus = _msg.deserializeTo(directive);
12029 
12030  // Internal interface should always deserialize
12031  FW_ASSERT(
12032  Fw::FW_SERIALIZE_OK == _deserStatus,
12033  static_cast<FwAssertArgType>(_deserStatus)
12034  );
12035 
12036  // Make sure there was no data left over.
12037  // That means the buffer size was incorrect.
12038  FW_ASSERT(
12039  _msg.getDeserializeSizeLeft() == 0,
12040  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
12041  );
12042 
12043  // Call handler function
12045  directive
12046  );
12047 
12048  break;
12049  }
12050 
12051  // Handle internal interface directive_storeRel
12052  case INT_IF_DIRECTIVE_STOREREL: {
12054  _deserStatus = _msg.deserializeTo(directive);
12055 
12056  // Internal interface should always deserialize
12057  FW_ASSERT(
12058  Fw::FW_SERIALIZE_OK == _deserStatus,
12059  static_cast<FwAssertArgType>(_deserStatus)
12060  );
12061 
12062  // Make sure there was no data left over.
12063  // That means the buffer size was incorrect.
12064  FW_ASSERT(
12065  _msg.getDeserializeSizeLeft() == 0,
12066  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
12067  );
12068 
12069  // Call handler function
12071  directive
12072  );
12073 
12074  break;
12075  }
12076 
12077  // Handle internal interface directive_storeRelConstOffset
12078  case INT_IF_DIRECTIVE_STORERELCONSTOFFSET: {
12080  _deserStatus = _msg.deserializeTo(directive);
12081 
12082  // Internal interface should always deserialize
12083  FW_ASSERT(
12084  Fw::FW_SERIALIZE_OK == _deserStatus,
12085  static_cast<FwAssertArgType>(_deserStatus)
12086  );
12087 
12088  // Make sure there was no data left over.
12089  // That means the buffer size was incorrect.
12090  FW_ASSERT(
12091  _msg.getDeserializeSizeLeft() == 0,
12092  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
12093  );
12094 
12095  // Call handler function
12097  directive
12098  );
12099 
12100  break;
12101  }
12102 
12103  // Handle internal interface directive_waitAbs
12104  case INT_IF_DIRECTIVE_WAITABS: {
12106  _deserStatus = _msg.deserializeTo(directive);
12107 
12108  // Internal interface should always deserialize
12109  FW_ASSERT(
12110  Fw::FW_SERIALIZE_OK == _deserStatus,
12111  static_cast<FwAssertArgType>(_deserStatus)
12112  );
12113 
12114  // Make sure there was no data left over.
12115  // That means the buffer size was incorrect.
12116  FW_ASSERT(
12117  _msg.getDeserializeSizeLeft() == 0,
12118  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
12119  );
12120 
12121  // Call handler function
12123  directive
12124  );
12125 
12126  break;
12127  }
12128 
12129  // Handle internal interface directive_waitRel
12130  case INT_IF_DIRECTIVE_WAITREL: {
12132  _deserStatus = _msg.deserializeTo(directive);
12133 
12134  // Internal interface should always deserialize
12135  FW_ASSERT(
12136  Fw::FW_SERIALIZE_OK == _deserStatus,
12137  static_cast<FwAssertArgType>(_deserStatus)
12138  );
12139 
12140  // Make sure there was no data left over.
12141  // That means the buffer size was incorrect.
12142  FW_ASSERT(
12143  _msg.getDeserializeSizeLeft() == 0,
12144  static_cast<FwAssertArgType>(_msg.getDeserializeSizeLeft())
12145  );
12146 
12147  // Call handler function
12149  directive
12150  );
12151 
12152  break;
12153  }
12154 
12155 
12156  // Handle signals to internal state machines
12157  case INTERNAL_STATE_MACHINE_SIGNAL:
12158  this->smDispatch(_msg);
12159  break;
12160 
12161  default:
12162  return MSG_DISPATCH_ERROR;
12163  }
12164 
12165  return MSG_DISPATCH_OK;
12166  }
12167 
12168  // ----------------------------------------------------------------------
12169  // Calls for messages received on special input ports
12170  // ----------------------------------------------------------------------
12171 
12172  void FpySequencerComponentBase ::
12173  m_p_cmdIn_in(
12174  Fw::PassiveComponentBase* callComp,
12175  FwIndexType portNum,
12176  FwOpcodeType opCode,
12177  U32 cmdSeq,
12178  Fw::CmdArgBuffer& args
12179  )
12180  {
12181  FW_ASSERT(callComp != nullptr);
12182  FpySequencerComponentBase* compPtr = static_cast<FpySequencerComponentBase*>(callComp);
12183  compPtr->cmdIn_handlerBase(
12184  portNum,
12185  opCode,
12186  cmdSeq,
12187  args
12188  );
12189  }
12190 
12191  // ----------------------------------------------------------------------
12192  // Calls for messages received on typed input ports
12193  // ----------------------------------------------------------------------
12194 
12195  void FpySequencerComponentBase ::
12196  m_p_checkTimers_in(
12197  Fw::PassiveComponentBase* callComp,
12198  FwIndexType portNum,
12199  U32 context
12200  )
12201  {
12202  FW_ASSERT(callComp != nullptr);
12203  FpySequencerComponentBase* compPtr = static_cast<FpySequencerComponentBase*>(callComp);
12204  compPtr->checkTimers_handlerBase(
12205  portNum,
12206  context
12207  );
12208  }
12209 
12210  void FpySequencerComponentBase ::
12211  m_p_cmdResponseIn_in(
12212  Fw::PassiveComponentBase* callComp,
12213  FwIndexType portNum,
12214  FwOpcodeType opCode,
12215  U32 cmdSeq,
12216  const Fw::CmdResponse& response
12217  )
12218  {
12219  FW_ASSERT(callComp != nullptr);
12220  FpySequencerComponentBase* compPtr = static_cast<FpySequencerComponentBase*>(callComp);
12221  compPtr->cmdResponseIn_handlerBase(
12222  portNum,
12223  opCode,
12224  cmdSeq,
12225  response
12226  );
12227  }
12228 
12229  void FpySequencerComponentBase ::
12230  m_p_pingIn_in(
12231  Fw::PassiveComponentBase* callComp,
12232  FwIndexType portNum,
12233  U32 key
12234  )
12235  {
12236  FW_ASSERT(callComp != nullptr);
12237  FpySequencerComponentBase* compPtr = static_cast<FpySequencerComponentBase*>(callComp);
12238  compPtr->pingIn_handlerBase(
12239  portNum,
12240  key
12241  );
12242  }
12243 
12244  void FpySequencerComponentBase ::
12245  m_p_seqCancelIn_in(
12246  Fw::PassiveComponentBase* callComp,
12247  FwIndexType portNum
12248  )
12249  {
12250  FW_ASSERT(callComp != nullptr);
12251  FpySequencerComponentBase* compPtr = static_cast<FpySequencerComponentBase*>(callComp);
12252  compPtr->seqCancelIn_handlerBase(portNum);
12253  }
12254 
12255  void FpySequencerComponentBase ::
12256  m_p_seqRunIn_in(
12257  Fw::PassiveComponentBase* callComp,
12258  FwIndexType portNum,
12259  const Fw::StringBase& filename,
12260  const Svc::SeqArgs& args
12261  )
12262  {
12263  FW_ASSERT(callComp != nullptr);
12264  FpySequencerComponentBase* compPtr = static_cast<FpySequencerComponentBase*>(callComp);
12265  compPtr->seqRunIn_handlerBase(
12266  portNum,
12267  filename,
12268  args
12269  );
12270  }
12271 
12272  void FpySequencerComponentBase ::
12273  m_p_tlmWrite_in(
12274  Fw::PassiveComponentBase* callComp,
12275  FwIndexType portNum,
12276  U32 context
12277  )
12278  {
12279  FW_ASSERT(callComp != nullptr);
12280  FpySequencerComponentBase* compPtr = static_cast<FpySequencerComponentBase*>(callComp);
12281  compPtr->tlmWrite_handlerBase(
12282  portNum,
12283  context
12284  );
12285  }
12286 
12287 #if !FW_DIRECT_PORT_CALLS
12288 
12289  // ----------------------------------------------------------------------
12290  // Invocation functions for special output ports
12291  // ----------------------------------------------------------------------
12292 
12293  void FpySequencerComponentBase ::
12294  cmdRegOut_out(
12295  FwIndexType portNum,
12296  FwOpcodeType opCode
12297  ) const
12298  {
12299  FW_ASSERT(
12300  (0 <= portNum) && (portNum < this->getNum_cmdRegOut_OutputPorts()),
12301  static_cast<FwAssertArgType>(portNum)
12302  );
12303 
12304  FW_ASSERT(
12305  this->m_cmdRegOut_OutputPort[portNum].isConnected(),
12306  static_cast<FwAssertArgType>(portNum)
12307  );
12308  this->m_cmdRegOut_OutputPort[portNum].invoke(
12309  opCode
12310  );
12311  }
12312 
12313  void FpySequencerComponentBase ::
12314  cmdResponseOut_out(
12315  FwIndexType portNum,
12316  FwOpcodeType opCode,
12317  U32 cmdSeq,
12318  const Fw::CmdResponse& response
12319  ) const
12320  {
12321  FW_ASSERT(
12322  (0 <= portNum) && (portNum < this->getNum_cmdResponseOut_OutputPorts()),
12323  static_cast<FwAssertArgType>(portNum)
12324  );
12325 
12326  FW_ASSERT(
12327  this->m_cmdResponseOut_OutputPort[portNum].isConnected(),
12328  static_cast<FwAssertArgType>(portNum)
12329  );
12330  this->m_cmdResponseOut_OutputPort[portNum].invoke(
12331  opCode,
12332  cmdSeq,
12333  response
12334  );
12335  }
12336 
12337  void FpySequencerComponentBase ::
12338  logOut_out(
12339  FwIndexType portNum,
12340  FwEventIdType id,
12341  Fw::Time& timeTag,
12342  const Fw::LogSeverity& severity,
12343  Fw::LogBuffer& args
12344  ) const
12345  {
12346  FW_ASSERT(
12347  (0 <= portNum) && (portNum < this->getNum_logOut_OutputPorts()),
12348  static_cast<FwAssertArgType>(portNum)
12349  );
12350 
12351  FW_ASSERT(
12352  this->m_logOut_OutputPort[portNum].isConnected(),
12353  static_cast<FwAssertArgType>(portNum)
12354  );
12355  this->m_logOut_OutputPort[portNum].invoke(
12356  id,
12357  timeTag,
12358  severity,
12359  args
12360  );
12361  }
12362 
12363 #if FW_ENABLE_TEXT_LOGGING
12364 
12365  void FpySequencerComponentBase ::
12366  logTextOut_out(
12367  FwIndexType portNum,
12368  FwEventIdType id,
12369  Fw::Time& timeTag,
12370  const Fw::LogSeverity& severity,
12371  Fw::TextLogString& text
12372  ) const
12373  {
12374  FW_ASSERT(
12375  (0 <= portNum) && (portNum < this->getNum_logTextOut_OutputPorts()),
12376  static_cast<FwAssertArgType>(portNum)
12377  );
12378 
12379  FW_ASSERT(
12380  this->m_logTextOut_OutputPort[portNum].isConnected(),
12381  static_cast<FwAssertArgType>(portNum)
12382  );
12383  this->m_logTextOut_OutputPort[portNum].invoke(
12384  id,
12385  timeTag,
12386  severity,
12387  text
12388  );
12389  }
12390 
12391 #endif
12392 
12393  Fw::ParamValid FpySequencerComponentBase ::
12394  prmGet_out(
12395  FwIndexType portNum,
12396  FwPrmIdType id,
12397  Fw::ParamBuffer& val
12398  ) const
12399  {
12400  FW_ASSERT(
12401  (0 <= portNum) && (portNum < this->getNum_prmGet_OutputPorts()),
12402  static_cast<FwAssertArgType>(portNum)
12403  );
12404 
12405  FW_ASSERT(
12406  this->m_prmGet_OutputPort[portNum].isConnected(),
12407  static_cast<FwAssertArgType>(portNum)
12408  );
12409  return this->m_prmGet_OutputPort[portNum].invoke(
12410  id,
12411  val
12412  );
12413  }
12414 
12415  void FpySequencerComponentBase ::
12416  prmSet_out(
12417  FwIndexType portNum,
12418  FwPrmIdType id,
12419  Fw::ParamBuffer& val
12420  ) const
12421  {
12422  FW_ASSERT(
12423  (0 <= portNum) && (portNum < this->getNum_prmSet_OutputPorts()),
12424  static_cast<FwAssertArgType>(portNum)
12425  );
12426 
12427  FW_ASSERT(
12428  this->m_prmSet_OutputPort[portNum].isConnected(),
12429  static_cast<FwAssertArgType>(portNum)
12430  );
12431  this->m_prmSet_OutputPort[portNum].invoke(
12432  id,
12433  val
12434  );
12435  }
12436 
12437  void FpySequencerComponentBase ::
12438  timeCaller_out(
12439  FwIndexType portNum,
12440  Fw::Time& time
12441  ) const
12442  {
12443  FW_ASSERT(
12444  (0 <= portNum) && (portNum < this->getNum_timeCaller_OutputPorts()),
12445  static_cast<FwAssertArgType>(portNum)
12446  );
12447 
12448  FW_ASSERT(
12449  this->m_timeCaller_OutputPort[portNum].isConnected(),
12450  static_cast<FwAssertArgType>(portNum)
12451  );
12452  this->m_timeCaller_OutputPort[portNum].invoke(
12453  time
12454  );
12455  }
12456 
12457  void FpySequencerComponentBase ::
12458  tlmOut_out(
12459  FwIndexType portNum,
12460  FwChanIdType id,
12461  Fw::Time& timeTag,
12462  Fw::TlmBuffer& val
12463  ) const
12464  {
12465  FW_ASSERT(
12466  (0 <= portNum) && (portNum < this->getNum_tlmOut_OutputPorts()),
12467  static_cast<FwAssertArgType>(portNum)
12468  );
12469 
12470  FW_ASSERT(
12471  this->m_tlmOut_OutputPort[portNum].isConnected(),
12472  static_cast<FwAssertArgType>(portNum)
12473  );
12474  this->m_tlmOut_OutputPort[portNum].invoke(
12475  id,
12476  timeTag,
12477  val
12478  );
12479  }
12480 
12481 #endif
12482 
12483  // ----------------------------------------------------------------------
12484  // Send signal helper functions
12485  // ----------------------------------------------------------------------
12486 
12487  void FpySequencerComponentBase ::
12488  sendSignalStart(
12489  SmId smId,
12490  FwEnumStoreType signal,
12491  Fw::SerialBufferBase& buffer
12492  )
12493  {
12495 
12496  // Serialize the message type
12497  status = buffer.serializeFrom(static_cast<FwEnumStoreType>(INTERNAL_STATE_MACHINE_SIGNAL));
12498  FW_ASSERT (status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12499 
12500  // Serialize the port number
12501  status = buffer.serializeFrom(static_cast<FwIndexType>(0));
12502  FW_ASSERT (status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12503 
12504  // Serialize the state machine ID
12505  status = buffer.serializeFrom(static_cast<FwEnumStoreType>(smId));
12506  FW_ASSERT (status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12507 
12508  // Serialize the signal
12509  status = buffer.serializeFrom(static_cast<FwEnumStoreType>(signal));
12510  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12511  }
12512 
12513  void FpySequencerComponentBase ::
12514  sequencer_sendSignalFinish(Fw::LinearBufferBase& buffer)
12515  {
12516  // Send message
12518  Os::Queue::Status qStatus = this->m_queue.send(buffer, 9, _block);
12519 
12520  FW_ASSERT(
12521  qStatus == Os::Queue::OP_OK,
12522  static_cast<FwAssertArgType>(qStatus)
12523  );
12524  }
12525 
12526  // ----------------------------------------------------------------------
12527  // Helper functions for state machine dispatch
12528  // ----------------------------------------------------------------------
12529 
12530  void FpySequencerComponentBase ::
12531  smDispatch(Fw::SerialBufferBase& buffer)
12532  {
12533  // Deserialize the state machine ID and signal
12534  FwEnumStoreType storedSmId;
12535  FwEnumStoreType storedSignal;
12536  FpySequencerComponentBase::deserializeSmIdAndSignal(buffer, storedSmId, storedSignal);
12537 
12538  // Select the target state machine instance
12539  const SmId smId = static_cast<SmId>(storedSmId);
12540  switch (smId) {
12541  case SmId::sequencer: {
12543  this->Svc_FpySequencer_SequencerStateMachine_smDispatch(buffer, this->m_stateMachine_sequencer, signal);
12544  break;
12545  }
12546  default:
12547  FW_ASSERT(false, static_cast<FwAssertArgType>(smId));
12548  break;
12549  }
12550  }
12551 
12552  void FpySequencerComponentBase ::
12553  deserializeSmIdAndSignal(
12554  Fw::SerialBufferBase& buffer,
12555  FwEnumStoreType& smId,
12556  FwEnumStoreType& signal
12557  )
12558  {
12559  // Move deserialization beyond the message type and port number
12560  Fw::SerializeStatus status =
12561  buffer.moveDeserToOffset(ComponentIpcSerializableBuffer::DATA_OFFSET);
12562  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12563 
12564  // Deserialize the state machine ID
12565  status = buffer.deserializeTo(smId);
12566  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12567 
12568  // Deserialize the signal
12569  status = buffer.deserializeTo(signal);
12570  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12571  }
12572 
12573  void FpySequencerComponentBase ::
12574  Svc_FpySequencer_SequencerStateMachine_smDispatch(
12575  Fw::SerialBufferBase& buffer,
12576  Svc_FpySequencer_SequencerStateMachine& sm,
12578  )
12579  {
12580  switch (signal) {
12582  // Deserialize the data
12584  const Fw::SerializeStatus status = buffer.deserializeTo(value);
12585  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12586  // Assert no data left in buffer
12587  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12588  // Call the sendSignal function for sm and cmd_VALIDATE
12589  sm.sendSignal_cmd_VALIDATE(value);
12590  break;
12591  }
12593  // Deserialize the data
12595  const Fw::SerializeStatus status = buffer.deserializeTo(value);
12596  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12597  // Assert no data left in buffer
12598  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12599  // Call the sendSignal function for sm and cmd_RUN
12600  sm.sendSignal_cmd_RUN(value);
12601  break;
12602  }
12604  // Deserialize the data
12606  const Fw::SerializeStatus status = buffer.deserializeTo(value);
12607  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12608  // Assert no data left in buffer
12609  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12610  // Call the sendSignal function for sm and cmd_RUN_VALIDATED
12611  sm.sendSignal_cmd_RUN_VALIDATED(value);
12612  break;
12613  }
12615  // Assert no data left in buffer
12616  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12617  // Call the sendSignal function for sm and cmd_CANCEL
12618  sm.sendSignal_cmd_CANCEL();
12619  break;
12620  }
12622  // Deserialize the data
12624  const Fw::SerializeStatus status = buffer.deserializeTo(value);
12625  FW_ASSERT(status == Fw::FW_SERIALIZE_OK, static_cast<FwAssertArgType>(status));
12626  // Assert no data left in buffer
12627  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12628  // Call the sendSignal function for sm and cmd_SET_BREAKPOINT
12629  sm.sendSignal_cmd_SET_BREAKPOINT(value);
12630  break;
12631  }
12633  // Assert no data left in buffer
12634  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12635  // Call the sendSignal function for sm and cmd_CLEAR_BREAKPOINT
12636  sm.sendSignal_cmd_CLEAR_BREAKPOINT();
12637  break;
12638  }
12640  // Assert no data left in buffer
12641  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12642  // Call the sendSignal function for sm and result_failure
12643  sm.sendSignal_result_failure();
12644  break;
12645  }
12647  // Assert no data left in buffer
12648  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12649  // Call the sendSignal function for sm and result_success
12650  sm.sendSignal_result_success();
12651  break;
12652  }
12654  // Assert no data left in buffer
12655  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12656  // Call the sendSignal function for sm and entered
12657  sm.sendSignal_entered();
12658  break;
12659  }
12661  // Assert no data left in buffer
12662  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12663  // Call the sendSignal function for sm and result_dispatchStatement_success
12664  sm.sendSignal_result_dispatchStatement_success();
12665  break;
12666  }
12668  // Assert no data left in buffer
12669  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12670  // Call the sendSignal function for sm and result_dispatchStatement_failure
12671  sm.sendSignal_result_dispatchStatement_failure();
12672  break;
12673  }
12675  // Assert no data left in buffer
12676  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12677  // Call the sendSignal function for sm and result_dispatchStatement_noMoreStatements
12678  sm.sendSignal_result_dispatchStatement_noMoreStatements();
12679  break;
12680  }
12682  // Assert no data left in buffer
12683  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12684  // Call the sendSignal function for sm and checkTimersIn
12685  sm.sendSignal_checkTimersIn();
12686  break;
12687  }
12689  // Assert no data left in buffer
12690  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12691  // Call the sendSignal function for sm and result_checkShouldWake_wakeup
12692  sm.sendSignal_result_checkShouldWake_wakeup();
12693  break;
12694  }
12696  // Assert no data left in buffer
12697  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12698  // Call the sendSignal function for sm and result_checkShouldWake_keepSleeping
12699  sm.sendSignal_result_checkShouldWake_keepSleeping();
12700  break;
12701  }
12703  // Assert no data left in buffer
12704  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12705  // Call the sendSignal function for sm and result_timeOpFailed
12706  sm.sendSignal_result_timeOpFailed();
12707  break;
12708  }
12710  // Assert no data left in buffer
12711  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12712  // Call the sendSignal function for sm and stmtResponse_beginSleep
12713  sm.sendSignal_stmtResponse_beginSleep();
12714  break;
12715  }
12717  // Assert no data left in buffer
12718  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12719  // Call the sendSignal function for sm and stmtResponse_success
12720  sm.sendSignal_stmtResponse_success();
12721  break;
12722  }
12724  // Assert no data left in buffer
12725  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12726  // Call the sendSignal function for sm and stmtResponse_failure
12727  sm.sendSignal_stmtResponse_failure();
12728  break;
12729  }
12731  // Assert no data left in buffer
12732  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12733  // Call the sendSignal function for sm and stmtResponse_unexpected
12734  sm.sendSignal_stmtResponse_unexpected();
12735  break;
12736  }
12738  // Assert no data left in buffer
12739  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12740  // Call the sendSignal function for sm and stmtResponse_keepWaiting
12741  sm.sendSignal_stmtResponse_keepWaiting();
12742  break;
12743  }
12745  // Assert no data left in buffer
12746  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12747  // Call the sendSignal function for sm and result_checkStatementTimeout_statementTimeout
12748  sm.sendSignal_result_checkStatementTimeout_statementTimeout();
12749  break;
12750  }
12752  // Assert no data left in buffer
12753  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12754  // Call the sendSignal function for sm and result_checkStatementTimeout_noTimeout
12755  sm.sendSignal_result_checkStatementTimeout_noTimeout();
12756  break;
12757  }
12759  // Assert no data left in buffer
12760  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12761  // Call the sendSignal function for sm and cmd_CONTINUE
12762  sm.sendSignal_cmd_CONTINUE();
12763  break;
12764  }
12766  // Assert no data left in buffer
12767  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12768  // Call the sendSignal function for sm and cmd_BREAK
12769  sm.sendSignal_cmd_BREAK();
12770  break;
12771  }
12773  // Assert no data left in buffer
12774  FW_ASSERT(buffer.getDeserializeSizeLeft() == 0, static_cast<FwAssertArgType>(buffer.getDeserializeSizeLeft()));
12775  // Call the sendSignal function for sm and cmd_STEP
12776  sm.sendSignal_cmd_STEP();
12777  break;
12778  }
12779  default:
12780  FW_ASSERT(false, static_cast<FwAssertArgType>(signal));
12781  break;
12782  }
12783  }
12784 
12785  // ----------------------------------------------------------------------
12786  // Parameter set functions
12787  // ----------------------------------------------------------------------
12788 
12789  Fw::CmdResponse FpySequencerComponentBase ::
12790  paramSet_STATEMENT_TIMEOUT_SECS(Fw::SerialBufferBase& val)
12791  {
12792  F32 _localVal{};
12793  const Fw::SerializeStatus _stat = val.deserializeTo(_localVal);
12794  if (_stat != Fw::FW_SERIALIZE_OK) {
12796  }
12797 
12798  // Assign value only if successfully deserialized
12799  this->m_paramLock.lock();
12800  this->m_STATEMENT_TIMEOUT_SECS = _localVal;
12801  this->m_param_STATEMENT_TIMEOUT_SECS_valid = Fw::ParamValid::VALID;
12802  this->m_paramLock.unlock();
12803 
12804  // Call notifier
12806  return Fw::CmdResponse::OK;
12807  }
12808 
12809  Fw::CmdResponse FpySequencerComponentBase ::
12810  paramSet_SEQ_BASE_DIR(Fw::SerialBufferBase& val)
12811  {
12812  Fw::ParamString _localVal{};
12813  const Fw::SerializeStatus _stat = val.deserializeTo(_localVal);
12814  if (_stat != Fw::FW_SERIALIZE_OK) {
12816  }
12817 
12818  // Assign value only if successfully deserialized
12819  this->m_paramLock.lock();
12820  this->m_SEQ_BASE_DIR = _localVal;
12821  this->m_param_SEQ_BASE_DIR_valid = Fw::ParamValid::VALID;
12822  this->m_paramLock.unlock();
12823 
12824  // Call notifier
12826  return Fw::CmdResponse::OK;
12827  }
12828 
12829  // ----------------------------------------------------------------------
12830  // Parameter save functions
12831  // ----------------------------------------------------------------------
12832 
12833  Fw::CmdResponse FpySequencerComponentBase ::
12834  paramSave_STATEMENT_TIMEOUT_SECS()
12835  {
12836  if (!this->isConnected_prmSet_OutputPort(0)) {
12838  }
12839  Fw::ParamBuffer _paramBuffer;
12840  const FwIdType idBase = this->getIdBase();
12842  // Serialize the parameter
12843  this->m_paramLock.lock();
12844  if ((this->m_param_STATEMENT_TIMEOUT_SECS_valid == Fw::ParamValid::VALID) || (this->m_param_STATEMENT_TIMEOUT_SECS_valid == Fw::ParamValid::DEFAULT)) {
12845  _stat = _paramBuffer.serializeFrom(m_STATEMENT_TIMEOUT_SECS);
12846  }
12847  this->m_paramLock.unlock();
12848  if (_stat != Fw::FW_SERIALIZE_OK) {
12850  }
12851  // Save the parameter
12852  this->prmSet_out(
12853  0,
12854  static_cast<FwPrmIdType>(idBase + PARAMID_STATEMENT_TIMEOUT_SECS),
12855  _paramBuffer
12856  );
12857  // Return the command response
12858  return Fw::CmdResponse::OK;
12859  }
12860 
12861  Fw::CmdResponse FpySequencerComponentBase ::
12862  paramSave_SEQ_BASE_DIR()
12863  {
12864  if (!this->isConnected_prmSet_OutputPort(0)) {
12866  }
12867  Fw::ParamBuffer _paramBuffer;
12868  const FwIdType idBase = this->getIdBase();
12870  // Serialize the parameter
12871  this->m_paramLock.lock();
12872  if ((this->m_param_SEQ_BASE_DIR_valid == Fw::ParamValid::VALID) || (this->m_param_SEQ_BASE_DIR_valid == Fw::ParamValid::DEFAULT)) {
12873  _stat = _paramBuffer.serializeFrom(m_SEQ_BASE_DIR);
12874  }
12875  this->m_paramLock.unlock();
12876  if (_stat != Fw::FW_SERIALIZE_OK) {
12878  }
12879  // Save the parameter
12880  this->prmSet_out(
12881  0,
12882  static_cast<FwPrmIdType>(idBase + PARAMID_SEQ_BASE_DIR),
12883  _paramBuffer
12884  );
12885  // Return the command response
12886  return Fw::CmdResponse::OK;
12887  }
12888 
12889 }
void cmdOut_out(FwIndexType portNum, Fw::ComBuffer &data, U32 context) const
Invoke output port cmdOut.
Serialization/Deserialization operation was successful.
void pingOut_out(FwIndexType portNum, U32 key) const
Invoke output port pingOut.
virtual void seqCancelIn_handler(FwIndexType portNum)=0
Handler for input port seqCancelIn.
void sequencer_sendSignal_result_dispatchStatement_noMoreStatements()
Send signal result_dispatchStatement_noMoreStatements to state machine sequencer. ...
sets the index of the next directive to execute
void sequencer_sendSignal_result_checkShouldWake_keepSleeping()
Send signal result_checkShouldWake_keepSleeping to state machine sequencer.
called when an unexpected or incorrect statement response comes in. only raised in the RUNNING state ...
virtual void directive_waitRel_internalInterfaceHandler(const Svc::FpySequencer_WaitRelDirective &directive)=0
Internal interface handler for directive_waitRel.
called in dispatchStatement method when a statement was unable to be sent out
virtual void DUMP_STACK_TO_FILE_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command DUMP_STACK_TO_FILE.
void addCallPort(InputTimePort *callPort)
Register an input port.
Definition: TimePortAc.cpp:157
void invoke(Fw::ComBuffer &data, U32 context) const
Invoke a port connection.
Definition: ComPortAc.cpp:181
bool isConnected_getTlmChan_OutputPort(FwIndexType portNum) const
void set_seqStartOut_OutputPort(FwIndexType portNum, Svc::InputCmdSeqInPort *port)
Connect port to seqStartOut[portNum].
void log_WARNING_HI_DirectiveTimedOut(U8 opCode, U32 stmtIdx, const Fw::StringBase &filePath) const
Log event DirectiveTimedOut.
virtual void directive_pushPrm_internalInterfaceHandler(const Svc::FpySequencer_PushPrmDirective &directive)=0
Internal interface handler for directive_pushPrm.
void init()
Initialization function.
Definition: ComPortAc.cpp:162
static constexpr FwSizeType CAPACITY
Definition: CmdPortAc.hpp:36
virtual void directive_peek_internalInterfaceHandler(const Svc::FpySequencer_PeekDirective &directive)=0
Internal interface handler for directive_peek.
void invoke(const Fw::StringBase &filename, const Svc::SeqArgs &args) const
Invoke a port connection.
void log_ACTIVITY_HI_SequencePaused(U32 stmtIdx) const
Log event SequencePaused.
virtual void directive_exit_internalInterfaceHandler(const Svc::FpySequencer_ExitDirective &directive)=0
Internal interface handler for directive_exit.
Fw::InputCmdResponsePort * get_cmdResponseIn_InputPort(FwIndexType portNum)
virtual void seqCancelIn_preMsgHook(FwIndexType portNum)
Pre-message hook for async input port seqCancelIn.
FwIdType FwOpcodeType
The type of a command opcode.
Operation succeeded.
Definition: Os.hpp:27
void set_cmdOut_OutputPort(FwIndexType portNum, Fw::InputComPort *port)
Connect port to cmdOut[portNum].
virtual void seqRunIn_handler(FwIndexType portNum, const Fw::StringBase &filename, const Svc::SeqArgs &args)=0
Handler for input port seqRunIn.
called in dispatchStatement method when there were no more statements in the sequence ...
branches based off of the top byte of the stack
void directive_pushVal_internalInterfaceInvoke(const Svc::FpySequencer_PushValDirective &directive)
Internal interface base-class function for directive_pushVal.
void tlmWrite_Debug_NextStatementOpcode(U8 arg, Fw::Time _tlmTime=Fw::Time())
virtual void parametersLoaded()
Called whenever parameters are loaded.
static constexpr FwSizeType CAPACITY
bool isConnected_cmdRegOut_OutputPort(FwIndexType portNum) const
virtual void directive_pushTime_internalInterfaceHandler(const Svc::FpySequencer_PushTimeDirective &directive)=0
Internal interface handler for directive_pushTime.
void log_WARNING_HI_InsufficientBufferSpace(U64 bufferSize, const Fw::StringBase &filePath) const
Log event InsufficientBufferSpace.
static constexpr FwIndexType getNum_seqStartOut_OutputPorts()
bool isConnected_getParam_OutputPort(FwIndexType portNum) const
PlatformSizeType FwSizeType
void directive_popEvent_internalInterfaceInvoke(const Svc::FpySequencer_PopEventDirective &directive)
Internal interface base-class function for directive_popEvent.
stores a value to an absolute address in the stack (for global variables), offset from stack ...
Status receive(U8 *destination, FwSizeType capacity, BlockingType blockType, FwSizeType &actualSize, FwQueuePriorityType &priority) override
receive a message from the queue through delegate
Definition: Queue.cpp:71
I32 FwEnumStoreType
void CONTINUE_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void sequencer_sendSignal_cmd_STEP()
Send signal cmd_STEP to state machine sequencer.
virtual void cmdResponseIn_handler(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response)=0
Handler for input port cmdResponseIn.
void sequencer_sendSignal_result_dispatchStatement_success()
Send signal result_dispatchStatement_success to state machine sequencer.
void directive_stackOp_internalInterfaceInvoke(const Svc::FpySequencer_StackOpDirective &directive)
Internal interface base-class function for directive_stackOp.
void log_WARNING_HI_WrongCRC(U32 expected, U32 actual) const
Log event WrongCRC.
void log_WARNING_HI_ArgSizeExceedsCapacity(FwSizeType actual, FwSizeType capacity) const
Log event ArgSizeExceedsCapacity.
void directive_pushTlmVal_internalInterfaceInvoke(const Svc::FpySequencer_PushTlmValDirective &directive)
Internal interface base-class function for directive_pushTlmVal.
Status
status returned from the queue send function
Definition: Queue.hpp:30
virtual void CLEAR_BREAKPOINT_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
virtual void parameterUpdated(FwPrmIdType id)
Called whenever a parameter is updated.
called when statement successfully executed. only raised in the RUNNING.AWAITING_CMD_RESPONSE state ...
called on VALIDATE cmd with the path of the sequence file to validate. only raised in IDLE state ...
virtual void directive_stackCmd_internalInterfaceHandler(const Svc::FpySequencer_StackCmdDirective &directive)=0
Internal interface handler for directive_stackCmd.
called on RUN cmd with the path of the sequence file to run. only raised in IDLE state ...
void sequencer_sendSignal_cmd_SET_BREAKPOINT(const Svc::FpySequencer_BreakpointArgs &value)
Send signal cmd_SET_BREAKPOINT to state machine sequencer.
called on RUN_VALIDATED cmd. only raised in AWAITING_CMD_RUN_VALIDATED state
void init()
Initialization function.
Definition: SchedPortAc.cpp:73
virtual void tlmWrite_preMsgHook(FwIndexType portNum, U32 context)
Pre-message hook for async input port tlmWrite.
Loads, validates and runs a sequence.
void log_WARNING_HI_CommandFailed(FwOpcodeType opCode, U32 stmtIdx, const Fw::StringBase &filePath, const Fw::CmdResponse &response) const
Log event CommandFailed.
message to exit active component task
virtual void CLEAR_BREAKPOINT_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CLEAR_BREAKPOINT.
static constexpr FwIndexType getNum_cmdIn_InputPorts()
BYTE pingInPortSize[Svc::PingPortBuffer::CAPACITY]
void tlmWrite_Debug_ReachedEndOfFile(bool arg, Fw::Time _tlmTime=Fw::Time())
void init()
Initialization function.
void init()
Initialization function.
Definition: CmdPortAc.cpp:89
void RUN_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
StringTemplate< FW_FIXED_LENGTH_STRING_SIZE > String
Definition: String.hpp:14
SerializeStatus deserializeTo(U8 &val, Endianness mode=Endianness::BIG) override
Deserialize an 8-bit unsigned integer value.
virtual void directive_popSerializable_internalInterfaceHandler(const Svc::FpySequencer_PopSerializableDirective &directive)=0
Internal interface handler for directive_popSerializable.
void set_seqDoneOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to seqDoneOut[portNum].
FwIdType FwPrmIdType
The type of a parameter identifier.
void set_tlmOut_OutputPort(FwIndexType portNum, Fw::InputTlmPort *port)
Connect port to tlmOut[portNum].
stores a value to a local variable at a compile-time-known offset relative to the current stack frame...
Fw::SerializeStatus serialOut_out(FwIndexType portNum, Fw::LinearBufferBase &buffer)
Invoke output port serialOut.
void addCallPort(InputPrmSetPort *callPort)
Register an input port.
virtual void CANCEL_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
Fw::ParamValid getParam_out(FwIndexType portNum, FwPrmIdType id, Fw::ParamBuffer &val) const
Invoke output port getParam.
void invoke(U32 key) const
Invoke a port connection.
Definition: PingPortAc.cpp:170
void STEP_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
static constexpr FwIndexType getNum_pingIn_InputPorts()
bool isConnected_prmGet_OutputPort(FwIndexType portNum) const
void addCallPort(InputTlmGetPort *callPort)
Register an input port.
pop an opcode and arg buf off the stack, send to cmd dispatcher and await response ...
virtual const CHAR * toChar() const =0
Convert to a C-style char*.
void log_WARNING_HI_SequenceFilePathTooLong(const Fw::StringBase &baseDir, const Fw::StringBase &fileName) const
Log event SequenceFilePathTooLong.
void sequencer_sendSignal_result_checkShouldWake_wakeup()
Send signal result_checkShouldWake_wakeup to state machine sequencer.
virtual void directive_goto_internalInterfaceHandler(const Svc::FpySequencer_GotoDirective &directive)=0
Internal interface handler for directive_goto.
void directive_if_internalInterfaceInvoke(const Svc::FpySequencer_IfDirective &directive)
Internal interface base-class function for directive_if.
bool isConnected_prmSet_OutputPort(FwIndexType portNum) const
const Time ZERO_TIME
Definition: Time.cpp:5
virtual void RUN_ARGS_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command RUN_ARGS.
virtual void directive_storeRel_internalInterfaceHandler(const Svc::FpySequencer_StoreRelDirective &directive)=0
Internal interface handler for directive_storeRel.
void sequencer_sendSignal_result_success()
Send signal result_success to state machine sequencer.
virtual void RUN_VALIDATED_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Svc::BlockState &block)=0
void cmdResponseIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response)
Handler base-class function for input port cmdResponseIn.
void sequencer_sendSignal_stmtResponse_success()
Send signal stmtResponse_success to state machine sequencer.
virtual void VALIDATE_ARGS_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command VALIDATE_ARGS.
virtual ~FpySequencerComponentBase()
Destroy FpySequencerComponentBase object.
void tlmWrite_Debug_StackSize(Svc::Fpy::StackSizeType arg, Fw::Time _tlmTime=Fw::Time())
virtual void SET_BREAKPOINT_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, U32 stmtIdx, bool breakOnce)=0
virtual void directive_stackOp_internalInterfaceHandler(const Svc::FpySequencer_StackOpDirective &directive)=0
Internal interface handler for directive_stackOp.
void sequencer_sendSignal_cmd_VALIDATE(const Svc::FpySequencer_SequenceExecutionArgs &value)
Send signal cmd_VALIDATE to state machine sequencer.
void directive_noOp_internalInterfaceInvoke(const Svc::FpySequencer_NoOpDirective &directive)
Internal interface base-class function for directive_noOp.
void init()
Initialization function.
Definition: TlmPortAc.cpp:171
static constexpr FwIndexType getNum_tlmWrite_InputPorts()
Enum representing a command response.
virtual void RUN_VALIDATED_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command RUN_VALIDATED.
No time base has been established (Required)
void set_logOut_OutputPort(FwIndexType portNum, Fw::InputLogPort *port)
Connect port to logOut[portNum].
virtual void DUMP_STACK_TO_FILE_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName)=0
SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG) override
Serialize an 8-bit unsigned integer value.
void tlmWrite_State(FwEnumStoreType arg, Fw::Time _tlmTime=Fw::Time())
void log_WARNING_HI_FileApiError(const Fw::StringBase &filePath, I32 errorCode) const
Log event FileApiError.
void addCallPort(InputCmdRegPort *callPort)
Register an input port.
void tlmWrite_SequencesSucceeded(U64 arg, Fw::Time _tlmTime=Fw::Time())
void log_WARNING_HI_ExtraBytesInSequence(FwSizeType remaining) const
Log event ExtraBytesInSequence.
virtual SerializeStatus serializeFrom(U8 val, Endianness mode=Endianness::BIG)=0
Serialize an 8-bit unsigned integer value.
void directive_allocate_internalInterfaceInvoke(const Svc::FpySequencer_AllocateDirective &directive)
Internal interface base-class function for directive_allocate.
pops bytes off the top of the stack and does nothing with them
void directive_storeRelConstOffset_internalInterfaceInvoke(const Svc::FpySequencer_StoreRelConstOffsetDirective &directive)
Internal interface base-class function for directive_storeRelConstOffset.
static constexpr FwIndexType getNum_timeCaller_OutputPorts()
virtual void seqRunIn_preMsgHook(FwIndexType portNum, const Fw::StringBase &filename, const Svc::SeqArgs &args)
Pre-message hook for async input port seqRunIn.
void log_DIAGNOSTIC_LogDiagnostic(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogDiagnostic.
void log_COMMAND_LogCommand(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogCommand.
virtual void directive_waitAbs_internalInterfaceHandler(const Svc::FpySequencer_WaitAbsDirective &directive)=0
Internal interface handler for directive_waitAbs.
void init()
Initialization function.
virtual void pingIn_preMsgHook(FwIndexType portNum, U32 key)
Pre-message hook for async input port pingIn.
virtual void STEP_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
Os::Queue m_queue
queue object for active component
void directive_pushTlmValAndTime_internalInterfaceInvoke(const Svc::FpySequencer_PushTlmValAndTimeDirective &directive)
Internal interface base-class function for directive_pushTlmValAndTime.
void directive_stackCmd_internalInterfaceInvoke(const Svc::FpySequencer_StackCmdDirective &directive)
Internal interface base-class function for directive_stackCmd.
void cmdIn_handlerBase(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
Handler base-class function for input port cmdIn.
void log_WARNING_HI_TooManySequenceDirectives(U16 count, U16 max) const
Log event TooManySequenceDirectives.
void sequencer_sendSignal_stmtResponse_unexpected()
Send signal stmtResponse_unexpected to state machine sequencer.
void sequencer_sendSignal_cmd_BREAK()
Send signal cmd_BREAK to state machine sequencer.
Software diagnostic events.
void sequencer_sendSignal_result_dispatchStatement_failure()
Send signal result_dispatchStatement_failure to state machine sequencer.
void log_WARNING_HI_DirectiveDeserializeError(U8 opcode, U32 stmtIdx, I32 errorCode, U64 buffLeft, U64 buffLength) const
Log event DirectiveDeserializeError.
virtual void pingIn_handler(FwIndexType portNum, U32 key)=0
Handler for input port pingIn.
Svc::InputSchedPort * get_checkTimers_InputPort(FwIndexType portNum)
void addCallPort(InputTlmPort *callPort)
Register an input port.
Definition: TlmPortAc.cpp:177
virtual void STEP_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command STEP.
void addCallPort(InputPrmGetPort *callPort)
Register an input port.
void RUN_VALIDATED_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void tlmWrite_PRM_STATEMENT_TIMEOUT_SECS(F32 arg, Fw::Time _tlmTime=Fw::Time())
void init()
Object initializer.
Definition: ObjBase.cpp:24
void set_pingOut_OutputPort(FwIndexType portNum, Svc::InputPingPort *port)
Connect port to pingOut[portNum].
static constexpr FwIndexType getNum_tlmOut_OutputPorts()
void log_ACTIVITY_LO_LogActivityLo(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogActivityLo.
virtual void directive_allocate_internalInterfaceHandler(const Svc::FpySequencer_AllocateDirective &directive)=0
Internal interface handler for directive_allocate.
static constexpr FwIndexType getNum_pingOut_OutputPorts()
SerializeStatus
forward declaration for string
Svc_FpySequencer_SequencerStateMachine::State sequencer_getState() const
Get the state of state machine instance sequencer.
called in STEP cmd. only raised in RUNNING.PAUSED state
Writes the contents of the stack to a file. This command is only valid in the RUNNING.PAUSED state.
void set_getTlmChan_OutputPort(FwIndexType portNum, Fw::InputTlmGetPort *port)
Connect port to getTlmChan[portNum].
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
Definition: CmdPortAc.cpp:95
void log_WARNING_HI_SequenceExitedWithError(const Fw::StringBase &filePath, I32 errorCode) const
Log event SequenceExitedWithError.
float F32
32-bit floating point
Definition: BasicTypes.h:84
void log_WARNING_HI_WrongCmdResponseIndex(FwOpcodeType opcode, const Fw::CmdResponse &response, U16 actualCmdIdx, U16 expectedCmdIdx) const
Log event WrongCmdResponseIndex.
virtual void checkTimers_handler(FwIndexType portNum, U32 context)=0
Handler for input port checkTimers.
virtual SerializeStatus deserializeTo(U8 &val, Endianness mode=Endianness::BIG)=0
Deserialize an 8-bit unsigned integer value.
Message will block until space is available.
Definition: Queue.hpp:47
void unlock()
alias for unLock to meet BasicLockable requirements
Definition: Mutex.hpp:64
static constexpr FwIndexType getNum_getParam_OutputPorts()
static constexpr FwIndexType getNum_cmdRegOut_OutputPorts()
void directive_popSerializable_internalInterfaceInvoke(const Svc::FpySequencer_PopSerializableDirective &directive)
Internal interface base-class function for directive_popSerializable.
virtual void RUN_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName, const Svc::BlockState &block)=0
void tlmWrite_StatementsFailed(U64 arg, Fw::Time _tlmTime=Fw::Time())
FwIdType FwEventIdType
The type of an event identifier.
loads a value from a local variable at a compile-time-known offset relative to the current stack fram...
void seqCancelIn_handlerBase(FwIndexType portNum)
Handler base-class function for input port seqCancelIn.
void log_ACTIVITY_HI_LogActivityHi(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogActivityHi.
void regCommands()
Register commands with the Command Dispatcher.
void invoke(FwOpcodeType opCode) const
Invoke a port connection.
void directive_loadAbs_internalInterfaceInvoke(const Svc::FpySequencer_LoadAbsDirective &directive)
Internal interface base-class function for directive_loadAbs.
static constexpr FwSizeType CAPACITY
Definition: PingPortAc.hpp:34
called in dispatchStatement method when a statement was successfully dispatched
F32 paramGet_STATEMENT_TIMEOUT_SECS(Fw::ParamValid &valid)
Svc::InputCmdSeqCancelPort * get_seqCancelIn_InputPort(FwIndexType portNum)
Fw::TlmValid invoke(FwChanIdType id, Fw::Time &timeTag, Fw::TlmBuffer &val) const
#define FW_OBJECT_NAMES
Indicates whether or not object names are stored (more memory, can be used for tracking objects) ...
Definition: FpConfig.h:40
void log_WARNING_HI_EndOfFileError(const Svc::FpySequencer_FileReadStage &readStage, const Fw::StringBase &filePath) const
Log event EndOfFileError.
pop two byte arrays off the top of the stack, call memcmp, push 1 if they were equal, 0 otherwise
void init()
Initialization function.
Definition: TimePortAc.cpp:151
void cmdResponse_out(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdResponse response)
Emit command response.
Data was the wrong format (e.g. wrong packet type)
void directive_memCmp_internalInterfaceInvoke(const Svc::FpySequencer_MemCmpDirective &directive)
Internal interface base-class function for directive_memCmp.
Less important informational events.
pops a severity and message from the stack and emits an F Prime event
Os::Queue::Status createQueue(FwSizeType depth, FwSizeType msgSize)
void directive_pushTime_internalInterfaceInvoke(const Svc::FpySequencer_PushTimeDirective &directive)
Internal interface base-class function for directive_pushTime.
void tlmWrite_DirectiveErrorId(const Svc::Fpy::DirectiveId &arg, Fw::Time _tlmTime=Fw::Time())
static constexpr FwIndexType getNum_cmdResponseIn_InputPorts()
Svc::InputPingPort * get_pingIn_InputPort(FwIndexType portNum)
void tlmWrite_Debug_NextCmdOpcode(FwOpcodeType arg, Fw::Time _tlmTime=Fw::Time())
void tlmWrite_handlerBase(FwIndexType portNum, U32 context)
Handler base-class function for input port tlmWrite.
void RUN_ARGS_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
Base-class handler function for command RUN_ARGS.
void init()
Initialization function.
An activity related to commanding.
#define FW_MIN(a, b)
MIN macro (deprecated in C++, use std::min)
Definition: BasicTypes.h:99
A less serious but recoverable event.
Fw::ParamValid invoke(FwPrmIdType id, Fw::ParamBuffer &val) const
virtual void directive_setSeed_internalInterfaceHandler(const Svc::FpySequencer_SetSeedDirective &directive)=0
Internal interface handler for directive_setSeed.
ActiveComponentBase(const char *name)
Constructor.
virtual void directive_constCmd_internalInterfaceHandler(const Svc::FpySequencer_ConstCmdDirective &directive)=0
Internal interface handler for directive_constCmd.
void init()
Initialization function.
Definition: PingPortAc.cpp:151
Fw::InputCmdPort * get_cmdIn_InputPort(FwIndexType portNum)
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum) const
void tlmWrite_PRM_SEQ_BASE_DIR(const Fw::StringBase &arg, Fw::Time _tlmTime=Fw::Time())
void invoke(Fw::Time &time) const
Invoke a port connection.
Definition: TimePortAc.cpp:170
void pingIn_handlerBase(FwIndexType portNum, U32 key)
Handler base-class function for input port pingIn.
stores a value to an absolute address in the stack (for global variables), const offset ...
void set_timeCaller_OutputPort(FwIndexType portNum, Fw::InputTimePort *port)
Connect port to timeCaller[portNum].
Serializable::SizeType getDeserializeSizeLeft() const override
Get remaining deserialization buffer size.
virtual void directive_pushVal_internalInterfaceHandler(const Svc::FpySequencer_PushValDirective &directive)=0
Internal interface handler for directive_pushVal.
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
void invoke(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response) const
Invoke a port connection.
void sequencer_sendSignal_cmd_RUN_VALIDATED(const Svc::FpySequencer_SequenceExecutionArgs &value)
Send signal cmd_RUN_VALIDATED to state machine sequencer.
virtual void BREAK_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
Svc_FpySequencer_SequencerStateMachine(FpySequencerComponentBase &component)
Constructor.
FwIdType FwChanIdType
The type of a telemetry channel identifier.
void log_WARNING_HI_FileReadError(const Svc::FpySequencer_FileReadStage &readStage, const Fw::StringBase &filePath, I32 errorCode) const
Log event FileReadError.
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
void addCallPort(InputPingPort *callPort)
Register an input port.
Definition: PingPortAc.cpp:157
Status send(const U8 *buffer, FwSizeType size, FwQueuePriorityType priority, BlockingType blockType) override
send a message into the queue through delegate
Definition: Queue.cpp:54
Sequencer blocking state.
FpySequencerComponentBase(const char *compName="")
Construct FpySequencerComponentBase object.
virtual void directive_call_internalInterfaceHandler(const Svc::FpySequencer_CallDirective &directive)=0
Internal interface handler for directive_call.
void init()
Initialization function.
virtual void CONTINUE_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
void sequencer_sendSignal_checkTimersIn()
Send signal checkTimersIn to state machine sequencer.
void tlmWrite_StatementsDispatched(U64 arg, Fw::Time _tlmTime=Fw::Time())
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
void tlmWrite_LastDirectiveError(const Svc::Fpy::DirectiveErrorCode &arg, Fw::Time _tlmTime=Fw::Time())
void VALIDATE_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
virtual void directive_discard_internalInterfaceHandler(const Svc::FpySequencer_DiscardDirective &directive)=0
Internal interface handler for directive_discard.
void resetDeser() override
Reset deserialization pointer to beginning of buffer.
void VALIDATE_ARGS_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
static constexpr FwIndexType getNum_prmSet_OutputPorts()
void log_WARNING_HI_LogWarningHi(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogWarningHi.
peeks at N bytes from the stack, starting from an offset relative to the top of the stack ...
void sequencer_sendSignal_stmtResponse_failure()
Send signal stmtResponse_failure to state machine sequencer.
Must be called after VALIDATE. Runs the sequence that was validated.
A string backed by an external buffer.
A serious but recoverable event.
void CANCEL_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void directive_waitAbs_internalInterfaceInvoke(const Svc::FpySequencer_WaitAbsDirective &directive)
Internal interface base-class function for directive_waitAbs.
void directive_peek_internalInterfaceInvoke(const Svc::FpySequencer_PeekDirective &directive)
Internal interface base-class function for directive_peek.
void set_cmdRegOut_OutputPort(FwIndexType portNum, Fw::InputCmdRegPort *port)
Connect port to cmdRegOut[portNum].
void tlmWrite_Debug_NextStatementIndex(U32 arg, Fw::Time _tlmTime=Fw::Time())
void sequencer_sendSignal_stmtResponse_beginSleep()
Send signal stmtResponse_beginSleep to state machine sequencer.
void invoke(FwChanIdType id, Fw::Time &timeTag, Fw::TlmBuffer &val) const
Invoke a port connection.
Definition: TlmPortAc.cpp:190
void log_WARNING_HI_CmdResponseWhileNotAwaiting(FwOpcodeType opcode, const Fw::CmdResponse &response) const
Log event CmdResponseWhileNotAwaiting.
const char * toChar() const
Convert to a C-style char*.
bool isConnected() const
Definition: PortBase.cpp:38
void log_WARNING_HI_CommandTimedOut(FwOpcodeType opCode, U32 stmtIdx, const Fw::StringBase &filePath) const
Log event CommandTimedOut.
void sequencer_sendSignal_result_checkStatementTimeout_noTimeout()
Send signal result_checkStatementTimeout_noTimeout to state machine sequencer.
Enum representing event severity.
static constexpr FwIndexType getNum_seqRunIn_InputPorts()
virtual void tlmWrite_handler(FwIndexType portNum, U32 context)=0
Handler for input port tlmWrite.
Svc::InputCmdSeqInPort * get_seqRunIn_InputPort(FwIndexType portNum)
virtual void directive_memCmp_internalInterfaceHandler(const Svc::FpySequencer_MemCmpDirective &directive)=0
Internal interface handler for directive_memCmp.
void loadParameters()
Load the parameters from a parameter source.
void log_WARNING_HI_InvalidSeqRunCall(I32 state) const
Log event InvalidSeqRunCall.
virtual void directive_if_internalInterfaceHandler(const Svc::FpySequencer_IfDirective &directive)=0
Internal interface handler for directive_if.
#define PRI_FwIndexType
void directive_getField_internalInterfaceInvoke(const Svc::FpySequencer_GetFieldDirective &directive)
Internal interface base-class function for directive_getField.
static constexpr FwIndexType getNum_cmdOut_OutputPorts()
FormatStatus format(const CHAR *formatString,...)
write formatted string to buffer
Definition: StringBase.cpp:58
void init()
Initialization function.
Definition: LogPortAc.cpp:180
Command successfully executed.
called in BREAK cmd. only raised in RUNNING state
virtual Serializable::SizeType getDeserializeSizeLeft() const =0
Get remaining deserialization buffer size.
sleeps for a relative duration from the current time
void setPortNum(FwIndexType portNum)
void seqDoneOut_out(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response) const
Invoke output port seqDoneOut.
virtual void directive_storeRelConstOffset_internalInterfaceHandler(const Svc::FpySequencer_StoreRelConstOffsetDirective &directive)=0
Internal interface handler for directive_storeRelConstOffset.
void directive_discard_internalInterfaceInvoke(const Svc::FpySequencer_DiscardDirective &directive)
Internal interface base-class function for directive_discard.
uint8_t U8
8-bit unsigned integer
Definition: BasicTypes.h:54
bool isConnected_serialOut_OutputPort(FwIndexType portNum) const
virtual void directive_noOp_internalInterfaceHandler(const Svc::FpySequencer_NoOpDirective &directive)=0
Internal interface handler for directive_noOp.
static constexpr FwSizeType CAPACITY
BlockingType
message type
Definition: Queue.hpp:46
void log_ACTIVITY_HI_BreakpointSet(U32 breakpointIdx, bool breakOnce) const
Log event BreakpointSet.
void directive_pushPrm_internalInterfaceInvoke(const Svc::FpySequencer_PushPrmDirective &directive)
Internal interface base-class function for directive_pushPrm.
void sequencer_sendSignal_result_timeOpFailed()
Send signal result_timeOpFailed to state machine sequencer.
void BREAK_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void log_WARNING_HI_FileOpenError(const Fw::StringBase &filePath, I32 errorCode) const
Log event FileOpenError.
void init(FpySequencerComponentBase::SmId smId)
Initialize the state machine.
void set_prmSet_OutputPort(FwIndexType portNum, Fw::InputPrmSetPort *port)
Connect port to prmSet[portNum].
Command failed to deserialize.
PlatformQueuePriorityType FwQueuePriorityType
The type of queue priorities used.
Command had execution error.
Important informational events.
void sequencer_sendSignal_cmd_CANCEL()
Send signal cmd_CANCEL to state machine sequencer.
void sequencer_sendSignal_result_checkStatementTimeout_statementTimeout()
Send signal result_checkStatementTimeout_statementTimeout to state machine sequencer.
static constexpr FwIndexType getNum_cmdResponseOut_OutputPorts()
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
Definition: SchedPortAc.cpp:79
void sequencer_sendSignal_stmtResponse_keepWaiting()
Send signal stmtResponse_keepWaiting to state machine sequencer.
void invoke(FwEventIdType id, Fw::Time &timeTag, const Fw::LogSeverity &severity, Fw::LogBuffer &args) const
Invoke a port connection.
Definition: LogPortAc.cpp:199
bool isConnected_tlmOut_OutputPort(FwIndexType portNum) const
void init()
Initialization function.
void log_WARNING_HI_InvalidCommand(I32 state) const
Log event InvalidCommand.
void tlmWrite_BreakBeforeNextLine(bool arg, Fw::Time _tlmTime=Fw::Time())
virtual void directive_storeAbs_internalInterfaceHandler(const Svc::FpySequencer_StoreAbsDirective &directive)=0
Internal interface handler for directive_storeAbs.
bool isConnected_logOut_OutputPort(FwIndexType portNum) const
void log_ACTIVITY_HI_SequenceCancelled(const Fw::StringBase &filePath) const
Log event SequenceCancelled.
virtual void RUN_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command RUN.
void log_ACTIVITY_HI_BreakpointCleared() const
Log event BreakpointCleared.
void log_WARNING_HI_ArgTotalSizeExceedsStackLimit(Svc::Fpy::StackSizeType argSize) const
Log event ArgTotalSizeExceedsStackLimit.
static constexpr FwIndexType getNum_getTlmChan_OutputPorts()
void init()
Initialization function.
void directive_pushRand_internalInterfaceInvoke(const Svc::FpySequencer_PushRandDirective &directive)
Internal interface base-class function for directive_pushRand.
virtual void directive_getField_internalInterfaceHandler(const Svc::FpySequencer_GetFieldDirective &directive)=0
Internal interface handler for directive_getField.
virtual void directive_loadRel_internalInterfaceHandler(const Svc::FpySequencer_LoadRelDirective &directive)=0
Internal interface handler for directive_loadRel.
Fw::ParamString paramGet_SEQ_BASE_DIR(Fw::ParamValid &valid)
A message was sent requesting an exit of the loop.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum) const
called when the statement unsuccessfully executed. only raised in the RUNNING.AWAITING_CMD_RESPONSE s...
called in CONTINUE cmd. only raised in RUNNING.PAUSED state
FpySequencer_SequencerStateMachineStateMachineBase::State getState() const
Get the state.
void tlmWrite_SequencesFailed(U64 arg, Fw::Time _tlmTime=Fw::Time())
The size of the serial representation.
void directive_setSeed_internalInterfaceInvoke(const Svc::FpySequencer_SetSeedDirective &directive)
Internal interface base-class function for directive_setSeed.
loads a value from an absolute address in the stack (for global variables)
virtual void directive_pushRand_internalInterfaceHandler(const Svc::FpySequencer_PushRandDirective &directive)=0
Internal interface handler for directive_pushRand.
void tlmWrite_SeqPath(const Fw::StringBase &arg, Fw::Time _tlmTime=Fw::Time())
virtual void SET_BREAKPOINT_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command SET_BREAKPOINT.
PlatformIndexType FwIndexType
void directive_constCmd_internalInterfaceInvoke(const Svc::FpySequencer_ConstCmdDirective &directive)
Internal interface base-class function for directive_constCmd.
virtual void VALIDATE_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command VALIDATE.
static constexpr FwIndexType getNum_checkTimers_InputPorts()
static constexpr FwIndexType getNum_serialOut_OutputPorts()
pops a U32 from the stack and uses it to seed the RNG used by PushRandDirective
bool isConnected_pingOut_OutputPort(FwIndexType portNum) const
pops serialized data from stack and sends to serial output port
A fatal non-recoverable event.
void log_WARNING_HI_MismatchedTimeContext(I32 internalTimeContext, I32 otherTimeContext) const
Log event MismatchedTimeContext.
void directive_return_internalInterfaceInvoke(const Svc::FpySequencer_ReturnDirective &directive)
Internal interface base-class function for directive_return.
bool isConnected_cmdOut_OutputPort(FwIndexType portNum) const
Svc::InputSchedPort * get_tlmWrite_InputPort(FwIndexType portNum)
void seqRunIn_handlerBase(FwIndexType portNum, const Fw::StringBase &filename, const Svc::SeqArgs &args)
Handler base-class function for input port seqRunIn.
void log_WARNING_HI_WrongSchemaVersion(U8 expected, U8 actual) const
Log event WrongSchemaVersion.
void addCallPort(InputLogPort *callPort)
Register an input port.
Definition: LogPortAc.cpp:186
void addCallPort(InputCmdSeqInPort *callPort)
Register an input port.
void sequencer_sendSignal_cmd_CLEAR_BREAKPOINT()
Send signal cmd_CLEAR_BREAKPOINT to state machine sequencer.
void log_WARNING_LO_LogWarningLo(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogWarningLo.
void log_WARNING_HI_UnknownSequencerDirective(U8 opcode, U32 stmtIdx, const Fw::StringBase &filePath) const
Log event UnknownSequencerDirective.
virtual void VALIDATE_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName)=0
void log_WARNING_HI_CmdResponseWhileAwaitingDirective(FwOpcodeType opcode, const Fw::CmdResponse &response, U8 expectedDirectiveOpcode) const
Log event CmdResponseWhileAwaitingDirective.
void init()
Initialization function.
void log_WARNING_HI_InvalidSeqCancelCall(I32 state) const
Log event InvalidSeqCancelCall.
stores a value to a local variable at a runtime-determined offset relative to the current stack frame...
void init()
Initialization function.
Definition: PingPortAc.cpp:73
virtual void directive_return_internalInterfaceHandler(const Svc::FpySequencer_ReturnDirective &directive)=0
Internal interface handler for directive_return.
virtual void BREAK_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command BREAK.
void tlmWrite_DirectiveErrorIndex(U64 arg, Fw::Time _tlmTime=Fw::Time())
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
Command failed validation.
RateGroupDivider component implementation.
virtual void cmdResponseIn_preMsgHook(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response)
Pre-message hook for async input port cmdResponseIn.
message sent/received okay
Definition: Queue.hpp:31
Enum representing parameter validity.
virtual void directive_popEvent_internalInterfaceHandler(const Svc::FpySequencer_PopEventDirective &directive)=0
Internal interface handler for directive_popEvent.
U8 BYTE
byte type
Definition: BasicTypes.h:57
void log_FATAL_LogFatal(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogFatal.
virtual void VALIDATE_ARGS_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName, const Svc::SeqArgs &buffer)=0
void log_WARNING_HI_TooManySequenceArgs(U8 count, U8 max) const
Log event TooManySequenceArgs.
void sequencer_sendSignal_cmd_CONTINUE()
Send signal cmd_CONTINUE to state machine sequencer.
void directive_storeAbs_internalInterfaceInvoke(const Svc::FpySequencer_StoreAbsDirective &directive)
Internal interface base-class function for directive_storeAbs.
void DUMP_STACK_TO_FILE_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void log_WARNING_HI_MismatchedTimeBase(I32 internalTimeBase, I32 otherTimeBase) const
Log event MismatchedTimeBase.
void invoke(FwPrmIdType id, Fw::ParamBuffer &val) const
Invoke a port connection.
void sequencer_sendSignal_result_failure()
Send signal result_failure to state machine sequencer.
void log_WARNING_LO_CmdResponseWhileNotRunningSequence(I32 state, FwOpcodeType opcode, const Fw::CmdResponse &response) const
Log event CmdResponseWhileNotRunningSequence.
bool isConnected_seqStartOut_OutputPort(FwIndexType portNum) const
virtual void RUN_ARGS_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName, const Svc::BlockState &block, const Svc::SeqArgs &buffer)=0
Handler for command RUN_ARGS.
virtual void CONTINUE_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CONTINUE.
void log_WARNING_HI_ArgSizeMismatch(Svc::Fpy::StackSizeType expected, FwSizeType actual, const Fw::StringBase &filePath) const
Log event ArgSizeMismatch.
called on CANCEL cmd. raised in all states except IDLE
virtual void checkTimers_preMsgHook(FwIndexType portNum, U32 context)
Pre-message hook for async input port checkTimers.
void addCallPort(InputComPort *callPort)
Register an input port.
Definition: ComPortAc.cpp:168
void seqStartOut_out(FwIndexType portNum, const Fw::StringBase &filename, const Svc::SeqArgs &args) const
Invoke output port seqStartOut.
void sequencer_sendSignal_entered()
Send signal entered to state machine sequencer.
void directive_call_internalInterfaceInvoke(const Svc::FpySequencer_CallDirective &directive)
Internal interface base-class function for directive_call.
void directive_exit_internalInterfaceInvoke(const Svc::FpySequencer_ExitDirective &directive)
Internal interface base-class function for directive_exit.
void log_WARNING_HI_WrongCmdResponseOpcode(FwOpcodeType opcode, const Fw::CmdResponse &response, FwOpcodeType expectedOpcode) const
Log event WrongCmdResponseOpcode.
void addCallComp(Fw::PassiveComponentBase *callComp, CompFuncPtr funcPtr)
Register a component.
Definition: PingPortAc.cpp:79
void directive_storeAbsConstOffset_internalInterfaceInvoke(const Svc::FpySequencer_StoreAbsConstOffsetDirective &directive)
Internal interface base-class function for directive_storeAbsConstOffset.
FpySequencerComponentBase::SmId getId() const
Get the state machine id.
pushes the current Fw.Time struct to the stack
void log_ACTIVITY_HI_SequenceDone(const Fw::StringBase &filePath) const
Log event SequenceDone.
LinearBufferTemplate< FW_SM_SIGNAL_BUFFER_MAX_SIZE > SmSignalBuffer
void directive_goto_internalInterfaceInvoke(const Svc::FpySequencer_GotoDirective &directive)
Internal interface base-class function for directive_goto.
static constexpr FwIndexType getNum_seqDoneOut_OutputPorts()
void directive_waitRel_internalInterfaceInvoke(const Svc::FpySequencer_WaitRelDirective &directive)
Internal interface base-class function for directive_waitRel.
virtual void directive_pushTlmValAndTime_internalInterfaceHandler(const Svc::FpySequencer_PushTlmValAndTimeDirective &directive)=0
Internal interface handler for directive_pushTlmValAndTime.
void directive_storeRel_internalInterfaceInvoke(const Svc::FpySequencer_StoreRelDirective &directive)
Internal interface base-class function for directive_storeRel.
Message will return with status when space is unavailable.
Definition: Queue.hpp:48
virtual void directive_pushTlmVal_internalInterfaceHandler(const Svc::FpySequencer_PushTlmValDirective &directive)=0
Internal interface handler for directive_pushTlmVal.
Implementation of malloc based allocator.
Loads and validates a sequence with arguments.
void SET_BREAKPOINT_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
void directive_loadRel_internalInterfaceInvoke(const Svc::FpySequencer_LoadRelDirective &directive)
Internal interface base-class function for directive_loadRel.
Auto-generated base for FpySequencer component.
static constexpr FwIndexType getNum_logOut_OutputPorts()
void sequencer_sendSignal_cmd_RUN(const Svc::FpySequencer_SequenceExecutionArgs &value)
Send signal cmd_RUN to state machine sequencer.
void log_WARNING_HI_FileWriteError(FwSizeType writeSize, const Fw::StringBase &filePath, I32 errorCode) const
Log event FileWriteError.
virtual void directive_storeAbsConstOffset_internalInterfaceHandler(const Svc::FpySequencer_StoreAbsConstOffsetDirective &directive)=0
Internal interface handler for directive_storeAbsConstOffset.
static constexpr SizeType BUFFER_SIZE(SizeType maxLength)
Get the size of a null-terminated string buffer.
void init()
Initialization function.
void log_WARNING_HI_FileReadDeserializeError(const Svc::FpySequencer_FileReadStage &readStage, const Fw::StringBase &filePath, I32 errorCode, U64 buffLeft, U64 buffLength) const
Log event FileReadDeserializeError.
void log_WARNING_LO_CmdResponseFromOldSequence(FwOpcodeType opcode, const Fw::CmdResponse &response, U16 oldSequenceIdx, U16 currentSequenceIdx) const
Log event CmdResponseFromOldSequence.
void checkTimers_handlerBase(FwIndexType portNum, U32 context)
Handler base-class function for input port checkTimers.
void init()
Initialization function.
static constexpr FwIndexType getNum_prmGet_OutputPorts()
static constexpr FwIndexType getNum_seqCancelIn_InputPorts()
virtual void CANCEL_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CANCEL.
void tlmWrite_BreakOnlyOnceOnBreakpoint(bool arg, Fw::Time _tlmTime=Fw::Time())
virtual SerializeStatus moveDeserToOffset(FwSizeType offset)=0
Move deserialization pointer to specified offset.
called when the statement is telling the sequencer to await a later stmt response ...
FpySequencer_SequencerStateMachineStateMachineBase::Signal Signal
Fw::TlmValid getTlmChan_out(FwIndexType portNum, FwChanIdType id, Fw::Time &timeTag, Fw::TlmBuffer &val) const
Invoke output port getTlmChan.
void tlmWrite_SequencesCancelled(U64 arg, Fw::Time _tlmTime=Fw::Time())
virtual void directive_loadAbs_internalInterfaceHandler(const Svc::FpySequencer_LoadAbsDirective &directive)=0
Internal interface handler for directive_loadAbs.
#define FW_ASSERT(...)
Definition: Assert.hpp:14
void tlmWrite_BreakpointInUse(bool arg, Fw::Time _tlmTime=Fw::Time())
static constexpr FwSizeType CAPACITY
Definition: SchedPortAc.hpp:34
bool isConnected_seqDoneOut_OutputPort(FwIndexType portNum) const
void set_prmGet_OutputPort(FwIndexType portNum, Fw::InputPrmGetPort *port)
Connect port to prmGet[portNum].
void set_getParam_OutputPort(FwIndexType portNum, Fw::InputPrmGetPort *port)
Connect port to getParam[portNum].
void CLEAR_BREAKPOINT_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
PlatformAssertArgType FwAssertArgType
The type of arguments to assert functions.
U32 StackSizeType
the type which everything referencing a size or offset on the stack is represented in ...
void addCallPort(InputCmdResponsePort *callPort)
Register an input port.
void lock()
lock the mutex and assert success
Definition: Mutex.cpp:34
void tlmWrite(FwChanIdType id, Fw::TlmBuffer &_tlmBuff, Fw::Time _tlmTime=Fw::Time()) const
void tlmWrite_BreakpointIndex(U32 arg, Fw::Time _tlmTime=Fw::Time())
U32 FwIdType
The id type.
SerializeStatus serializeTo(SerialBufferBase &buffer, Endianness mode=Endianness::BIG) const override
Serialize the contents of this object to a buffer.
BYTE cmdPortSize[Fw::CmdPortBuffer::CAPACITY]
#define U64(C)
Definition: sha.h:181
void tlmWrite_Debug_NextStatementReadSuccess(bool arg, Fw::Time _tlmTime=Fw::Time())