FreeRTOS Support Archive
The FreeRTOS support forum is used to obtain active support directly from Real
Time Engineers Ltd. In return for using our top quality software and services for
free, we request you play fair and do your bit to help others too! Sign up
to receive notifications of new support topics then help where you can.
This is a read only archive of threads posted to the FreeRTOS support forum.
The archive is updated every week, so will not always contain the very latest posts.
Use these archive pages to search previous posts. Use the Live FreeRTOS Forum
link to reply to a post, or start a new support thread.
[FreeRTOS Home] [Live FreeRTOS Forum] [FAQ] [Archive Top] [January 2008 Threads] task utilizationPosted by lafleur on January 15, 2008 Is there a function that one can call to determine the approximate % utilization of the target processor and application in FreeRTOS??
if not this would be a great debug tool to add in the future...
thanks..
RE: task utilizationPosted by woops_ on January 15, 2008 Not directly but there are possibilities.
Use an idle hook to toggle a pin continuously. Then you can see on a scope the amount of time the idle task is running.
Use a tick hook to see if the current task is the idle task and keep a count of the frequence.
Use an idle hook to perform some other form of measurement.
RE: task utilizationPosted by David Hawks on January 16, 2008 If you are fortunate enough to have a spare DAC on board, you can send the current task number to the DAC on a context switch. Not only do you get % utilization, but you also get a very handy real time execution graph on your scope. Granted this increases the length of a context switch (by ten instructions for me), the visibility you gain into your system usually makes it worth the cost.
P.S. I modify the "tskTCB" structure so that "uxTCBNumber" is directly after "pxTopOfStack". That way my context switch code can easily grab the task number after reading the stack pointer.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
|