MATLAB Interface Programming

Slides:



Advertisements
Similar presentations
MATLAB and SimulinkLecture 71 To days Outline  Callbacks  MATLAB And Simulink  S-functions  Project suggestions.
Advertisements

General Computer Science for Engineers CISC 106 Lecture 08 Dr. John Cavazos Computer and Information Sciences 2/27/2009.
How shell works Shell reads in input, parse & process it, the resulting string is taken to be argv[] and executed echo a  shell sees “ echo a ” echo gets.
Division Example 2x - 3y + 4z = 10 x + 6y - 3z = 4 -5x + y + 2z = 3 A*X = B where A = B = >> X = A\B X =
Reverse Engineering In Rational Rose. Steps to take… Set up new Java project Click on class path.
Introduction to MATLAB ENGR 1187 MATLAB 1. Programming In The Real World Programming is a powerful tool for solving problems in every day industry settings.
Introduction to programming in MATLAB MATLAB can be thought of as an super-powerful graphing calculator Remember the TI-83 from calculus? With many more.
EPSII 59:006 Spring Topics Using TextPad If Statements Relational Operators Nested If Statements Else and Elseif Clauses Logical Functions For Loops.
M-files While commands can be entered directly to the command window, MATLAB also allows you to put commands in text files called M- files. M-files are.
MATLAB File Management. MATLAB User File Management Matlab provides a group of commands to manage user files. For more information, type help iofun. pwd.
What should I do first Young Joon Kim MSRDS First Beginner Course - STEP1.
HelloApps.com What should I do first Young Joon Kim MSRDS First Beginner Course - STEP1.
Computational Methods of Scientific Programming Lecturers Thomas A Herring, Room A, Chris Hill, Room ,
Introduction to Engineering MATLAB – 6 Script Files - 1 Agenda Script files.
Oracle Data Integrator Workflow Management: The Packages.
Elegant avoiding of obstacle Young Joon Kim MSRDS First Beginner Course – STEP5.
Version How to Use Packet Tracer MarinaMD.
VPL basic – data and variables Young Joon Kim MSRDS First Beginner Course – STEP6.
Script M-Files Group of Matlab commands placed in a text file with a text editor. Matlab can open and execute the commands exactly as if they were entered.
Introduction to Matlab Module #9 Page 1 Introduction to Matlab Module #9 – Simulink Topics 1.Simulink Textbook Reading Assignments Practice Problems.
CSE123 Lecture 3 Files and File ManagementScripts.
Matlab Basic. MATLAB Product Family 2 3 Entering & Quitting MATLAB To enter MATLAB double click on the MATLAB icon. To Leave MATLAB Simply type quit.
Read, Read, Read, Read, Read!! The following presentation is a review over important icons and commands in the Microsoft Word program. They are important.
Use SPSS for solving the problems Lecture#21. Opening SPSS The default window will have the data editor There are two sheets in the window: 1. Data view2.
My first robot programming - Simple “Go” Young Joon Kim MSRDS First Beginner Course – STEP4.
SPL basic – Build Simulation Environment Young Joon Kim SPL First Beginner Course – 03.
Start Anaglyph Programming Young Joon Kim Stereoscopic & Anaglyph Course.
Matlab Programming for Engineers
Installing Analysis Tool Pak
VBA - Excel VBA is Visual Basic for Applications
MATLAB Basics Nafees Ahmed Asstt. Professor, EE Deptt DIT, DehraDun.
Welcome to MATLAB.
Basic operations in Matlab
What should I do first MSRDS First Beginner Course - STEP1
MATLAB DENC 2533 ECADD LAB 9.
User Defined Functions
Introduction to MATLAB
Matlab review Matlab is a numerical analysis system
CS100J 26 April. Matlab Use help button!!! Variables, values, types
Use of Mathematics using Technology (Maltlab)
I decided to put both the 9:00 and 10:00 class in one presentation to give you a little more information. Be sure to look at the information under notes.
Writing functions in MATLAB
StatLab Workshop: Intro to Matlab for Data Analysis and Statistical Modeling 11/29/2018.
Basic Sensors – Laser Distance Sensor
Installing Analysis Tool Pak
Digital Image Processing
Young Joon Kim SPL basic – Quick Start SPL First Beginner Course – 01 Young Joon Kim
funCTIONs and Data Import/Export
VPL Patterns – Multi-Action Activity
CSCI N317 Computation for Scientific Applications Unit 1 – 1 MATLAB
My first robot programming - Simple “GoTo”
SPL GraphicSprite Command
Matlab Basic Dr. Imtiaz Hussain
VPL Patterns – Loop Pattern using Notification
Using Script Files and Managing Data
Scripts In Matlab.
Young Joon Kim SPL basic – Quick Start SPL First Beginner Course – 01 Young Joon Kim
SPL Programming – While Loop Pattern
My first robot programming - Simple “Go”
Introduction to Matlab:
SPL Programming – Procedure Pattern
Pose Sensors – Detect Orientation
ENERGY 211 / CME 211 Lecture 28 December 1, 2008.
Basic Sensors – RFID Sensor
My first robot programming - Simple “GoTo”
My first robot programming - Simple “GoFor”
SPL basic – Script types
ME 123 Computer Applications I Lecture 4: Vectors and Matrices 3/14/03
Introduction to Matlab
Programming The ideal style of programming is Structured or
Presentation transcript:

