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.

Compiler/LAUNCHXL2-TMS57012: Call stack is filled with same frame entries

Part Number: LAUNCHXL2-TMS57012
Other Parts Discussed in Thread: HALCOGEN

Tool/software: TI C/C++ Compiler

Hello;

I don't know if this is the right forum for my problem but as it seems similar to the following post i am sending it here. 

https://e2e.ti.com/support/development_tools/compiler/f/343/t/594763

I have a problem when debugging in Code Composer Version: 7.2.0.00013. I generated code with FreeRTOS support using Halcogen. I created a free rtos task sending 1 byte periodically using sci api. Byte sent by the task is manipulated in an ISR triggered form GIOB[2] pin connected to User Switch A on LAUNCHXL2-TMS57012. While debugging in ISR sometimes call stack is filled with frames pointing to same address. Below image illustrates that case. When I click <...more frames...>, I see more of them and it looks like an infinitely long list of the same frame.

My compiler and linker flags are as below.

Compiler:

-mv7R4 --code_state=32 --float_support=VFPv3D16 --include_path="C:/Users/Murat/Desktop/workspace/FreeRTOS_InterruptTest" --include_path="C:/Users/Murat/Desktop/workspace/FreeRTOS_InterruptTest/include" --include_path="C:/TI/ccsv7/tools/compiler/ti-cgt-arm_16.9.4.LTS/include" -g --diag_warning=225 --diag_wrap=off --display_error_number --enum_type=packed --abi=eabi

Linker:

-mv7R4 --code_state=32 --float_support=VFPv3D16 -g --diag_warning=225 --diag_wrap=off --display_error_number --enum_type=packed --abi=eabi -z -m"FreeRTOS_InterruptTest.map" --heap_size=0x800 --stack_size=0x800 -i"C:/TI/ccsv7/tools/compiler/ti-cgt-arm_16.9.4.LTS/lib" -i"C:/TI/ccsv7/tools/compiler/ti-cgt-arm_16.9.4.LTS/include" --reread_libs --diag_wrap=off --display_error_number --warn_sections --xml_link_info="FreeRTOS_InterruptTest_linkInfo.xml" --rom_model --be32

 

Below is my code from "sys_main.c".

/* USER CODE BEGIN (0) */
/* USER CODE END */

/* Include Files */

#include "sys_common.h"

/* USER CODE BEGIN (1) */
#include "gio.h"
#include "sci.h"

#include "FreeRTOS.h"
#include "os_task.h"

/* USER CODE END */

/** @fn void main(void)
*   @brief Application main function
*   @note This function is empty by default.
*
*   This function is called after startup.
*   The user can use this function to implement the application.
*/

/* USER CODE BEGIN (2) */
static void prvInterruptTestTask( void *pvParameters );

static const TickType_t xLoopDelay = 1000 / portTICK_PERIOD_MS;
static volatile uint32 ulx = 0;

/* USER CODE END */

int main(void)
{
/* USER CODE BEGIN (3) */
BaseType_t xRet;

    gioInit();
    sciInit();

    xRet = xTaskCreate( prvInterruptTestTask, "prvInterruptTestTask",
                        128, NULL, 1, NULL );

    if( xRet != pdPASS )
        /* Task could not be created */
        while( 1 );

    /* Start Scheduler */
    vTaskStartScheduler( );

    while(1);
/* USER CODE END */

    return 0;
}


/* USER CODE BEGIN (4) */
static void prvInterruptTestTask( void *pvParameters )
{
    while(1)
    {
        sciSendByte( scilinREG,  ulx + 0x30 );
        sciSend( scilinREG, 2, "\r\n" );

        vTaskDelay( xLoopDelay );
    }
}

void gioNotification(gioPORT_t *port, uint32  bit)
{
    ulx++;

    if( ulx > 9 )
        ulx = 0;
}

/* USER CODE END */

This is my first time using interrupts with freertos tasks. Is there anything wrong with my code or there is really an issue at the compiler side?

Thanks,

Murat

  • I apologize for the delay.  This issue has been getting some internal discussion among various experts.

    Please attach the executable .out file to your next post.  Since that file extension is not accepted on the forum, please compress it into a .zip file first.

    Thanks and regards,

    -George