I have used OPC UA and Siemens UDTs and Structs throughout my entire project without issues. Now suddenly new tags are starting to show up like this, It’s not giving me the tags in the struct as a JSON. I guess its something on the PLC side but I’m not sure what is causing this.
Some new ones, I tried to move it from InstanceDB to Global, change the name, change the Struct but does not work. Old ones work though. It’s the same PLC and same OPC Connection.
Setting that to false actually fixed the issue of this when i have the struct in a Global DB. However, it did not fix the issue when the struct is used in a IDB:
When true, you can only used structs defined the “Default Simatic Namespace” or whatever they call it. It’s only true by default on connections that were part of an upgrade from 8.1.
You might have to work with support to further troubleshoot. You’ll need to connect with UaExpert and look to see if these nodes that don’t work have DataTypeDefinition attributes correctly defined, and possibly explore the DataTypes folder in the address space to find and verify these types exist.
Error decoding ExtensionObject: ExtensionObject[body=ByteString[bytes=000000000000000000000000], encodingId=NodeId{ns=3, id=TE_"misc"."Data"}]
org.eclipse.milo.opcua.stack.core.UaSerializationException: no codec registered for encodingId=ns=3;s=TE_"misc"."Data"
at org.eclipse.milo.opcua.stack.core.encoding.binary.OpcUaDefaultBinaryEncoding.decode(OpcUaDefaultBinaryEncoding.java:89)
at org.eclipse.milo.opcua.stack.core.types.builtin.ExtensionObject.lambda$decode$0(ExtensionObject.java:116)
at org.eclipse.milo.opcua.stack.core.util.Lazy.get(Lazy.java:39)
at org.eclipse.milo.opcua.stack.core.types.builtin.ExtensionObject.decode(ExtensionObject.java:116)
at org.eclipse.milo.opcua.stack.core.types.builtin.ExtensionObject.decode(ExtensionObject.java:75)
at com.inductiveautomation.ignition.gateway.opcua.OpcUaToIgnition.decodeExtensionObject(OpcUaConversions.kt:680)
at com.inductiveautomation.ignition.gateway.opcua.OpcUaToIgnition.opcUaScalarToIgnition$opc_ua_gateway(OpcUaConversions.kt:671)
at com.inductiveautomation.ignition.gateway.opcua.util.ktx.Variant.toRawValueUnsafe(Variant.kt:68)
at com.inductiveautomation.ignition.gateway.opcua.util.ktx.DataValue.toQualifiedValueUnsafe(DataValue.kt:34)
at com.inductiveautomation.ignition.gateway.opcua.util.ktx.DataValue.toQualifiedValue-0E7RQCE(DataValue.kt:21)
at com.inductiveautomation.ignition.gateway.opcua.client.connection.OpcUaSubscriptionManager$OpcUaSubscriptionListener.onDataReceived(OpcUaSubscriptionManager.kt:506)
at org.eclipse.milo.opcua.sdk.client.subscriptions.OpcUaSubscription.notifyDataReceived(OpcUaSubscription.java:1346)
at org.eclipse.milo.opcua.sdk.client.subscriptions.PublishingManager.deliverNotificationMessage(PublishingManager.java:334)
at org.eclipse.milo.opcua.sdk.client.subscriptions.PublishingManager.lambda$processPublishResponse$16(PublishingManager.java:302)
at org.eclipse.milo.opcua.stack.core.util.TaskQueue$TaskWrapper.run(TaskQueue.java:259)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
Hi, looks like you are right. I just noticed that TypeDicitonary is enabled in the PLC. I will try to disable that at the next production stop to see if that makes a difference.
I need to confirm this later today, but I think I may know what's going on.
If the issue is what I think, then you would see structures go from readable to not readable if you made a change to it in TIA portal (e.g. add/remove a member) and then downloaded the change, even after the automatic reconnect.
If you force a reconnect manually (e.g. edit/save the connection) then the structure should be readable again.