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.

CC2640R2F: Custom OAD app build fails when moving linker command file from SDK folder into project folder

Part Number: CC2640R2F

[This might be better placed in the CCS forum, but the Select a forum dropdown does not provide other options.]

We have a product based on the simple peripheral OAD example, using CCS v10.2.0.00009, SDK v5.10.00.02.  We have customized the linker command file for the product.  The linker command file is in the SDK install directory in C:\ti\simplelink_cc2640r2_sdk_5_10_00_02\source\ti\blestack\common\cc26xx\ccs.

We would like to place the custom file under source control, so would like to move it within the project directory, the first thought being to place it in the TOOLS folder.

After placing the file in the TOOLS folder, and removing the entry from the Build\Arm Linker\File Search Path property, the link fails with these errors:

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
"../TOOLS/app_oad.cmd", line 257: error #10104: undefined symbol "ICALL_STACK0_START" used in expression
"configPkg/linker.cmd", line 613: warning #10096-D: specified address lies outside memory map
error #10264: DEFAULT memory range overlaps existing memory range GPRAM
error #10264: DEFAULT memory range overlaps existing memory range SRAM
"../TOOLS/app_oad.cmd", line 318: error #10099-D: program will not fit into available memory. placement with alignment fails for section "GROUP_3" size 0xd874 . Available memory ranges:
FLASH size: 0xffffffffffffff98 unused: 0xffffffffffffff98 max hole: 0xffffffffffffff98
"../TOOLS/app_oad.cmd", line 327: error #10099-D: program will not fit into available memory. placement with alignment fails for section ".cinit" size 0x3a3 . Available memory ranges:
FLASH size: 0xffffffffffffff98 unused: 0xffffffffffffff98 max hole: 0xffffffffffffff98
error #10010: errors encountered during linking; "app_oad_offchip_FlashROM_unsecure.out" not built
>> Compilation failure
makefile:223: recipe for target 'app_oad_offchip_FlashROM_unsecure.out' failed
gmake[1]: *** [app_oad_offchip_FlashROM_unsecure.out] Error 1
makefile:216: recipe for target 'all' failed
gmake: *** [all] Error 2
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

The file itself is fine and the firmware builds correctly if the file is left in the SDK install folder.  I have not seen any documentation about adjustments that need to be made when moving the linker command file to a different location, and another post where the questioner also mentioned placing the linker command file under source control indicated that placing the file into the project directory was possible.

Any info on what I'm overlooking would be appreciated.

  • Hi Tony,

    Passing this onto our OAD expert to weigh in.

  • Hey Tony,

    Did you happen to replace the entry in File Search Path with the new location of your custom .cmd files? I see the first error shows an undefined symbol.

  • Apparently as I was trying different arrangements to get the build to work, I had some error in the particular setup that should have worked.  I had seen that originally there was a shortcut to cc26xx_app_oad.cmd in the TOOLS folder, excluded from the build.  I deleted this shortcut.  After placing the custom .cmd file in the TOOLS folder, what I thought I had done was change the path in the entry in the File Search Path list to the project TOOLS folder and exclude the file from the build in the Project Explorer view.  I must have had something else out of place for that test, because doing the same thing just worked.  (I had changed the path back to the SDK folder so I could release some binaries since the original post).

    So somewhere along the line in earlier testing, I must have had something out of place.  The steps that worked were to 1) remove the shortcut/resource link to the original .cmd file from the TOOLS directory; 2) place the custom .cmd file in the TOOLS directory; 3) update the path to the file in the File Search Path list to ${PROJECT_LOC}/TOOLS; 4) exclude the file from the build as it appears in the Project Explorer view.

    In the most recent failure, I had tried removing the entry from the File Search Path completely, and left the .cmd file in the TOOLS directory included in the build, which results in errors.

    Thanks for your help.

  • Glad you were able to get this working!