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.

TI-RTOS function relocation overflow

Other Parts Discussed in Thread: MSP430F5659, SYSBIOS, MSP430DRIVERLIB, MSP430F5529, MSP430F6459, MSP430F5527

I'm not sure if this question is for the compiler or the TI-RTOS forum, but here goes.

After enabling the UIA logger in my application *.cfg file, I get some driver functions overflow (see below).

How do I mitigate this?

I've also included my linker script.


"MSP430F5xx_6xx/ucs.c", line 176: warning #17003-D: relocation from function "privateUCSSourceClockFromDCO" to symbol "privateXT2ClockFrequency" overflowed; the 20-bit relocated address 0xf12ba is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000056, section = ".text:privateUCSSourceClockFromDCO")
"MSP430F5xx_6xx/ucs.c", line 176: warning #17003-D: relocation from function "privateUCSSourceClockFromDCO" to symbol "privateXT2ClockFrequency" overflowed; the 20-bit relocated address 0xf12bc is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x0000005a, section = ".text:privateUCSSourceClockFromDCO")
"MSP430F5xx_6xx/ucs.c", line 140: warning #17003-D: relocation from function "privateUCSSourceClockFromDCO" to symbol "privateXT1ClockFrequency" overflowed; the 20-bit relocated address 0xf12b6 is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000074, section = ".text:privateUCSSourceClockFromDCO")
"MSP430F5xx_6xx/ucs.c", line 140: warning #17003-D: relocation from function "privateUCSSourceClockFromDCO" to symbol "privateXT1ClockFrequency" overflowed; the 20-bit relocated address 0xf12b8 is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000078, section = ".text:privateUCSSourceClockFromDCO")
"MSP430F5xx_6xx/ucs.c", line 269: warning #17003-D: relocation from function "privateUCSComputeCLKFrequency" to symbol "privateXT2ClockFrequency" overflowed; the 20-bit relocated address 0xf12ba is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000034, section = ".text:privateUCSComputeCLKFrequency")
"MSP430F5xx_6xx/ucs.c", line 269: warning #17003-D: relocation from function "privateUCSComputeCLKFrequency" to symbol "privateXT2ClockFrequency" overflowed; the 20-bit relocated address 0xf12bc is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000038, section = ".text:privateUCSComputeCLKFrequency")
"MSP430F5xx_6xx/ucs.c", line 227: warning #17003-D: relocation from function "privateUCSComputeCLKFrequency" to symbol "privateXT1ClockFrequency" overflowed; the 20-bit relocated address 0xf12b6 is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000060, section = ".text:privateUCSComputeCLKFrequency")
"MSP430F5xx_6xx/ucs.c", line 227: warning #17003-D: relocation from function "privateUCSComputeCLKFrequency" to symbol "privateXT1ClockFrequency" overflowed; the 20-bit relocated address 0xf12b8 is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000064, section = ".text:privateUCSComputeCLKFrequency")
"MSP430F5xx_6xx/ucs.c", line 298: warning #17003-D: relocation from function "UCS_setExternalClockSource" to symbol "privateXT1ClockFrequency" overflowed; the 20-bit relocated address 0xf12b6 is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000002, section = ".text:UCS_setExternalClockSource")
"MSP430F5xx_6xx/ucs.c", line 298: warning #17003-D: relocation from function "UCS_setExternalClockSource" to symbol "privateXT1ClockFrequency" overflowed; the 20-bit relocated address 0xf12b8 is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x00000006, section = ".text:UCS_setExternalClockSource")
"MSP430F5xx_6xx/ucs.c", line 299: warning #17003-D: relocation from function "UCS_setExternalClockSource" to symbol "privateXT2ClockFrequency" overflowed; the 20-bit relocated address 0xf12ba is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x0000000a, section = ".text:UCS_setExternalClockSource")
"MSP430F5xx_6xx/ucs.c", line 299: warning #17003-D: relocation from function "UCS_setExternalClockSource" to symbol "privateXT2ClockFrequency" overflowed; the 20-bit relocated address 0xf12bc is too large to encode in the 16-bit field (type = 'R_MSP430X_ABS16' (15), file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>", offset = 0x0000000e, section = ".text:UCS_setExternalClockSource")
warning #10015-D: output file "scorli-fw.out" cannot be loaded and run on a target system


/* ============================================================================ */
/* Copyright (c) 2016, Texas Instruments Incorporated                           */
/*  All rights reserved.                                                        */
/*                                                                              */
/*  Redistribution and use in source and binary forms, with or without          */
/*  modification, are permitted provided that the following conditions          */
/*  are met:                                                                    */
/*                                                                              */
/*  *  Redistributions of source code must retain the above copyright           */
/*     notice, this list of conditions and the following disclaimer.            */
/*                                                                              */
/*  *  Redistributions in binary form must reproduce the above copyright        */
/*     notice, this list of conditions and the following disclaimer in the      */
/*     documentation and/or other materials provided with the distribution.     */
/*                                                                              */
/*  *  Neither the name of Texas Instruments Incorporated nor the names of      */
/*     its contributors may be used to endorse or promote products derived      */
/*     from this software without specific prior written permission.            */
/*                                                                              */
/*  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" */
/*  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,       */
/*  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR      */
/*  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR            */
/*  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,       */
/*  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,         */
/*  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; */
/*  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,    */
/*  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR     */
/*  OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,              */
/*  EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.                          */
/* ============================================================================ */

/******************************************************************************/
/* lnk_msp430f5659.cmd - LINKER COMMAND FILE FOR LINKING MSP430F5659 PROGRAMS     */
/*                                                                            */
/*   Usage:  lnk430 <obj files...>    -o <out file> -m <map file> lnk.cmd     */
/*           cl430  <src files...> -z -o <out file> -m <map file> lnk.cmd     */
/*                                                                            */
/*----------------------------------------------------------------------------*/
/* These linker options are for command line linking only.  For IDE linking,  */
/* you should set your linker options in Project Properties                   */
/* -c                                               LINK USING C CONVENTIONS  */
/* -stack  0x0100                                   SOFTWARE STACK SIZE       */
/* -heap   0x0100                                   HEAP AREA SIZE            */
/*                                                                            */
/*----------------------------------------------------------------------------*/
/* Version: 1.185                                                             */
/*----------------------------------------------------------------------------*/

