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.

TMS320F28379D: RAM usage, values to be added up clarification

Part Number: TMS320F28379D

I wanted to ask a few clarifications with regards to the content of the map file I have open. Could you help me identify the values that I should be adding up in this scenario? I would really appreciate it, so then I can document this in one of our internal guides. Thank you.

for Page 0 I can see RAMLS_PROG used = 0000003b

for Page 1 I can see RAMM0M1 used = 00000400

RAMLS_DATA used = 0

RAMD0D1 = 0

RAMGS_DATA = 00006ef3

MEMORY CONFIGURATION

name origin length used unused attr fill
---------------------- -------- --------- -------- -------- ---- --------
PAGE 0:
BEGIN 00000000 00000002 00000000 00000002 RWIX
RAMLS_PROG 00008000 00002000 0000003b 00001fc5 RWIX
BEGIN_FLASH 00080000 00000002 00000002 00000000 RWIX
FLASHA_N 00080002 0003fffe 0002b4be 00014b40 RWIX
RESET 003fffc0 00000002 00000000 00000002 RWIX

PAGE 1:
BOOT_RSVD 00000002 00000120 00000000 00000120 RWIX
RAMM0M1 00000122 000006de 00000400 000002de RWIX
ADCA_RESULT 00000b00 00000020 00000018 00000008 RWIX
ADCB_RESULT 00000b20 00000020 00000018 00000008 RWIX
ADCC_RESULT 00000b40 00000020 00000018 00000008 RWIX
ADCD_RESULT 00000b60 00000020 00000018 00000008 RWIX
CPU_TIMER0 00000c00 00000008 00000008 00000000 RWIX
CPU_TIMER1 00000c08 00000008 00000008 00000000 RWIX
CPU_TIMER2 00000c10 00000008 00000008 00000000 RWIX
PIE_CTRL 00000ce0 00000020 0000001a 00000006 RWIX
PIE_VECT 00000d00 00000200 000001c0 00000040 RWIX
DMA 00001000 00000200 000000e0 00000120 RWIX
CLA1 00001400 00000040 0000003e 00000002 RWIX
CLA1_MSGRAMLOW 00001480 00000080 00000000 00000080 RWIX
CLA1_MSGRAMHIGH 00001500 00000080 00000000 00000080 RWIX
EPWM1 00004000 00000100 00000100 00000000 RWIX
EPWM2 00004100 00000100 00000100 00000000 RWIX
EPWM3 00004200 00000100 00000100 00000000 RWIX
EPWM4 00004300 00000100 00000100 00000000 RWIX
EPWM5 00004400 00000100 00000100 00000000 RWIX
EPWM6 00004500 00000100 00000100 00000000 RWIX
EPWM7 00004600 00000100 00000100 00000000 RWIX
EPWM8 00004700 00000100 00000100 00000000 RWIX
EPWM9 00004800 00000100 00000100 00000000 RWIX
EPWM10 00004900 00000100 00000100 00000000 RWIX
EPWM11 00004a00 00000100 00000100 00000000 RWIX
EPWM12 00004b00 00000100 00000100 00000000 RWIX
ECAP1 00005000 00000020 00000020 00000000 RWIX
ECAP2 00005020 00000020 00000020 00000000 RWIX
ECAP3 00005040 00000020 00000020 00000000 RWIX
ECAP4 00005060 00000020 00000020 00000000 RWIX
ECAP5 00005080 00000020 00000020 00000000 RWIX
ECAP6 000050a0 00000020 00000020 00000000 RWIX
EQEP1 00005100 00000040 00000022 0000001e RWIX
EQEP2 00005140 00000040 00000022 0000001e RWIX
EQEP3 00005180 00000040 00000022 0000001e RWIX
DACA 00005c00 00000010 00000008 00000008 RWIX
DACB 00005c10 00000010 00000008 00000008 RWIX
DACC 00005c20 00000010 00000008 00000008 RWIX
CMPSS1 00005c80 00000020 00000020 00000000 RWIX
CMPSS2 00005ca0 00000020 00000020 00000000 RWIX
CMPSS3 00005cc0 00000020 00000020 00000000 RWIX
CMPSS4 00005ce0 00000020 00000020 00000000 RWIX
CMPSS5 00005d00 00000020 00000020 00000000 RWIX
CMPSS6 00005d20 00000020 00000020 00000000 RWIX
CMPSS7 00005d40 00000020 00000020 00000000 RWIX
CMPSS8 00005d60 00000020 00000020 00000000 RWIX
SDFM1 00005e00 00000080 00000080 00000000 RWIX
SDFM2 00005e80 00000080 00000080 00000000 RWIX
MCBSPA 00006000 00000040 00000024 0000001c RWIX
MCBSPB 00006040 00000040 00000024 0000001c RWIX
SPIA 00006100 00000010 00000010 00000000 RWIX
SPIB 00006110 00000010 00000010 00000000 RWIX
SPIC 00006120 00000010 00000010 00000000 RWIX
SPID 00006130 00000010 00000000 00000010 RWIX
UPP 00006200 00000100 00000048 000000b8 RWIX
WD 00007000 00000040 0000002b 00000015 RWIX
NMIINTRUPT 00007060 00000010 00000007 00000009 RWIX
XINT 00007070 00000010 0000000b 00000005 RWIX
SCIA 00007200 00000010 00000010 00000000 RWIX
SCIB 00007210 00000010 00000010 00000000 RWIX
SCIC 00007220 00000010 00000010 00000000 RWIX
SCID 00007230 00000010 00000010 00000000 RWIX
I2CA 00007300 00000040 00000022 0000001e RWIX
I2CB 00007340 00000040 00000022 0000001e RWIX
ADCA 00007400 00000080 00000080 00000000 RWIX
ADCB 00007480 00000080 00000080 00000000 RWIX
ADCC 00007500 00000080 00000080 00000000 RWIX
ADCD 00007580 00000080 00000080 00000000 RWIX
INPUT_XBAR 00007900 00000020 00000020 00000000 RWIX
XBAR 00007920 00000020 00000020 00000000 RWIX
SYNC_SOC 00007940 00000010 00000006 0000000a RWIX
DMACLASRCSEL 00007980 00000040 0000001a 00000026 RWIX
EPWM_XBAR 00007a00 00000040 00000040 00000000 RWIX
CLB_XBAR 00007a40 00000040 00000000 00000040 RWIX
OUTPUT_XBAR 00007a80 00000040 00000040 00000000 RWIX
GPIOCTRL 00007c00 00000180 00000180 00000000 RWIX
GPIODAT 00007f00 00000030 00000030 00000000 RWIX
RAMLS_DATA 0000a000 00001000 00000000 00001000 RWIX
RAMD0D1 0000b000 00001000 00000000 00001000 RWIX
RAMGS_IPCBuffCPU1 0000c000 00001000 00000000 00001000 RWIX
RAMGS_IPCBuffCPU2 0000d000 00001000 00000000 00001000 RWIX
RAMGS_DATA 0000e000 00007000 00006ef3 0000010d RWIX
CPU2TOCPU1RAM 0003f800 00000400 00000000 00000400 RWIX
CPU1TOCPU2RAM 0003fc00 00000400 00000000 00000400 RWIX
EMIF1 00047000 00000800 00000070 00000790 RWIX
EMIF2 00047800 00000800 00000070 00000790 RWIX
IPC 00050000 00000024 00000024 00000000 RWIX
FLASHPUMPSEMAPHORE 00050024 00000002 00000002 00000000 RWIX
DEV_CFG 0005d000 00000180 0000012e 00000052 RWIX
ANALOG_SUBSYS 0005d180 00000080 00000048 00000038 RWIX
CLK_CFG 0005d200 00000100 00000032 000000ce RWIX
CPU_SYS 0005d300 00000100 00000082 0000007e RWIX
ROMPREFETCH 0005e608 00000002 00000002 00000000 RWIX
DCSM_Z1 0005f000 00000030 00000024 0000000c RWIX
DCSM_Z2 0005f040 00000030 00000024 0000000c RWIX
DCSM_COMMON 0005f070 00000010 00000008 00000008 RWIX
MEMCFG 0005f400 00000080 00000080 00000000 RWIX
EMIF1CONFIG 0005f480 00000020 00000020 00000000 RWIX
EMIF2CONFIG 0005f4a0 00000020 00000020 00000000 RWIX
ACCESSPROTECTION 0005f4c0 00000040 00000040 00000000 RWIX
MEMORYERROR 0005f500 00000040 00000040 00000000 RWIX
ROMWAITSTATE 0005f540 00000002 00000002 00000000 RWIX
FLASH0_CTRL 0005f800 00000300 00000182 0000017e RWIX
FLASH0_ECC 0005fb00 00000040 00000028 00000018 RWIX
DCSM_Z1_OTP 00078000 00000020 00000020 00000000 RWIX
DCSM_Z2_OTP 00078200 00000020 00000020 00000000 RWIX

