AnsweredAssumed Answered

Pi AF Counter

Question asked by JeffElzy on Jul 20, 2020
Latest reply on Jul 20, 2020 by TimCarmichael

I'm new to PI AF, started learning last week. 

I'm trying to count how many times a tag value equals a certain value.

I tried creating a simple counter, but it keeps giving me calc failed.


1. Checks the value of the tag which is different steps of the equipment, then assigns it to a created tag. 

2. If the tag equals a certain value, then it gives a '+ 1' value to the counter Pi tag that is created.

      if tagvalue = 12 then counter +1 else counter

3. I then read the 'counter' tag using Pi Vision.


Hopefully I explained well enough.