/****************************************************************************/
/* Specify the system memory map                                            */
/****************************************************************************/

MEMORY
{
    SFR                     : origin = 0x0000, length = 0x0010
    PERIPHERALS_8BIT        : origin = 0x0010, length = 0x00F0
    PERIPHERALS_16BIT       : origin = 0x0100, length = 0x0100
    RAM                     : origin = 0x2400, length = 0x4000
    RAM2                    : origin = 0xF0000, length = 0xC000
    USBRAM                  : origin = 0x1C00, length = 0x0800
    INFOA                   : origin = 0x1980, length = 0x0080
    INFOB                   : origin = 0x1900, length = 0x0080
    INFOC                   : origin = 0x1880, length = 0x0080
    INFOD                   : origin = 0x1800, length = 0x0080
    FLASH                   : origin = 0x8000, length = 0x7F80
    FLASH2                  : origin = 0x10000,length = 0x78000
    INT00                   : origin = 0xFF80, length = 0x0002
    INT01                   : origin = 0xFF82, length = 0x0002
    INT02                   : origin = 0xFF84, length = 0x0002
    INT03                   : origin = 0xFF86, length = 0x0002
    INT04                   : origin = 0xFF88, length = 0x0002
    INT05                   : origin = 0xFF8A, length = 0x0002
    INT06                   : origin = 0xFF8C, length = 0x0002
    INT07                   : origin = 0xFF8E, length = 0x0002
    INT08                   : origin = 0xFF90, length = 0x0002
    INT09                   : origin = 0xFF92, length = 0x0002
    INT10                   : origin = 0xFF94, length = 0x0002
    INT11                   : origin = 0xFF96, length = 0x0002
    INT12                   : origin = 0xFF98, length = 0x0002
    INT13                   : origin = 0xFF9A, length = 0x0002
    INT14                   : origin = 0xFF9C, length = 0x0002
    INT15                   : origin = 0xFF9E, length = 0x0002
    INT16                   : origin = 0xFFA0, length = 0x0002
    INT17                   : origin = 0xFFA2, length = 0x0002
    INT18                   : origin = 0xFFA4, length = 0x0002
    INT19                   : origin = 0xFFA6, length = 0x0002
    INT20                   : origin = 0xFFA8, length = 0x0002
    INT21                   : origin = 0xFFAA, length = 0x0002
    INT22                   : origin = 0xFFAC, length = 0x0002
    INT23                   : origin = 0xFFAE, length = 0x0002
    INT24                   : origin = 0xFFB0, length = 0x0002
    INT25                   : origin = 0xFFB2, length = 0x0002
    INT26                   : origin = 0xFFB4, length = 0x0002
    INT27                   : origin = 0xFFB6, length = 0x0002
    INT28                   : origin = 0xFFB8, length = 0x0002
    INT29                   : origin = 0xFFBA, length = 0x0002
    INT30                   : origin = 0xFFBC, length = 0x0002
    INT31                   : origin = 0xFFBE, length = 0x0002
    INT32                   : origin = 0xFFC0, length = 0x0002
    INT33                   : origin = 0xFFC2, length = 0x0002
    INT34                   : origin = 0xFFC4, length = 0x0002
    INT35                   : origin = 0xFFC6, length = 0x0002
    INT36                   : origin = 0xFFC8, length = 0x0002
    INT37                   : origin = 0xFFCA, length = 0x0002
    INT38                   : origin = 0xFFCC, length = 0x0002
    INT39                   : origin = 0xFFCE, length = 0x0002
    INT40                   : origin = 0xFFD0, length = 0x0002
    INT41                   : origin = 0xFFD2, length = 0x0002
    INT42                   : origin = 0xFFD4, length = 0x0002
    INT43                   : origin = 0xFFD6, length = 0x0002
    INT44                   : origin = 0xFFD8, length = 0x0002
    INT45                   : origin = 0xFFDA, length = 0x0002
    INT46                   : origin = 0xFFDC, length = 0x0002
    INT47                   : origin = 0xFFDE, length = 0x0002
    INT48                   : origin = 0xFFE0, length = 0x0002
    INT49                   : origin = 0xFFE2, length = 0x0002
    INT50                   : origin = 0xFFE4, length = 0x0002
    INT51                   : origin = 0xFFE6, length = 0x0002
    INT52                   : origin = 0xFFE8, length = 0x0002
    INT53                   : origin = 0xFFEA, length = 0x0002
    INT54                   : origin = 0xFFEC, length = 0x0002
    INT55                   : origin = 0xFFEE, length = 0x0002
    INT56                   : origin = 0xFFF0, length = 0x0002
    INT57                   : origin = 0xFFF2, length = 0x0002
    INT58                   : origin = 0xFFF4, length = 0x0002
    INT59                   : origin = 0xFFF6, length = 0x0002
    INT60                   : origin = 0xFFF8, length = 0x0002
    INT61                   : origin = 0xFFFA, length = 0x0002
    INT62                   : origin = 0xFFFC, length = 0x0002
    RESET                   : origin = 0xFFFE, length = 0x0002
}

/****************************************************************************/
/* Specify the sections allocation into memory                              */
/****************************************************************************/

