Getting started with SysML v2#
-
Start by installing a SysML v2 aware editor, e.g. Visual Studio Code with the Syside Editor plugin. Download the codegen and unpack the zip file.
-
Use the traffic light project available from our GitHub page. Make sure you have a recent Java Runtime Environment (17 or newer), compiler, and make tool. Then build the example by calling
make(don’t forget to export the path variableCODEGEN_PATHto reflect your codegen installation folder). Example:export CODEGEN_PATH=/home/myusername/develop/sinelaboreRT7.1/bin/ -
Modify the SysML code or create your own example. Start with something small. Identify the elements like parts, ports, events and states of your model. Integrate the state machine. Then use a small C++ main function to run the generated system code.
-
Grow the model incrementally. Add one feature at a time (choices, junctions, regions), regenerate, and re-test to avoid hard-to-debug regressions.