Apply simple arithmetic operations on values?

meklubba

New member
Hi!

Is it possible to say divide a calculated value (id=@01) with another calculated value (id=@02) and display the result or have the result determining graph_min or graph_max?

/Daniel
Looking for additional LCD resources? Check out our LCD blog for the latest developments in LCD technology.
 

meklubba

New member
My thought was to use it for histograms over network trafic. I discovered that setting the min/max values to -1 makes them autoadjust. Nifty feature btw. :)
I wanted a percentage usage histogram but I read that the perfmon value for a NICs current bandwith often is the nominal bandwidth (i.e. 100mbps) and then the utilization value would seldom go over 5% which makes it unusefull.
However, I can think of other situations that would prefer such a plugin, say you get the uptime value from perfmon, not from the predefined static id since it is formatted as a string, and want to format it in your own way that requires calculating the elapsed amount of seconds, minutes, hours and so on manually.

Such a plugin would be nice, but still, for now, I don't think it has high priority. :)

/Daniel
 

CF Mark

Administrator
My thought was to use it for histograms over network trafic. I discovered that setting the min/max values to -1 makes them autoadjust. Nifty feature btw. :)
So that works ok then?
I never tested it much.
I havnt heard of anyone using it until now :)

I wanted a percentage usage histogram but I read that the perfmon value for a NICs current bandwith often is the nominal bandwidth (i.e. 100mbps) and then the utilization value would seldom go over 5% which makes it unusefull.
However, I can think of other situations that would prefer such a plugin, say you get the uptime value from perfmon, not from the predefined static id since it is formatted as a string, and want to format it in your own way that requires calculating the elapsed amount of seconds, minutes, hours and so on manually.

Such a plugin would be nice, but still, for now, I don't think it has high priority. :)
[/B]
I see.
Well ill add it to my now massive to-do list.
 

meklubba

New member
Feels great to contribute to your massive to-do list! :D

The autoadjust feature works good. All previous visible histogram bars changes in proportion to the highest bar when a higher bar is displayed. The only downside is that if you, as in my case, are displaying a histogram over the bps currently beeing received by the NIC you will have at least one bar in full hight all the time (even if you are receiving 1 bps or 10 Mbps). This could give you a false impression that your NIC is havily used. :)

I've encountered two problems. I think it is like this, but I have to get back to confirm when I get home and can test it. If I set graph_min=0 and graph_max=-1 (min is 0bps and max is auto) then the histogram is not working at all and if I have min and max = -1 I get a constant histogram of half bar hight for the two rows displaying incoming "E in:" and "I in:" when there is no activity on the NICs.
EDIT: If I set graph_min=0 and graph_max=-1 I get a constant histogram of full hight.

multiplier=0.0009765625 is for converting bytes/sec to Mbytes/sec.
E and I on the screen stands for External (to Internet) NIC and Internal (to my intranet) NIC. Here's the screen definition file:


[pre]
rows=4
cols=20

[from00]
from="cc2_perfmon.ini"
sec="perf#"
opt01="id=@01"
opt02="full_name=\Network Interface(Intel[R] PRO_1000 CT Network Connection - Packet Scheduler Miniport)\Bytes Received/sec"
opt03="precision=0"
opt04="multiplier=0.0009765625"

[from01]
from="cc2_perfmon.ini"
sec="perf#"
opt01="id=@02"
opt02="full_name=\Network Interface(Intel[R] PRO_1000 CT Network Connection - Packet Scheduler Miniport)\Bytes Sent/sec"
opt03="precision=0"
opt04="multiplier=0.0009765625"

[from02]
from="cc2_perfmon.ini"
sec="perf#"
opt01="id=@03"
opt02="full_name=\Network Interface(D-Link DFE-530TX PCI Fast Ethernet Adapter [rev.A] - Packet Scheduler Miniport)\Bytes Received/sec"
opt03="precision=0"
opt04="multiplier=0.0009765625"

[from03]
from="cc2_perfmon.ini"
sec="perf#"
opt01="id=@04"
opt02="full_name=\Network Interface(D-Link DFE-530TX PCI Fast Ethernet Adapter [rev.A] - Packet Scheduler Miniport)\Bytes Sent/sec"
opt03="precision=0"
opt04="multiplier=0.0009765625"

[from04]
from="cc2_histogram.ini"
sec="graph#"
opt01="id_data=@01"
opt02="width=10"
opt03="height=1"
opt04="id3=@"
opt05="id2=@"
opt06="id1=@"
opt07="id0=@06"
opt08="scroll_speed=500"
opt09="graph_min=-1"
opt10="graph_max=-1"
opt11=id_gmin=@"
opt12="id_gmax=@"

[from05]
from="cc2_histogram.ini"
sec="graph#"
opt01="id_data=@02"
opt02="width=10"
opt03="height=1"
opt04="id3=@"
opt05="id2=@"
opt06="id1=@"
opt07="id0=@07"
opt08="scroll_speed=500"
opt09="graph_min=-1"
opt10="graph_max=-1"
opt11=id_gmin=@"
opt12="id_gmax=@"

[from06]
from="cc2_histogram.ini"
sec="graph#"
opt01="id_data=@03"
opt02="width=10"
opt03="height=1"
opt04="id3=@"
opt05="id2=@"
opt06="id1=@"
opt07="id0=@08"
opt08="scroll_speed=500"
opt09="graph_min=-1"
opt10="graph_max=-1"
opt11=id_gmin=@"
opt12="id_gmax=@"

[from07]
from="cc2_histogram.ini"
sec="graph#"
opt01="id_data=@04"
opt02="width=10"
opt03="height=1"
opt04="id3=@"
opt05="id2=@"
opt06="id1=@"
opt07="id0=@09"
opt08="scroll_speed=500"
opt09="graph_min=-1"
opt10="graph_max=-1"
opt11=id_gmin=@"
opt12="id_gmax=@"

[screen]
screen_name="Net Send/Receive Usage Histogram"
options=0
alt_delay=5000

[r00]
options=0

[r00-i00]
length=5
string="E In:"

[r00-i01]
length=5
options=0
id=@01

[r00-i02]
id=@06

[r01]
options=0

[r01-i00]
length=5
string="EOut:"

[r01-i01]
length=5
options=0
id=@02

[r01-i01]
id=@07

[r02]
options=0

[r02-i00]
length=5
string="I In:"

[r02-i01]
length=5
options=0
id=@03

[r02-i02]
id=@08

[r03]
options=0

[r03-i00]
length=5
string="I Out:"

[r03-i01]
length=5
options=0
id=@04

[r03-i01]
id=@09

/Daniel
 
Last edited:
Top