SECTIONS
{
    .bss        : {} > RAM | RAM2           /* Global & static vars              */
    .data       : {} > RAM | RAM2           /* Global & static vars              */
    .TI.noinit  : {} > RAM | RAM2           /* For #pragma noinit                */
    .sysmem     : {} > RAM                  /* Dynamic memory allocation area    */
    .stack      : {} > RAM (HIGH)           /* Software system stack             */

#ifndef __LARGE_DATA_MODEL__
    .text       : {} > FLASH                /* Code                              */
#else
    .text       : {} >> FLASH2 | FLASH      /* Code                              */
#endif
    .text:_isr  : {} > FLASH                /* ISR Code space                    */
    .cinit      : {} > FLASH | FLASH2      /* Initialization tables - modified by Boaz (was only FLASH) */
#ifndef __LARGE_DATA_MODEL__
    .const      : {} > FLASH                /* Constant data                     */
#else
    .const      : {} >> FLASH | FLASH2      /* Constant data                     */
#endif
    .cio        : {} > RAM                  /* C I/O Buffer                      */

    .pinit      : {} > FLASH                /* C++ Constructor tables            */
    .binit      : {} > FLASH                /* Boot-time Initialization tables   */
    .init_array : {} > FLASH                /* C++ Constructor tables            */
    .mspabi.exidx : {} > FLASH              /* C++ Constructor tables            */
    .mspabi.extab : {} > FLASH              /* C++ Constructor tables            */
#ifdef __TI_COMPILER_VERSION
  #if __TI_COMPILER_VERSION >= 15009000
    #ifndef __LARGE_DATA_MODEL__
    .TI.ramfunc : {} load=FLASH, run=RAM, table(BINIT)
    #else
    .TI.ramfunc : {} load=FLASH | FLASH2, run=RAM, table(BINIT)
    #endif
  #endif
#endif

    .infoA     : {} > INFOA              /* MSP430 INFO FLASH Memory segments */
    .infoB     : {} > INFOB
    .infoC     : {} > INFOC
    .infoD     : {} > INFOD

    /* MSP430 Interrupt vectors          */
    .int00       : {}               > INT00
    .int01       : {}               > INT01
    .int02       : {}               > INT02
    .int03       : {}               > INT03
    .int04       : {}               > INT04
    .int05       : {}               > INT05
    .int06       : {}               > INT06
    .int07       : {}               > INT07
    .int08       : {}               > INT08
    .int09       : {}               > INT09
    .int10       : {}               > INT10
    .int11       : {}               > INT11
    .int12       : {}               > INT12
    .int13       : {}               > INT13
    .int14       : {}               > INT14
    .int15       : {}               > INT15
    .int16       : {}               > INT16
    .int17       : {}               > INT17
    .int18       : {}               > INT18
    .int19       : {}               > INT19
    .int20       : {}               > INT20
    .int21       : {}               > INT21
    .int22       : {}               > INT22
    .int23       : {}               > INT23
    .int24       : {}               > INT24
    .int25       : {}               > INT25
    .int26       : {}               > INT26
    .int27       : {}               > INT27
    .int28       : {}               > INT28
    .int29       : {}               > INT29
    .int30       : {}               > INT30
    .int31       : {}               > INT31
    .int32       : {}               > INT32
    .int33       : {}               > INT33
    .int34       : {}               > INT34
    USCI_B2      : { * ( .int35 ) } > INT35 type = VECT_INIT
    USCI_A2      : { * ( .int36 ) } > INT36 type = VECT_INIT
    PORT4        : { * ( .int37 ) } > INT37 type = VECT_INIT
    PORT3        : { * ( .int38 ) } > INT38 type = VECT_INIT
    TIMER2_A1    : { * ( .int39 ) } > INT39 type = VECT_INIT
    TIMER2_A0    : { * ( .int40 ) } > INT40 type = VECT_INIT
    DAC12        : { * ( .int41 ) } > INT41 type = VECT_INIT
    RTC          : { * ( .int42 ) } > INT42 type = VECT_INIT
    .int43       : {}               > INT43
    PORT2        : { * ( .int44 ) } > INT44 type = VECT_INIT
    USCI_B1      : { * ( .int45 ) } > INT45 type = VECT_INIT
    USCI_A1      : { * ( .int46 ) } > INT46 type = VECT_INIT
    PORT1        : { * ( .int47 ) } > INT47 type = VECT_INIT
    TIMER1_A1    : { * ( .int48 ) } > INT48 type = VECT_INIT
    TIMER1_A0    : { * ( .int49 ) } > INT49 type = VECT_INIT
    DMA          : { * ( .int50 ) } > INT50 type = VECT_INIT
    USB_UBM      : { * ( .int51 ) } > INT51 type = VECT_INIT
    TIMER0_A1    : { * ( .int52 ) } > INT52 type = VECT_INIT
    TIMER0_A0    : { * ( .int53 ) } > INT53 type = VECT_INIT
    ADC12        : { * ( .int54 ) } > INT54 type = VECT_INIT
    USCI_B0      : { * ( .int55 ) } > INT55 type = VECT_INIT
    USCI_A0      : { * ( .int56 ) } > INT56 type = VECT_INIT
    WDT          : { * ( .int57 ) } > INT57 type = VECT_INIT
    TIMER0_B1    : { * ( .int58 ) } > INT58 type = VECT_INIT
    TIMER0_B0    : { * ( .int59 ) } > INT59 type = VECT_INIT
    COMP_B       : { * ( .int60 ) } > INT60 type = VECT_INIT
    UNMI         : { * ( .int61 ) } > INT61 type = VECT_INIT
    SYSNMI       : { * ( .int62 ) } > INT62 type = VECT_INIT
    .reset       : {}               > RESET  /* MSP430 Reset vector         */
}

/****************************************************************************/
/* Include peripherals memory map                                           */
/****************************************************************************/

