Panelview programming question

Ok, So I ahve a formula something like this 100/a*B When the machine is not running (a) is 0 so it gives me stars on the panelview. How can I get this to go to 0?
 
More info. What is "a" an integer? floating point number? Where is this formula? In the PLC or your PV. What value does the *** on the PV represent?("a" or the results of the formula)
 
You can put a conditional statement before executing the formula. Use an if A is greater than instruction (GRT in AB speak) before the formula is ran. Also, you can fault out some processors doing a divide by zero.
 
Bruce is right on; it's good programming practice on any platform to boundary-limit division instructions like that. You probably want a zero when the machine is not running, so make your logic "if a> 0 then x=100/a*b, if a<= 0, then x=0".
 
If this is a numeric display in a PanelView Plus terminal, you can make the display connection an Expression to prevent the "*****" onboard, like this:

If TagA > 0 then (100/TagA)*TagB
else 0
 

Similar Topics

I'm currently updating one of the Panelview programs at my plant, and I am hoping someone can answer a question for me. In this program I have 4...
4
Replies
3,803
Views
I have RSLogix 5000 Standard Edition V13.03.00 (Copyright 1997 to 2004). Is there Rockwell software available that I can use to program a...
2
Replies
399
Views
Good Morning All. I have a couple of challenges, programming a Panel View Plus 7 HMI. This HMI needs to talk to a MicroLogix 1400. And I need to...
8
Replies
2,178
Views
Hey Guys I am trying to figure out the correct cable to use to connect from my laptop to this Panelview using panelbuilder32. I was sure I had...
5
Replies
2,831
Views
I am new to programming the Panelview 800 HMI screens. I have built some basic screens and it is mostly self explanatory. I would like to add a...
1
Replies
10,495
Views
Top