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.

Need Some Help: Bluetopia Stack From MSP430F5438A To MSP430F5529

Other Parts Discussed in Thread: MSP430F5529, MSP430F5438A

Hi everyone !

I have been working these last few days on using the Bluetopia library (supporting MSP430F5438A) for MSP430F5529.

My first step was to compile the sample SPPLEDemo for MSP430F5438A, which worked after some trials. But since I don't have the corresponding boards, I did not load the program. Then, I modified the program for my board with MSP430F5529, by adjusting the Hardware files. I do not want to run de SPPLEDemo in a first step, but only to run the library on my microcontroller. I must be very close to succeed but I still face a warning:

"#10247-D creating ouput section ".patch" without a SECTIONS"

I compiled in legacy COFF with TI v4.1.1 compiler. Please find attached the linker I use (I extended a bit the RAM, from 0x2400 to 0x7400, I do not know if I did correct). What does this warning mean, what is the ".patch" section ?

I also inserted the following lines of code because I had warnings related to undeclared interrupt vectors:

#pragma vector=RTC_VECTOR,PORT2_VECTOR,         \
  USCI_B1_VECTOR,TIMER1_A1_VECTOR,DMA_VECTOR,      \
  TIMER0_A1_VECTOR,TIMER0_A0_VECTOR,TIMER2_A1_VECTOR,TIMER2_A0_VECTOR,USB_UBM_VECTOR,ADC12_VECTOR,COMP_B_VECTOR,             \
  USCI_B0_VECTOR,USCI_A0_VECTOR,WDT_VECTOR,TIMER0_B1_VECTOR,TIMER0_B0_VECTOR,  \
  UNMI_VECTOR,SYSNMI_VECTOR
__interrupt void ISR_trap(void)
{
  // the following will cause an access violation which results in a PUC reset
  WDTCTL = 0;
}

When I start debugging, the program is being loaded on the chip. I see every interrupt vector being loaded to the memory untill I see the image below. The window freezes for half a second and then the program stops being loaded. It looks communication is lost with the microcontroller. The IDE enters debug mode but the PLAY button is already pushed. When I pause, I don't see anything from the chip. The PC is set to 0xFFFFE and if I enter a random value in the program, it fastly jumps back to 0xFFFFE.

Fig1 - Window frozen for half a second

Fig2 - Program loading very quiclky (too quickly to be true)

Since #10247-D is only a warning, may the problem be due to an error in my source code ?

I use the 90-days trial version of CCS5 (I think it is 5.2) with no code size limit.

Thank you very much for your help.

Corentin

  • Good morning,

    I am sorry for insisting.

    Does anyone understand where does the warning "#10247-D creating ouput section ".patch" without a SECTIONS" come from and what a ".patch" section mean ?

    Should I work on understanding how a linker exactly works or may the problem come from another source ?

    Thank you very much for your help.

    Corentin

  • Hi,

    any idea ?

    Corentin

  • Corentin


    That .patch is used to locate the patch in data20 memory.  All of the CCS projects have custom linker files (lnk_msp430f5438a.cmd) that define this in the Sections part of the linker file.  See below for an example:


        .patch     : {} > FLASH2
    


  • Corentin ALTEPE said:
    Since #10247-D is only a warning, may the problem be due to an error in my source code ?

    While #10247-D is only a warning, it means the linker may place the section in the wrong area of memory and thus can lead to a runtime failure - see Should linker warning #10247-D really be an error

    Looking at one example SPPLEDdemo project shows that the lnk_msp430f5438a.cmd linker command file had been edited to add the following line for the .patch section:

      .patch : {} > FLASH2
    When the device type is changed to a MSP430F5529 CCS adds a default lnk_msp430f5529.cmd linker command file which doesn't have the .patch section, which you have to manually add (as already mentioned by Tim C.)

  • Thank you very much for your answer Chester,

    I indeed hadn't paid attention to the linker in the example code. I was only comparing the default linkers of F5438A and F5529 used by CSS.

    Thank you again.

    Corentin

**Attention** This is a public forum