Arduino 時間 VS A0ピンに入力される電圧をプロットする。
6 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Shinsuke Okayasu
am 14 Okt. 2019
Beantwortet: Shinsuke Okayasu
am 27 Okt. 2019
Arduinoからの5V信号をポテンショメータで電圧を調整しています。
時間 vs 電圧をプロットする方法(下記①、②からplot関数でできると思うのですが・・・・)をご教示いただけないでしょうか。
①ワークスペースに時間を作成する方法
②while文が実行中のain(readVoltageのデータが格納される)が①に対応した電圧をワークスペースに作成する。
下記のコードを実行中です。
clear all;
a = arduino();
tic
while(toc<10)
ain = readVoltage(a,'A0');
fprintf('Voltage = %f',ain);
pause(0.5);
end
1 Kommentar
Akzeptierte Antwort
Weitere Antworten (1)
Siehe auch
Kategorien
Mehr zu Arduino Hardware finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!