Set Tag Quality in data read by devices indirectly

Hello,

I have a question how to set Quality tag in the simplest way. I have a device - a data hub collecting data locally in the PLC from the read devices. It issues tags via OPC to SCADA, but when the device has a communication problem in PLC I would like to inform about it in SCADA via error overlay. I have a special bool tag for this which informs about the correctness of the connection. The only way I have found is use qualifiedValue expression but it causes me to duplicate all the tags. Is there another way to do it?

qualifiedValue(1, 'bad', 515, 'New Quality')  //Returns the value 1 but with a quality of Bad_Disabled("New Quality").

Best regards
MichaƂ

Why is your OPC connection not showing bad quality in this situation? That would be the correct behavior. Using expression tags as you have is the work around for broken OPC UA servers.

I simply have a PLC that is an OPC UA server. The connection between PLC and SCADA is correct however the PLC reads the devices and writes the read values into own tags. When the PLC does not have a local read of the device it just write 1 to 'no communication' tag in structure, tags are snagged . All PLC registers can be seen correctly and read by SCADA.

Then your expression tag method is the best you can do with that broken server.

Edit: "Broken" is too harsh. Suboptimal, but understandable. In most applications I've seen, a broken connection at that level would be an alarm.