lnk_msp430g2452.cmd 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. /******************************************************************************/
  2. /* lnk_msp430g2452.cmd - LINKER COMMAND FILE FOR LINKING MSP430G2452 PROGRAMS */
  3. /* */
  4. /* Usage: lnk430 <obj files...> -o <out file> -m <map file> lnk.cmd */
  5. /* cl430 <src files...> -z -o <out file> -m <map file> lnk.cmd */
  6. /* */
  7. /*----------------------------------------------------------------------------*/
  8. /* These linker options are for command line linking only. For IDE linking, */
  9. /* you should set your linker options in Project Properties */
  10. /* -c LINK USING C CONVENTIONS */
  11. /* -stack 0x0100 SOFTWARE STACK SIZE */
  12. /* -heap 0x0100 HEAP AREA SIZE */
  13. /* */
  14. /*----------------------------------------------------------------------------*/
  15. /****************************************************************************/
  16. /* SPECIFY THE SYSTEM MEMORY MAP */
  17. /****************************************************************************/
  18. MEMORY
  19. {
  20. SFR : origin = 0x0000, length = 0x0010
  21. PERIPHERALS_8BIT : origin = 0x0010, length = 0x00F0
  22. PERIPHERALS_16BIT : origin = 0x0100, length = 0x0100
  23. RAM : origin = 0x0200, length = 0x0100
  24. INFOA : origin = 0x10C0, length = 0x0040
  25. INFOB : origin = 0x1080, length = 0x0040
  26. INFOC : origin = 0x1040, length = 0x0040
  27. INFOD : origin = 0x1000, length = 0x0040
  28. FLASH : origin = 0xE000, length = 0x1FE0
  29. INT00 : origin = 0xFFE0, length = 0x0002
  30. INT01 : origin = 0xFFE2, length = 0x0002
  31. INT02 : origin = 0xFFE4, length = 0x0002
  32. INT03 : origin = 0xFFE6, length = 0x0002
  33. INT04 : origin = 0xFFE8, length = 0x0002
  34. INT05 : origin = 0xFFEA, length = 0x0002
  35. INT06 : origin = 0xFFEC, length = 0x0002
  36. INT07 : origin = 0xFFEE, length = 0x0002
  37. INT08 : origin = 0xFFF0, length = 0x0002
  38. INT09 : origin = 0xFFF2, length = 0x0002
  39. INT10 : origin = 0xFFF4, length = 0x0002
  40. INT11 : origin = 0xFFF6, length = 0x0002
  41. INT12 : origin = 0xFFF8, length = 0x0002
  42. INT13 : origin = 0xFFFA, length = 0x0002
  43. INT14 : origin = 0xFFFC, length = 0x0002
  44. RESET : origin = 0xFFFE, length = 0x0002
  45. }
  46. /****************************************************************************/
  47. /* SPECIFY THE SECTIONS ALLOCATION INTO MEMORY */
  48. /****************************************************************************/
  49. SECTIONS
  50. {
  51. .bss : {} > RAM /* GLOBAL & STATIC VARS */
  52. .data : {} > RAM /* GLOBAL & STATIC VARS */
  53. .sysmem : {} > RAM /* DYNAMIC MEMORY ALLOCATION AREA */
  54. .stack : {} > RAM (HIGH) /* SOFTWARE SYSTEM STACK */
  55. .text : {} > FLASH /* CODE */
  56. .cinit : {} > FLASH /* INITIALIZATION TABLES */
  57. .const : {} > FLASH /* CONSTANT DATA */
  58. .cio : {} > RAM /* C I/O BUFFER */
  59. .pinit : {} > FLASH /* C++ CONSTRUCTOR TABLES */
  60. .init_array : {} > FLASH /* C++ CONSTRUCTOR TABLES */
  61. .mspabi.exidx : {} > FLASH /* C++ CONSTRUCTOR TABLES */
  62. .mspabi.extab : {} > FLASH /* C++ CONSTRUCTOR TABLES */
  63. .infoA : {} > INFOA /* MSP430 INFO FLASH MEMORY SEGMENTS */
  64. .infoB : {} > INFOB
  65. .infoC : {} > INFOC
  66. .infoD : {} > INFOD
  67. /* MSP430 INTERRUPT VECTORS */
  68. .int00 : {} > INT00
  69. .int01 : {} > INT01
  70. PORT1 : { * ( .int02 ) } > INT02 type = VECT_INIT
  71. PORT2 : { * ( .int03 ) } > INT03 type = VECT_INIT
  72. USI : { * ( .int04 ) } > INT04 type = VECT_INIT
  73. ADC10 : { * ( .int05 ) } > INT05 type = VECT_INIT
  74. .int06 : {} > INT06
  75. .int07 : {} > INT07
  76. TIMER0_A1 : { * ( .int08 ) } > INT08 type = VECT_INIT
  77. TIMER0_A0 : { * ( .int09 ) } > INT09 type = VECT_INIT
  78. WDT : { * ( .int10 ) } > INT10 type = VECT_INIT
  79. COMPARATORA : { * ( .int11 ) } > INT11 type = VECT_INIT
  80. .int12 : {} > INT12
  81. .int13 : {} > INT13
  82. NMI : { * ( .int14 ) } > INT14 type = VECT_INIT
  83. .reset : {} > RESET /* MSP430 RESET VECTOR */
  84. }
  85. /****************************************************************************/
  86. /* INCLUDE PERIPHERALS MEMORY MAP */
  87. /****************************************************************************/
  88. -l msp430g2452.cmd