Main Content

验证

证明 MATLAB® 代码与生成的代码之间的数值等效性

通过执行软件在环 (SIL) 和处理器在环 (PIL) 仿真,检查从 MATLAB 函数中生成的代码的数值行为。软件在环 (SIL) 仿真在开发计算机上编译生成的源代码并将其作为单独的进程执行。PIL 仿真(需要目标连接配置)交叉编译生成的源代码,然后在目标硬件上下载并运行目标代码。通过将 SIL 或 PIL 仿真的结果与原始 MATLAB 函数的结果进行比较,可以验证代码的数值行为。

您可以生成可追溯的代码,帮助您检查是否存在不需要的功能、了解生成的代码如何实现您的算法,并评估生成的代码质量。

对象

全部展开

rtw.connectivity.ComponentArgsProvide parameters for each target connectivity component
rtw.connectivity.ConfigDefine connectivity implementation that comprises builder, launcher, and communicator components
rtw.connectivity.ConfigRegistryRegister connectivity configuration
rtw.connectivity.LauncherControl downloading, starting, and resetting of a target application
rtw.connectivity.MakefileBuilderConfigure toolchain-based build process
rtw.connectivity.RtIOStreamHostCommunicatorConfigure development computer communications with target processor
rtw.pil.RtIOStreamApplicationFrameworkConfigure target-side communications
coder.EmbeddedCodeConfigConfiguration parameters for C/C++ code generation from MATLAB code with Embedded Coder

函数

全部展开

coder.hardwareCreate hardware board configuration object for C/C++ code generation from MATLAB code
rtIOStreamCloseShut down communications channel
rtIOStreamOpenInitialize communications channel
rtIOStreamRecvReceive data through communication channel
rtIOStreamSendSend data through communication channel
rtiostreamtestTest custom rtiostream interface implementation
rtiostream_wrapperTest rtiostream shared library functions in MATLAB
piltestVerify custom target connectivity configuration for MATLAB PIL execution

主题

SIL 和 PIL 测试

代码追溯

Polyspace 验证

生成报告