从 DSP C6748 的 Matlab-Simulink 模型生成 C 代码
我正在尝试从 Matlab-Simulink 简单模型生成 C 代码(例如:输出端带有 DAC 的正弦波发生器)。此代码必须使用 Code Composer Studio 执行 适用于 TMS320C6748 DSP(德州仪器 C6748)。具体来说,适用于开发板 OMAP-L138 ZOOM ™EVM 开发套件。
为此,我使用以下版本: Simulink(版本 7.7 - R2011a) 嵌入式编码器(版本 6.0 - R2011a) Code Composer Studio v3.3
我尝试了几种选项(使用 Simulink 中的通用模块并对 C6748 定时器进行编程、使用“OMAP_L138/C6748 EVM”配置模块“目标首选项”...),但它不起作用。
这个想法有可能实现吗?有一个有效的例子吗?
谢谢
I'm trying to generate C code from a Matlab-Simulink simple model (eg.: sine wave generator with a DAC at the output). This code must be executed with Code Composer Studio
for TMS320C6748 DSP (Texas Instrument C6748). Specifically, for the development board OMAP-L138 ZOOM ™EVM DEVELOPMENT KIT.
For this, I am using the following versions:
Simulink (Version 7.7 - R2011a)
Embedded Coder (Version 6.0 - R2011a)
Code Composer Studio v3.3
I tried several options (with generic modules in Simulink and programming the C6748 timers, configuring a module "Target Preferences" with "OMAP_L138/C6748 EVM"...) but it isn't working.
Is it possible to implement this idea? Is there an example working?
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
R2011a 中的 Simulink 支持 OMAP-L138 EVM / C6748EVM 的代码生成。在打开 Target Preferences 块之前,从 DSP/BIOS 导入处理器定义。在 MATLAB 命令行中,键入以下内容:
完成这些步骤后,您应该能够打开 Target Preferences 块并检查设置。在继续代码生成之前,运行 checkEnvSetup() 实用程序以确保您安装了代码生成所需的所有 TI 软件:
上面的命令为您提供了需要安装的内容的列表。确保您已安装上述所有软件并具有正确的版本号后,请执行以下命令:
这会设置代码生成所需的所有环境变量。 MATLAB 通过以此方式创建的环境变量查看工具的位置。
完成这些步骤后,您应该能够生成代码。
Code generation for OMAP-L138 EVM / C6748EVM is supported in Simulink in R2011a. Before opening the Target Preferences block, import the processor definitions from DSP/BIOS. On the MATLAB command line, type the following:
After these steps, you should be able to open the Target Preferences block and examine the settings. Before proceeding with code generation, run checkEnvSetup() utility to make sure that you installed all TI software required for code generation:
The command above gives you a list of what you need to install. After making sure you have all of the software installed above with correct version numbers, execute the following:
This sets all environment variables needed for code generation. MATLAB sees the location of the tools through environment variables created this way.
After these steps you should be able to generate code.
Matlab 2011a 之前的版本不支持 OMAP-L138 EVM 和 C6748 EVM 的代码生成。
对于 2011a 版本,设置过程并不简单,而且没有很好的文档记录。但 Matlab 有一个针对此版本的补丁支持并可满足某些特定要求。
版本2011b进行了改进(第三方产品与该处理器的CCStudio v4配合使用所需的超链接)并支持OMAP-L138 EVM和C6748 EVM< /em>.
对于 2012a 版本,Matlab 已考虑在文档中添加特定部分,以使用这些处理器进行配置和自动代码生成。
Code generation for OMAP-L138 EVM and C6748 EVM is not supported for older versions than Matlab 2011a.
For the release 2011a, the setup process is not trivial and it is not well documented. But Matlab has a patch for this version supports and works with certain specific requirements.
The release 2011b has improvements (hyperlinks required for products of thirds work with CCStudio v4 for this processor) and supports code generation for OMAP-L138 EVM and C6748 EVM.
For the release 2012a, Matlab has considered adding specific sections in the documentation for configuration and automatic code generation with these processors.