13.07.2015 Views

An Integrated, Modular Simulation System for Education ... - Cal Poly

An Integrated, Modular Simulation System for Education ... - Cal Poly

An Integrated, Modular Simulation System for Education ... - Cal Poly

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

instructor a graphical interface to control the simulation that runs as a separate process oreven on a separate computer.The second restriction is that there is no direct support <strong>for</strong> graphical output. Userscan write their own graphics wrapped in the S-function template.Keeping in mind the two limitations, just about any thing that can be written in ccan be used as an S-function including reading from and writing to hardware, storage,TCP/IP communications, graphics, timing functions and custom math functions andmodels.Simulink model code is plat<strong>for</strong>m independent as long as only generic c S-functioncode blocks are included in the model. This feature has the advantage that a model canbe created on a desktop PC, then be ported to a Unix based workstation. Using aworkstation, advanced analysis and optimization programs can be made available. Thespeed increase possible using a workstation could allow real time execution if the modelis complex enough that real time execution is not possible on a PC. Some hardwaredrivers can be ported between plat<strong>for</strong>ms as long as the c code is generic. The BG systemsFlyBox uses a serial port with generic c code drivers so the S-function drivers shouldfunction on a PC as well as a Unix workstation. The generic nature of the c and S-function code was demonstrated by running the Euler S-function and the 6 DOF S-function blocks on both a PC and a several Silicon Graphics workstations including anIndigo and an Onyx.On a Windows 95 system the user can only use 32 bit program code to link intothe S-functions. This caused all of the 16 bit snoopy game IO functions used to test theoriginal desktop simulation functions to be abandoned. A new set of 32 bit game joystick36

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!