F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
FpySequencerComponentAc.hpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title FpySequencerComponentAc.hpp
3 // \author Generated by fpp-to-cpp
4 // \brief hpp file for FpySequencer component base class
5 // ======================================================================
6 
7 #ifndef Svc_FpySequencerComponentAc_HPP
8 #define Svc_FpySequencerComponentAc_HPP
9 
10 #include <atomic>
11 
12 #include "Fw/Cmd/CmdPortAc.hpp"
13 #include "Fw/Cmd/CmdRegPortAc.hpp"
16 #include "Fw/Cmd/CmdString.hpp"
17 #include "Fw/Com/ComPortAc.hpp"
19 #include "Fw/FPrimeBasicTypes.hpp"
20 #include "Fw/Log/LogPortAc.hpp"
21 #include "Fw/Log/LogString.hpp"
22 #if FW_ENABLE_TEXT_LOGGING == 1
23 #include "Fw/Log/LogTextPortAc.hpp"
24 #endif
25 #if !FW_DIRECT_PORT_CALLS
27 #endif
28 #if !FW_DIRECT_PORT_CALLS
30 #endif
31 #include "Fw/Prm/PrmGetPortAc.hpp"
32 #include "Fw/Prm/PrmSetPortAc.hpp"
33 #include "Fw/Prm/PrmString.hpp"
34 #include "Fw/Time/TimePortAc.hpp"
35 #include "Fw/Tlm/TlmGetPortAc.hpp"
36 #include "Fw/Tlm/TlmPortAc.hpp"
37 #include "Fw/Tlm/TlmString.hpp"
39 #include "Os/Mutex.hpp"
78 #include "Svc/Ping/PingPortAc.hpp"
87 
88 namespace Svc {
89 
96  {
97 
98  // ----------------------------------------------------------------------
99  // Friend classes
100  // ----------------------------------------------------------------------
101 
105  friend class FpySequencerTester;
106 
107  protected:
108 
109  // ----------------------------------------------------------------------
110  // Constants
111  // ----------------------------------------------------------------------
112 
114  enum {
116  };
117 
119  enum {
125  };
126 
128  enum {
137  };
138 
140  enum {
147  };
148 
150  enum {
151  OPCODE_RUN = 0x0,
155  OPCODE_SET_BREAKPOINT = 0x4,
157  OPCODE_BREAK = 0x5,
161  OPCODE_CONTINUE = 0x6,
166  OPCODE_STEP = 0x8,
172  };
173 
175  enum {
215  };
216 
218  enum {
240  };
241 
243  enum {
245  };
249 
251  enum class SmId : FwEnumStoreType {
252  sequencer,
253  };
254 
255  protected:
256 
257  // ----------------------------------------------------------------------
258  // Types for internal state machines
259  // ----------------------------------------------------------------------
260 
264  {
265 
266  // ----------------------------------------------------------------------
267  // Friend classes
268  // ----------------------------------------------------------------------
269 
273  friend class FpySequencerTester;
274 
275  public:
276 
279  FpySequencerComponentBase& component
280  );
281 
282  public:
283 
285  void init(
287  );
288 
289  public:
290 
293 
294  private:
295 
297  void action_signalEntered(
298  Signal signal
299  );
300 
302  void action_setSequenceFilePath(
303  Signal signal,
305  );
306 
308  void action_setSequenceBlockState(
309  Signal signal,
311  );
312 
314  void action_validate(
315  Signal signal
316  );
317 
319  void action_report_seqSucceeded(
320  Signal signal
321  );
322 
324  void action_report_seqCancelled(
325  Signal signal
326  );
327 
329  void action_report_seqFailed(
330  Signal signal
331  );
332 
334  void action_report_seqStarted(
335  Signal signal
336  );
337 
339  void action_setGoalState_RUNNING(
340  Signal signal
341  );
342 
344  void action_setGoalState_VALID(
345  Signal signal
346  );
347 
349  void action_setGoalState_IDLE(
350  Signal signal
351  );
352 
354  void action_sendCmdResponse_OK(
355  Signal signal
356  );
357 
359  void action_sendCmdResponse_EXECUTION_ERROR(
360  Signal signal
361  );
362 
364  void action_clearSequenceFile(
365  Signal signal
366  );
367 
369  void action_clearBreakpoint(
370  Signal signal
371  );
372 
374  void action_checkShouldWake(
375  Signal signal
376  );
377 
379  void action_dispatchStatement(
380  Signal signal
381  );
382 
384  void action_resetRuntime(
385  Signal signal
386  );
387 
389  void action_checkStatementTimeout(
390  Signal signal
391  );
392 
394  void action_incrementSequenceCounter(
395  Signal signal
396  );
397 
399  void action_report_seqBroken(
400  Signal signal
401  );
402 
404  void action_setBreakpoint(
405  Signal signal,
407  );
408 
410  void action_setBreakBeforeNextLine(
411  Signal signal
412  );
413 
415  void action_clearBreakBeforeNextLine(
416  Signal signal
417  );
418 
419  private:
420 
422  bool guard_goalStateIs_RUNNING(
423  Signal signal
424  ) const;
425 
427  bool guard_shouldBreak(
428  Signal signal
429  ) const;
430 
432  bool guard_breakOnce(
433  Signal signal
434  ) const;
435 
436  private:
437 
439  FpySequencerComponentBase& m_component;
440 
441  };
442 
443  public:
444 
445  // ----------------------------------------------------------------------
446  // Component initialization
447  // ----------------------------------------------------------------------
448 
450  void init(
451  FwSizeType queueDepth,
452  FwEnumStoreType instance = 0
453  );
454 
455 #if !FW_DIRECT_PORT_CALLS
456 
457  public:
458 
459  // ----------------------------------------------------------------------
460  // Getters for special input ports
461  // ----------------------------------------------------------------------
462 
467  FwIndexType portNum
468  );
469 
470 #endif
471 
472 #if !FW_DIRECT_PORT_CALLS
473 
474  public:
475 
476  // ----------------------------------------------------------------------
477  // Getters for typed input ports
478  // ----------------------------------------------------------------------
479 
484  FwIndexType portNum
485  );
486 
491  FwIndexType portNum
492  );
493 
498  FwIndexType portNum
499  );
500 
505  FwIndexType portNum
506  );
507 
512  FwIndexType portNum
513  );
514 
515 #endif
516 
517 #if !FW_DIRECT_PORT_CALLS
518 
519  public:
520 
521  // ----------------------------------------------------------------------
522  // Connect input ports to special output ports
523  // ----------------------------------------------------------------------
524 
527  FwIndexType portNum,
528  Fw::InputCmdRegPort* port
529  );
530 
533  FwIndexType portNum,
535  );
536 
539  FwIndexType portNum,
540  Fw::InputLogPort* port
541  );
542 
543 #if FW_ENABLE_TEXT_LOGGING == 1
544 
546  void set_logTextOut_OutputPort(
547  FwIndexType portNum,
548  Fw::InputLogTextPort* port
549  );
550 
551 #endif
552 
555  FwIndexType portNum,
556  Fw::InputPrmGetPort* port
557  );
558 
561  FwIndexType portNum,
562  Fw::InputPrmSetPort* port
563  );
564 
567  FwIndexType portNum,
568  Fw::InputTimePort* port
569  );
570 
573  FwIndexType portNum,
574  Fw::InputTlmPort* port
575  );
576 
577 #endif
578 
579 #if !FW_DIRECT_PORT_CALLS
580 
581  public:
582 
583  // ----------------------------------------------------------------------
584  // Connect typed input ports to typed output ports
585  // ----------------------------------------------------------------------
586 
589  FwIndexType portNum,
590  Fw::InputComPort* port
591  );
592 
595  FwIndexType portNum,
596  Fw::InputPrmGetPort* port
597  );
598 
601  FwIndexType portNum,
602  Fw::InputTlmGetPort* port
603  );
604 
607  FwIndexType portNum,
608  Svc::InputPingPort* port
609  );
610 
613  FwIndexType portNum,
615  );
616 
619  FwIndexType portNum,
621  );
622 
623 #endif
624 
625 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
626 
627  public:
628 
629  // ----------------------------------------------------------------------
630  // Connect serial input ports to special output ports
631  // ----------------------------------------------------------------------
632 
635  FwIndexType portNum,
636  Fw::InputSerializePort* port
637  );
638 
641  FwIndexType portNum,
642  Fw::InputSerializePort* port
643  );
644 
647  FwIndexType portNum,
648  Fw::InputSerializePort* port
649  );
650 
651 #if FW_ENABLE_TEXT_LOGGING == 1
652 
654  void set_logTextOut_OutputPort(
655  FwIndexType portNum,
656  Fw::InputSerializePort* port
657  );
658 
659 #endif
660 
663  FwIndexType portNum,
664  Fw::InputSerializePort* port
665  );
666 
669  FwIndexType portNum,
670  Fw::InputSerializePort* port
671  );
672 
675  FwIndexType portNum,
676  Fw::InputSerializePort* port
677  );
678 
679 #endif
680 
681 #if !FW_DIRECT_PORT_CALLS && FW_PORT_SERIALIZATION
682 
683  public:
684 
685  // ----------------------------------------------------------------------
686  // Connect serial input ports to typed output ports
687  // ----------------------------------------------------------------------
688 
691  FwIndexType portNum,
692  Fw::InputSerializePort* port
693  );
694 
697  FwIndexType portNum,
698  Fw::InputSerializePort* port
699  );
700 
703  FwIndexType portNum,
704  Fw::InputSerializePort* port
705  );
706 
709  FwIndexType portNum,
710  Fw::InputSerializePort* port
711  );
712 
713 #endif
714 
715  public:
716 
717  // ----------------------------------------------------------------------
718  // Command registration
719  // ----------------------------------------------------------------------
720 
724  void regCommands();
725 
726  public:
727 
728  // ----------------------------------------------------------------------
729  // Parameter loading
730  // ----------------------------------------------------------------------
731 
735  void loadParameters();
736 
737  protected:
738 
739  // ----------------------------------------------------------------------
740  // Component construction and destruction
741  // ----------------------------------------------------------------------
742 
745  const char* compName = ""
746  );
747 
749  virtual ~FpySequencerComponentBase();
750 
751  protected:
752 
753  // ----------------------------------------------------------------------
754  // Getters for numbers of special input ports
755  // ----------------------------------------------------------------------
756 
761  return NUM_CMDIN_INPUT_PORTS;
762  }
763 
764  protected:
765 
766  // ----------------------------------------------------------------------
767  // Getters for numbers of typed input ports
768  // ----------------------------------------------------------------------
769 
775  }
776 
782  }
783 
788  return NUM_PINGIN_INPUT_PORTS;
789  }
790 
796  }
797 
803  }
804 
805  protected:
806 
807  // ----------------------------------------------------------------------
808  // Getters for numbers of special output ports
809  // ----------------------------------------------------------------------
810 
816  }
817 
823  }
824 
830  }
831 
832 #if FW_ENABLE_TEXT_LOGGING == 1
833 
837  static constexpr FwIndexType getNum_logTextOut_OutputPorts() {
839  }
840 
841 #endif
842 
848  }
849 
855  }
856 
862  }
863 
869  }
870 
871  protected:
872 
873  // ----------------------------------------------------------------------
874  // Getters for numbers of typed output ports
875  // ----------------------------------------------------------------------
876 
882  }
883 
889  }
890 
896  }
897 
903  }
904 
910  }
911 
917  }
918 
919  protected:
920 
921  // ----------------------------------------------------------------------
922  // Connection status queries for special output ports
923  // ----------------------------------------------------------------------
924 
929  FwIndexType portNum
930  ) const;
931 
936  FwIndexType portNum
937  ) const;
938 
943  FwIndexType portNum
944  ) const;
945 
946 #if FW_ENABLE_TEXT_LOGGING == 1
947 
951  bool isConnected_logTextOut_OutputPort(
952  FwIndexType portNum
953  ) const;
954 
955 #endif
956 
961  FwIndexType portNum
962  ) const;
963 
968  FwIndexType portNum
969  ) const;
970 
975  FwIndexType portNum
976  ) const;
977 
982  FwIndexType portNum
983  ) const;
984 
985  protected:
986 
987  // ----------------------------------------------------------------------
988  // Connection status queries for typed output ports
989  // ----------------------------------------------------------------------
990 
995  FwIndexType portNum
996  ) const;
997 
1002  FwIndexType portNum
1003  ) const;
1004 
1009  FwIndexType portNum
1010  ) const;
1011 
1016  FwIndexType portNum
1017  ) const;
1018 
1023  FwIndexType portNum
1024  ) const;
1025 
1030  FwIndexType portNum
1031  ) const;
1032 
1033 #if FW_DIRECT_PORT_CALLS
1034  public:
1035 #else
1036  protected:
1037 #endif
1038 
1039  // ----------------------------------------------------------------------
1040  // Port handler base-class functions for special input ports
1041  //
1042  // Call these functions directly to bypass the corresponding ports
1043  // ----------------------------------------------------------------------
1044 
1046  void cmdIn_handlerBase(
1047  FwIndexType portNum,
1048  FwOpcodeType opCode,
1049  U32 cmdSeq,
1050  Fw::CmdArgBuffer& args
1051  );
1052 
1053  protected:
1054 
1055  // ----------------------------------------------------------------------
1056  // Handlers to implement for typed input ports
1057  // ----------------------------------------------------------------------
1058 
1060  virtual void checkTimers_handler(
1061  FwIndexType portNum,
1062  U32 context
1063  ) = 0;
1064 
1066  virtual void cmdResponseIn_handler(
1067  FwIndexType portNum,
1068  FwOpcodeType opCode,
1069  U32 cmdSeq,
1070  const Fw::CmdResponse& response
1071  ) = 0;
1072 
1074  virtual void pingIn_handler(
1075  FwIndexType portNum,
1076  U32 key
1077  ) = 0;
1078 
1080  virtual void seqRunIn_handler(
1081  FwIndexType portNum,
1082  const Fw::StringBase& filename
1083  ) = 0;
1084 
1086  virtual void tlmWrite_handler(
1087  FwIndexType portNum,
1088  U32 context
1089  ) = 0;
1090 
1091 #if FW_DIRECT_PORT_CALLS
1092  public:
1093 #else
1094  protected:
1095 #endif
1096 
1097  // ----------------------------------------------------------------------
1098  // Port handler base-class functions for typed input ports
1099  //
1100  // Call these functions directly to bypass the corresponding ports
1101  // ----------------------------------------------------------------------
1102 
1105  FwIndexType portNum,
1106  U32 context
1107  );
1108 
1111  FwIndexType portNum,
1112  FwOpcodeType opCode,
1113  U32 cmdSeq,
1114  const Fw::CmdResponse& response
1115  );
1116 
1118  void pingIn_handlerBase(
1119  FwIndexType portNum,
1120  U32 key
1121  );
1122 
1124  void seqRunIn_handlerBase(
1125  FwIndexType portNum,
1126  const Fw::StringBase& filename
1127  );
1128 
1130  void tlmWrite_handlerBase(
1131  FwIndexType portNum,
1132  U32 context
1133  );
1134 
1135  protected:
1136 
1137  // ----------------------------------------------------------------------
1138  // Pre-message hooks for typed async input ports
1139  //
1140  // Each of these functions is invoked just before processing a message
1141  // on the corresponding port. By default, they do nothing. You can
1142  // override them to provide specific pre-message behavior.
1143  // ----------------------------------------------------------------------
1144 
1146  virtual void checkTimers_preMsgHook(
1147  FwIndexType portNum,
1148  U32 context
1149  );
1150 
1152  virtual void cmdResponseIn_preMsgHook(
1153  FwIndexType portNum,
1154  FwOpcodeType opCode,
1155  U32 cmdSeq,
1156  const Fw::CmdResponse& response
1157  );
1158 
1160  virtual void pingIn_preMsgHook(
1161  FwIndexType portNum,
1162  U32 key
1163  );
1164 
1166  virtual void seqRunIn_preMsgHook(
1167  FwIndexType portNum,
1168  const Fw::StringBase& filename
1169  );
1170 
1172  virtual void tlmWrite_preMsgHook(
1173  FwIndexType portNum,
1174  U32 context
1175  );
1176 
1177  protected:
1178 
1179  // ----------------------------------------------------------------------
1180  // Invocation functions for typed output ports
1181  // ----------------------------------------------------------------------
1182 
1184  void cmdOut_out(
1185  FwIndexType portNum,
1186  Fw::ComBuffer& data,
1187  U32 context
1188  ) const;
1189 
1192  FwIndexType portNum,
1193  FwPrmIdType id,
1194  Fw::ParamBuffer& val
1195  ) const;
1197 
1200  FwIndexType portNum,
1201  FwChanIdType id,
1202  Fw::Time& timeTag,
1203  Fw::TlmBuffer& val
1204  ) const;
1207 
1209  void pingOut_out(
1210  FwIndexType portNum,
1211  U32 key
1212  ) const;
1213 
1215  void seqDoneOut_out(
1216  FwIndexType portNum,
1217  FwOpcodeType opCode,
1218  U32 cmdSeq,
1219  const Fw::CmdResponse& response
1220  ) const;
1221 
1223  void seqStartOut_out(
1224  FwIndexType portNum,
1225  const Fw::StringBase& filename
1226  ) const;
1227 
1228  protected:
1229 
1230  // ----------------------------------------------------------------------
1231  // Internal interface handlers
1232  // ----------------------------------------------------------------------
1233 
1236 
1239 
1242 
1245 
1248 
1251 
1254 
1256  virtual void directive_if_internalInterfaceHandler(const Svc::FpySequencer_IfDirective& directive) = 0;
1257 
1260 
1263 
1266 
1269 
1272 
1275 
1278 
1281 
1284 
1287 
1290 
1293 
1296 
1299 
1302 
1305 
1308 
1311 
1314 
1317 
1318  protected:
1319 
1320  // ----------------------------------------------------------------------
1321  // Internal interface base-class functions
1322  // ----------------------------------------------------------------------
1323 
1326 
1329 
1332 
1335 
1338 
1341 
1344 
1347 
1350 
1353 
1356 
1359 
1362 
1365 
1368 
1371 
1374 
1377 
1380 
1383 
1386 
1389 
1392 
1395 
1398 
1401 
1404 
1407 
1408  protected:
1409 
1410  // ----------------------------------------------------------------------
1411  // State getter functions
1412  // ----------------------------------------------------------------------
1413 
1416 
1417  protected:
1418 
1419  // ----------------------------------------------------------------------
1420  // Signal send functions
1421  // ----------------------------------------------------------------------
1422 
1426  );
1427 
1431  );
1432 
1436  );
1437 
1440 
1443  const Svc::FpySequencer_BreakpointArgs& value
1444  );
1445 
1448 
1451 
1454 
1457 
1460 
1463 
1466 
1469 
1472 
1475 
1478 
1481 
1484 
1487 
1490 
1493 
1496 
1499 
1502 
1505 
1508 
1509  protected:
1510 
1511  // ----------------------------------------------------------------------
1512  // Functions to implement for internal state machine actions
1513  // ----------------------------------------------------------------------
1514 
1519  SmId smId,
1521  ) = 0;
1522 
1527  SmId smId,
1530  ) = 0;
1531 
1536  SmId smId,
1539  ) = 0;
1540 
1545  SmId smId,
1547  ) = 0;
1548 
1553  SmId smId,
1555  ) = 0;
1556 
1561  SmId smId,
1563  ) = 0;
1564 
1569  SmId smId,
1571  ) = 0;
1572 
1577  SmId smId,
1579  ) = 0;
1580 
1585  SmId smId,
1587  ) = 0;
1588 
1593  SmId smId,
1595  ) = 0;
1596 
1601  SmId smId,
1603  ) = 0;
1604 
1609  SmId smId,
1611  ) = 0;
1612 
1617  SmId smId,
1619  ) = 0;
1620 
1625  SmId smId,
1627  ) = 0;
1628 
1633  SmId smId,
1635  ) = 0;
1636 
1641  SmId smId,
1643  ) = 0;
1644 
1649  SmId smId,
1651  ) = 0;
1652 
1657  SmId smId,
1659  ) = 0;
1660 
1665  SmId smId,
1667  ) = 0;
1668 
1673  SmId smId,
1675  ) = 0;
1676 
1681  SmId smId,
1683  ) = 0;
1684 
1689  SmId smId,
1691  const Svc::FpySequencer_BreakpointArgs& value
1692  ) = 0;
1693 
1698  SmId smId,
1700  ) = 0;
1701 
1706  SmId smId,
1708  ) = 0;
1709 
1710  protected:
1711 
1712  // ----------------------------------------------------------------------
1713  // Functions to implement for internal state machine guards
1714  // ----------------------------------------------------------------------
1715 
1720  SmId smId,
1722  ) const = 0;
1723 
1729  SmId smId,
1731  ) const = 0;
1732 
1737  SmId smId,
1739  ) const = 0;
1740 
1741  protected:
1742 
1743  // ----------------------------------------------------------------------
1744  // Command response
1745  // ----------------------------------------------------------------------
1746 
1748  void cmdResponse_out(
1749  FwOpcodeType opCode,
1750  U32 cmdSeq,
1751  Fw::CmdResponse response
1752  );
1753 
1754  protected:
1755 
1756  // ----------------------------------------------------------------------
1757  // Command handlers to implement
1758  // ----------------------------------------------------------------------
1759 
1763  virtual void RUN_cmdHandler(
1764  FwOpcodeType opCode,
1765  U32 cmdSeq,
1766  const Fw::CmdStringArg& fileName,
1768  ) = 0;
1769 
1773  virtual void VALIDATE_cmdHandler(
1774  FwOpcodeType opCode,
1775  U32 cmdSeq,
1776  const Fw::CmdStringArg& fileName
1777  ) = 0;
1778 
1782  virtual void RUN_VALIDATED_cmdHandler(
1783  FwOpcodeType opCode,
1784  U32 cmdSeq,
1786  ) = 0;
1787 
1792  virtual void CANCEL_cmdHandler(
1793  FwOpcodeType opCode,
1794  U32 cmdSeq
1795  ) = 0;
1796 
1803  virtual void SET_BREAKPOINT_cmdHandler(
1804  FwOpcodeType opCode,
1805  U32 cmdSeq,
1806  U32 stmtIdx,
1807  bool breakOnce
1808  ) = 0;
1809 
1815  virtual void BREAK_cmdHandler(
1816  FwOpcodeType opCode,
1817  U32 cmdSeq
1818  ) = 0;
1819 
1824  virtual void CONTINUE_cmdHandler(
1825  FwOpcodeType opCode,
1826  U32 cmdSeq
1827  ) = 0;
1828 
1833  virtual void CLEAR_BREAKPOINT_cmdHandler(
1834  FwOpcodeType opCode,
1835  U32 cmdSeq
1836  ) = 0;
1837 
1842  virtual void STEP_cmdHandler(
1843  FwOpcodeType opCode,
1844  U32 cmdSeq
1845  ) = 0;
1846 
1850  virtual void DUMP_STACK_TO_FILE_cmdHandler(
1851  FwOpcodeType opCode,
1852  U32 cmdSeq,
1853  const Fw::CmdStringArg& fileName
1854  ) = 0;
1855 
1856  protected:
1857 
1858  // ----------------------------------------------------------------------
1859  // Command handler base-class functions
1860  //
1861  // Call these functions directly to bypass the command input port
1862  // ----------------------------------------------------------------------
1863 
1867  void RUN_cmdHandlerBase(
1868  FwOpcodeType opCode,
1869  U32 cmdSeq,
1870  Fw::CmdArgBuffer& args
1871  );
1872 
1877  FwOpcodeType opCode,
1878  U32 cmdSeq,
1879  Fw::CmdArgBuffer& args
1880  );
1881 
1886  FwOpcodeType opCode,
1887  U32 cmdSeq,
1888  Fw::CmdArgBuffer& args
1889  );
1890 
1895  void CANCEL_cmdHandlerBase(
1896  FwOpcodeType opCode,
1897  U32 cmdSeq,
1898  Fw::CmdArgBuffer& args
1899  );
1900 
1908  FwOpcodeType opCode,
1909  U32 cmdSeq,
1910  Fw::CmdArgBuffer& args
1911  );
1912 
1918  void BREAK_cmdHandlerBase(
1919  FwOpcodeType opCode,
1920  U32 cmdSeq,
1921  Fw::CmdArgBuffer& args
1922  );
1923 
1929  FwOpcodeType opCode,
1930  U32 cmdSeq,
1931  Fw::CmdArgBuffer& args
1932  );
1933 
1939  FwOpcodeType opCode,
1940  U32 cmdSeq,
1941  Fw::CmdArgBuffer& args
1942  );
1943 
1948  void STEP_cmdHandlerBase(
1949  FwOpcodeType opCode,
1950  U32 cmdSeq,
1951  Fw::CmdArgBuffer& args
1952  );
1953 
1958  FwOpcodeType opCode,
1959  U32 cmdSeq,
1960  Fw::CmdArgBuffer& args
1961  );
1962 
1963  protected:
1964 
1965  // ----------------------------------------------------------------------
1966  // Pre-message hooks for async commands
1967  //
1968  // Each of these functions is invoked just before processing the
1969  // corresponding command. By default they do nothing. You can
1970  // override them to provide specific pre-command behavior.
1971  // ----------------------------------------------------------------------
1972 
1974  virtual void RUN_preMsgHook(
1975  FwOpcodeType opCode,
1976  U32 cmdSeq
1977  );
1978 
1980  virtual void VALIDATE_preMsgHook(
1981  FwOpcodeType opCode,
1982  U32 cmdSeq
1983  );
1984 
1986  virtual void RUN_VALIDATED_preMsgHook(
1987  FwOpcodeType opCode,
1988  U32 cmdSeq
1989  );
1990 
1992  virtual void CANCEL_preMsgHook(
1993  FwOpcodeType opCode,
1994  U32 cmdSeq
1995  );
1996 
1998  virtual void SET_BREAKPOINT_preMsgHook(
1999  FwOpcodeType opCode,
2000  U32 cmdSeq
2001  );
2002 
2004  virtual void BREAK_preMsgHook(
2005  FwOpcodeType opCode,
2006  U32 cmdSeq
2007  );
2008 
2010  virtual void CONTINUE_preMsgHook(
2011  FwOpcodeType opCode,
2012  U32 cmdSeq
2013  );
2014 
2016  virtual void CLEAR_BREAKPOINT_preMsgHook(
2017  FwOpcodeType opCode,
2018  U32 cmdSeq
2019  );
2020 
2022  virtual void STEP_preMsgHook(
2023  FwOpcodeType opCode,
2024  U32 cmdSeq
2025  );
2026 
2028  virtual void DUMP_STACK_TO_FILE_preMsgHook(
2029  FwOpcodeType opCode,
2030  U32 cmdSeq
2031  );
2032 
2033  protected:
2034 
2035  // ----------------------------------------------------------------------
2036  // Event logging functions
2037  // ----------------------------------------------------------------------
2038 
2040  void log_WARNING_HI_InvalidCommand(I32 state) const;
2041 
2043  void log_WARNING_HI_InvalidSeqRunCall(I32 state) const;
2044 
2047  const Fw::StringBase& filePath,
2048  I32 errorCode
2049  ) const;
2050 
2053  FwSizeType writeSize,
2054  const Fw::StringBase& filePath,
2055  I32 errorCode
2056  ) const;
2057 
2061  const Fw::StringBase& filePath,
2062  I32 errorCode
2063  ) const;
2064 
2068  const Fw::StringBase& filePath
2069  ) const;
2070 
2074  const Fw::StringBase& filePath,
2075  I32 errorCode,
2076  U64 buffLeft,
2077  U64 buffLength
2078  ) const;
2079 
2082  U8 expected,
2083  U8 actual
2084  ) const;
2085 
2088  U32 expected,
2089  U32 actual
2090  ) const;
2091 
2093  void log_WARNING_HI_ExtraBytesInSequence(FwSizeType remaining) const;
2094 
2097  U64 bufferSize,
2098  const Fw::StringBase& filePath
2099  ) const;
2100 
2103  FwOpcodeType opCode,
2104  U32 stmtIdx,
2105  const Fw::StringBase& filePath,
2106  Fw::CmdResponse response
2107  ) const;
2108 
2110  void log_ACTIVITY_HI_SequenceDone(const Fw::StringBase& filePath) const;
2111 
2113  void log_ACTIVITY_HI_SequenceCancelled(const Fw::StringBase& filePath) const;
2114 
2117  const Fw::StringBase& filePath,
2118  U8 errorCode
2119  ) const;
2120 
2123  U8 opcode,
2124  U32 stmtIdx,
2125  const Fw::StringBase& filePath
2126  ) const;
2127 
2130  I32 state,
2131  FwOpcodeType opcode,
2132  Fw::CmdResponse response
2133  ) const;
2134 
2137  FwOpcodeType opcode,
2138  Fw::CmdResponse response,
2139  U16 oldSequenceIdx,
2140  U16 currentSequenceIdx
2141  ) const;
2142 
2145  FwOpcodeType opcode,
2146  Fw::CmdResponse response
2147  ) const;
2148 
2151  FwOpcodeType opcode,
2152  Fw::CmdResponse response,
2153  U8 expectedDirectiveOpcode
2154  ) const;
2155 
2158  FwOpcodeType opcode,
2159  Fw::CmdResponse response,
2160  FwOpcodeType expectedOpcode
2161  ) const;
2162 
2165  FwOpcodeType opcode,
2166  Fw::CmdResponse response,
2167  U16 actualCmdIdx,
2168  U16 expectedCmdIdx
2169  ) const;
2170 
2173  U8 opcode,
2174  U32 stmtIdx,
2175  I32 errorCode,
2176  U64 buffLeft,
2177  U64 buffLength
2178  ) const;
2179 
2182  I32 internalTimeBase,
2183  I32 otherTimeBase
2184  ) const;
2185 
2188  I32 internalTimeContext,
2189  I32 otherTimeContext
2190  ) const;
2191 
2194  FwOpcodeType opCode,
2195  U32 stmtIdx,
2196  const Fw::StringBase& filePath
2197  ) const;
2198 
2201  U8 opCode,
2202  U32 stmtIdx,
2203  const Fw::StringBase& filePath
2204  ) const;
2205 
2208  U8 count,
2209  U8 max
2210  ) const;
2211 
2214  U16 count,
2215  U16 max
2216  ) const;
2217 
2219  void log_ACTIVITY_HI_SequencePaused(U32 stmtIdx) const;
2220 
2223  U32 breakpointIdx,
2224  bool breakOnce
2225  ) const;
2226 
2228  void log_ACTIVITY_HI_BreakpointCleared() const;
2229 
2231  void log_FATAL_LogFatal(
2232  const Fw::StringBase& filePath,
2233  const Fw::StringBase& message
2234  ) const;
2235 
2238  const Fw::StringBase& filePath,
2239  const Fw::StringBase& message
2240  ) const;
2241 
2244  const Fw::StringBase& filePath,
2245  const Fw::StringBase& message
2246  ) const;
2247 
2250  const Fw::StringBase& filePath,
2251  const Fw::StringBase& message
2252  ) const;
2253 
2256  const Fw::StringBase& filePath,
2257  const Fw::StringBase& message
2258  ) const;
2259 
2262  const Fw::StringBase& filePath,
2263  const Fw::StringBase& message
2264  ) const;
2265 
2268  const Fw::StringBase& filePath,
2269  const Fw::StringBase& message
2270  ) const;
2271 
2272  protected:
2273 
2274  // ----------------------------------------------------------------------
2275  // Telemetry write functions
2276  // ----------------------------------------------------------------------
2277 
2281  void tlmWrite_State(
2282  FwEnumStoreType arg,
2283  Fw::Time _tlmTime = Fw::Time()
2284  );
2285 
2290  U64 arg,
2291  Fw::Time _tlmTime = Fw::Time()
2292  );
2293 
2298  U64 arg,
2299  Fw::Time _tlmTime = Fw::Time()
2300  );
2301 
2306  U64 arg,
2307  Fw::Time _tlmTime = Fw::Time()
2308  );
2309 
2316  U64 arg,
2317  Fw::Time _tlmTime = Fw::Time()
2318  );
2319 
2324  U64 arg,
2325  Fw::Time _tlmTime = Fw::Time()
2326  );
2327 
2332  const Svc::Fpy::DirectiveErrorCode& arg,
2333  Fw::Time _tlmTime = Fw::Time()
2334  );
2335 
2340  U64 arg,
2341  Fw::Time _tlmTime = Fw::Time()
2342  );
2343 
2348  const Svc::Fpy::DirectiveId& arg,
2349  Fw::Time _tlmTime = Fw::Time()
2350  );
2351 
2355  void tlmWrite_SeqPath(
2356  const Fw::StringBase& arg,
2357  Fw::Time _tlmTime = Fw::Time()
2358  );
2359 
2364  bool arg,
2365  Fw::Time _tlmTime = Fw::Time()
2366  );
2367 
2372  bool arg,
2373  Fw::Time _tlmTime = Fw::Time()
2374  );
2375 
2380  U8 arg,
2381  Fw::Time _tlmTime = Fw::Time()
2382  );
2383 
2388  U32 arg,
2389  Fw::Time _tlmTime = Fw::Time()
2390  );
2391 
2396  FwOpcodeType arg,
2397  Fw::Time _tlmTime = Fw::Time()
2398  );
2399 
2405  Fw::Time _tlmTime = Fw::Time()
2406  );
2407 
2412  bool arg,
2413  Fw::Time _tlmTime = Fw::Time()
2414  );
2415 
2421  U32 arg,
2422  Fw::Time _tlmTime = Fw::Time()
2423  );
2424 
2429  bool arg,
2430  Fw::Time _tlmTime = Fw::Time()
2431  );
2432 
2439  bool arg,
2440  Fw::Time _tlmTime = Fw::Time()
2441  );
2442 
2447  F32 arg,
2448  Fw::Time _tlmTime = Fw::Time()
2449  );
2450 
2451  protected:
2452 
2453  // ----------------------------------------------------------------------
2454  // Parameter hook functions
2455  // ----------------------------------------------------------------------
2456 
2460  virtual void parameterUpdated(
2461  FwPrmIdType id
2462  );
2463 
2467  virtual void parametersLoaded();
2468 
2469  protected:
2470 
2471  // ----------------------------------------------------------------------
2472  // Parameter get functions
2473  // ----------------------------------------------------------------------
2474 
2484  Fw::ParamValid& valid
2485  );
2486 
2487  protected:
2488 
2489  // ----------------------------------------------------------------------
2490  // Time
2491  // ----------------------------------------------------------------------
2492 
2496  Fw::Time getTime() const;
2497 
2498  private:
2499 
2500  // ----------------------------------------------------------------------
2501  // Message dispatch functions
2502  // ----------------------------------------------------------------------
2503 
2505  virtual MsgDispatchStatus doDispatch();
2506 
2507  private:
2508 
2509  // ----------------------------------------------------------------------
2510  // Calls for messages received on special input ports
2511  // ----------------------------------------------------------------------
2512 
2514  static void m_p_cmdIn_in(
2515  Fw::PassiveComponentBase* callComp,
2516  FwIndexType portNum,
2517  FwOpcodeType opCode,
2518  U32 cmdSeq,
2519  Fw::CmdArgBuffer& args
2520  );
2521 
2522  private:
2523 
2524  // ----------------------------------------------------------------------
2525  // Calls for messages received on typed input ports
2526  // ----------------------------------------------------------------------
2527 
2529  static void m_p_checkTimers_in(
2530  Fw::PassiveComponentBase* callComp,
2531  FwIndexType portNum,
2532  U32 context
2533  );
2534 
2536  static void m_p_cmdResponseIn_in(
2537  Fw::PassiveComponentBase* callComp,
2538  FwIndexType portNum,
2539  FwOpcodeType opCode,
2540  U32 cmdSeq,
2541  const Fw::CmdResponse& response
2542  );
2543 
2545  static void m_p_pingIn_in(
2546  Fw::PassiveComponentBase* callComp,
2547  FwIndexType portNum,
2548  U32 key
2549  );
2550 
2552  static void m_p_seqRunIn_in(
2553  Fw::PassiveComponentBase* callComp,
2554  FwIndexType portNum,
2555  const Fw::StringBase& filename
2556  );
2557 
2559  static void m_p_tlmWrite_in(
2560  Fw::PassiveComponentBase* callComp,
2561  FwIndexType portNum,
2562  U32 context
2563  );
2564 
2565  private:
2566 
2567  // ----------------------------------------------------------------------
2568  // Invocation functions for special output ports
2569  // ----------------------------------------------------------------------
2570 
2572  void cmdRegOut_out(
2573  FwIndexType portNum,
2574  FwOpcodeType opCode
2575  ) const;
2576 
2578  void cmdResponseOut_out(
2579  FwIndexType portNum,
2580  FwOpcodeType opCode,
2581  U32 cmdSeq,
2582  const Fw::CmdResponse& response
2583  ) const;
2584 
2586  void logOut_out(
2587  FwIndexType portNum,
2588  FwEventIdType id,
2589  Fw::Time& timeTag,
2590  const Fw::LogSeverity& severity,
2591  Fw::LogBuffer& args
2592  ) const;
2593 
2594 #if FW_ENABLE_TEXT_LOGGING
2595 
2597  void logTextOut_out(
2598  FwIndexType portNum,
2599  FwEventIdType id,
2600  Fw::Time& timeTag,
2601  const Fw::LogSeverity& severity,
2602  Fw::TextLogString& text
2603  ) const;
2604 
2605 #endif
2606 
2608  Fw::ParamValid prmGet_out(
2609  FwIndexType portNum,
2610  FwPrmIdType id,
2611  Fw::ParamBuffer& val
2612  ) const;
2614 
2616  void prmSet_out(
2617  FwIndexType portNum,
2618  FwPrmIdType id,
2619  Fw::ParamBuffer& val
2620  ) const;
2621 
2623  void timeCaller_out(
2624  FwIndexType portNum,
2625  Fw::Time& time
2626  ) const;
2627 
2629  void tlmOut_out(
2630  FwIndexType portNum,
2631  FwChanIdType id,
2632  Fw::Time& timeTag,
2633  Fw::TlmBuffer& val
2634  ) const;
2635 
2636  private:
2637 
2638  // ----------------------------------------------------------------------
2639  // Send signal helper functions
2640  // ----------------------------------------------------------------------
2641 
2643  void sendSignalStart(
2644  SmId smId,
2645  FwEnumStoreType signal,
2646  Fw::SerialBufferBase& buffer
2647  );
2648 
2650  void sequencer_sendSignalFinish(
2651  Fw::LinearBufferBase& buffer
2652  );
2653 
2654  private:
2655 
2656  // ----------------------------------------------------------------------
2657  // Helper functions for state machine dispatch
2658  // ----------------------------------------------------------------------
2659 
2661  void smDispatch(
2662  Fw::SerialBufferBase& buffer
2663  );
2664 
2666  static void deserializeSmIdAndSignal(
2667  Fw::SerialBufferBase& buffer,
2668  FwEnumStoreType& smId,
2669  FwEnumStoreType& signal
2670  );
2671 
2673  void Svc_FpySequencer_SequencerStateMachine_smDispatch(
2674  Fw::SerialBufferBase& buffer,
2675  Svc_FpySequencer_SequencerStateMachine& sm,
2677  );
2678 
2679  private:
2680 
2681  // ----------------------------------------------------------------------
2682  // Parameter set functions
2683  // ----------------------------------------------------------------------
2684 
2688  Fw::CmdResponse paramSet_STATEMENT_TIMEOUT_SECS(
2689  Fw::SerialBufferBase& val
2690  );
2691 
2692  private:
2693 
2694  // ----------------------------------------------------------------------
2695  // Parameter save functions
2696  // ----------------------------------------------------------------------
2697 
2701  Fw::CmdResponse paramSave_STATEMENT_TIMEOUT_SECS();
2702 
2703 #if !FW_DIRECT_PORT_CALLS
2704 
2705  private:
2706 
2707  // ----------------------------------------------------------------------
2708  // Special input ports
2709  // ----------------------------------------------------------------------
2710 
2712  Fw::InputCmdPort m_cmdIn_InputPort[NUM_CMDIN_INPUT_PORTS];
2713 
2714 #endif
2715 
2716 #if !FW_DIRECT_PORT_CALLS
2717 
2718  private:
2719 
2720  // ----------------------------------------------------------------------
2721  // Typed input ports
2722  // ----------------------------------------------------------------------
2723 
2725  Svc::InputSchedPort m_checkTimers_InputPort[NUM_CHECKTIMERS_INPUT_PORTS];
2726 
2728  Fw::InputCmdResponsePort m_cmdResponseIn_InputPort[NUM_CMDRESPONSEIN_INPUT_PORTS];
2729 
2731  Svc::InputPingPort m_pingIn_InputPort[NUM_PINGIN_INPUT_PORTS];
2732 
2734  Svc::InputCmdSeqInPort m_seqRunIn_InputPort[NUM_SEQRUNIN_INPUT_PORTS];
2735 
2737  Svc::InputSchedPort m_tlmWrite_InputPort[NUM_TLMWRITE_INPUT_PORTS];
2738 
2739 #endif
2740 
2741 #if !FW_DIRECT_PORT_CALLS
2742 
2743  private:
2744 
2745  // ----------------------------------------------------------------------
2746  // Special output ports
2747  // ----------------------------------------------------------------------
2748 
2750  Fw::OutputCmdRegPort m_cmdRegOut_OutputPort[NUM_CMDREGOUT_OUTPUT_PORTS];
2751 
2753  Fw::OutputCmdResponsePort m_cmdResponseOut_OutputPort[NUM_CMDRESPONSEOUT_OUTPUT_PORTS];
2754 
2756  Fw::OutputLogPort m_logOut_OutputPort[NUM_LOGOUT_OUTPUT_PORTS];
2757 
2758 #if FW_ENABLE_TEXT_LOGGING == 1
2759 
2761  Fw::OutputLogTextPort m_logTextOut_OutputPort[NUM_LOGTEXTOUT_OUTPUT_PORTS];
2762 
2763 #endif
2764 
2766  Fw::OutputPrmGetPort m_prmGet_OutputPort[NUM_PRMGET_OUTPUT_PORTS];
2767 
2769  Fw::OutputPrmSetPort m_prmSet_OutputPort[NUM_PRMSET_OUTPUT_PORTS];
2770 
2772  Fw::OutputTimePort m_timeCaller_OutputPort[NUM_TIMECALLER_OUTPUT_PORTS];
2773 
2775  Fw::OutputTlmPort m_tlmOut_OutputPort[NUM_TLMOUT_OUTPUT_PORTS];
2776 
2777 #endif
2778 
2779 #if !FW_DIRECT_PORT_CALLS
2780 
2781  private:
2782 
2783  // ----------------------------------------------------------------------
2784  // Typed output ports
2785  // ----------------------------------------------------------------------
2786 
2788  Fw::OutputComPort m_cmdOut_OutputPort[NUM_CMDOUT_OUTPUT_PORTS];
2789 
2791  Fw::OutputPrmGetPort m_getParam_OutputPort[NUM_GETPARAM_OUTPUT_PORTS];
2792 
2794  Fw::OutputTlmGetPort m_getTlmChan_OutputPort[NUM_GETTLMCHAN_OUTPUT_PORTS];
2795 
2797  Svc::OutputPingPort m_pingOut_OutputPort[NUM_PINGOUT_OUTPUT_PORTS];
2798 
2800  Fw::OutputCmdResponsePort m_seqDoneOut_OutputPort[NUM_SEQDONEOUT_OUTPUT_PORTS];
2801 
2803  Svc::OutputCmdSeqInPort m_seqStartOut_OutputPort[NUM_SEQSTARTOUT_OUTPUT_PORTS];
2804 
2805 #endif
2806 
2807  private:
2808 
2809  // ----------------------------------------------------------------------
2810  // First update flags for telemetry channels
2811  // ----------------------------------------------------------------------
2812 
2814  bool m_first_update_State = true;
2815 
2817  bool m_first_update_SequencesSucceeded = true;
2818 
2820  bool m_first_update_SequencesFailed = true;
2821 
2823  bool m_first_update_SequencesCancelled = true;
2824 
2826  bool m_first_update_StatementsDispatched = true;
2827 
2829  bool m_first_update_StatementsFailed = true;
2830 
2832  bool m_first_update_LastDirectiveError = true;
2833 
2835  bool m_first_update_DirectiveErrorIndex = true;
2836 
2838  bool m_first_update_DirectiveErrorId = true;
2839 
2841  bool m_first_update_SeqPath = true;
2842 
2844  bool m_first_update_Debug_ReachedEndOfFile = true;
2845 
2847  bool m_first_update_Debug_NextStatementReadSuccess = true;
2848 
2850  bool m_first_update_Debug_NextStatementOpcode = true;
2851 
2853  bool m_first_update_Debug_NextStatementIndex = true;
2854 
2856  bool m_first_update_Debug_NextCmdOpcode = true;
2857 
2859  bool m_first_update_Debug_StackSize = true;
2860 
2862  bool m_first_update_BreakpointInUse = true;
2863 
2865  bool m_first_update_BreakpointIndex = true;
2866 
2868  bool m_first_update_BreakOnlyOnceOnBreakpoint = true;
2869 
2871  bool m_first_update_BreakBeforeNextLine = true;
2872 
2874  bool m_first_update_PRM_STATEMENT_TIMEOUT_SECS = true;
2875 
2876  private:
2877 
2878  // ----------------------------------------------------------------------
2879  // Last value storage for telemetry channels
2880  // ----------------------------------------------------------------------
2881 
2883  FwEnumStoreType m_last_State = {};
2884 
2886  U64 m_last_SequencesSucceeded = {};
2887 
2889  U64 m_last_SequencesFailed = {};
2890 
2892  U64 m_last_SequencesCancelled = {};
2893 
2895  U64 m_last_StatementsDispatched = {};
2896 
2898  U64 m_last_StatementsFailed = {};
2899 
2901  Svc::Fpy::DirectiveErrorCode m_last_LastDirectiveError = {};
2902 
2904  U64 m_last_DirectiveErrorIndex = {};
2905 
2907  Svc::Fpy::DirectiveId m_last_DirectiveErrorId = {};
2908 
2910  Fw::TlmString m_last_SeqPath = {};
2911 
2913  bool m_last_Debug_ReachedEndOfFile = {};
2914 
2916  bool m_last_Debug_NextStatementReadSuccess = {};
2917 
2919  U8 m_last_Debug_NextStatementOpcode = {};
2920 
2922  U32 m_last_Debug_NextStatementIndex = {};
2923 
2925  FwOpcodeType m_last_Debug_NextCmdOpcode = {};
2926 
2928  Svc::Fpy::StackSizeType m_last_Debug_StackSize = {};
2929 
2931  bool m_last_BreakpointInUse = {};
2932 
2934  U32 m_last_BreakpointIndex = {};
2935 
2937  bool m_last_BreakOnlyOnceOnBreakpoint = {};
2938 
2940  bool m_last_BreakBeforeNextLine = {};
2941 
2943  F32 m_last_PRM_STATEMENT_TIMEOUT_SECS = {};
2944 
2945  private:
2946 
2947  // ----------------------------------------------------------------------
2948  // Parameter validity flags
2949  // ----------------------------------------------------------------------
2950 
2952  Fw::ParamValid m_param_STATEMENT_TIMEOUT_SECS_valid;
2953 
2954  private:
2955 
2956  // ----------------------------------------------------------------------
2957  // Parameter variables
2958  // ----------------------------------------------------------------------
2959 
2966  F32 m_STATEMENT_TIMEOUT_SECS;
2967 
2968  private:
2969 
2970  // ----------------------------------------------------------------------
2971  // State machine instances
2972  // ----------------------------------------------------------------------
2973 
2975  Svc_FpySequencer_SequencerStateMachine m_stateMachine_sequencer;
2976 
2977  private:
2978 
2979  // ----------------------------------------------------------------------
2980  // Mutexes
2981  // ----------------------------------------------------------------------
2982 
2984  Os::Mutex m_paramLock;
2985 
2986  };
2987 
2988 }
2989 
2990 #endif
void cmdOut_out(FwIndexType portNum, Fw::ComBuffer &data, U32 context) const
Invoke output port cmdOut.
void pingOut_out(FwIndexType portNum, U32 key) const
Invoke output port pingOut.
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.
virtual void directive_waitRel_internalInterfaceHandler(const Svc::FpySequencer_WaitRelDirective &directive)=0
Internal interface handler for directive_waitRel.
virtual void DUMP_STACK_TO_FILE_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command DUMP_STACK_TO_FILE.
virtual void Svc_FpySequencer_SequencerStateMachine_action_checkStatementTimeout(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
virtual void Svc_FpySequencer_SequencerStateMachine_action_incrementSequenceCounter(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
virtual void Svc_FpySequencer_SequencerStateMachine_action_report_seqFailed(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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.
virtual void directive_peek_internalInterfaceHandler(const Svc::FpySequencer_PeekDirective &directive)=0
Internal interface handler for directive_peek.
virtual void Svc_FpySequencer_SequencerStateMachine_action_setSequenceFilePath(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal, const Svc::FpySequencer_SequenceExecutionArgs &value)=0
virtual void Svc_FpySequencer_SequencerStateMachine_action_signalEntered(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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)
FwIdType FwOpcodeType
The type of a command opcode.
void set_cmdOut_OutputPort(FwIndexType portNum, Fw::InputComPort *port)
Connect port to cmdOut[portNum].
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.
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 ...
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.
void sequencer_sendSignal_result_dispatchStatement_success()
Send signal result_dispatchStatement_success 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 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 directive_pushTlmVal_internalInterfaceInvoke(const Svc::FpySequencer_PushTlmValDirective &directive)
Internal interface base-class function for directive_pushTlmVal.
virtual void CLEAR_BREAKPOINT_cmdHandler(FwOpcodeType opCode, U32 cmdSeq)=0
virtual void parameterUpdated(FwPrmIdType id)
Called whenever a parameter is updated.
virtual void directive_stackCmd_internalInterfaceHandler(const Svc::FpySequencer_StackCmdDirective &directive)=0
Internal interface handler for directive_stackCmd.
void sequencer_sendSignal_cmd_SET_BREAKPOINT(const Svc::FpySequencer_BreakpointArgs &value)
Send signal cmd_SET_BREAKPOINT to state machine sequencer.
virtual void Svc_FpySequencer_SequencerStateMachine_action_sendCmdResponse_OK(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
virtual void tlmWrite_preMsgHook(FwIndexType portNum, U32 context)
Pre-message hook for async input port tlmWrite.
virtual void CLEAR_BREAKPOINT_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CLEAR_BREAKPOINT.
static constexpr FwIndexType getNum_cmdIn_InputPorts()
void tlmWrite_Debug_ReachedEndOfFile(bool arg, Fw::Time _tlmTime=Fw::Time())
void seqStartOut_out(FwIndexType portNum, const Fw::StringBase &filename) const
Invoke output port seqStartOut.
void log_WARNING_HI_SequenceExitedWithError(const Fw::StringBase &filePath, U8 errorCode) const
Log event SequenceExitedWithError.
void RUN_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
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].
virtual void Svc_FpySequencer_SequencerStateMachine_action_setGoalState_IDLE(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
stores a value to a local variable at a compile-time-known offset relative to the current stack frame...
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 STEP_cmdHandlerBase(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdArgBuffer &args)
virtual bool Svc_FpySequencer_SequencerStateMachine_guard_breakOnce(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal) const =0
static constexpr FwIndexType getNum_pingIn_InputPorts()
virtual void Svc_FpySequencer_SequencerStateMachine_action_report_seqStarted(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
bool isConnected_prmGet_OutputPort(FwIndexType portNum) const
pop an opcode and arg buf off the stack, send to cmd dispatcher and await response ...
void sequencer_sendSignal_result_checkShouldWake_wakeup()
Send signal result_checkShouldWake_wakeup to state machine sequencer.
friend class FpySequencerTesterBase
Friend class tester to support autocoded test harness.
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
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.
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 ~FpySequencerComponentBase()
Destroy FpySequencerComponentBase object.
void log_WARNING_LO_CmdResponseWhileNotRunningSequence(I32 state, FwOpcodeType opcode, Fw::CmdResponse response) const
Log event CmdResponseWhileNotRunningSequence.
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.
static constexpr FwIndexType getNum_tlmWrite_InputPorts()
Enum representing a command response.
virtual void Svc_FpySequencer_SequencerStateMachine_action_validate(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
virtual void RUN_VALIDATED_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command RUN_VALIDATED.
void log_WARNING_HI_FileReadError(Svc::FpySequencer_FileReadStage readStage, const Fw::StringBase &filePath, I32 errorCode) const
Log event FileReadError.
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
void tlmWrite_State(FwEnumStoreType arg, Fw::Time _tlmTime=Fw::Time())
void tlmWrite_SequencesSucceeded(U64 arg, Fw::Time _tlmTime=Fw::Time())
void log_WARNING_HI_ExtraBytesInSequence(FwSizeType remaining) const
Log event ExtraBytesInSequence.
virtual void Svc_FpySequencer_SequencerStateMachine_action_clearSequenceFile(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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()
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.
virtual void RUN_VALIDATED_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, Svc::FpySequencer_BlockState block)=0
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
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.
virtual void RUN_cmdHandler(FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdStringArg &fileName, Svc::FpySequencer_BlockState block)=0
void sequencer_sendSignal_cmd_BREAK()
Send signal cmd_BREAK to state machine sequencer.
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)
virtual void STEP_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command STEP.
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()
Svc_FpySequencer_SequencerStateMachine::State sequencer_getState() const
Get the state of state machine instance sequencer.
void set_getTlmChan_OutputPort(FwIndexType portNum, Fw::InputTlmGetPort *port)
Connect port to getTlmChan[portNum].
float F32
32-bit floating point
Definition: BasicTypes.h:83
virtual bool Svc_FpySequencer_SequencerStateMachine_guard_shouldBreak(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal) const =0
virtual void checkTimers_handler(FwIndexType portNum, U32 context)=0
Handler for input port checkTimers.
static constexpr FwIndexType getNum_getParam_OutputPorts()
static constexpr FwIndexType getNum_cmdRegOut_OutputPorts()
void log_WARNING_HI_WrongCmdResponseOpcode(FwOpcodeType opcode, Fw::CmdResponse response, FwOpcodeType expectedOpcode) const
Log event WrongCmdResponseOpcode.
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 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 directive_loadAbs_internalInterfaceInvoke(const Svc::FpySequencer_LoadAbsDirective &directive)
Internal interface base-class function for directive_loadAbs.
F32 paramGet_STATEMENT_TIMEOUT_SECS(Fw::ParamValid &valid)
pop two byte arrays off the top of the stack, call memcmp, push 1 if they were equal, 0 otherwise
void cmdResponse_out(FwOpcodeType opCode, U32 cmdSeq, Fw::CmdResponse response)
Emit command response.
void directive_memCmp_internalInterfaceInvoke(const Svc::FpySequencer_MemCmpDirective &directive)
Internal interface base-class function for directive_memCmp.
pops a severity and message from the stack and emits an F Prime event
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.
Must be called after VALIDATE. Runs the sequence that was validated.
virtual void directive_constCmd_internalInterfaceHandler(const Svc::FpySequencer_ConstCmdDirective &directive)=0
Internal interface handler for directive_constCmd.
Fw::InputCmdPort * get_cmdIn_InputPort(FwIndexType portNum)
bool isConnected_cmdResponseOut_OutputPort(FwIndexType portNum) const
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].
friend class FpySequencerTester
Test implementation for the enclosing component.
virtual void Svc_FpySequencer_SequencerStateMachine_action_dispatchStatement(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
virtual void directive_pushVal_internalInterfaceHandler(const Svc::FpySequencer_PushValDirective &directive)=0
Internal interface handler for directive_pushVal.
void sequencer_sendSignal_cmd_RUN_VALIDATED(const Svc::FpySequencer_SequenceExecutionArgs &value)
Send signal cmd_RUN_VALIDATED to state machine sequencer.
virtual void Svc_FpySequencer_SequencerStateMachine_action_clearBreakpoint(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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_EndOfFileError(Svc::FpySequencer_FileReadStage readStage, const Fw::StringBase &filePath) const
Log event EndOfFileError.
void set_cmdResponseOut_OutputPort(FwIndexType portNum, Fw::InputCmdResponsePort *port)
Connect port to cmdResponseOut[portNum].
void log_WARNING_LO_CmdResponseFromOldSequence(FwOpcodeType opcode, Fw::CmdResponse response, U16 oldSequenceIdx, U16 currentSequenceIdx) const
Log event CmdResponseFromOldSequence.
FpySequencerComponentBase(const char *compName="")
Construct FpySequencerComponentBase object.
virtual void directive_call_internalInterfaceHandler(const Svc::FpySequencer_CallDirective &directive)=0
Internal interface handler for directive_call.
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 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.
static constexpr FwIndexType getNum_prmSet_OutputPorts()
virtual void seqRunIn_preMsgHook(FwIndexType portNum, const Fw::StringBase &filename)
Pre-message hook for async input port seqRunIn.
void log_WARNING_HI_LogWarningHi(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogWarningHi.
Implementation of state machine Svc_FpySequencer_SequencerStateMachine.
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.
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 log_WARNING_HI_CommandFailed(FwOpcodeType opCode, U32 stmtIdx, const Fw::StringBase &filePath, Fw::CmdResponse response) const
Log event CommandFailed.
void sequencer_sendSignal_stmtResponse_beginSleep()
Send signal stmtResponse_beginSleep to state machine sequencer.
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.
Writes the contents of the stack to a file. This command is only valid in the RUNNING.PAUSED state.
void loadParameters()
Load the parameters from a parameter source.
virtual void Svc_FpySequencer_SequencerStateMachine_action_sendCmdResponse_EXECUTION_ERROR(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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.
void directive_getField_internalInterfaceInvoke(const Svc::FpySequencer_GetFieldDirective &directive)
Internal interface base-class function for directive_getField.
static constexpr FwIndexType getNum_cmdOut_OutputPorts()
virtual void Svc_FpySequencer_SequencerStateMachine_action_setGoalState_VALID(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
sleeps for a relative duration from the current time
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:53
virtual void directive_noOp_internalInterfaceHandler(const Svc::FpySequencer_NoOpDirective &directive)=0
Internal interface handler for directive_noOp.
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].
virtual void Svc_FpySequencer_SequencerStateMachine_action_setSequenceBlockState(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal, const Svc::FpySequencer_SequenceExecutionArgs &value)=0
virtual void seqRunIn_handler(FwIndexType portNum, const Fw::StringBase &filename)=0
Handler for input port seqRunIn.
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 sequencer_sendSignal_stmtResponse_keepWaiting()
Send signal stmtResponse_keepWaiting to state machine sequencer.
bool isConnected_tlmOut_OutputPort(FwIndexType portNum) const
virtual void Svc_FpySequencer_SequencerStateMachine_action_resetRuntime(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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.
static constexpr FwIndexType getNum_getTlmChan_OutputPorts()
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.
bool isConnected_timeCaller_OutputPort(FwIndexType portNum) const
void tlmWrite_SequencesFailed(U64 arg, Fw::Time _tlmTime=Fw::Time())
void log_WARNING_HI_FileReadDeserializeError(Svc::FpySequencer_FileReadStage readStage, const Fw::StringBase &filePath, I32 errorCode, U64 buffLeft, U64 buffLength) const
Log event FileReadDeserializeError.
loads a value from an absolute address in the stack (for global variables)
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()
bool isConnected_pingOut_OutputPort(FwIndexType portNum) const
void log_WARNING_HI_MismatchedTimeContext(I32 internalTimeContext, I32 otherTimeContext) const
Log event MismatchedTimeContext.
virtual void Svc_FpySequencer_SequencerStateMachine_action_clearBreakBeforeNextLine(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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 log_WARNING_HI_WrongSchemaVersion(U8 expected, U8 actual) const
Log event WrongSchemaVersion.
virtual void Svc_FpySequencer_SequencerStateMachine_action_report_seqBroken(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
virtual void Svc_FpySequencer_SequencerStateMachine_action_setBreakBeforeNextLine(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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.
Svc::FpySequencer_SequencerStateMachine_State State
The state type.
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
stores a value to a local variable at a runtime-determined offset relative to the current stack frame...
virtual void directive_return_internalInterfaceHandler(const Svc::FpySequencer_ReturnDirective &directive)=0
Internal interface handler for directive_return.
virtual void Svc_FpySequencer_SequencerStateMachine_action_report_seqSucceeded(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
virtual void BREAK_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command BREAK.
void tlmWrite_DirectiveErrorIndex(U64 arg, Fw::Time _tlmTime=Fw::Time())
RateGroupDivider component implementation.
void log_WARNING_HI_CmdResponseWhileNotAwaiting(FwOpcodeType opcode, Fw::CmdResponse response) const
Log event CmdResponseWhileNotAwaiting.
virtual void Svc_FpySequencer_SequencerStateMachine_action_setGoalState_RUNNING(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
void log_WARNING_HI_CmdResponseWhileAwaitingDirective(FwOpcodeType opcode, Fw::CmdResponse response, U8 expectedDirectiveOpcode) const
Log event CmdResponseWhileAwaitingDirective.
virtual void cmdResponseIn_preMsgHook(FwIndexType portNum, FwOpcodeType opCode, U32 cmdSeq, const Fw::CmdResponse &response)
Pre-message hook for async input port cmdResponseIn.
void seqRunIn_handlerBase(FwIndexType portNum, const Fw::StringBase &filename)
Handler base-class function for input port seqRunIn.
Enum representing parameter validity.
virtual void directive_popEvent_internalInterfaceHandler(const Svc::FpySequencer_PopEventDirective &directive)=0
Internal interface handler for directive_popEvent.
virtual void Svc_FpySequencer_SequencerStateMachine_action_setBreakpoint(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal, const Svc::FpySequencer_BreakpointArgs &value)=0
Loads, validates and runs a sequence.
void log_FATAL_LogFatal(const Fw::StringBase &filePath, const Fw::StringBase &message) const
Log event LogFatal.
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)
friend class FpySequencerTester
Friend class tester implementation to support white-box testing.
void log_WARNING_HI_MismatchedTimeBase(I32 internalTimeBase, I32 otherTimeBase) const
Log event MismatchedTimeBase.
void sequencer_sendSignal_result_failure()
Send signal result_failure to state machine sequencer.
bool isConnected_seqStartOut_OutputPort(FwIndexType portNum) const
virtual void CONTINUE_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CONTINUE.
virtual void checkTimers_preMsgHook(FwIndexType portNum, U32 context)
Pre-message hook for async input port checkTimers.
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.
virtual void Svc_FpySequencer_SequencerStateMachine_action_checkShouldWake(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
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.
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.
virtual void directive_pushTlmVal_internalInterfaceHandler(const Svc::FpySequencer_PushTlmValDirective &directive)=0
Internal interface handler for directive_pushTlmVal.
virtual bool Svc_FpySequencer_SequencerStateMachine_guard_goalStateIs_RUNNING(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal) const =0
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.
void checkTimers_handlerBase(FwIndexType portNum, U32 context)
Handler base-class function for input port checkTimers.
static constexpr FwIndexType getNum_prmGet_OutputPorts()
virtual void CANCEL_preMsgHook(FwOpcodeType opCode, U32 cmdSeq)
Pre-message hook for command CANCEL.
void tlmWrite_BreakOnlyOnceOnBreakpoint(bool arg, Fw::Time _tlmTime=Fw::Time())
void log_WARNING_HI_WrongCmdResponseIndex(FwOpcodeType opcode, Fw::CmdResponse response, U16 actualCmdIdx, U16 expectedCmdIdx) const
Log event WrongCmdResponseIndex.
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.
void tlmWrite_BreakpointInUse(bool arg, Fw::Time _tlmTime=Fw::Time())
virtual void Svc_FpySequencer_SequencerStateMachine_action_report_seqCancelled(SmId smId, Svc_FpySequencer_SequencerStateMachine::Signal signal)=0
bool isConnected_seqDoneOut_OutputPort(FwIndexType portNum) const
friend class FpySequencerTesterBase
Autocoded test harness for the enclosing component.
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)
U32 StackSizeType
the type which everything referencing a size or offset on the stack is represented in ...
void tlmWrite_BreakpointIndex(U32 arg, Fw::Time _tlmTime=Fw::Time())
#define U64(C)
Definition: sha.h:181
void tlmWrite_Debug_NextStatementReadSuccess(bool arg, Fw::Time _tlmTime=Fw::Time())