Other Parts Discussed in Thread: SYSBIOS
Hello,
I am trying to implement the Load module so that we can monitor total time spent in/out of Idle. I added the following code to the relevant release.cfg file:
/* ================ Load configuration ================ */
var Load = xdc.useModule('ti.sysbios.utils.Load');
Load.taskEnabled = true;
Load.updateInIdle = true;
Load.windowInMs = 500;
Load.common$ = undefined;
Load.enableCPULoadCalc = true;
Load.minIdle = 0;
I have a Task that then calls Load_getCPULoad() periodically and uses this percentage to update a counter which is supposed to show total time spent outside of the Idle loop.
Unfortunately Load_getCPULoad() always reports 100% CPU usage, which is baffling given that the execution graph shows we are in Idle ~99% of the time. I would expect Load_getCPULoad() to return something more like 1 or 0.
I have tried other configurations as well, including setting Load.updateInIdle to false and manually calling Load_update() from the aforementioned Task. The result is the same.
Any advice is appreciated.
Thanks,
Scott