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.
That diagnostic message says that your .text section (program code) is too big to fit into the remaining FLASH memory. Are you sure nothing about your project changed, such as the build options? Are you using the new EABI mode?
Could you generate a linker memory map file and post it? It would also be helpful to compare the map file to one generated using the old tools.
Do you mean the --printf_support option? Under CCS 5.1, for MSP430 compiler version 4.0.x, this option is under the "Library Function Assumptions" subcategory of the category "MSP430 Compiler" in the build options.
Thank you for replying. I am not sure what the new EABI mode is. I will read up about the EABI mode today at lunch. I won't be able to compare the linker memory map files until tonight. If I can't find the problem I will post the Linker memory map file and post it. Thank you again for your help. Tim
Thank You. I found the --printf_support as you stated. I just have to get use to how CCS5 presents the options vs how CCS4 presents them.
I compared both the Build and Debug options and they looked the same. I did not have a whole lot of time last night to look at this problem last night; the future Mrs. ...;)... any ways. The following is part of the Map file for the Working Build...
******************************************************************************
MSP430 Evaluation Linker PC v3.3.2
******************************************************************************
>> Linked Mon Nov 14 22:20:54 2011
OUTPUT FILE NAME: <PCviaUARTtoG2452toLCDviaSPI.out>
ENTRY POINT SYMBOL: "_c_int00" address: 0000fd20
MEMORY CONFIGURATION
name origin length used unused attr fill
---------------------- -------- --------- -------- -------- ---- --------
SFR 00000000 00000010 00000000 00000010 RWIX
PERIPHERALS_8BIT 00000010 000000f0 00000000 000000f0 RWIX
PERIPHERALS_16BIT 00000100 00000100 00000000 00000100 RWIX
RAM 00000200 00000100 000000b2 0000004e RWIX
INFOD 00001000 00000040 00000000 00000040 RWIX
INFOC 00001040 00000040 00000000 00000040 RWIX
INFOB 00001080 00000040 00000000 00000040 RWIX
INFOA 000010c0 00000040 00000000 00000040 RWIX
FLASH 0000e000 00001fe0 00001fa0 00000040 RWIX
INT00 0000ffe0 00000002 00000000 00000002 RWIX
INT01 0000ffe2 00000002 00000000 00000002 RWIX
INT02 0000ffe4 00000002 00000002 00000000 RWIX
INT03 0000ffe6 00000002 00000000 00000002 RWIX
INT04 0000ffe8 00000002 00000000 00000002 RWIX
INT05 0000ffea 00000002 00000002 00000000 RWIX
INT06 0000ffec 00000002 00000000 00000002 RWIX
INT07 0000ffee 00000002 00000000 00000002 RWIX
INT08 0000fff0 00000002 00000000 00000002 RWIX
INT09 0000fff2 00000002 00000002 00000000 RWIX
INT10 0000fff4 00000002 00000000 00000002 RWIX
INT11 0000fff6 00000002 00000000 00000002 RWIX
INT12 0000fff8 00000002 00000000 00000002 RWIX
INT13 0000fffa 00000002 00000000 00000002 RWIX
INT14 0000fffc 00000002 00000000 00000002 RWIX
RESET 0000fffe 00000002 00000002 00000000 RWIX
SECTION ALLOCATION MAP
output attributes/
section page origin length input sections
-------- ---- ---------- ---------- ----------------
.cinit 0 0000e000 00000000 UNINITIALIZED
.pinit 0 0000e000 00000000 UNINITIALIZED
.bss 0 00000200 0000004e UNINITIALIZED
00000200 00000046 main.obj (.bss)
00000246 00000004 rts430.lib : _lock.obj (.bss)
0000024a 00000004 : boot.obj (.bss)
.stack 0 0000029c 00000064 UNINITIALIZED
0000029c 00000002 rts430.lib : boot.obj (.stack)
0000029e 00000062 --HOLE--
.text 0 0000e000 00001e4a
0000e000 00000216 rts430.lib : _printfi.obj (.text:_setfield)
0000e216 000001b6 : _printfi.obj (.text:_printfi)
0000e3cc 000001b4 main.obj (.text:main)
0000e580 00000168 rts430.lib : _printfi.obj (.text:ecvt)
0000e6e8 00000160 : _printfi.obj (.text:fcvt)
0000e848 00000154 : _printfi.obj (.text:_pconv_e)
0000e99c 00000130 : fs_add.obj (.text)
0000eacc 00000100 : _printfi.obj (.text:_getarg_diouxp)
0000ebcc 000000fe : _printfi.obj (.text:_pproc_fwp)
0000ecca 000000fc : _printfi.obj (.text:_pconv_g)
0000edc6 000000f2 : _printfi.obj (.text:_pproc_diouxp)
0000eeb8 000000c6 main.obj (.text:Port_1)
0000ef7e 000000c2 rts430.lib : fs_mpy.obj (.text)
0000f040 000000ac : _printfi.obj (.text:_pproc_str)
0000f0ec 000000a6 main.obj (.text:Timer_A)
0000f192 000000a0 DOGM_Library.obj (.text:DOGM_init_lcd)
0000f232 0000009a rts430.lib : fs_div.obj (.text)
0000f2cc 00000096 : _printfi.obj (.text:_ltostr)
0000f362 00000090 : _printfi.obj (.text:_mcpy)
0000f3f2 00000086 : _printfi.obj (.text:_pproc_fge)
0000f478 00000084 : ltoa.obj (.text:ltoa)
0000f4fc 00000080 DOGM_Library.obj (.text:DOGM_init_mcp_ports)
0000f57c 0000007e rts430.lib : fs_tol.obj (.text)
0000f5fa 0000007a : _printfi.obj (.text:_ecpy)
0000f674 00000074 : _printfi.obj (.text:_pconv_f)
0000f6e8 00000068 : fs_toi.obj (.text)
0000f750 0000005c : lsr32.obj (.text:l_lsr_const)
0000f7ac 00000058 DOGM_Library.obj (.text:mcpWriteSPI2LCD)
0000f804 00000058 rts430.lib : div32u.obj (.text)
0000f85c 00000054 : atoi.obj (.text:atoi)
0000f8b0 0000004e DOGM_Library.obj (.text:DOGM_printLocation)
0000f8fe 0000004e rts430.lib : _printfi.obj (.text:_fcpy)
0000f94c 0000004c ports.obj (.text:mcpPortDir)
0000f998 0000004c ports.obj (.text:mcpPortWrite)
0000f9e4 0000004a rts430.lib : fs_cmp.obj (.text)
0000fa2e 0000004a : fs_ltof.obj (.text)
0000fa78 00000046 : fs_tou.obj (.text)
0000fabe 00000044 : _printfi.obj (.text:_pproc_fflags)
0000fb02 00000040 : div32s.obj (.text)
0000fb42 0000003a main.obj (.text:Transmit)
0000fb7c 00000038 rts430.lib : sprintf.obj (.text:sprintf)
0000fbb4 00000036 : fs_itof.obj (.text)
0000fbea 00000034 : _printfi.obj (.text:_div)
0000fc1e 00000032 delayTimerA.obj (.text:loop_delay_200ms)
0000fc50 0000002c rts430.lib : div16s.obj (.text)
0000fc7c 0000002c : lsl16.obj (.text)
0000fca8 0000002a main.obj (.text:Single_Measure_REF)
0000fcd2 00000028 rts430.lib : memccpy.obj (.text:memccpy)
0000fcfa 00000026 : mult32.obj (.text)
0000fd20 0000001e : boot.obj (.text:_c_int00_noinit_noexit)
0000fd3e 0000001e SPI.obj (.text:spiMasterInitialization)
0000fd5c 0000001a rts430.lib : sprintf.obj (.text:_outs)
0000fd76 00000018 delayTimerA.obj (.text:delayMicroseconds)
0000fd8e 00000016 rts430.lib : div16u.obj (.text)
0000fda4 00000014 : memset.obj (.text:memset)
0000fdb8 00000014 : mult16.obj (.text)
0000fdcc 00000012 main.obj (.text:ADC10_ISR)
0000fdde 00000012 rts430.lib : sprintf.obj (.text:_outc)
0000fdf0 00000012 : memcpy.obj (.text:memcpy)
0000fe02 00000012 : strlen.obj (.text:strlen)
0000fe14 00000010 : epilog.obj (.text)
0000fe24 0000000a : abs.obj (.text:abs)
0000fe2e 0000000a : fs_neg.obj (.text)
0000fe38 00000008 DOGM_Library.obj (.text:DOGM_command)
0000fe40 00000004 rts430.lib : pre_init.obj (.text:_system_pre_init)
0000fe44 00000004 : exit.obj (.text:abort)
0000fe48 00000002 : _lock.obj (.text:_nop)
.const 0 0000fe4a 00000156
0000fe4a 00000101 rts430.lib : ctype.obj (.const:_ctypes_)
0000ff4b 00000001 --HOLE-- [fill = 0]
0000ff4c 00000024 : _printfi.obj (.const:.string)
0000ff70 00000012 main.obj (.const:msg1)
0000ff82 00000012 main.obj (.const:msg2)
0000ff94 0000000c main.obj (.const:.string)
.int02 0 0000ffe4 00000002
0000ffe4 00000002 main.obj (.int02)
.int05 0 0000ffea 00000002
0000ffea 00000002 main.obj (.int05)
.int09 0 0000fff2 00000002
0000fff2 00000002 main.obj (.int09)
.reset 0 0000fffe 00000002
0000fffe 00000002 rts430.lib : boot.obj (.reset)
I did not include the Global symbols (If you need them let me know)
The following is from the non-working build...
******************************************************************************
MSP430 Linker PC v4.0.0
******************************************************************************
>> Linked Mon Nov 14 22:59:05 2011
OUTPUT FILE NAME: <PCviaUARTtoG2452toLCDviaSPI.out>
ENTRY POINT SYMBOL: "_c_int00" address: 000023bc
MEMORY CONFIGURATION
name origin length used unused attr fill
---------------------- -------- --------- -------- -------- ---- --------
SFR 00000000 00000010 00000000 00000010 RWIX
PERIPHERALS_8BIT 00000010 000000f0 00000000 000000f0 RWIX
PERIPHERALS_16BIT 00000100 00000100 00000000 00000100 RWIX
RAM 00000200 00000100 000000b6 0000004a RWIX
INFOD 00001000 00000040 00000000 00000040 RWIX
INFOC 00001040 00000040 00000000 00000040 RWIX
INFOB 00001080 00000040 00000000 00000040 RWIX
INFOA 000010c0 00000040 00000000 00000040 RWIX
FLASH 0000e000 00001fe0 0000012c 00001eb4 RWIX
INT00 0000ffe0 00000002 00000000 00000002 RWIX
INT01 0000ffe2 00000002 00000000 00000002 RWIX
INT02 0000ffe4 00000002 00000002 00000000 RWIX
INT03 0000ffe6 00000002 00000000 00000002 RWIX
INT04 0000ffe8 00000002 00000000 00000002 RWIX
INT05 0000ffea 00000002 00000002 00000000 RWIX
INT06 0000ffec 00000002 00000000 00000002 RWIX
INT07 0000ffee 00000002 00000000 00000002 RWIX
INT08 0000fff0 00000002 00000000 00000002 RWIX
INT09 0000fff2 00000002 00000002 00000000 RWIX
INT10 0000fff4 00000002 00000000 00000002 RWIX
INT11 0000fff6 00000002 00000000 00000002 RWIX
INT12 0000fff8 00000002 00000000 00000002 RWIX
INT13 0000fffa 00000002 00000000 00000002 RWIX
INT14 0000fffc 00000002 00000000 00000002 RWIX
RESET 0000fffe 00000002 00000002 00000000 RWIX
SECTION ALLOCATION MAP
output attributes/
section page origin length input sections
-------- ---- ---------- ---------- ----------------
.text 0 00000000 0000250c FAILED TO ALLOCATE
.cinit 0 0000e000 00000000 UNINITIALIZED
.pinit 0 0000e000 00000000 UNINITIALIZED
.bss 0 00000200 00000052 UNINITIALIZED
00000200 0000004a main.obj (.bss)
0000024a 00000004 rts430.lib : _lock.obj (.bss)
0000024e 00000004 : boot.obj (.bss)
.stack 0 0000029c 00000064 UNINITIALIZED
0000029c 00000002 rts430.lib : boot.obj (.stack)
0000029e 00000062 --HOLE--
.const 0 0000e000 0000012c
0000e000 00000101 rts430.lib : ctype.obj (.const:_ctypes_)
0000e101 00000001 --HOLE-- [fill = 0]
0000e102 00000024 : _printfi.obj (.const:.string)
0000e126 00000006 main.obj (.const:.string)
.int02 0 0000ffe4 00000002
0000ffe4 00000002 main.obj (.int02)
.int05 0 0000ffea 00000002
0000ffea 00000002 main.obj (.int05)
.int09 0 0000fff2 00000002
0000fff2 00000002 main.obj (.int09)
.reset 0 0000fffe 00000002
0000fffe 00000002 rts430.lib : boot.obj (.reset)
I commented out a group of code in an attempt to reduce the .text size but that did not help either.
THANK YOU for your help.
Tim
Unfortunately, the map file doesn't show what I want to see: the input sections for the output section that failed to allocate (.text). I suspect what's going on is that because 4.0.0 adds support for "long long int", which includes support in printf, just using one call to the printf family (sprintf in your case) will now have extra overhead to handle printing "long long int" numbers, even if you don't use them in your program. This increase in size from 3.3.3 to 4.0.0 is approximately 0x880 bytes. The increase in the .text size for your test case is 0x6C2, so I can easily believe that it is this increase in the overhead of printf that is pushing you over the limit. Try using --printf_support=minimal, which eliminates support for "long int" and "long long int".
I will try that tonight. The sad part is that I went from minimal to full support to remove data corruption in V 3.3.3. I will have to reconsider how I am handling the string data. Thank You for your help.
Tim
In what way is the data corrupted in 3.3.3? Does the sprintf format string rely on features of printf that are removed in --printf_support=minimal mode? If not, there is some other bug.
I have installed CCS V5.1 and I have been unable to build my old applications. I am wondering what is going on…Yes, I tried adjusting the heap size and nothing works. Any ideas?
“../lnk_msp430g2452.cmd”, line 60: error #10099-D: program will not fit into
available memory. placement with alignment fails for section “.text” size
0x250c . Available memory ranges:
FLASH size: 0x1fe0 unused: 0x1eb4 max hole: 0x1eb4
error #10010: errors encountered during linking;
also... I can't seem to find the sprintf_support