Author Topic: C++ generated code for executable STM  (Read 1666 times)

YannM

  • EA User
  • **
  • Posts: 22
  • Karma: +0/-0
    • View Profile
C++ generated code for executable STM
« on: April 02, 2021, 02:59:42 am »
Hi all,

I'm currently successfully generating C++ code for a state machine designed in EA 15.2.
However this state machine so far steps from state to state without doing much.

I would like that each state calls a function defined in an interface.

So far I designed in EA:

[Class A] --Dependency--> [Class B : realizing the interface] --Realization--> Interface

with Class A calling function from the class B, and class A being the parent of the state machine diagram.

Automatic generation fails when compiling because classB is not instanciated.

I must explicitly instantiate manually the object in class A in order to make it work. What is not the aim of the experiment, where I want to generate, compile, and simulate the generated code without manual intervention.

Any idea if this can be achieved and how shall I declare the different objects to make it work ?

Thanks a lot for your time reading this point.