インテル® Quartus® Primeプロ・エディション・ユーザーガイド: デバッグツール

ID 683819
日付 9/30/2019
Public
ドキュメント目次

7.11.1. サポートされているMATLAB* APIコマンド

MATLAB*環境から作業を実行し、System Consoleを使用してマスターとスレーブに対する読み出しや書き込みを行います。サポートされているMATLAB* APIコマンドによって、System Consoleソフトウェアを起動する手間が省けます。サポートされているコマンドは、次の通りです。

  • SystemConsole.refreshMasters;
  • M = SystemConsole.openMaster(1);
  • M.write (type, byte address, data);
  • M.read (type, byte address, number of words);
  • M.close

MATLAB* APIスクリプトの例

SystemConsole.refreshMasters; %Investigate available targets
M = SystemConsole.openMaster(1); %Creates connection with FPGA target
%%%%%%%% User Application %%%%%%%%%%%%
....
M.write('uint32',write_address,data); %Send data to FPGA target
....
data = M.read('uint32',read_address,size); %Read data from FPGA target
....
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
M.close; %Terminates connection to FPGA target