MATLAB Interface Programming Young Joon Kim http://www.helloapps.com

Topics MATLAB Command in SPL Execute MATLAB in SPL Execute Simulink model file Get Variable from MATLAB Get String from MATLAB Put string to MATLAB Put and Get Full Matrix Put and Get Workspace Data

MATLAB Command in SPL

MATLAB Command in SPL MATLAB Command under “Expression” tab

Execute MATLAB in SPL

Execute MATLAB in SPL Add “MATLAB” command as follows Double click

Execute MATLAB in SPL Add “matlab1.Execute()” command as follows

Execute MATLAB in SPL Type “print” command as follows

Execute MATLAB in SPL Save and execute script

Prepare Simulink

Prepare Simulink Draw below diagram with Simulink

Prepare Simulink Executed result

Prepare Simulink Save diagram as “satellite.mdl”

Execute Simulink model file

Execute Simulink model file Type command [t,x,y] = sim(‘satellite.mdl’) Util.UserDataDir returns MSRDS’s UserData path

Execute Simulink model file Execute script and print

Execute Simulink model file Save and execute SPL script

Get Variable from MATLAB

Get Variable from MATLAB Execute command

Get Variable from MATLAB Use “matlab1.GetVariable()” command to get variable

Get Variable from MATLAB Check the upper bound of returned array Dimension 1 and dimension 2

Get Variable from MATLAB Print the value of variable

Get Variable from MATLAB Save and execute script

Get String from MATLAB

Get String from MATLAB Define string value in the MATLAB

Get String from MATLAB Use “GetCharArray()” method to get string from MATLAB

Get String from MATLAB Save and execute script

Put String to MATLAB

Put string to MATLAB Use “PutCharArray()” command to send string to MATLAB

Put string to MATLAB Save and execute SPL script

Put and Get Full Matrix

Put and Get Full Matrix Define array and initialize

Put and Get Full Matrix Use “PutFullMatrix()” to send array data to MATLAB

Put and Get Full Matrix Send command to make matrix “b”

Put and Get Full Matrix Use “GetFullMatrix()” command to get matrix data from MATLAB

Put and Get Full Matrix Full script

Put and Get Full Matrix Save and execute SPL script

Put and Get Workspace Data

Put and Get Workspace Data Use “PutWorkspaceData” to send data to MATLAB

Put and Get Workspace Data Send command to define matrix “b” as follows

Put and Get Workspace Data Use “GetWorkspaceData” command to get data

Put and Get Workspace Data Save and execute SPL Script