This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

280049 CLA code是否一定要运行在RAM里

Other Parts Discussed in Thread: C2000WARE

看了TI例程 D:\ti\c2000\C2000Ware_2_00_00_03\device_support\f28004x\examples\cla              cla_ex1_background_task

问题:

1、280049 的代码是否一定要运行在RAM里?为什么?

2、工程初始化代码中有如下:

void initCLA( void )
{
//
// Copy the program and constants from FLASH to RAM before configuring
// the CLA
//
#if defined(_FLASH)
memcpy((uint32_t *)&Cla1ProgRunStart, (uint32_t *)&Cla1ProgLoadStart,
(uint32_t)&Cla1ProgLoadSize );
memcpy((uint32_t *)&Cla1ConstRunStart, (uint32_t *)&Cla1ConstLoadStart,
(uint32_t)&Cla1ConstLoadSize );
#endif //defined(_FLASH)

EALLOW;

但是没定义_FLASH,而且没有在“cla_ex2_background_task_cla.cla”文件中指定 Cla1Task1()的运行位置。如果CLA代码要运行在RAM里,需要怎样配置呢?

3、如果要运行在RAM里,CMD文件需要怎样配置?

希望TI大神指点一下,谢谢!

  • 是,CLA一定要放在ram中运行,CLA是个协处理器,它有对应的程序RAM和data RAM, 由c28内核将这些RAM映射给CLA用
    cmd文件配置你可以参考官方提供的cmd文件:C:\ti\c2000\C2000Ware_2_00_00_03\device_support\f28004x\common\cmd