-l msp430f5659.cmd

  • Please show all the build options exactly as seen by the compiler and linker.  I suspect you either do not use -vmspx, or you use --code_model=small .

    Thanks and regards,

    -George

  • Thanks George - see flags below. As far as I can tell both are set correctly.
    I'm using TI-RTOS for the MSP430F5659, so I built the driverlib locally (MSP430F5659.lib). Is this relevent?

    Compiler flags (I removed the --include_path for brevity) : -vmspx --data_model=restricted -Ooff --use_hw_mpy=F5 --define=__MSP430F5659__ --define=__TI_TIME_USES_64=1 -g --c99 --float_operations_allowed=all --gcc --printf_support=nofloat --diag_warning=225 --diag_wrap=off --display_error_number --abi=eabi --silicon_errata=CPU21 --silicon_errata=CPU22 --silicon_errata=CPU40

    Linker flags: -vmspx --data_model=restricted -Ooff --use_hw_mpy=F5 --define=__MSP430F5659__ --define=__TI_TIME_USES_64=1 -g --c99 --float_operations_allowed=all --gcc --printf_support=nofloat --diag_warning=225 --diag_wrap=off --display_error_number --abi=eabi --silicon_errata=CPU21 --silicon_errata=CPU22 --silicon_errata=CPU40 -z -m"scorli-fw.map" --heap_size=160 --stack_size=160 --cinit_hold_wdt=on -i"C:/ti/ccsv6/ccs_base/msp430/include" -i"C:/ti/ccsv6/ccs_base/msp430/lib/5xx_6xx_FRxx" -i"C:/ti/ccsv6/tools/compiler/ti-cgt-msp430_16.6.0.STS/lib" -i"C:/ti/ccsv6/tools/compiler/ti-cgt-msp430_16.6.0.STS/include" --reread_libs --diag_wrap=off --display_error_number --warn_sections --xml_link_info="scorli-fw_linkInfo.xml" --use_hw_mpy=F5 --rom_model

  • Boaz Aizenshtark said:
    After enabling the UIA logger in my application *.cfg file, I get some driver functions overflow (see below).

    You need to make sure this UIA logger code is built the same as your code.  Do that by comparing the build attributes.  You can see the build attributes of an object file or library with the object file display utility.  Here is an example.

    C:\some\dir\path>ofd430 --obj_display=none,battrs file.obj
    
    OBJECT FILE:  file.obj
    
     Build Attributes in "__TI_build_attributes"
    
        Format Version:  'A'
    
        <0>  Vendor Name:  "TI" (Texas Instruments, Inc.)
    
             Tag_File:
                Attributes:
                 Tag_Producer_Name       Assembler
                 Tag_Producer_VMajor     16         (Producer Major Version + 1)
                 Tag_Producer_VMinor     13         (Producer Minor Version + 1)
                 Tag_Producer_VPatch     1          (Producer Patch Version + 1)
                 Tag_ABI                 2          (EABI)
                 Tag_HW_MPY_ISR_INFO     1          (hw mpy interrupt safe)
                 Tag_HW_MPY_INLINE_INFO  1          (does not have hw mpy inlining)
    
        <1>  Vendor Name:  "mspabi" (ABI for the Texas Instruments MSP430 Architecture)
    
             Tag_File:
                Attributes:
                 Tag_ISA         2  (MSPX)
                 Tag_Code_Model  2  (large code)
                 Tag_Data_Model  3  (restricted large data)
                 Tag_enum_size   3  (no enums that affect object file compatibility are used)

    Focus on the lines that begin Tag_ . The Tag_Producer lines can vary. But the remaining ones need to match. These settings come from compiler command line options like --code_model.

    The utility ofd430 is supplied with the compiler. If you have CCS installed, it is located in a directory similar to ...

    C:\ti\ccsv6\tools\compiler\ti-cgt-msp430_15.12.3.LTS\bin

    I suspect the UIA logger code is built in some way that is incompatible with the rest of your project.

    Thanks and regards,

    -George

  • Hi George,

    Below are the results. The first I ran on <project_folder>/src/sysbios/bios.obj (am I suppose to locate a 'UIA.obj' file?). The second is on my main.c.

    Do you see any obvious mismatches?


    OBJECT FILE: BIOS.obj

    Build Attributes in "__TI_build_attributes"

    Format Version: 'A'

    <0> Vendor Name: "TI" (Texas Instruments, Inc.)

    Tag_File:
    Attributes:
    Tag_Producer_Name Assembler
    Tag_Producer_VMajor 17 (Producer Major Version + 1)
    Tag_Producer_VMinor 7 (Producer Minor Version + 1)
    Tag_Producer_VPatch 1 (Producer Patch Version + 1)
    Tag_ABI 2 (EABI)
    Tag_LPM_INFO 2 (has lpm instruction)
    Tag_HW_MPY_ISR_INFO 3 (not hw mpy interrupt safe due to ISR with func calls)
    Tag_HW_MPY_INLINE_INFO 1 (does not have hw mpy inlining)

    <1> Vendor Name: "mspabi" (ABI for the Texas Instruments MSP430 Architecture)

    Tag_File:
    Attributes:
    Tag_ISA 2 (MSPX)
    Tag_Code_Model 2 (large code)
    Tag_Data_Model 3 (restricted large data)
    Tag_enum_size 2 (integer (default))



    OBJECT FILE: main.obj

    Build Attributes in "__TI_build_attributes"

    Format Version: 'A'

    <0> Vendor Name: "TI" (Texas Instruments, Inc.)

    Tag_File:
    Attributes:
    Tag_Producer_Name Assembler
    Tag_Producer_VMajor 17 (Producer Major Version + 1)
    Tag_Producer_VMinor 7 (Producer Minor Version + 1)
    Tag_Producer_VPatch 1 (Producer Patch Version + 1)
    Tag_ABI 2 (EABI)
    Tag_HW_MPY_ISR_INFO 1 (hw mpy interrupt safe)
    Tag_HW_MPY_INLINE_INFO 1 (does not have hw mpy inlining)

    <1> Vendor Name: "mspabi" (ABI for the Texas Instruments MSP430 Architecture)

    Tag_File:
    Attributes:
    Tag_ISA 2 (MSPX)
    Tag_Code_Model 2 (large code)
    Tag_Data_Model 3 (restricted large data)
    Tag_enum_size 2 (integer (default))

     

  • Thanks for showing us the build attributes of those files.  We also need to see the build attribute for the file mentioned in the relocation error diagnostic ...

    Boaz Aizenshtark said:
    file = "C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib<ucs.obj>"

    First extract that file out of the library ...

    % ar430 -x C:/ti/tirtos_msp43x_2_20_00_06/products/msp430_driverlib_2_70_01_01a/driverlib/MSP430F5xx_6xx/ccs/MSP430F5659.lib ucs.obj
    

    Then inspect the build attributes ...

    % ofd430 --obj_display=none,battrs ucs.obj

    Please show these attributes in your next post.  We suspect this file is built in a way that is not compatible with the rest of your code.

    Thanks and regards,

    -George

  • Thanks George. Here is the object listing:


    OBJECT FILE: ucs.obj

    Build Attributes in "__TI_build_attributes"

    Format Version: 'A'

    <0> Vendor Name: "TI" (Texas Instruments, Inc.)

    Tag_File:
    Attributes:
    Tag_Producer_Name Assembler
    Tag_Producer_VMajor 17 (Producer Major Version + 1)
    Tag_Producer_VMinor 7 (Producer Minor Version + 1)
    Tag_Producer_VPatch 1 (Producer Patch Version + 1)
    Tag_ABI 2 (EABI)
    Tag_HW_MPY_ISR_INFO 1 (hw mpy interrupt safe)
    Tag_HW_MPY_INLINE_INFO 1 (does not have hw mpy inlining)

    <1> Vendor Name: "mspabi" (ABI for the Texas Instruments MSP430 Architecture)

    Tag_File:
    Attributes:
    Tag_ISA 2 (MSPX)
    Tag_Code_Model 2 (large code)
    Tag_Data_Model 3 (restricted large data)
    Tag_enum_size 3 (no enums that affect object file compatibility are used)

  • I thought I would be able to explain your problem once I saw all the build attributes.  Unfortunately, I cannot.  I expected to see some mismatches.  Yet everything that needs to match does match.  

    At this point, I have no choice but to ask you for a test case, so I can reproduce the problem and investigate it.  Is your system organized as a CCS project?  If so, please submit it.  Please see this post for the details.

    Thanks and regards,

    -George

  • Hi George, can I send this file directly to TI support, and not post it here? It contains proprietary code.
  • You can send the file directly to me, using the messaging system built into the forum.  Hover your mouse over my avatar or name.  A dialog box pops up.  Click on Send a Private Message.  A message compose interface comes up.  Use the paper clip icon to attach a file.

    Thanks and regards,

    -George

  • Hi Boaz,

    What compiler did you rebuild the TI-RTOS drivers with to generate the 5659 driver libraries? Did you rebuild the whole product (e.g. kernel, uia, etc.) with that version? I see that you are using ti-cgt-msp430_16.6.0.STS for the application (George gave me a peek at your project).

    Todd
  • Thanks Todd.

    Attached is my makefile - C:\ti\tirtos_msp43x_2_20_00_06\tirtos.mak. I built the drivers using the command:

    ..\xdctools_3_32_00_06_core\gmake SHELL=xdctools_3_32_00_06_core/bin/sh.exe -f tirtos.mak all

    #

    # ======== tirtos.mak ========
    #

    #
    # Set location of various cgtools
    #
    # These variables can be set here or on the command line. Paths must not
    # have spaces. If using a Windows PC, the following can be used to determine
    # a directory's DOS path (path without spaces):
    #
    # 1. Open a command prompt.
    # 2. Navigate (cd) into the directory.
    # 2. Enter the following command:
    # > for %I in (".") do echo %~sI
    #
    # The steps above should provide you with a path similar to the following:
    # Original Path: c:\Program Files (x86)\IAR Systems\Embedded Workbench 7.2
    # DOS Path: c:\PROGRA~2\IARSYS~1\EMBEDD~1.2
    #
    # The final step is to replace all backslashes '\' in the path with forward
    # slashes '/'.
    # Correct Path: c:/PROGRA~2/IARSYS~1/EMBEDD~1.2
    #
    DEFAULT_INSTALL_DIR ?= c:/ti
    CCS_COMPILERS_DIR ?= $(DEFAULT_INSTALL_DIR)/ccsv6/tools/compiler

    #
    # Enable TI-RTOS to build for CCS.
    # Set CCS_BUILD to true and modify path to toolchain
    #
    CCS_BUILD ?= true
    TI_INSTALL_DIR ?= $(CCS_COMPILERS_DIR)
    ti.targets.msp430.elf.MSP430X ?= $(TI_INSTALL_DIR)/ti-cgt-msp430_16.6.0.STS
    ti.targets.arm.elf.M4F ?= $(TI_INSTALL_DIR)/ti-cgt-arm_16.6.0.STS

    #
    # Enable TI-RTOS to build for IAR.
    # Set IAR_BUILD to true and modify path to toolchain.
    #
    # The IAR_MSP430/ARM_INSTALL_DIR must be set to point to the
    # "Embedded Workbench x.y" directory in IAR Workbench. This path MUST NOT
    # contain spaces. If using a Windows PC, see the comments above for steps to
    # get the DOS path for a directory.
    #
    IAR_BUILD ?= false
    IAR_MSP430_INSTALL_DIR ?= c:/iar
    iar.targets.msp430.MSP430X_small ?= $(IAR_MSP430_INSTALL_DIR)/430
    IAR_MSP430HEADERS ?= $(IAR_MSP430_INSTALL_DIR)/430/inc

    IAR_ARM_INSTALL_DIR ?= c:/iar
    iar.targets.arm.M4F ?= $(IAR_ARM_INSTALL_DIR)/arm
    IAR_MSP432HEADERS ?= $(IAR_ARM_INSTALL_DIR)/arm/inc/TexasInstruments

    #
    # Enable TI-RTOS to build for GCC.
    # Set GCC_BUILD to true and modify path to toolchain
    #
    GCC_BUILD ?= false
    GCC_INSTALL_DIR ?= $(CCS_COMPILERS_DIR)
    gnu.targets.arm.M4F ?= $(GCC_INSTALL_DIR)/gcc-arm-none-eabi-4_9-2015q3

    #
    # Enable TI-RTOS to build for MSP430/MSP432 devices.
    # Set MSP430_BUILD or MSP432_BUILD to false to skip building TI-RTOS for the
    # respective device family.
    #
    MSP430_BUILD ?= true
    MSP432_BUILD ?= false

    #
    # TI-RTOS and XDCTools settings
    #
    XDCTOOLS_INSTALL_DIR ?= $(DEFAULT_INSTALL_DIR)/xdctools_3_32_00_06_core
    export XDCTOOLS_JAVA_HOME ?= $(DEFAULT_INSTALL_DIR)/ccsv6/eclipse/jre

    TIRTOS_INSTALL_VER ?= tirtos_msp43x_2_20_00_06
    TIRTOS_INSTALL_DIR ?= $(DEFAULT_INSTALL_DIR)/$(TIRTOS_INSTALL_VER)
    TIDRIVERS_INSTALL_DIR ?= $(TIRTOS_INSTALL_DIR)/products/tidrivers_msp43x_2_20_00_08
    BIOS_INSTALL_DIR ?= $(TIRTOS_INSTALL_DIR)/products/bios_6_46_00_23
    UIA_INSTALL_DIR ?= $(TIRTOS_INSTALL_DIR)/products/uia_2_00_06_52

    MSP430DRIVERLIB_INSTALL_DIR ?= $(TIRTOS_INSTALL_DIR)/products/msp430_driverlib_2_70_01_01a
    MSP430GRLIB_INSTALL_DIR ?= $(TIRTOS_INSTALL_DIR)/products/msp430_grlib_2_00_00_17
    MSP430USBLIB_INSTALL_DIR ?= $(TIRTOS_INSTALL_DIR)/products/msp430_usblib_5_00_01
    MSP432DRIVERLIB_INSTALL_DIR ?= $(TIRTOS_INSTALL_DIR)/products/msp432_driverlib_3_21_00_05

    MSP430HEADERS ?= $(DEFAULT_INSTALL_DIR)/ccsv6/ccs_base/msp430/include
    MSP432HEADERS ?= $(DEFAULT_INSTALL_DIR)/ccsv6/ccs_base/arm/include

    TIRTOS_PACKAGES_DIR ?= $(TIRTOS_INSTALL_DIR)/packages
    TIDRIVERS_PACKAGES_DIR ?= $(TIDRIVERS_INSTALL_DIR)/packages
    BIOS_PACKAGES_DIR ?= $(BIOS_INSTALL_DIR)/packages
    UIA_PACKAGES_DIR ?= $(UIA_INSTALL_DIR)/packages

    #
    # To build TI-RTOS driver libraries for other MSP430 devices; simply append the
    # device names to MSP430DEVLIST (separated by commas)
    # MSP430DEVLIST := MSP430F5529,MSP430F5527,MSP430F6459,etc...
    #
    MSP430DEVLIST := MSP430F5659

    #
    # To build TI-RTOS driver libraries for other MSP432 devices; simply append the
    # device names to MSP432DEVLIST (separated by commas)
    # MSP432DEVLIST := MSP432P401R,etc...
    #
    MSP432DEVLIST := MSP432P401R

    #
    # Set XDCARGS to some of the variables above. XDCARGS are passed
    # to the XDC build engine... which will load tirtos.bld... which will
    # extract these variables and use them to determine what to build and which
    # toolchains to use.
    #
    # Note that not all of these variables need to be set to something valid.
    # Unfortunately, since these vars are unconditionally assigned, your build line
    # will be longer and more noisy than necessary (e.g., it will include CC_V5T
    # assignment even if you're just building for C64P).
    #
    # Some background is here:
    # rtsc.eclipse.org/.../Command_-_xdc
    #
    XDCARGS = \
    profile=release \
    XDCTOOLS=$(XDCTOOLS_INSTALL_DIR) \
    TIRTOS=$(TIRTOS_INSTALL_DIR) \
    TIDRIVERS=$(TIDRIVERS_INSTALL_DIR) \
    BIOS=$(BIOS_INSTALL_DIR) \
    UIA=$(UIA_INSTALL_DIR) \
    MSP430DRIVERLIB=$(MSP430DRIVERLIB_INSTALL_DIR) \
    MSP430GRLIB=$(MSP430GRLIB_INSTALL_DIR) \
    MSP430USBLIB=$(MSP430USBLIB_INSTALL_DIR) \
    MSP432DRIVERLIB=$(MSP432DRIVERLIB_INSTALL_DIR) \
    MSP430DEVLIST="$(MSP430DEVLIST)" \
    MSP432DEVLIST="$(MSP432DEVLIST)"

    ifeq ("$(CCS_BUILD)", "true")
    ifeq ("$(MSP430_BUILD)", "true")
    XDCARGS += \
    ti.targets.msp430.elf.MSP430X=$(ti.targets.msp430.elf.MSP430X) \
    MSP430HEADERS=$(MSP430HEADERS)
    endif
    ifeq ("$(MSP432_BUILD)", "true")
    XDCARGS += \
    ti.targets.arm.elf.M4F=$(ti.targets.arm.elf.M4F) \
    MSP432HEADERS=$(MSP432HEADERS)
    endif
    endif

    ifeq ("$(IAR_BUILD)", "true")
    ifeq ("$(MSP430_BUILD)", "true")
    XDCARGS += \
    iar.targets.msp430.MSP430X_small=$(iar.targets.msp430.MSP430X_small) \
    IAR_MSP430HEADERS=$(IAR_MSP430HEADERS)
    endif
    ifeq ("$(MSP432_BUILD)", "true")
    XDCARGS += \
    iar.targets.arm.M4F=$(iar.targets.arm.M4F) \
    IAR_MSP432HEADERS=$(IAR_MSP432HEADERS)
    endif
    endif

    ifeq ("$(GCC_BUILD)", "true")
    XDCARGS += \
    gnu.targets.arm.M4F=$(gnu.targets.arm.M4F) \
    MSP432HEADERS=$(MSP432HEADERS)
    endif

    export XDCARGS

    #
    # Set XDCPATH to contain necessary repositories.
    #
    XDCPATH = $(TIRTOS_PACKAGES_DIR);$(TIDRIVERS_PACKAGES_DIR);$(BIOS_PACKAGES_DIR);$(UIA_PACKAGES_DIR);
    export XDCPATH

    #
    # Set XDCOPTIONS. Use -v for a verbose build.
    #
    #XDCOPTIONS=v
    export XDCOPTIONS

    #
    # Set XDC executable command
    # Note that XDCBUILDCFG points to the tirtos.bld file which uses
    # the arguments specified by XDCARGS
    #
    XDC = $(XDCTOOLS_INSTALL_DIR)/xdc XDCARGS="$(XDCARGS)" XDCBUILDCFG=./tirtos.bld
    XS = $(XDCTOOLS_INSTALL_DIR)/xs

    #######################################################
    ## Shouldn't have to modify anything below this line ##
    #######################################################

    help:
    @ echo Makefile to build components within TI-RTOS
    @ echo goal description
    @ echo -----------------------------------------------------------------------------
    @ echo all Builds SYS/BIOS, UIA, and TI-RTOS drivers
    @ echo drivers Builds TI-RTOS drivers and other components in /packages
    @ echo bios Builds SYS/BIOS
    @ echo uia Builds UIA
    @ echo build-ccs-msp430-driverlib Builds MSP430 driverlib CCS libraries
    @ echo build-iar-msp430-driverlib Builds MSP430 driverlib IAR libraries
    @ echo clean Cleans SYS/BIOS, UIA, and TI-RTOS drivers
    @ echo clean-drivers Cleans TI-RTOS drivers and other components in /packages
    @ echo clean-bios Cleans SYS/BIOS
    @ echo clean-uia Cleans UIA
    @ echo clean-msp430-driverlib Cleans MSP430 driverlib libraries
    @ echo examplesgen Generates TI-RTOS examples and makefiles
    @ echo help Displays this description

    all: bios uia drivers product

    clean: clean-uia clean-drivers clean-bios clean-product

    product:
    @ echo building tirtos packages...
    @ $(XDC) -Pr ./packages

    clean-product:
    @ echo cleaning tirtos packages ...
    @ $(XDC) clean -Pr ./packages

    drivers:
    @ echo building tirtos drivers...
    @ $(XDCTOOLS_INSTALL_DIR)/gmake -f $(TIDRIVERS_INSTALL_DIR)/drivers.mak \
    XDC_INSTALL_DIR=$(XDCTOOLS_INSTALL_DIR) \
    BIOS_INSTALL_DIR=$(BIOS_INSTALL_DIR) \
    $(XDCARGS) -C $(TIDRIVERS_INSTALL_DIR)

    clean-drivers:
    @ echo cleaning tirtos drivers...
    @ $(XDCTOOLS_INSTALL_DIR)/gmake -f $(TIDRIVERS_INSTALL_DIR)/drivers.mak \
    XDC_INSTALL_DIR=$(XDCTOOLS_INSTALL_DIR) \
    BIOS_INSTALL_DIR=$(BIOS_INSTALL_DIR) \
    $(XDCARGS) -C $(TIDRIVERS_INSTALL_DIR) clean

    build-ccs-msp430-driverlib:
    @ $(MAKE) -C $(MSP430DRIVERLIB_INSTALL_DIR) PARTS='$(MSP430DEVLIST)' \
    IPATH='$(MSP430HEADERS)' COMPILER=ccs \
    TOOLPATH='$(ti.targets.msp430.elf.MSP430X)'

    build-iar-msp430-driverlib:
    @ $(MAKE) -C $(MSP430DRIVERLIB_INSTALL_DIR) PARTS='$(MSP430DEVLIST)' \
    IPATH='$(IAR_MSP430HEADERS)' COMPILER=iar \
    TOOLPATH='$(iar.targets.msp430.MSP430X_small)'

    clean-msp430-driverlib:
    @ $(MAKE) -C $(MSP430DRIVERLIB_INSTALL_DIR) clean

    bios:
    @ echo building bios ...
    @ $(XDCTOOLS_INSTALL_DIR)/gmake -f $(BIOS_INSTALL_DIR)/bios.mak \
    XDC_INSTALL_DIR=$(XDCTOOLS_INSTALL_DIR) \
    BIOS_SMPENABLED=0 \
    $(XDCARGS) -C $(BIOS_INSTALL_DIR)

    clean-bios:
    @ echo cleaning bios ...
    @ $(XDCTOOLS_INSTALL_DIR)/gmake -f $(BIOS_INSTALL_DIR)/bios.mak \
    XDC_INSTALL_DIR=$(XDCTOOLS_INSTALL_DIR) \
    BIOS_SMPENABLED=0 \
    -C $(BIOS_INSTALL_DIR) clean

    uia:
    @ echo building uia ...
    @ $(XDCTOOLS_INSTALL_DIR)/gmake -f $(UIA_INSTALL_DIR)/uia.mak \
    XDC_INSTALL_DIR=$(XDCTOOLS_INSTALL_DIR) \
    BIOS_INSTALL_DIR=$(BIOS_INSTALL_DIR) \
    $(XDCARGS) -C $(UIA_INSTALL_DIR)

    clean-uia:
    @ echo cleaning uia ...
    @ $(XDCTOOLS_INSTALL_DIR)/gmake -f $(UIA_INSTALL_DIR)/uia.mak \
    XDC_INSTALL_DIR=$(XDCTOOLS_INSTALL_DIR) \
    BIOS_INSTALL_DIR=$(BIOS_INSTALL_DIR) \
    -C $(UIA_INSTALL_DIR) clean

    validate-paths:
    ifneq (1, $(words $(ti.targets.msp430.elf.MSP430X)))
    $(error Toolchain path must not have spaces, please update the TI_INSTALL_DIR variable.)
    endif

    ifneq (1, $(words $(iar.targets.msp430.MSP430X_small)))
    $(error Toolchain path must not have spaces, please update the IAR_MSP430_INSTALL_DIR variable.)
    endif

    ifneq (1, $(words $(iar.targets.arm.M4F)))
    $(error Toolchain path must not have spaces, please update the IAR_ARM_INSTALL_DIR variable.)
    endif

    ifneq (1, $(words $(gnu.targets.arm.M4F)))
    $(error Toolchain path must not have spaces, please update the GCC_INSTALL_DIR variable.)
    endif

    examplesgen: validate-paths
    ifneq ("$(DEST)","")
    @ echo generating examples in $(DEST) ...
    ifeq ("$(CCS_BUILD)", "true")
    @ $(XS) examples.examplesgen \
    --productGroup="MSP430" \
    --toolchain="TI" \
    --toolchainDir="$(ti.targets.msp430.elf.MSP430X)" \
    --deviceFamily="MSP430" \
    --output="$(DEST)/examples/MSP430"

    @ $(XS) examples.examplesgen \
    --productGroup="MSP430" \
    --toolchain="TI" \
    --toolchainDir="$(ti.targets.arm.elf.M4F)" \
    --deviceFamily="MSP432" \
    --output="$(DEST)/examples/MSP432"
    endif

    ifeq ("$(IAR_BUILD)", "true")
    @ $(XS) examples.examplesgen \
    --productGroup="MSP430" \
    --toolchain="IAR" \
    --toolchainDir="$(iar.targets.msp430.MSP430X_small)" \
    --deviceFamily="MSP430" \
    --output="$(DEST)/examples/MSP430"

    @ $(XS) examples.examplesgen \
    --productGroup="MSP430" \
    --toolchain="IAR" \
    --toolchainDir="$(iar.targets.arm.M4F)" \
    --deviceFamily="MSP432" \
    --output="$(DEST)/examples/MSP432"
    endif

    ifeq ("$(GCC_BUILD)", "true")
    @ $(XS) examples.examplesgen \
    --productGroup="MSP430" \
    --toolchain="GNU" \
    --toolchainDir="$(gnu.targets.arm.M4F)" \
    --deviceFamily="MSP432" \
    --output="$(DEST)/examples/MSP432"
    endif

    @ echo ***********************************************************
    @ echo Please refer to "Examples for TI-RTOS" section in the TI-RTOS
    @ echo "Getting Started Guide" for details on how to build and load the examples
    @ echo into IAR WorkBench and CCS.
    else
    @ echo Specify destination path like this: DEST="YOURPATH". Use UNIX style path "C:/examples"
    endif

  • Can you rebuild the whole product (use the "all" rule) with that compiler version? It takes a bit (maybe 10 minutes). We built your version of TI-RTOS with ti-cgt-msp430_15.12.1.LTS. I hoping there is a versioning issue.

    Todd
  • Hi Todd,

    I'm not sure I understand - I've built both my application and TI-RTOS with ti-cgt-msp430_16.6.0.STS.

    Do you want me to build both with  ti-cgt-msp430_15.12.1.LTS and try adding the logging module?

  • I thought you had just rebuilt the drivers based on one of your comments. Looking back through it all again, I now see that you did "-f tirtos.mak all". Sorry I missed that.

    Can you try using ti-cgt-msp430_15.12.1.LTS for everything (TI-RTOS and application)? I'll try building your application here in the meantime to see if I can reproduce the problem.

    Todd

  • Sure. I'll try and update you :)
  • Hi Todd,

    I've tried it with 15.12.1.LTS (both TI-RTOS and the application were built with this compiler), but I still get the overflow warnings.

    Please advise.

  • Thanks for the update. I'll get your project building tomorrow. I hit a snag rebuilding the drivers for MSP430FR5659 that I have to resolve first.

    Todd
  • Hi Boaz,

    Ok. We have a bug in TI-RTOS. As you know, this device has RAM both high and low. We are using the default near_data build setting which is --near_data=globals. This is causing the problem. We need to have --near_data=none in the following places

    1. driverlib: in the <tirtos_install_dir>\products\msp430_driverlib_2_70_01_01a\makedefs file, add the option and rebuild it

    CFLAGS=                             \
           -vmspx                       \
           --abi=eabi                   \
           --near_data=none             \
           --code_model=large           \

    2. application settings: I'd recommend you set near_data=none also for your application (Build->MSP430 Compiler->Processor Options).

    The TI-RTOS kernel and drivers are being built with near_data=none, so no change are needed here.

    Let me know if this works for you. I was able to build without the warnings (after I commented out several graphics_ calls since I did not have the library).

    Todd

  • It worked! - Thanks Todd :)

    Out of curiosity, where are the build flags for the kernel? Is it XDC-defined?

  • Hi Boaz,

    Boaz Aizenshtark said:
    It worked!

    Great!

    Boaz Aizenshtark said:
    Out of curiosity, where are the build flags for the kernel? Is it XDC-defined?

    Yes. I'll give you the gory details since you asked:) Since the target is ti.targets.msp430.elf.MSP430X (in the Project Properties->General->RTSC page), it pulls in the buld "stuff" generated from <TI-RTOS install dir>\products\<bios version>\packages\ti\targets\msp430\elf\MSP430X.xdc module. If you look in that file, you'll see the near_data setting in the opts fields.

    The drivers use the same target logic. Driverlib does not. We added the makefiles to build the driverlib library and missed the near_data setting. We had done all of our testing with ones that placed data in lower RAM/FRAM addresses (e.g. 5529, 5969) so the issue did not show up.

    Todd