Arduino and Serial port in MATLAB
5 ビュー (過去 30 日間)
古いコメントを表示
Hi,
I have an Arduino DUE connected to my Virtual machine on which there is installed UBUNTU.
If I try to create a serial connection at the address where the Arduino DUE is everything is fine.
The problem is that when I close MATLAB and I want to open the Arduino IDE again, there is no serial port available.
I think it´s some kind of closing and deleting that I have to do, but I don´t know what is the right command.
Someone of you can help me?
thanks, Fab.
0 件のコメント
回答 (1 件)
David Sanchez
2013 年 8 月 1 日
You have to close the serial object once you are done with it:
s1 = serial('COM1'); % create serial object, it will be something different
fopen(s1=),% open your serial object
....% do whatever you want to do with it
fclose(s1);% close it when you are done with it
% get rid of the serial object
delete(s1)
clear s1
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で MATLAB Support Package for Arduino Hardware についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!