File Exchange

image thumbnail

MATLAB serial - code example

version 1.2.0.3 (1.95 KB) by Steven Kolak
MATLAB with serial devices - code example

37 Downloads

Updated 30 Oct 2018

View License

Editor's Note: Popular File 2010 2011

MATLAB supports serial devices including RS-232 when using Instrument Control Toolbox.
This MATLAB code example shows you how to communicate with a serial device.

This MATLAB code example was automatically generated with a device configuration tool provided by the toolbox. Type "tmtool" to start this tool. This is a basic code example to show you how to get started using MATLAB to communicate with a serial device.

Learn more about using MATLAB with serial devices at:
https://www.mathworks.com/products/instrument/supported/serial.html

Comments and Ratings (61)

Philipp

I was able to connect my device to MATLAB using this code. But how to actually read and save the data which is sent from the device?

M M

hello, quen I write pmode start or matlabpool('open',numberf of core) have one err. Do you know why:

Team 6

Chulinkaa

only basic information.....

ooo lale e du mor burr ket program se e do profesori

Don't waste your time- this is just the most basic four-line example copied straight from the MATLAB help file.

Tortuka

salim hadjsaid

Thank you,I was using:
"p=instrfind;
s1=Serial('COM1','baudrate',9600,'stopbits',1,
'Terminator','LF','timeout',Te);"
s1.ReadAsyncMode = 'continuous';
but acquisition can't go down .05s

kee douang

Baba Omar

I NEED IT FOR STUDY

fathy alsaka

effendi dodi arisandi

thank you

din esh rajan

good

gilson borba

en gex

shahir uddin

it will help me to modify the project

renáta petrovková

Erick Suret

hobby

dragan djokovic

156 15616

22

Teerapun Phiyakunphanid

vab mishra

alex morais

its very good.

heri gunawan

ahmed abdalla

Juan García

Solicito su orientación para conseguir el serial de matlab 2006.

Dongwen zhang

good

Jose Medina

good

ALIN Kamdeu

it is good to have something to leaD US

patryk kubi?ski

jamal mazloom

tarik amrouche

Bouzegag younes

j'ai besoin d'un programme en matlab pour identifier une trame avec le protocole RS232
sur le oport série de mon pc;

shivi shetty

good application

Cheol Min Kim

Miguel Delgado

Nick Panagiotopoulos

Gowri shankar J

while using Rs-232 of PLC & SCADA the micro controller programming is used , while used in m- file programming , we r using the concept of c language

mahdi Haghzadeh

mahdi Haghzadeh

mahdi Haghzadeh

mahdi Haghzadeh

bontong wasri

Wang juan

Thangk You!

rashid addamt

thank u

jay collins

Manatchai Prommin

thankyou

morin patrick

Maksic Natasa

sten ipkins

M. Huxby

Works for me. It is a basic example, but it shows how to use Matlab to talk to a serial device by using a tool, how the tool auto generates Matlab script for you, and how to generate a report.

ER NEWB

Doesn't help me any! :(

Dave Billingham

Updates

1.2.0.3

Removed citation entry.

1.2.0.2

Updated URL for the resource page for using MATLAB and Instrument Control Toolbox with serial devices.

1.2.0.1

Updated license

1.2.0.0

Added BSD License

1.0.0.0

Updated description

Updated description

MATLAB Release Compatibility
Created with R2006b
Compatible with any release
Platform Compatibility
Windows macOS Linux