Mrz 052016

YAKINDU statechart tools are a pretty nice tool to model statemachines. You can generate code for C/C++ and Java out of the model. Further you can validate and simulate your statemachine to verify the behaviour. If you want to integrate your statemachine into a Qt application the concept of signals and slots fits perfectly into the in and out events of the statechart definition language of the YAKINDU SCT. My new custom Qt generator links both concepts together. It generates a C++ class which links between the C++ class generated from the C++ generator of YAKINDU SCT and the custom implementation code which must be implemented for custom behaviour of your application.

The generated code implements the following methods of the statemachines base class:

  1. Initialisation of all SCT operation callbacks (so called OCB).
  2. A pure virtual method initializeValues() for custom value initialisation.
  3. In events as Qt slots.
  4. Out events as Qt signals.
  5. Respects internal events with an extra runCycle() call.
  6. Optional implementation of the TimerInterface.
  7. Implementation of all SCT operations.

There is a detailed documentation at the SourceForge project site. There is also a small example Qt application to show how the generator works:



If you have a working YAKINDU SCT running you only need to add an update site to your Eclipse. You may choose between a snapshot build or the release build.

Have a lot of fun with the new generator and feel free to file bugs or add comments into the forum.