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.

CLA C Compiler and Scratchpad F28035

Other Parts Discussed in Thread: CONTROLSUITE

Hey all,


I presently have an ISR that is written in C that is running on the main C28x processor of an F28035 micro.  Unfortunately it is getting to the point that the ISR takes up the majority of the clock cycles between ISR calls.  I was hoping to reduce the C28x processor burden by moving some of the functionality over to the CLA.  Running custom C code on the CLA on a 28035 isn't very well documented for CCS 6.1.3.  As far as I can tell I need to manually setup a scratch pad since the compiler doesn't automatically allocate one. I haven't found any examples for the F28035 micro about how to do this. 

The closest thing I've seen is the CLA C Digital Power Library v 3.5 reference.  This is based off of DP Library functions and it makes no mention of a scratchpad and the associated example code doesn't provide a sample linker file. I'm guessing the code is written in such a way it doesn't require a scratchpad.  I'm just trying to fully understand what I need to do in terms of getting code up and running on the CLA.


Based on the wiki page it looks like I just need to add the following line to my linker.

.scratchpad     : > CLARAM1,  PAGE = 1


Any clarification would be helpful. Thanks!


Lance

  • Hi Lance,

    there are several examples for the 28035 in controlsuite, C:\ti\controlSUITE\device_support\f2803x\v130\DSP2803x_examples_cla_ccsv5

    Even though the examples were written on ccs5 you can import them into ccs6 without issue. As far as the scratchpad goes, yes you do have to define it in the linker command file and assign it to either of RAMLS0,1 and then transfer ownership of that RAM block to the CLA (in the MMEMCFG register).

  • Hi Vishal,

    Those examples are definitely. I also found the appropriate example linker file to use as a reference located at:
    C:\ti\controlSUITE\device_support\f2803x\v130\DSP2803x_common\cmd\F28035_CLA_C.cmd

    I think that should be enough to get me moving forward. Thanks for the help.

    Regards,

    Lance