Advertisement

Wednesday 3 July 2013

How to interface Arduino and Matlab

Hi,Today i am going to tell you about interfacing of Arduino and Labview as my previous post was about how to interface Arduuino and LabVIEW .
Interfacing Arduino with Matlab is much more easy than LabVIEW you need just one file to upload in Arduino and one file for  Matlab.

Step by Step Startup Guide

Since January 2010 there are 2 basic ways to interact with the Arduino board using MATLAB and Simulink:


MATLAB Interface for Arduino:
  1. Download zip file from here and unzip.
  2. Now open folder pde.
  3. Inside pde folder there are three folders
    1. ardiosrv
    2. motorsrv
    3. srv
  4. open ardiosrv folder you will find adiosrv.pde upload this file into Arduino
  5. At main folder you will find arduino.m file place this file in current working directory of Matlab or extract whole zip file into current working directory of Matlab
Here is sample program for led .

           a=arduino('COM5'); 
           a.pinMode(13,'output');
           a.digitalWrite(13,1);

Some Basic examples are given in folder
If you have any problem feel free to ask


Like,comment and Share

0 comments:

Post a Comment