Getting Started with Sans GUI A Quick Sans
- Slides: 60
Getting Started with Sans. GUI® A Quick Sans. GUI Tutorial for Simulation Users and Developers Copyright © 2001 -2003 Proto. Design, Inc. All rights reserved.
What is Sans. GUI. . . n An Interactive Environment l for building models, entering parameters, running simulations, monitoring progress, and viewing results n A Software Framework l for developing and deploying simulation programs without tedious Graphical User Interface programming
Who are the users … Anyone who is involved in developing and using computer simulation in scientific and engineering fields. n Simulation Users l Use Sans. GUI Run-Time Environment n Simulation Developers l Use Sans. GUI Development Environment
Simulation Users Those who use building blocks to configure experimental models, perform simulation runs, study the effects from different sets of inputs in order to fine tune their designs. n Research Assistants n Project Engineers n Design Engineers n Data Analysts
Simulation Developers Those who study the underlying logic and mathematics of target systems to define model building blocks and implement computer algorithms for simulation. n Research Scientists n Research Engineers n Software Developers
Sans. GUI Architecture n Sans. GUI Development Environment l l l Define model building blocks in classes Specify attributes involved in simulation model Implement simulator logic and mathematics n Sans. GUI Run-Time Environment l l l Configure model and prepare input data Run simulation and monitor progress Analyze simulation results to refine design
Run-Time Features n Interactive Model Building Tools n Data Entry Assistance and Validation n User Extensible Unit Conversion n Model Data Version Synchronization n Interactive Simulation Control n Dynamic Charting & 3 D Animation n User Plug-In Routine Support
Development Features n Interactive Simulator Development n Class Schema Definition & Update n Programmable Data Validation n Unit Object Creation & Maintenance n Sans. GUI Source Code Framework n Interactive Tracing and Debugging n Open. GL® 3 D Graphics Programming
Using Sans. GUI®
Modeling and Simulation n Working with Sans. GUI l l l l System Abstraction - Entity / Relation Model Configuration Data Entry / GUI Control Types User Extensible Unit Conversion Simulation Run Controls Simulation Result Logging and Plotting Animated 3 D Graphics Controls
System Abstraction - E/R Entity Entity Entity A Model of the Target System denotes physical links with directionality; non-directional links are without arrows denotes referential links
Components and References n Component Objects l l Physical objects used to create parts Links are special components that connect parts to form network models n Reference Objects l l Informational objects referred to by other objects, parts or links Collection, Graphics, Matrix, Table, and more
Class Hierarchy n Object-Attribute-Value Class-A Diameter (mm) Length (mm) * see next slide Class-B Diameter (mm) Length (mm) Curvature (mm) Orientation Object-1 Diameter Length Curvature Orientation = 1. 2 in = 10. 5 in = 5. 0 in = “SE” Object-2 Diameter Length Curvature Orientation = 2. 0 in = 4. 8 in = 10. 0 in = * Class-C Object-3 Diameter (mm) Length (mm) Inner. Diameter (mm) Diameter = 2. 5 in Length = 9. 0 in Inner. Diameter = 2. 0 in
System Parts List n Overriding Values Object-1 Diameter Length Curvature Orientation = 1. 2 in = 10. 5 in = 5. 0 in = “SE” Part-1 Part-2 Part-3 Length = 14. 0 in optional Object-2 Diameter Length Curvature Orientation = 2. 0 in = 4. 8 in = 10. 0 in = * Part-4 Orientation = “NE” mandatory
Assembly Hierarchy TOP Assembly Part Subassembly Part
Assembly Hierarchy TOP Assembly Part Subassembly Part denotes Exported Port Part
Project Models n Class Hierarchy n Assembly Hierarchy TOP Part Class Object Part Assembly Part
Project Models n Class Hierarchy n Assembly Hierarchy TOP Part Class Object Part Assembly Part
Model Configuration n Common Properties in Objects l Start from Simulator Object Libraries n Hierarchical Assemblies of Parts l l l Create parts and links from objects Form assemblies with parts and links Exports to parent assembly for linking Replicate parts and all its subassemblies Override object values in parts or links
Data Entry/GUI Control Types n Numbers l l l Integer Floating Point (single or double precision) Currency Format n String l l l Regular Masked Encrypted n URL / File n Date / Time n On-Off Switch n Tri-State Switch n Enumerated Items n Object Reference n Quality n Symbolic Parameter
Unit Conversion n User Extensible Unit Objects l l Specify units of measure for data input, output and presentation Automatic conversion to units required by the simulators before simulation runs Expand unit tables to add new units not covered by the simulator developer Service Session - lock / unlock unit objects by simulation developers
Simulation Run Controls n In-Process Simulation Controls l l l Run, pause / resume, step, fast forward, stop Monitor and change data values on the fly Simulation runs in a thread within Sans. GUI n External Process Controls l l l Run and stop a simulation Customize invocation script Simulation runs in a separate process
Simulation Control Objects n In-Process Cycle Simulation Control l Continuous, cycle-driven simulation control – Program location, log file name, start / pause / end cycle number, current cycle number, screen refresh interval, part evaluation order n External Process Simulation Control l Stand-alone or legacy code integration – Program location, invocation script, model file name and type, working directory, command parameters
Results Logging and Plotting n Logging l l l Select logged values in objects, parts or links Logged results can be viewed in a data grid Change output units as desired n Plotting l l l Plot selected set of logged data when running Change plot specifications when paused Customize plotting features
Sans. GUI Object Library n Simulator Dependent n Class Schema Version Control n Convenient & Custom Objects l l Mandatory Objects: required by simulators Default Objects: with default values Common Objects: frequently used values Special Objects: with hard to enter or remember values
Run-Time Environment Object Library On-Line Help . SGO File . HTM, . HLP, etc. Sans. GUI Run-Time Environment Sans. GUI Object System Model & Schematic Editor Simulation User Version Control Execution Control Result Logger & Viewer Project Model File . SGP File . TXT or. XML
Run-Time Environment Object Library On-Line Help . SGO File . HTM, . HLP, etc. User Override Routines Software Implementation Core Simulator Sans. GUI Run-Time Environment In-Process. DLL File Sans. GUI Object System Editing Model & Schematic Editor Simulation User Execution Version Control Evaluation Execution Control Result Logger & Viewer Invocation Script. BAT File Project Model File External Process . SGP File . TXT or. XML Local or Remote
Run-Time Environment Object Library On-Line Help . SGO File . HTM, . HLP, etc. User Override Routines Software Implementation Core Simulator Sans. GUI Run-Time Environment In-Process. DLL File Sans. GUI Object System Editing Database Access Model & Schematic Editor Simulation User 3 D Graphics Open. GL® Execution Version Control Evaluation Execution Control Hardware-in-the-Loop Device Control Result Logger & Viewer IPC or RPC Invocation Script. BAT File Project Model File External Process . SGP File . TXT or. XML Local or Remote Custom Pre-Processor Custom Post-Processor Other Programs
Advanced Simulation Users n Managing Common Objects l l Customizing Object Libraries Importing Objects and Classes n Overriding Simulator Routines n Customizing Sans. GUI Environment l l l Managing User Workspaces Tuning Environment Parameters Using Different Directories
Developing with Sans. GUI®
Simulator Development n Sans. GUI File Types and Architecture n Simulator Schema Definition n Input Data Specification / Validation n Internal Data Structures n Core Simulator Programming n Pre-processors / Post-processors n On-Line Help Development
Sans. GUI File Types n Primary Extensions Schema Definition. SGS Design Development Legacy Simulator. EXE Object Library. SGO Class Functions. DLL Deployment Run-Time Model File. TXT or. XML External Process Simulator Project Model. SGP User Functions. DLL In-Process Simulator denotes the source information is used to generate the target file or code framework denotes the source information is sent to the target for execution
Development Environment Sans. GUI Development Environment Schema Definition. SGS File Meta. Schema Object System Version Control Source Framework Schema Compiler Object Library. SGO File Simulation Developer
Development Environment Sans. GUI Development Environment Schema Definition. SGS File Meta. Schema Object System Version Control Source Framework Schema Compiler Object Library In-Process Source Files . SGO File C/C++ or Fortran In-Process. DLL File Programming Language - IDE External Process. EXE File Simulation Developer External Process Source Files Other Programming Libraries Text Editor
Development Environment Sans. GUI Development Environment Schema Definition. SGS File Meta. Schema Object System Version Control Source Framework Schema Compiler Files for Distribution Object Library In-Process Source Files . SGO File C/C++ or Fortran In-Process. DLL File Programming Language - IDE External Process. EXE File Simulation Developer External Process Source Files Other Programming Libraries Text Editor Help Authoring Tool Invocation Script. BAT File (optional) On-Line Help. HTM, . HLP, etc.
Sans. GUI Schema Definition n Simulator Identification n Class Properties and Attributes n Class Sharing Options n DLL Function Specifications n Port Specifications in Components n Connectivity Specifications n Unit Objects
Sans. GUI Intrinsic Classes n Component Classes l Base, Assembly, and Link n Reference Classes l Collection, Graphics, Matrix, and Table n Simulation Control Classes l Cycle and XProc n Unit Class
External Process Simulator n Model File Format l l Tabular Data Blocks XML Model Data n Invocation Script Customization l l Input Filter - convert Sans. GUI file format Pre & Post Processor - integrate execution Job Control - submit long running job Remote Execution - run simulation remotely
In-Process Simulator n Checking DLL Function Entry Points l Define DLL entry points in Class Properties n Using Source Code Framework l Generate skeleton code in C/C++ & Fortran n Working with MS Visual Studio l l l Create DLL projects and insert source files Implement simulator logic and mathematics Compile, debug, and trace through code
Run-Time System Review Object Library On-Line Help . SGO File . HTM, . HLP, etc. User Override Routines Software Implementation Core Simulator Sans. GUI Run-Time Environment In-Process. DLL File Sans. GUI Object System Editing Database Access Model & Schematic Editor Simulation User 3 D Graphics Open. GL® Execution Version Control Evaluation Execution Control Hardware-in-the-Loop Device Control Result Logger & Viewer IPC or RPC Invocation Script. BAT File Project Model File External Process . SGP File . TXT or. XML Local or Remote Custom Pre-Processor Custom Post-Processor Other Programs
Sans. GUI Object System n Sans. GUI Data Object Format l l l SG_OBJ Data Structure SG_VALU Data Structure GUI Control Type Funneling n Sans. GUI API l l l DLL Function Prototype DLL Function Entry Points Cycle Simulation Calling Sequence
SG_OBJ Data Structure n Sans. GUI Schema Version n Object Status and User Data n Class Information l Class Name, Path, Version, and Attributes n Object Information l Component Path and Serial Number n SG_VALU Data Array
SG_OBJ in C/C++ typedef struct SG_OBJ_tag { SG_CONST UINT n. SGobj. Schema; INT i. Status, i. User. Data; SG_CONST INT i. Num. Vars; SG_VALU *SG_CONST z. Values; SG_CONST INT i. Ver. Major, i. Ver. Minor, i. Ver. Patch, i. Ver. Build; SG_CONST UINT n. Cmpn. No; const TCHAR *SG_CONST c. Obj. Name, c. Cmpn. Name; SG_CONST TCHAR *SG_CONST c. Class. Path, c. Cmpn. Path; const TCHAR *SG_CONST s. Var. Names; } SG_OBJ;
SG_VALU Data Structure n Data Type n Dimension l Size, columns, and rows n Data Array l l All values are in arrays INT*, FLOAT*, DOUBLE* TCHAR* (Dynamic TCHAR Array) TCHAR** (String Array)
SG_VALU in C/C++ typedef struct SG_VALU_tag { SG_CONST UINT n. Type; SG_CONST INT i. Size, i. Cols; INT i. Rows; union { void *SG_CONST v. Data; INT *SG_CONST i. Data; FLOAT *SG_CONST f. Data; DOUBLE *SG_CONST d. Data; TCHAR *SG_CONST c. Data; TCHAR *SG_CONST s. Data; }; } SG_VALU;
GUI Control Type Funneling n SG_VALU Data Storage l l Number ® INT, FLOAT, DOUBLE Array String ® String Array – Regular string in a cell ® Dynamic TCHAR Array l l URL / File / Reference ® String Array Date / Time ® INT Array On-Off and Tri-State Switch ® INT Array Enumerated Items ® INT Array
DLL Function Prototype n SG_SIM_FUNC Arguments sim. Ctrl ref. Obj adj. Obj lnk. Obj self lnk. Obj chg. Child (Reserved) adj. Obj Other Arguments ·c. Message ·c. Command ·p. Out. File
SG_SIM_FUNC in C/C++ typedef SG_RET_CODE (SG_SIM_FUNC)( SG_OBJ *const self, SG_OBJ *const sim. Ctrl, SG_OBJ *const chg. Child, SG_OBJ *const ref. Objs[], const INT *const pi. Ref. Objs, SG_OBJ *const adj. Objs[], const INT *const pi. Adj. Objs, SG_OBJ *const lnk. Objs[], const INT *const pi. Lnk. Objs, TCHAR *const c. Message, const INT i. Msg. Len, TCHAR *const c. Command, const INT i. Cmd. Len, SG_FILE *const p. Out. File );
DLL Function Return Value n SG_R_OK - success, continue simulation n SG_R_LMSG - display a message to user n SG_R_PAUS - pause and inquire user n SG_R_STOP - error detected by simulator n SG_R_VERS / SG_R_SCHM - version n SG_R_ERR - error detected by Sans. GUI n SG_R_* | 24 Bit Simulator Error Number
DLL Function Entry Points n Data Editing Functions l l End Edit Check Resize/Load Data n Execution Functions l l Resize/Initialize Data Begin/End Run and Case n Evaluation Functions l Pre Evaluation/Post Evaluation
Cycle Simulation Sequence (1) All Reference Objects and then all Parts (2) All Parts and then all Reference Objects n Init-Size (2) / Initialization (1) n Begin Run / Case (1) n Pre Evaluation (1) n Evaluation and Post Evaluation (2) n End Run / Case (2)
Evaluation Cycles n Reference Objects l By Name n Parts in Assembly Tree - Depth First l l l By Name By Z-Order By Horizontal Scan Lines By Vertical Scan Lines Random
Using Class Graphics n Support Open. GL® 3 D Graphics l l Initialize - mapped to Begin Run function Reshape - mapped to Pre Evaluation function Display - mapped to Post Evaluation function Select - mapped to Evaluation function n Simplify 3 D Graphics Operations l l Rotate, Pan, Zoom, and Reset Print, Copy to clipboard, Save to image files
Visual Fortran Support n Select Column-Major Data Storage n Use Generated Framework l l Source files are generated as in C/C++ Choose Fortran or C/C++ implementation on a class-by-class basis n Use Supplied Header File - SGdllf. h n Dump SG_OBJ in Visual Fortran l Use the distributed SGdump. f code
Data Access in Fortran Variable f. Var Array of SG_VALUs SG_OBJ via PTR_z. Values POINTER PTR_f. Var z. Values(index)%v. Data SG_VALU pz. Values real*4, dimension(*) : : f. Var POINTER(PTR_f. Var, f. Var) PTR_z. Values = self%pz. Values PTR_f. Var = z. Values(index)%v. Data
Development Environment n Microsoft Visual Studio® l l Microsoft Visual C++ 6. 0 (SP 3+) Compaq Visual Fortran 6. 1+ Simulator code debugging and tracing Multi-Threaded Execution Support n Open. GL® 3 D Graphics Programming n XML Model Data Support n Existing Code/Library Integration
Other Language Support n In-Process Simulation - PC l l Can create Win 32 DLLs Can be called from Microsoft Visual C++ – Function names (length and case sensitivity) – Compatible function argument list l Can access C data structures with pointers n External Process Simulation l Can create stand-alone programs – Batch command / Shell script invocation
Experiencing with Sans. GUI®
Hands-On Sessions n Visual Calculator for Sans. GUI l Creating a simple graphical calculator with step-by-step instructions n MIDI Player for Sans. GUI l Showing a legacy program and an in-process layer work in concert for dynamic charting n Mixer Example for Sans. GUI l Building, loading and solving a system of linear equations
Thank you ! n Visit Our Web Site l l http: //protodesign-inc. com http: //sansgui. com n E-Mail l l Information: info@protodesign-inc. com Sales: sales@protodesign-inc. com Support: support@protodesign-inc. com Beta testing: beta@protodesign-inc. com
- Getting ahead
- Getting started with ft8
- Dr jeffrey roach
- Counter code
- Android development getting started
- Find these things in unit 1
- Rancher getting started
- Unit 3 getting started
- Lua getting started
- Getting started with vivado
- Tipos de habilidades del pensamiento
- Linkedin getting started
- Getting started with excel
- Unit 1 getting started
- Lesson 1 hobbies
- Unix for bioinformatics
- Getting started with eclipse
- Hi3ms
- Microsoft outlook 2010 training
- Poll everywhere register
- Unit 1 getting started
- Mathematica getting started
- Splunke
- Ge gi gue gui güe güi
- Quick find vs quick union
- Quickchek menu
- Quick sans
- Vivre sans richesse presque sans le sou
- Qu'est-ce que tu aimes manger
- Nx get started
- Implicit cost example
- The speedy fast ski resort has started to keep track
- Owner herbalife
- When labour day started
- Ww1 countries allies
- Cooperative movement in pakistan
- Gina fox has started her own company
- Rizal’s teacher at the village school in biñan was
- When was samaritan's purse founded
- Drawbacks of green revolution
- When labour day started
- The place where in futsal created in 1930 was in
- How to get started with soar?
- Michael jackson vocabulary
- Tcs maitree initiative
- Who was the governor at the time of urdu hindi controversy
- The journey has just started
- Lets get started images
- Where did the renaissance spread
- Paola stipo
- 1950s television history
- Judy believes that her fate is determined
- "you+us"
- When labour day started
- Ron has just started as a scrum master
- Fepblue org mra/login
- What period lasted from 1750-1825?
- When islam started
- Excited to get started
- Cause of world war 1
- What started the renaissance