Navigation: Developing Apps > BINETIX® AGE™ API > Plugins > System Monitor > Modules > sysmon
get_cpu_avg/1
Description
get_cpu_avg/1 is an Erlang function exported by "sysmon" module.
Returns a list of fields with summarized information and averaged values all system CPUs installed on the current node.
References
•get_info/1
Parameters
Name
Type
Fields
list()
List of fields with system information retrieved by get_info/1
Result
Value or Type
List of fields with averaged values.
Code Sample
> {sysinfo, Fields} = sysmon:get_info().
> sysmon:get_cpu_avg(Fields).
[
{name, "cpu"},
{cpu_load, 8.911195960093607},
{cpu_user, 273856},
{cpu_nice, 149057},
{cpu_kernel, 1006346},
{cpu_idle, 11450097},
{cpu_iowait, 20900},
{cpu_irq, 0},
{cpu_softirq, 108905}
]