生成执行时间探查数据
在运行软件在环 (SIL) 或处理器在环 (PIL) 执行之前,要启用执行时间探查:
要打开 MATLAB® Coder™,请在 MATLAB 工具条的 App 选项卡上,点击代码生成下的 App 图标。App 将打开“创建 MATLAB Coder 工程”对话框。
要打开您的工程,请点击打开,导航到包含您的 MATLAB Coder 工程文件的文件夹,并选择该文件。例如,
kalman_filter01.coderprj
。选中启用入口函数执行探查复选框。
如果您还希望为在入口函数中调用的函数生成执行时间探查数据,请选中启用函数执行探查复选框。
或者,从命令行窗口中,指定 coder.EmbeddedCodeConfig
对象的属性。例如:
% Enable entry point execution profiling config.CodeExecutionProfiling = true; % Enable function execution profiling config.CodeProfilingInstrumentation = true; % Disable OpenMP config.EnableOpenMP = false;