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.

CCS does not compile SampleBLEPeripheral

Other Parts Discussed in Thread: CC2650

Hi
I am planning to use TIs CC2650 for making a Bluetooth UART bridge. When I compile the example project SimpleBLEPeripheral using CCS ver 6.1 I get a build error. The build log is attached. Am I doing something wrong because my belief is that a sample project is supposed to compile off the bat.

BuildLog.txt
**** Build of configuration FlashROM for project SimpleBLEPeripheral ****

"C:\\TI\\ccsv6\\utils\\bin\\gmake" -k all 
'Building file: C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/SimpleBLEPeripheral/CC26xx/CCS/Config/appBLE.cfg'
'Invoking: XDCtools'
"C:/TI/xdctools_3_30_06_67_core/xs" --xdcpath="C:/TI/tirtos_simplelink_2_11_01_09/packages;C:/TI/tirtos_simplelink_2_11_01_09/products/bios_6_41_02_41/packages;C:/TI/tirtos_simplelink_2_11_01_09/products/uia_2_00_02_39/packages;C:/TI/ccsv6/ccs_base;" xdc.tools.configuro -o configPkg -t ti.targets.arm.elf.M3 -p ti.platforms.simplelink:CC2640F128 -r release -c "C:/TI/ccsv6/tools/compiler/ti-cgt-arm_5.2.4" --compileOptions "-mv7M3 --code_state=16 --abi=eabi -me -O4 --opt_for_speed=0 --include_path=\"C:/TI/ccsv6/tools/compiler/ti-cgt-arm_5.2.4/include\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/SimpleBLEPeripheral/CC26xx/Source/Application\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/include\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/ICall/Include\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/Profiles/Roles/CC26xx\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/Profiles/Roles\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/Profiles/DevInfo\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/Profiles/SimpleProfile/CC26xx\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/Profiles/SimpleProfile\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/common/cc26xx\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/applib/heap\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/ble/hci\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/ble/controller/CC26xx/include\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/ble/host\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/hal/target/CC2650TIRTOS\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/hal/target/_common/cc26xx\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/hal/include\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/osal/include\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/services/sdata\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/services/saddr\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/icall/include\" --include_path=\"C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Components/ble/include\" --include_path=\"C:/ti/tirtos_simplelink_2_11_01_09/products/cc26xxware_2_20_06_14829\" --include_path=\"C:/ti/tirtos_simplelink_2_11_01_09/packages/ti/boards/SRF06EB/CC2650EM_7ID\" -g --gcc --define=USE_ICALL --define=POWER_SAVING --define=SBP_TASK_STACK_SIZE=700 --define=GAPROLE_TASK_STACK_SIZE=520 --define=HEAPMGR_SIZE=2672 --define=TI_DRIVERS_SPI_DMA_INCLUDED --define=TI_DRIVERS_LCD_INCLUDED --define=ICALL_MAX_NUM_TASKS=3 --define=ICALL_MAX_NUM_ENTITIES=6 --define=xdc_runtime_Assert_DISABLE_ALL --define=xdc_runtime_Log_DISABLE_ALL --define=MAX_NUM_BLE_CONNS=1 --define=CC26XXWARE --define=CC26XX --define=ccs --define=__TI_COMPILER_VERSION=1 --define=DEBUG --display_error_number --diag_suppress=48 --diag_warning=225 --diag_wrap=off --gen_func_subsections=on " "C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/SimpleBLEPeripheral/CC26xx/CCS/Config/appBLE.cfg"
making package.mak (because of config.bld) ...
configuring appBLE.xem3 from package/cfg/appBLE_pem3.cfg ...
generating custom ROM library makefile ... 
Starting build of library sources ...
making C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/SimpleBLEPeripheral/CC26xx/CCS/Config/src/sysbios/sysbios.aem3 ...
gmake[1]: Entering directory `C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/SimpleBLEPeripheral/CC26xx/CCS/Config/src/sysbios'
Preprocessing library source files ...
_main: memory allocation error during startup.
_main: memory allocation error during startup.
gmake[1]: *** [mangled_ti.sysbios.family.arm.m3.TaskSupport_config_lib.pp] Error 127
gmake[1]: *** Waiting for unfinished jobs....
gmake[1]: *** [mangled_arm_cc26xx_Power_lib.pp] Error 127
gmake[1]: Leaving directory `C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/SimpleBLEPeripheral/CC26xx/CCS/Config/src/sysbios'
gmake: *** [C:/TI/simplelink/ble_cc26xx_2_00_00_42893/Projects/ble/SimpleBLEPeripheral/CC26xx/CCS/Config/src/sysbios/sysbios.aem3] Error 2
Build of libraries failed.
error: xdc.cfg.SourceDir: "C:/TI/xdctools_3_30_06_67_core/packages/xdc/cfg/SourceDir.xs", line 184: xdc.cfg.SourceDir : Build of generated source libraries failed: exit status = 2:

