Expresion tags are stuck and not updating

Ignition version: 8.1.42

The Tag Group is configured with a 10-second scan rate and the mode is set to Direct.

We created a UDT to scale the raw value and generate alarms.

  • AiRaw is a memory tag that stores the raw value. This value is updated from another OPC tag through an event script.

  • AiScld is an expression tag that is expected to continuously scale the raw value from AiRaw using the expression below.

  • ControlSP, AlmHiSp, AlmLoSp, AlmHiDb, and AlmLoDb are memory tags whose values are entered by the operator from the Vision Client.

At present, both RangeMax and RawMax are set to 1,000,000, while both RangeMin and RawMin are set to 0. Therefore, based on the following expression, the scaled value should be the same as the raw value:

(({[.]AiRaw} - {[.]RawMin}) / ({[.]RawMax} - {[.]RawMin})) * (({[.]RangeMax}) - ({[.]RangeMin})) + ({[.]RangeMin})

According to the end user, the UDT instances were working properly until few days back, after which they stopped working.

We tried to trigger / check the value by changing the Execution Mode from "Event Driven" to "Fixed Rate" or "Tag Group", but this did not resolve the issue.

When we restarted the Gateway PC, the tags started working again. However, the actual reason why they stopped working is still unknown.
Question is why expression tags stopped working?

Any errors in your gateway log? What are the scripts on AiRaw, AiScld and GatewayTime doing? Was it just that tag that failed to update or were additional tags not updating values?

No errors on gateway status\log.
AiRaw, AiScld and GatewayTime

these tags has event script to check the max scaled value. Script on the AiRaw has been disabled.

I am not sure why the tag stopped updating, but I do have to wonder why all of this work is being done in Ignition rather than in the PLC.

It's going to be basically impossible to troubleshoot this after the fact.

If you're ever in a situation where things are "stuck", the thing to get is a thread dump. Without that snapshot of what the gateway is doing at that moment in time, you're significantly handicapped.

From past experience, look out for:

  1. runScript expressions in tags
  2. Tag event scripts

Either of which could be running operations with indefinite time bounds if you're not careful.

1 Like