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.

How to allocate memory on DSP based on codec engine in DM3730

Other Parts Discussed in Thread: DM3730

Hi,

I am trying to allocate memory on dsp through Memory_alloc() function. This work is based on codec engine in DM3730, which is modified from the videnc_copy example. I made some changes in the (.tcf) file  as follows:

bios.setMemDataHeapSections (prog, bios.DDRALGHEAP);

bios.MEM.MALLOCSEG  = bios.DDRALGHEAP;

(the default setup is

bios.setMemDataHeapSections (prog, bios.DDR2);

bios.MEM.MALLOCSEG  = bios.DDR2;

)

and also in the .cfg file, change is made  as follows:

DSKT2.ALLOW_EXTERNAL_SCRATCH = true;

(the default setup is false)

And then in the videnc_copy.c file, i coded :

Memory_AllocParams allocParams;
allocParams.type = Memory_CONTIGPOOL;
allocParams.flags = Memory_NONCACHED;
allocParams.align = 128;
allocParams.seg = 0;

tempBuf2 = (XDAS_UInt8 *)Memory_alloc( minSamples, &allocParams);

I can build the files well. But the run result is wrong. FT_trace print the result

shows that the memory request failed.

How can i copy with this problem?

thks in advance!

F.H. Sun