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.

Minimal example build using CCSv6, TI-RTOS & msp430f5438 won't run

Other Parts Discussed in Thread: MSP430F5438, SYSBIOS, CCSTUDIO, MSP430WARE

I have been using CCSv5, SYS/BIOS, & msp430f5438 for years w/o (many) problems.

I have upgraded to CCSv6, and can't get even the simplest example (minimal_MSP430F5438) to run using the new TI-RTOS.  It doesn't even get to the first line of my code (which simply sets a port output & direction to turn on an led).  I built the library for MSP430F5438 which seemed to work (completed w/o errors and created the appropriate directories).  There must be something else I am missing.

I can do this same basic thing with CCSv5 & SYS/BIOS w/o issues.

Thanks.

  • Hi,
    Are you importing an older TI-RTOS project created in CCS v5 into CCS v6? Carrying over CCS v5 and older TI-RTOS projects over to CCS v6 and a newer TI-RTOS might introduce problems. Verify that in CCS v6 you can start afresh by creating an empty project without making any changes (say minimal_MSP430F5438) from the new TI-RTOS (Let me know what version) and build and run it. Once that works, you can slowly migrate your code over.

    Let me know if this helps.

    Moses
  • Moses,

    I did create a new project from the CCSv6 TI-RTOS examples; minimal_MSP430F5438. All I changed was the port location of my led.

    I have installed tirtos_msp430_2_10_01_38 and xdctools_3_30_06_67_core. Btw, I get the following build warnings.

    Description Resource Path Location Type
    function "_get_SR_register" declared implicitly .ccsproject /minimal_MSP430F5438 line 132, external location: C:\ti6a\tirtos_msp430_2_10_01_38\products\bios_6_41_00_26\packages\ti\sysbios\family\msp430\Hwi.c C/C++ Problem
    function "_disable_interrupts" declared implicitly .ccsproject /minimal_MSP430F5438 line 133, external location: C:\ti6a\tirtos_msp430_2_10_01_38\products\bios_6_41_00_26\packages\ti\sysbios\family\msp430\Hwi.c C/C++ Problem
    function "_get_SR_register" declared implicitly .ccsproject /minimal_MSP430F5438 line 149, external location: C:\ti6a\tirtos_msp430_2_10_01_38\products\bios_6_41_00_26\packages\ti\sysbios\family\msp430\Hwi.c C/C++ Problem
    function "_enable_interrupts" declared implicitly .ccsproject /minimal_MSP430F5438 line 150, external location: C:\ti6a\tirtos_msp430_2_10_01_38\products\bios_6_41_00_26\packages\ti\sysbios\family\msp430\Hwi.c C/C++ Problem
    function "_enable_interrupts" declared implicitly .ccsproject /minimal_MSP430F5438 line 165, external location: C:\ti6a\tirtos_msp430_2_10_01_38\products\bios_6_41_00_26\packages\ti\sysbios\family\msp430\Hwi.c C/C++ Problem
    function "_disable_interrupts" declared implicitly .ccsproject /minimal_MSP430F5438 line 172, external location: C:\ti6a\tirtos_msp430_2_10_01_38\products\bios_6_41_00_26\packages\ti\sysbios\family\msp430\Hwi.c C/C++ Problem
  • Moses, perhaps the warnings are a clue to some misconfiguration.

    These functions are called in Hwi.c within a macro:

    #if defined(__ICC430__)
    __enable_interrupt();
    #else
    _enable_interrupts();
    #endif

    However, the definition is in intrinsics.h which is included in Hwi.c thusly:

    #if defined(__ICC430__)
    #include <intrinsics.h>
    #endif

    I don’t see how this works.

    Spencer

  • Spencer,

        The minimal example doesn't have any LED code. First confirm that it builds without any of your changes. If it does then we can focus our efforts on the changes you made for the LED. You can copy and paste the code changes you made to this thread so I can see if you're doing something wrong.

    Regards,

    Moses

  • It does not build w/o warnings w/o my changes. The 3 lines I added are commented out below.

    #include <xdc/std.h>
    #include <xdc/runtime/System.h>
    #include <ti/sysbios/BIOS.h>
    #include <ti/sysbios/knl/Task.h>

    //#include <msp430.h>

    Void taskFxn(UArg a0, UArg a1)
    {
    System_printf("enter taskFxn()\n");
    Task_sleep(10);
    System_printf("exit taskFxn()\n");
    }

    Int main()
    {
    // P7OUT = 0;
    // P7DIR = 0x0E;
    System_printf("enter main()\n");

    BIOS_start(); /* does not return */
    return(0);
    }
  • Without your changes it doesn't build? What error message/warnings are you getting?

    Moses
  • It builds (as in generates a hex file) but with the warnings I identified earlier. Several instances of this.

    function "_get_SR_register" declared implicitly .ccsproject /minimal_MSP430F5438 line 132, external location: C:\ti6a\tirtos_msp430_2_10_01_38\products\bios_6_41_00_26\packages\ti\sysbios\family\msp430\Hwi.c C/C++ Problem


    With or without my led additions.
  • So what compiler version are you using? You can find that by opening the project properties and under the General options as shown below:

    I just discovered that we have a known issue regarding the same warnings when building with TI v4.4 compiler. The fix will be in the next TI-RTOS release. I wasn't seeing the warnings because I was building with the v4.3.3 compiler.

    Regards,

    Moses

  • Moses, I have been using 4.4.3.

    When I switch to 4.3.3 I get an error directing me to the project.log file, here:

    !CONFIGURATION: 'com.ti.ccstudio.buildDefinitions.MSP430.Release.344093532' [Fri Mar 06 15:46:18 EST 2015]

           !TOOL: 'com.ti.ccstudio.buildDefinitions.MSP430_4.3.exe.compilerRelease.1736347807'

                  !WARNING: Unresolved option: com.ti.ccstudio.buildDefinitions.MSP430_4.3.compilerID.USE_HW_MPY

     

    When I build I get the same warnings as before (see that this is 4.3.3 compiler).

    "C:/ti6a/xdctools_3_30_06_67_core/xs" --xdcpath="C:/ti6a/tirtos_msp430_2_10_01_38/packages;C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages;C:/ti6a/tirtos_msp430_2_10_01_38/products/uia_2_00_02_39/packages;C:/ti6a/msp430/MSP430ware_1_97_00_47/driverlib/packages;C:/ti6a/msp430/MSP430ware_1_97_00_47/driverlib/packages;C:/ti6a/msp430/MSP430ware_1_97_00_47/driverlib;C:/ti6a/ccsv6/ccs_base;" xdc.tools.configuro -o configPkg -t ti.targets.msp430.elf.MSP430X -p ti.platforms.msp430:MSP430F5438 -r release –c

    "C:/ti6a/ccsv6/tools/compiler/msp430_4.3.3" --compileOptions "-g --optimize_with_debug" "../app.cfg"

    gmake[1]: Entering directory `C:/Users/Spencer Allen/workspace_v6_0/minimal_MSP430F5438/src/sysbios'

    cle430X C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages/ti/sysbios/BIOS.c ...

    "C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages/ti/sysbios/family/msp430/Hwi.c", line 132: warning: function "_get_SR_register" declared implicitly

    "C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages/ti/sysbios/family/msp430/Hwi.c", line 133: warning: function "_disable_interrupts" declared implicitly

    "C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages/ti/sysbios/family/msp430/Hwi.c", line 149: warning: function "_get_SR_register" declared implicitly

    "C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages/ti/sysbios/family/msp430/Hwi.c", line 150: warning: function "_enable_interrupts" declared implicitly

    "C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages/ti/sysbios/family/msp430/Hwi.c", line 165: warning: function "_enable_interrupts" declared implicitly

    "C:/ti6a/tirtos_msp430_2_10_01_38/products/bios_6_41_00_26/packages/ti/sysbios/family/msp430/Hwi.c", line 172: warning: function "_disable_interrupts" declared implicitly

     Spencer

  • Spencer,
    Sorry for the delay. Can you send me your project? The minimal one without your LED changes.

    Regards,
    Moses
  •  Hi,

    I have the same problem.The functions are declared in intrinsics.h. But if you work with code composer the __ICC430__ is not defined( it is defined with IAR)

    To remove the warning you have ton comment the defined

    //#if defined(__ICC430__)
    #include <intrinsics.h>
    //#endif

  •  Hi,

    I have the same problem.The functions are declared in intrinsics.h. But if you work with code composer the __ICC430__ is not defined( it is defined with IAR)

    To remove the warning you have ton comment the defined

    //#if defined(__ICC430__)
    #include <intrinsics.h>
    //#endif