code generation,
fee tool,
modeling,
QM,
State Machine,
uml
|
7 replies
The qm_pelican example demonstrates automatic code generation from a graphical model of the software. The example contains code that is 100% generated by the free QM graphical modeling tool.
The screen shot below shows a view of the PELICAN crossing model opened in the QM tool (click on the picture to see higher resolution).
The QM tool is available for a free download, without the need for registration or relinquishing any personal information from state-machine.com/downloads. Please select the download for your platform (Windows, Linux, and Mac OS X are supported). The installation on any platform is trivial and does not require any DLLs, sharable libraries or any other third party software (no Java, Eclipse, etc.). The provided setup installs the QM application, creates a desktop icon, and associates the QM model files (*.qm) with the QM application. QM is very easy to uninstall with the provided uninstaller.
Please right-click on the link below and and select "Save link as..." option to save the pelican.qm model file to your computer.
To view the model, assuming that you have installed the QM tool, you can just double-click on the pelican.qm model file, or you can launch the QM tool first and then open the model from the File|Open menu command. Please note that the QM user interface is highly customizable, so your screen might look a little differently than the screen shot above. But you can always re-arrange the docking windows to suit best your particular taste and the tool will remember your layout for the future.
Code generation is literally accomplished by pressing a single button (the "Code Generation" button, 4th from the left in the screen shot above). Once you press the button, the QM tool will show the model compilation log. This particular model is setup to generate the code in the same directory as the pelican.qm model file.
Once the code is generated, you simply import the code as a program to the mbed compiler. The code should compile cleanly. You execute the synthesized program just as any hand-crafted mbed program.
Please visit state-machine.com/qm for more information.
Please login to post comments.
mbed compiler produces error
"Cannot open source input file "qp_port.h": No such file or directory
In every qp, related project I imported.
The same with code (7 files but missing qp_port.h) for Pelican project I created form QM as described above
Please advise.
SOLVED, Have to import qm library to all qm projects. It is not mentioned above..
Nikos Chalikias