I'm migrating from DSP/BIOS to SYS/BIOS (CCSv5.2.2, BIOS 6.33.05.46, XDC Tools 3.23.03.53) and am seeing the following error in the Problems Window:
Description Resource Path Location Type
#20 identifier "Memory_alloc" is undefined DecimationFilter.cpp /Vibration Monitor/SignalProcessing line 228 C/C++ Problem
In those files where I'm seeing the above error, I have:
#include <xdc/runtime/Memory.h>
#include <xdc/runtime/System.h>
#include <ti/sysbios/BIOS.h>
#include <xdc/cfg/global.h>
The errors are referring to the following lines in each file where I'm seeing the error:
//mpPolyphaseFilters[i] = reinterpret_cast<float*>(MEM_alloc(FAST_HEAP, (mPolyphaseLength + mPolyphaseLength%2)*sizeof(float), 8));
mpPolyphaseFilters[i] = reinterpret_cast<float*>(Memory_alloc(FAST_HEAP, (mPolyphaseLength + mPolyphaseLength%2)*sizeof(float), 8, NULL));
The first line is my DSP/BIOS implementation. The second is the SYS/BIOS implementation.
For the heap handle, I have this in my .cfg file (attached - 3386.VibrationMonitor.cfg):
var HeapMem = xdc.useModule('ti.sysbios.heaps.HeapMem');
var heapMem0Params = new HeapMem.Params();
heapMem0Params.instance.name = "DDR_HEAP";
heapMem0Params.align = 8;
heapMem0Params.size = 0x00100000;
heapMem0Params.sectionName = "DDR";
//Program.global.DDR_HEAP = HeapMem.create(heapMem0Params);
var heapMem1Params = new HeapMem.Params();
heapMem1Params.instance.name = "FAST_HEAP";
heapMem1Params.align = 8;
heapMem1Params.size = 0x00010000;
heapMem1Params.sectionName = "IRAM";
//Program.global.FAST_HEAP = HeapMem.create(heapMem1Params);
What am I missing?