fscanf read multiple data
이전 댓글 표시
Hi everybody,
I have a matlab program in which I can read distance data from an Arduino. I received them over Bluetooth. I use fscanf function to read but now I want to read the number of sample and distance as follows:
N.sample (tab) distance
How could I do it? Thank you
답변 (1개)
Santhana Raj
2017년 3월 30일
0 개 추천
Modify the fscanf command's formatspec, the 2nd variable to include two float variables.
Ex: A=fscanf(fileid, '%f %f',[Inf,2]);
hope it helps
카테고리
도움말 센터 및 File Exchange에서 Bluetooth Communication에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!