Monitoring the CPU Usage of a LabVIEW Real-Time Target
Downloads
Filename: rt_cpu_usage_71.llb
Requirements: View
Filename: rt_cpu_usage_820.zip
Requirements: View
Filename: rt_cpu_usage_8.0.llb
Requirements: View
Filename: rt_cpu_usage_70.zip
Requirements: View
These debugging utility VIs for the LabVIEW Real-Time Module ETS allow a user to view CPU usage information per priority, thread, and overall. This provides programmatic access to information similar to that provided by the Real-Time System Manager. The attached library includes examples illustrating how to use the functions. Please refer to the Context Help for documentation of the individual functions. Overhead is added to the system when logging CPU information is enabled; therefore it is recommended that logging be disabled when it is not being used.
Notes:
You will notice that even when no applications are running, this VI shows between 10%-30% of CPU usage (100% on FieldPoint). This is due to processes running in the background at low priorities. If you run a time-critical task, you will still have 100% of the processor available.
Time-critical priority tasks preempt these low priority processes. Therefore, a VI set to time-critical priority receives 100% of the CPU resources.
The LabVIEW RT 7.0 VIs will only run on PXI controller targets and do not provide priority or thread information.
When using the LabVIEW RT 7.0 VIs, logging is always enabled and the overhead will always be present when they are loaded into memory.
Requirements
Filename: rt_cpu_usage_71.llb
Software Requirements
Application Software: LabVIEW Full Development System 7.1
Toolkits and Add-Ons: LabVIEW Real-Time Module 7.1
Language(s): LabVIEW
Hardware Requirements
Hardware Group: Real-Time (RT)
Software Requirements
Application Software: LabVIEW Full Development System 8.2
Toolkits and Add-Ons: LabVIEW Real-Time Module 8.2
Language(s): LabVIEW
Hardware Requirements
Hardware Group: Real-Time (RT)
Software Requirements
Application Software: LabVIEW Full Development System 8.0
Toolkits and Add-Ons: LabVIEW Real-Time Module 8.0
Language(s): LabVIEW
Hardware Requirements
Hardware Group: Real-Time (RT)
Software Requirements
Application Software: LabVIEW Full Development System 7.0
Toolkits and Add-Ons: LabVIEW Real-Time Module 7.0
Language(s): LabVIEW
Hardware Requirements
Hardware Group: Real-Time (RT)
Reader Comments | Submit a comment »
I'm trying this in an sbRIO board and LV
2009.
The simple CPU usage vi returns 100%.
The RT CPU usage vi returns
approximately 12% in total and this
doesn't seem to change when I add load
to the processor.
The RT task manager returns 100%.
I'm not sure of what should I believe and
how to really measure this...
I downloaded the 8.5 version and just
compiled it in LV2009.
- Paulo Martins, Fibersensing. paulo.martins@fibersensing.com - Oct 23, 2009
I'm trying this in an sbRIO board and LV
2009.
The simple CPU usage vi returns 100%.
The RT CPU usage vi returns
approximately 12% in total and this
doesn't seem to change when I add load
to the processor.
The RT task manager returns 100%.
I'm not sure of what should I believe and
how to really measure this...
I downloaded the 8.5 version and just
compiled it in LV2009.
- Paulo Martins, Fibersensing. paulo.martins@fibersensing.com - Oct 23, 2009
CPU VIs for Real-Time 8.5
You can recompile the VIs from 8.20.
- Michael King, National Instruments. michael.king@ni.com - Nov 20, 2007
Do we have a similar lib to be used for
Realtime 8.5?
- Nov 19, 2007
Legal
This example program (this "program") was developed by a National Instruments ("NI") Applications Engineer. Although technical support of this program may be made available by National Instruments, this program may not be completely tested and verified, and NI does not guarantee its quality in any way or that NI will continue to support this program with each new revision of related products and drivers. THIS EXAMPLE PROGRAM IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND AND SUBJECT TO CERTAIN RESTRICTIONS AS MORE SPECIFICALLY SET FORTH IN NI.COM'S TERMS OF USE (http://ni.com/legal/termsofuse/unitedstates/us/).
