最新のリリースでは、このページがまだ翻訳されていません。 このページの最新版は英語でご覧になれます。
ソフトウェアインザループ (SIL) とプロセッサインザループ (PIL) 実行を使用して、MATLAB 関数から生成したコードの数値的動作をチェックします。ソフトウェアインザループ (SIL) 実行は生成されたソース コードをコンパイルし、そのコードを個別のプロセスとして開発用コンピューターで実行します。ターゲット接続性設定を必要とする PIL 実行は生成されたソース コードをクロスコンパイルし、ターゲット ハードウェア上でオブジェクト コードをダウンロードして実行します。数値的動作は SIL または PIL 実行の結果を元の MATLAB 関数の結果と比較することで検証できます。
トレース可能なコードを生成すると、意図しない機能が存在しないことを確認し、生成済みコードがアルゴリズムを実装する方法を理解し、生成済みコードの品質を評価するのに役立ちます。
Code Verification Through Software-in-the-Loop and Processor-in-the-Loop Execution
A workflow that uses SIL and PIL execution to verify the numerical behavior of generated MATLAB code.
Software-in-the-Loop Execution with the MATLAB Coder App
Use the MATLAB Coder app to verify the numerical behavior of generated C/C++ code.
Software-in-the-Loop Execution From Command Line
Use MATLAB commands to verify the numerical behavior of generated C/C++ code.
Debug Generated Code During SIL Execution
Use a debugger to understand the behavior of generated code.
Create PIL Target Connectivity Configuration for MATLAB
Customize PIL execution for your target environment.
Host-Target Communication for MATLAB PIL Execution
Use the rtiostream
API for communication
between your development computer and target during PIL execution.
Specify a hardware timer using the Code Replacement Tool.
Custom Toolchain Directives Required for Code Execution Profiling
Specify compiler directives for building PIL application that supports code execution profiling.
Processor-in-the-Loop Execution with the MATLAB Coder App
Use the MATLAB Coder app to verify the numerical behavior of cross-compiled object code.
Processor-in-the-Loop Execution From Command Line
Use MATLAB commands to verify the numerical behavior of cross-compiled object code.
PIL Execution with ARM Cortex-A at the Command Line
This example shows how to set up a PIL execution to verify generated code at the command line.
PIL Execution with ARM Cortex-A by Using the MATLAB Coder App
PIL Execution with App.
Verification of Code Generation Assumptions
PIL execution checks Hardware tab settings.
Speed Up SIL/PIL Execution by Disabling Constant Input Checking and Global Data Synchronization
Configure code generation parameters to turn off constant input checking or global data synchronization for SIL or PIL executions.
SIL/PIL Execution Support and Limitations
SIL and PIL execution support for code generation features.
Interactively Trace Between MATLAB Code and Generated C/C++ Code
Visualize the mapping between the MATLAB code and the generated C/C++ code.
生成されるコードにコメントとして MATLAB ソース コードを含めます。関数のヘルプ テキストと関数シグネチャを関数バナーに含めます。
Polyspace Verification of C/C++ Code Generated by MATLAB Coder
Check for run-time errors or defects in generated C/C++ code.
Highlight Potential Data Type Issues in a Report
Highlight MATLAB code that results in double-precision, single-precision, or expensive fixed-point operations.
Find Potential Data Type Issues in Generated Code
Highlight potential data type issues in report.