Running External Process Simulation

If you have a Default object created under the SimControl.XProc class, the external process simulation described in this section is available to you. Otherwise, please consult the Running In-Process Simulation section for how to execute your simulator. One of the advantages in using external process simulation is that it is script-driven, i.e., the simulator is invoked via a text script file. In Microsoft Windows(tm) environment, it is a batch command file with a .BAT extension. You can customize it as needed.

Running Simulation

To execute an external process simulator, click on the Run External button (with an icon similar to the eject button on a CD/DVD player) in the Run toolbar. If the simulator cannot be found, an error message will be displayed to show the name and the expected path of the simulator executable. If you put the simulator in a different path, you can enter it in the Simulator Program Path field in the Default simulation control object. If you leave the field blank (as default), SansGUI will try to locate the executable in the sim subdirectory under the SansGUI installation directory.

The invocation script is, by default, the SGxProc.bat file (Windows) in the bin subdirectory under the SansGUI installation directory. You can enter a different location for your customized script.

When you click on the Run External button, a model file containing all the necessary input data in a plain ASCII format will be created in the current working directory; the same as your Project Model file. The file name will be whatever your Project Model file name with a .txt extension for the Tabular Data Blocks format and a .xml extension for the XML Model Data format. You can change the Model File Name and the Working Directory via the Object Properties dialog of the Default simulation control object.

The Model File Type is simulator dependent. The optional Command Parameters are also simulator dependent. Please consult your simulator's documentation for details.

After clicking on the Run External button, the trace of the simulation run will be shown in the Operation View in the bottom pane and a separate command window will be opened for the simulator to output messages.

Stopping Simulation

Normally, closing or pressing Ctrl+C in the command window will stop the external simulator. This behavior, however, may be modified by the simulator. Please consult your simulator's documentation for how to terminate the simulation. When the simulator ends normally, you may need to press the Enter key to finish the simulation and close the command window before submitting the same Project Model to the simulator again.

Customizing Invocation Script

The invocation script SGxProc.bat, distributed and installed with SansGUI, is the default command file used to start external simulators. Under normal circumstances, you do not have to modify the script. If you really need to make custom changes, please do not alter the original script file. Instead, do:

Details of the invocation script is documented directly in the script file and in the SansGUI Simulation Control section of the Reference Manual.


C:\FH_Suite\htmlgifs\home.gif Running In-Process Simulation Plotting Simulation Results

SansGUI Modeling and Simulation Environment Version 1.2

Copyright 2000-2003 ProtoDesign, Inc. All rights reserved.