Other Parts Discussed in Thread: SYSBIOS
Based on setup
* : CCS 11.0 Or latest version.
* : Complier TI x20.2.6.LTS Or latest version.
* : XDCTools 3.32.2.25
* : TI-RTOS for TivaC <tirtos_tivac_2_16_01_14>
* : TivaWare_C_Series 2.1.1.71b
I wish to check heap from time to time temporary during runtime and then remove it.
I have reviewed the SPRUEX3P, page 166 mentioned about HeapTrack and
file:///E:/010_WorkAOT/011MyGit20/106-TM4C_2021/tirtos_tivac_2_16_01_14/products/bios_6_45_02_31/docs/cdoc/ti/sysbios/heaps/HeapTrack.html
I placed the code in cfg
/* ================ Kernel (SYS/BIOS) configuration ================ */ var BIOS = xdc.useModule('ti.sysbios.BIOS'); //BIOS.assertsEnabled = true; BIOS.assertsEnabled = false; /* * Specify default heap size for BIOS. */ //BIOS.heapSize = 5120; //ex 1024. 5120 for FATFS. BIOS.heapSize = 10000; //Will it fix crashes? BIOS.heapTrackEnabled = true; // RGP: 6Jan21: To debug Heap operation ,remove when not needed. BIOS.includeXdcRuntime = false; //BIOS.includeXdcRuntime = true;......
//----------------------------------------------Heap Debug #include <ti/sysbios/heaps/HeapTrack.h> // to debug heaps. See SPRUEX3T, page 166. #include <xdc/runtime/IHeap.h> #include <xdc/runtime/Memory.h> ...... HeapTrack_Handle heap; void RFD_Heap_Init(void) { //-------------------------Heap Monitor HeapTrack_Params prms; //HeapTrack_Handle heap; Error_Block eb; Error_init(&eb); HeapTrack_Params_init(&prms); prms.heap = heapHandle; heap = HeapTrack_create(&prms, &eb); if (heap == NULL) { System_abort("HeapTrack create failed"); } }
I'm not sure where "heapHandle" come from?, can u advise?
Thanks.