js: "C:/TI/xdctools_3_30_06_67_core/packages/xdc/cfg/Main.xs", line 160: Error: Configuration failed!
gmake.exe: *** [package/cfg/appBLE_pem3.xdl] Error 1
gmake.exe: *** Deleting file `package/cfg/appBLE_pem3.xdl'
gmake.exe: *** [package/cfg/appBLE_pem3.xdl] Deleting file `package/cfg/appBLE_pem3.h'
gmake.exe: *** [package/cfg/appBLE_pem3.xdl] Deleting file `package/cfg/appBLE_pem3.c'
js: "C:/TI/xdctools_3_30_06_67_core/packages/xdc/tools/Cmdr.xs", line 51: Error: xdc.tools.configuro: configuration failed due to earlier errors (status = 2); 'linker.cmd' deleted.
gmake: *** [configPkg/linker.cmd] Error 1
gmake: Target `all' not remade because of errors.

**** Build Finished ****

  • Hi Gautham,
    You are right, it should compile right out of the box if you have the proper components installed and it looks like you do. How did you import and build the project? via Resource Explorer? Also, do you have any other make utilities installed (maybe from another software package)?

    Thanks
    ki
  • Ki. Thanks for confirming that.
    I imported the project from Project Explorer -> Right click -> Import. I have ticked the option to copy the projects into local workspace where I can isolate my changes. One thing I notice now is that I have multiple versions of XDCtools and TIRTOS installed. Should I remove them?
    I have full license IAR for ARM installed as well. The problem begins when I try to open the eww file in IAR. I get an error message "Broken Options were detected in the project file. A backup copy will be made (See log window for details)". If I still continue on IAR the APP and stack are loaded. When I try to compile I get the build fail with the below message

    Building configuration: CC2640App - FlashROM
    Updating build tree...
    Variable expansion failed for Pre-Build command line.
    Offending text: ""$XDCROOT$/xs" --xdcpath="$XDCPATH$" iar.tools.configuro -c "$TOOLKIT_DIR$" --cc "$COMPILER_PATH$" --device "$DEVICE$" --compileOptions $COMPILER_ARGS_ROOT_QUOTED$ --linkOptions
    $LINKER_ARGS_QUOTED$ --profile release --projFile "$PROJ_PATH$""

    Total number of errors: 1
    Total number of warnings: 0
  • Can you try using the Resource Explorer? That is what I have been using and it build out of the box for me. Looking at your build output, it looks like the correct versions of the tools are being used so I think you are ok there.
  • I am confused about the resource explorer as it is my first experience with CCS. I tried the online version of Resource explorer with Cloud CCS. I was able to compile it online and was also able to download it onto the target SmartRF06 board with CC2650. However it stopped running.

    I still am unable to run the resource explorer on CCS. It leads me to a wiki page and I do not have an option to import.
  • If you go to 'Project -> Examples..', It should open the Resource Explorer and you should be able to browse through all examples in the project. This assumes the BLE-SDK package was detected by CCS (it should have found this if you installed it in the default):


  • Ki I do not seem to have that option. My screenshot is below. I do not have Project-> Examples. However I have the TI resource explorer open but I do not see what you see. It would be great if we can talk. This is taking far too long.

  • Your screenshot did not come through. Can you repost?

    Thanks
    ki
  • If you go to 'Project -> Examples..', It should open the Resource Explorer and you should be able to browse through all examples in the project. This assumes the BLE-SDK package was detected by CCS (it should have found this if you installed it in the default):

  • I have sent you the screenshot in my next reply. I am still awaiting your inputs.
  • Gautham Karnik said:
    The build log is attached.

    The build log is showing the following errors:

    _main: memory allocation error during startup.

    From a quick search think this error might be coming from gmake.

    Can you follow the advice in http://processors.wiki.ti.com/index.php/Mklib?keyMatch=cygwin&tisearch=Search-EN#MKS_or_Cygwin_or_gmake_tools_in_your_path to check if there are any instances of sh.exe or gmake.sh in your path from programs other than CCS.

    If there are sh.exe or gmake.exe in your path other than CCS, can you try removing them from the path to see if that changes the error?

  • Hi Ki

    Back again on this forum to address my compiling issues with CCS.

    I was in touch with the applications group and they led me to this forum to figure out if there are any issues with CCS installation. Unfortunately I do not have all the conversation I had with the other forum. However, I have attached some of the screenshots for you to look at what I am seeing.

    I am trying to compile the SimpleBLEperipheral after reinstalling CCS and the TI stack. However, in spite of all this I am still unable to compile. Please look at my screenshots in the order Pic1 .. Pic21... to get a picture of what I am facing.

    ThanksAll screenshots.zip

  • Your CCS installation looks fine. And the versions of CCS, RTOS, XDC and BLE SDK should all work well together. I just tried it in my environment and it worked fine.

    The errors you are seeing are related to the generation of the rtos lib. Try clearing out any generated source and try to build again. Basically delete the whole 'src' folder in:

    .\ble_cc26xx_2_01_00_44423\Projects\ble\SimpleBLEPeripheral\CC26xx\CCS\Config\

    Thanks
    ki