Kindest Regards

Chris

  • Hi Chris,

    I am not sure if I fully understood your question. If you requirement is to figure out the total RAM usage, you can check the MODULE SUMMARY section in the .map file. It gives the total size of data and code, along with file level breakup

    Eg:

    You may ignore the data size consumed by F2837xD_GlobalVariableDefs file. This is for peripheral register allocation, and not RAM memories.

    Regards,

    Veena

  • Thank you very much Veena, that is very useful information.

    The processor specs define two options for RAM size: 172KB (86KW) or 204KB (102KW) of RAM, which equals 176128 or 208896 bytes.

    As I am a new user, I'm looking to understand what is the limit under which I need to stay so that when my build fails then I know by how much I need to make a reduction. Any help would be appreciated.

    A build that completes ok has the following totals:

    Total:                                            201743   9802               32913

    Grand Total:                                      202431   9834               33947

    One of the builds that fails has the following totals:

    Total:                                             220298   9690               37055

    Grand Total:                                       220986   9722               38089

    Below is an example of the output when the build fails:

    "C:/ProgramData/MATLAB/SupportPackages/R2020b/toolbox/target/supportpackages/tic2000/src/c28377D.cmd", line 140: error:

    program will not fit into available memory. run placement with

    alignment/blocking fails for section ".ebss" size 0x8740 page 1. Available

    memory ranges:

    RAMGS_DATA size: 0x7000 unused: 0x0 max hole: 0x0

    RAMLS_DATA size: 0x1000 unused: 0xea6 max hole: 0xea5

    error: errors encountered during linking;

    "../RML_TMS320F28379D_SafetyCttr_Mid_Test10.out" not built

    >> Compilation failure

    gmake: *** [../RML_TMS320F28379D_SafetyCttr_Mid_Test10.out] Error 1

    C:\SvnRepository\CtrlSys\Projects\P200\EmbeddedSW\BatteryControlUnit_TI_F28379D\CodeOutput\RML_TMS320F28379D_SafetyCttr_Mid_Test10_ert_rtw>echo The make command returned an error of 2

    The make command returned an error of 2

    C:\SvnRepository\CtrlSys\Projects\P200\EmbeddedSW\BatteryControlUnit_TI_F28379D\CodeOutput\RML_TMS320F28379D_SafetyCttr_Mid_Test10_ert_rtw>exit 1

    ### Creating HTML report file RML_TMS320F28379D_SafetyCttr_Mid_Test10_codegen_rpt.html

    ### Build procedure for RML_TMS320F28379D_SafetyCttr_Mid_Test10 aborted due to an error.

    Kindest regards

    Chris

  • Hi Chris,

    You can also check the actual RAM usage across different different RAM blocks in the MEMORY CONFIGURATION tab and rearrange sections as required.

    In your case, you are getting an error for ebss allocation. The actual size of ebss is 0x8740. You can check is there are any memory ranges which has unused memory that can fit this section. You can even combine consecutive memory regions to from a larger memory region.

    For example,

       /* RAMLS4      	   : origin = 0x00A000, length = 0x000800 */
       /* RAMLS5           : origin = 0x00A800, length = 0x000800 */
       RAMLS4_5         : origin = 0x00A000,   length = 0x001000

    Reagrds,

    Veena

  • Thank you very much Veena.

    This is quite an interesting and challenging topic so I will try to arrange some time with the persons who can provide some support in combining memory regions and other tasks.

    Kindest Regards

    Chris