This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

FreeRTOS debugging

Hi,

I am trying to debug my code in Eclipse using J-Link. Whenever the code executes vPortStartFirstTask() in vTaskStartScheduler() the debugger stops and I can't debug my program.

It happens when this code is executed:

__asm volatile(
                " ldr r0, =__isr_vector \n" /* Locate the stack using __isr_vector table. */
                " ldr r0, [r0]          \n"
                " msr msp, r0           \n" /* Set the msp back to the start of the stack. */
                " cpsie i               \n" /* Globally enable interrupts. */
                " cpsie f               \n"
                " dsb                   \n"
                " isb                   \n"
#ifdef SOFTDEVICE_PRESENT
                /* Block kernel interrupts only (PendSV) before calling SVC */
                " mov r0, %0            \n"
                " msr basepri, r0       \n"
#endif
                " svc 0                 \n" /* System call to start first task. */
                "                       \n"
                " .align 2              \n"
#ifdef SOFTDEVICE_PRESENT
                ::"i"(configKERNEL_INTERRUPT_PRIORITY  << (8 - configPRIO_BITS))
#endif
            );

Does anybody know why this happens and how I can fix this?

Thanks in advance!

Related