Apologies, I was incorrect, I got confused with Bad_NotFound. In this case it is because expression language is used for expression tags so it should be {POS}/16.
The OPC tag uses 'formatted string' to form the path, so {POS/16} is valid.
Just setting up a quick test to support the theory, edit incoming shortly.
The expression language is completely different to the basic parameter expression language. In the expression language, {stuff} tries to read stuff as a tag. It doesnt see stuff as a udt parameter you're trying to use. Have you tried your parameter expression inside the opcitempath?
What do you mean by 'alarm configuration'? Where is this expression used?
If this is in an alarm attached to the 'Alarm' tag as part of the set point's expression, you need to use the expression language to manipulate the value of the tag, you can't read the value of another OPC item
I believe you are correct. I did some additional testing and that is the problem.It evaluates correctly if I take out that division.
I assumed it would do int math since they were both ints and it does not. I even attempted to use a different parameter using the math and put it into an int parameter to use, but it still returns floating point.
To format a value, use the form {ParameterName|format}. The format pattern is the same as that used for the numberFormat expression function. In short, "0" can be used to require a digit, and "#" can be used for optional digits. ie: ##0
I forgot about this @matthew.ayre. Shows how often I use parameter expressions haha
are you sure I try and this does not work for me…
what I see:
{PATH}.Alarm[{POS/16|#}].{POS%16}
if pos is <=8 the result is 0
if POS > 8 the result is 1 …
Hi @stra, this was working from what I remember . Looking at the date, I think it would have been tested in 8.0.x, what version are you using? Something could have changed in 8.1.x…