2837xD_FLASH_CLA_lnk_cpu1.cmd 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178
  1. // The user must define CLA_C in the project linker settings if using the
  2. // CLA C compiler
  3. // Project Properties -> C2000 Linker -> Advanced Options -> Command File
  4. // Preprocessing -> --define
  5. #ifdef CLA_C
  6. // Define a size for the CLA scratchpad area that will be used
  7. // by the CLA compiler for local symbols and temps
  8. // Also force references to the special symbols that mark the
  9. // scratchpad are.
  10. CLA_SCRATCHPAD_SIZE = 0x100;
  11. --undef_sym=__cla_scratchpad_end
  12. --undef_sym=__cla_scratchpad_start
  13. #endif //CLA_C
  14. MEMORY
  15. {
  16. PAGE 0 :
  17. /* BEGIN is used for the "boot to SARAM" bootloader mode */
  18. BEGIN : origin = 0x080000, length = 0x000002
  19. RAMM0 : origin = 0x000122, length = 0x0002DE
  20. RAMD0 : origin = 0x00B000, length = 0x000800
  21. RAMLS0 : origin = 0x008000, length = 0x000800
  22. RAMLS1 : origin = 0x008800, length = 0x000800
  23. /* RAMLS4 : origin = 0x00A000, length = 0x000800 */
  24. /* RAMLS5 : origin = 0x00A800, length = 0x000800 */
  25. RAMLS4_5 : origin = 0x00A000, length = 0x001000
  26. RAMGS14 : origin = 0x01A000, length = 0x001000 /* Only Available on F28379D, F28377D, F28375D devices. Remove line on other devices. */
  27. RAMGS15 : origin = 0x01B000, length = 0x001000 /* Only Available on F28379D, F28377D, F28375D devices. Remove line on other devices. */
  28. RESET : origin = 0x3FFFC0, length = 0x000002
  29. /* Flash sectors */
  30. FLASHA : origin = 0x080002, length = 0x001FFE /* on-chip Flash */
  31. FLASHB : origin = 0x082000, length = 0x002000 /* on-chip Flash */
  32. FLASHC : origin = 0x084000, length = 0x002000 /* on-chip Flash */
  33. FLASHD : origin = 0x086000, length = 0x002000 /* on-chip Flash */
  34. FLASHE : origin = 0x088000, length = 0x008000 /* on-chip Flash */
  35. FLASHF : origin = 0x090000, length = 0x008000 /* on-chip Flash */
  36. FLASHG : origin = 0x098000, length = 0x008000 /* on-chip Flash */
  37. FLASHH : origin = 0x0A0000, length = 0x008000 /* on-chip Flash */
  38. FLASHI : origin = 0x0A8000, length = 0x008000 /* on-chip Flash */
  39. FLASHJ : origin = 0x0B0000, length = 0x008000 /* on-chip Flash */
  40. FLASHK : origin = 0x0B8000, length = 0x002000 /* on-chip Flash */
  41. FLASHL : origin = 0x0BA000, length = 0x002000 /* on-chip Flash */
  42. FLASHM : origin = 0x0BC000, length = 0x002000 /* on-chip Flash */
  43. FLASHN : origin = 0x0BE000, length = 0x002000 /* on-chip Flash */
  44. PAGE 1 :
  45. BOOT_RSVD : origin = 0x000002, length = 0x000120 /* Part of M0, BOOT rom will use this for stack */
  46. RAMM1 : origin = 0x000400, length = 0x000400 /* on-chip RAM block M1 */
  47. RAMLS2 : origin = 0x009000, length = 0x000800
  48. RAMLS3 : origin = 0x009800, length = 0x000800
  49. RAMGS0 : origin = 0x00C000, length = 0x001000
  50. RAMGS1 : origin = 0x00D000, length = 0x001000
  51. RAMGS2 : origin = 0x00E000, length = 0x001000
  52. RAMGS3 : origin = 0x00F000, length = 0x001000
  53. RAMGS4 : origin = 0x010000, length = 0x001000
  54. RAMGS5 : origin = 0x011000, length = 0x001000
  55. RAMGS6 : origin = 0x012000, length = 0x001000
  56. RAMGS7 : origin = 0x013000, length = 0x001000
  57. RAMGS8 : origin = 0x014000, length = 0x001000
  58. RAMGS9 : origin = 0x015000, length = 0x001000
  59. RAMGS10 : origin = 0x016000, length = 0x001000
  60. RAMGS11 : origin = 0x017000, length = 0x001000
  61. RAMGS12 : origin = 0x018000, length = 0x001000 /* Only Available on F28379D, F28377D, F28375D devices. Remove line on other devices. */
  62. RAMGS13 : origin = 0x019000, length = 0x001000 /* Only Available on F28379D, F28377D, F28375D devices. Remove line on other devices. */
  63. EMIF1_CS0n : origin = 0x80000000, length = 0x10000000
  64. EMIF1_CS2n : origin = 0x00100000, length = 0x00200000
  65. EMIF1_CS3n : origin = 0x00300000, length = 0x00080000
  66. EMIF1_CS4n : origin = 0x00380000, length = 0x00060000
  67. EMIF2_CS0n : origin = 0x90000000, length = 0x10000000
  68. EMIF2_CS2n : origin = 0x00002000, length = 0x00001000
  69. CLA1_MSGRAMLOW : origin = 0x001480, length = 0x000080
  70. CLA1_MSGRAMHIGH : origin = 0x001500, length = 0x000080
  71. }
  72. SECTIONS
  73. {
  74. /* Allocate program areas: */
  75. .cinit : > FLASHB PAGE = 0, ALIGN(4)
  76. .pinit : > FLASHB, PAGE = 0, ALIGN(4)
  77. .text : > FLASHB PAGE = 0, ALIGN(4)
  78. codestart : > BEGIN PAGE = 0, ALIGN(4)
  79. /* Allocate uninitalized data sections: */
  80. .stack : > RAMM1 PAGE = 1
  81. .ebss : > RAMLS2 PAGE = 1
  82. .esysmem : > RAMLS2 PAGE = 1
  83. /* Initalized sections go in Flash */
  84. .econst : > FLASHB PAGE = 0, ALIGN(4)
  85. .switch : > FLASHB PAGE = 0, ALIGN(4)
  86. .reset : > RESET, PAGE = 0, TYPE = DSECT /* not used, */
  87. Filter_RegsFile : > RAMGS0, PAGE = 1
  88. .em2_cs0 : > EMIF2_CS0n, PAGE = 1
  89. .em2_cs2 : > EMIF2_CS2n, PAGE = 1
  90. /* CLA specific sections */
  91. Cla1Prog : LOAD = FLASHD,
  92. RUN = RAMLS4_5,
  93. LOAD_START(_Cla1funcsLoadStart),
  94. LOAD_END(_Cla1funcsLoadEnd),
  95. RUN_START(_Cla1funcsRunStart),
  96. LOAD_SIZE(_Cla1funcsLoadSize),
  97. PAGE = 0, ALIGN(4)
  98. CLADataLS0 : > RAMLS0, PAGE=0
  99. CLADataLS1 : > RAMLS1, PAGE=0
  100. Cla1ToCpuMsgRAM : > CLA1_MSGRAMLOW, PAGE = 1
  101. CpuToCla1MsgRAM : > CLA1_MSGRAMHIGH, PAGE = 1
  102. #ifdef __TI_COMPILER_VERSION__
  103. #if __TI_COMPILER_VERSION__ >= 15009000
  104. .TI.ramfunc : {} LOAD = FLASHD,
  105. RUN = RAMD0,
  106. LOAD_START(_RamfuncsLoadStart),
  107. LOAD_SIZE(_RamfuncsLoadSize),
  108. LOAD_END(_RamfuncsLoadEnd),
  109. RUN_START(_RamfuncsRunStart),
  110. RUN_SIZE(_RamfuncsRunSize),
  111. RUN_END(_RamfuncsRunEnd),
  112. PAGE = 0, ALIGN(4)
  113. #else
  114. ramfuncs : LOAD = FLASHD,
  115. RUN = RAMD0,
  116. LOAD_START(_RamfuncsLoadStart),
  117. LOAD_SIZE(_RamfuncsLoadSize),
  118. LOAD_END(_RamfuncsLoadEnd),
  119. RUN_START(_RamfuncsRunStart),
  120. RUN_SIZE(_RamfuncsRunSize),
  121. RUN_END(_RamfuncsRunEnd),
  122. PAGE = 0, ALIGN(4)
  123. #endif
  124. #endif
  125. /* The following section definition are for SDFM examples */
  126. Filter1_RegsFile : > RAMGS1, PAGE = 1, fill=0x1111
  127. Filter2_RegsFile : > RAMGS2, PAGE = 1, fill=0x2222
  128. Filter3_RegsFile : > RAMGS3, PAGE = 1, fill=0x3333
  129. Filter4_RegsFile : > RAMGS4, PAGE = 1, fill=0x4444
  130. #ifdef CLA_C
  131. /* CLA C compiler sections */
  132. //
  133. // Must be allocated to memory the CLA has write access to
  134. //
  135. CLAscratch :
  136. { *.obj(CLAscratch)
  137. . += CLA_SCRATCHPAD_SIZE;
  138. *.obj(CLAscratch_end) } > RAMLS1, PAGE = 0
  139. .scratchpad : > RAMLS1, PAGE = 0
  140. .bss_cla : > RAMLS1, PAGE = 0
  141. .const_cla : LOAD = FLASHB,
  142. RUN = RAMLS1,
  143. RUN_START(_Cla1ConstRunStart),
  144. LOAD_START(_Cla1ConstLoadStart),
  145. LOAD_SIZE(_Cla1ConstLoadSize),
  146. PAGE = 0
  147. #endif //CLA_C
  148. }
  149. /*
  150. //===========================================================================
  151. // End of file.
  152. //===========================================================================
  153. */