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.

CC2340R5: can't make systick_handler work under noRTOS kernel.

Part Number: CC2340R5

Tool/software:

Hi,

I am trying to modify the empty example code to implement a basic scheduler mechanism which supports context switching. 

To keep up the system time trying to use the systick functionality. Have modified the startup file found under the kernel specific startup folder and updated the vector table to point to syctick_handler defined in main application. configured systick using SysTick_Config for 48000 ticks to get 1 second interrupts. 

But seems like the systick_handler is never called and while debugging and adding a breakpoint to my sytick_handler it pops up an error message saying there is no code associated with line in project.out file. 

Any help would be highly appreciated. May provide the project source if needed. 

  • Hello,

    Have modified the startup file found under the kernel specific startup folder

    Is the modification only in the folder?

    If yes, then it will not have an impact on your project, since it is part of a pre-built library.

    I recommend to add this file to your project (or link to it), so that the compiler will know about the changes.

    Are any of your interrupts working in the project? (e.g. GPIO)

    Thanks,
    Toby

  • Hi Toby,

    Thank you for answering, this did solve my issue. and yes, the Interrupts were working fine. But as you said the changes in SDK were not being reflected, so had to keep the startup file in project.  

    If I may ask one more leading question here, to implement context switching I will need to have some ASM instruction, which are in an assembly script file (.S). I was having inline assemble but I need to keep'em separate for portability, how can I link this to my project in CC studio? I am a bit new to CC studio.