Hi,
I'm using embos for M16c with IAR.
I'm using some code from the sample of '21.0.1.3 Sample application for OS_STAT_Sample() and OS_STAT_GetLoad()', all that I want is the the whole cpu load of my all tasks.
After I got the separated cpu loads, I added them together and got a number greater than 100%, like 123%. ( I have divided the result by 10 because the unit is in 1/10 percent).
I'm curious that if it's possible? or something is wrong with my code?
There's some difference from the sample and my code. In the sample, OS_STAT_GetLoad is called in a dummy task, while in my case I call it in a task which does some stuff but with a lowest priority. (while in the sample it's called in a highest priority task.)
Thanks in advance.
Fei
I'm using embos for M16c with IAR.
I'm using some code from the sample of '21.0.1.3 Sample application for OS_STAT_Sample() and OS_STAT_GetLoad()', all that I want is the the whole cpu load of my all tasks.
After I got the separated cpu loads, I added them together and got a number greater than 100%, like 123%. ( I have divided the result by 10 because the unit is in 1/10 percent).
I'm curious that if it's possible? or something is wrong with my code?
There's some difference from the sample and my code. In the sample, OS_STAT_GetLoad is called in a dummy task, while in my case I call it in a task which does some stuff but with a lowest priority. (while in the sample it's called in a highest priority task.)
Thanks in advance.
Fei
The post was edited 1 time, last by flyingxu ().