Simulink UCGN Hello World

From UcgnWiki

Jump to: navigation, search
Line 7: Line 7:
The '''SimulinkUcgnDistribution''' contains a "Hello World" example, in the simulink/Examples/HelloWorld subfolder. You will find a simple Simulink model showing how to set up a design and then process it through the stages of model transformation and code-generation. The model is intended to show some of the basic concepts available.
The '''SimulinkUcgnDistribution''' contains a "Hello World" example, in the simulink/Examples/HelloWorld subfolder. You will find a simple Simulink model showing how to set up a design and then process it through the stages of model transformation and code-generation. The model is intended to show some of the basic concepts available.
-
The following files are part of the design
+
The following files are part of the design (located in ./simulink/Examples/HelloWorld)
-
* '''TST_HelloWorldModel.mdl''' - the simulink model
+
* '''TST_HelloWorldModel.mdl''' - the simulink model  
* '''GBL_Constants.m''' - showing how workspace parameters are used as "tunable parameters"
* '''GBL_Constants.m''' - showing how workspace parameters are used as "tunable parameters"
* '''FCS_FlightControlSystemDefinitions.m''' - showing how to work with bus objects
* '''FCS_FlightControlSystemDefinitions.m''' - showing how to work with bus objects
Line 19: Line 19:
* '''SimulinkUcgn.bat''' - batchfile to run model transformation and code generator
* '''SimulinkUcgn.bat''' - batchfile to run model transformation and code generator
 +
All files listed above are located in the ./simulink/Examples/HelloWorld folder.
== Prerequisites ==  
== Prerequisites ==  
Line 32: Line 33:
* Modify '''SlcGenExport_TST_HelloWorldModel.m''', to point to your <br />UcgnBasePath = '<your UCGN_SIMULINK_BASE>';
* Modify '''SlcGenExport_TST_HelloWorldModel.m''', to point to your <br />UcgnBasePath = '<your UCGN_SIMULINK_BASE>';
* Modify '''SlcProject.xml''', to point to UCGN_SIMULINK_BASE/work as the Working Directory <br /><workingDirectory><your UCGN_SIMULINK_BASE>\work</workingDirectory>
* Modify '''SlcProject.xml''', to point to UCGN_SIMULINK_BASE/work as the Working Directory <br /><workingDirectory><your UCGN_SIMULINK_BASE>\work</workingDirectory>
-
* Modify '''SimulinkUcgn.bat''', to point to your UCGN_SIMULINK_BASE<br />set UCGN_SIMULINK_BASE=<your UCGN_SIMULINK_BASE>
+
* Modify '''SimulinkUcgn.bat''', to point to your UCGN_SIMULINK_BASE<br />set UCGN_SIMULINK_BASE=<your UCGN_SIMULINK_BASE> (enclose in quotes if your path containes spaces!)

Revision as of 19:49, 30 June 2010

Personal tools