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

Using RTX weak functions - rt_post_taskswitch() never called

Hello

I'm doing some experiments with RTX to investigate how quickly it switches between tasks and how much of the time I can make the processor (STM32F103 sleep.

Following the advice in this thread (http://www.keil.com/forum/18158/) I've implemented a function in my code with the signature:

void rt_post_taskswitch (U32 task_id)

As I understand it, RTX should call this after a task switch however this never happens (the break point I've set in the function is never hit). I had a quick poke around the RTX source and I can see where the function is weakly declared and where it's called. Everything looks fine except my implementation of the function never gets called.

I suspect this is because the project is linking against the RTX library and unless I recompile RTX along with my project it'll never know I've implemented the function.

What's the neatest way to go about making this work?

Many thanks in advance,
Al