OPC COM Error

I got the following error when trying to view opc item values in the quick client and in designer. We are using Kepsever V5,

[quote]COM object method returns error code: 0xC0040007;
See log for details.
com.inductiveautomation.ignition.client.gateway_interface.GatewayException: Gateway Error 500: COM object method returns error code: 0xC0040007;
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.newGatewayException(GatewayInterface.java:236)
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.sendMessage(GatewayInterface.java:211)
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.sendMessage(GatewayInterface.java:201)
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.invoke(GatewayInterface.java:587)
at com.inductiveautomation.ignition.designer.sqltags.opcbrowser.OPCFolderNode.loadChildren(OPCFolderNode.java:48)
at com.inductiveautomation.ignition.client.util.gui.tree.AbstractAsynchronousTreeNode$Loader.run(AbstractAsynchronousTreeNode.java:65)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: com.jniwrapper.win32.com.ComException: COM object method returns error code: 0xC0040007;
at com.jniwrapper.win32.com.impl.IUnknownImpl.invokeStandardVirtualMethod(SourceFile:744)
at com.jniwrapper.win32.com.impl.IUnknownImpl.invokeStandardVirtualMethod(SourceFile:723)
at com.inductiveautomation.opccom.interop.opcda.impl.IOPCBrowseImpl.browse(IOPCBrowseImpl.java:89)
at com.inductiveautomation.opccom.wrapper.browsing.BrowserDA3$BrowseJob3.internalRun(BrowserDA3.java:93)
at com.inductiveautomation.opccom.wrapper.OleJob.run(OleJob.java:45)
at com.jniwrapper.win32.MessageLoopThread$ThreadSynchronizedAction.run(MessageLoopThread.java:566)
at com.jniwrapper.win32.MessageLoopThread$LoopThread.run(MessageLoopThread.java:508)
Ignition v7.0.0 (b4384)
Java: Sun Microsystems Inc. 1.6.0_04

[/quote]

I believe that error corresponds to “Unknown Item”. Is it happening from the start, or after browsing several levels deep?

If you go into the OPC connection configuration and select “Use DA2 when possible”, do you get a similar error? Changing to DA2 will use a different browse mechanism.

Regards,

That didnt seem to help.

[quote]com.inductiveautomation.ignition.client.gateway_interface.GatewayException: Gateway Error 500: COM object method returns error code: 0xC0040007;
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.newGatewayException(GatewayInterface.java:236)
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.sendMessage(GatewayInterface.java:211)
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.sendMessage(GatewayInterface.java:201)
at com.inductiveautomation.ignition.client.gateway_interface.GatewayInterface.invoke(GatewayInterface.java:587)
at com.inductiveautomation.ignition.designer.sqltags.opcbrowser.OPCFolderNode.loadChildren(OPCFolderNode.java:48)
at com.inductiveautomation.ignition.client.util.gui.tree.AbstractAsynchronousTreeNode$Loader.run(AbstractAsynchronousTreeNode.java:65)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: com.jniwrapper.win32.com.ComException: COM object method returns error code: 0xC0040007;
at com.jniwrapper.win32.com.impl.IUnknownImpl.invokeStandardVirtualMethod(SourceFile:744)
at com.jniwrapper.win32.com.impl.IUnknownImpl.invokeStandardVirtualMethod(SourceFile:723)
at com.inductiveautomation.opccom.interop.opcda.impl.IOPCBrowseImpl.browse(IOPCBrowseImpl.java:89)
at com.inductiveautomation.opccom.wrapper.browsing.BrowserDA3$BrowseJob3.internalRun(BrowserDA3.java:93)
at com.inductiveautomation.opccom.wrapper.OleJob.run(OleJob.java:45)
at com.jniwrapper.win32.MessageLoopThread$ThreadSynchronizedAction.run(MessageLoopThread.java:566)
at com.jniwrapper.win32.MessageLoopThread$LoopThread.run(MessageLoopThread.java:508)
Ignition v7.0.0 (b4384)
Java: Sun Microsystems Inc. 1.6.0_11
[/quote]

OK, sorry, it looks like that setting isn’t impacting the browse the way I expected. Could you do the following:

  1. Go to View->Diagnostics->OPC in Kepware.
  2. Click the “start” button on the toolbar.
  3. Run through your browse procedure
  4. Go back to Kepware, click stop, and then save the log file from the File menu.
  5. Email the file to support AT inductiveautomation.com

Thanks,

What plug-in of Kep V5 are you connecting to? To find out where exactly the issue is, you should try to reproduce the same issue with other MatrikonOPC products? That way you can isolate where the issue might be. Although, if it’s an OPC problem, you won’t be able to replicate it with ours. It’s gonna work right-out-the-box :wink:

Here is a link to download an OPC Server:
http://www.matrikonopc.com/downloads/index.aspx

Let me know how it went

Cheers,

Wassim Daoud
Global Solutions Architect
http://www.MatrikonOPC.com

The file has been sent

Really Wassim, did you not make your quota of web-links this month? I know we’ve told you before: we’re perfectly happy to let you suggest products that fit specific user questions/requirements, but coming along on a thread like this and saying “try matrikon, it’ll work out of the box!” doesn’t really help. This is clearly a specific issue that needs to be tracked down and resolved between our product and Kepware, and a special case- we have many users already using Ignition with both Kepware 4 and 5.

So, I’m going to tell you a final time: try harder to be relevant, or I’m going to start deleting your posts and ban you. I want to be perfectly clear on this: We have no problems with companies suggesting products on our forum. We do have a strong issue with posts that don’t directly add value to the discussion.

Be nice Colby! He’s suggesting a viable alternative. And we do appreciate OPC vendors and other 3rd party forum member participation.

Ok after changing the DA2 setting nothing happened. After restarting the gateway it was fixed. I am finding this to be a common thing with Ignition. Most changes not taking effect until restart. This is going to be a problem, when in our case, it is mission critical.

I agree with Colby on this one. We narrowed it down to a plugin issue at this point in time.

We certainly do appreciate the participation of 3rd party vendors. But when someone has 4 posts over 2 user names that are all ads with little relevance to the thread, it shows they aren’t really participating, just advertising. I suggest taking a look at the posts of someone like Eric Murphy (also from Matrikon) for an example of how this can be done correctly.

Now back to the topic at hand. David- Thanks for sending the log, I’ll take a look at it first thing on monday. As for your concerns about restarting the gateway, we certainly agree with you. We really appreciate your help/patience this week, and will be working hard this week to clear up all of these issues that have come up so far. Since I haven’t looked at the log yet, I can only speculate, but the fact that it worked after restart is useful info. You didn’t by chance also upgrade to the build that was released on friday did you?

Regards,

Yes the gateway restart was on the newest version.

Ok, too bad I couldn’t get to the log a bit sooner. This isn’t really a functional bug, but more of a user experience thing.

Basically, you’re browsing down to the tag, and then trying to browse further- which is perfectly understandable since the tag has a + next to it- which errors out. The error is appropriate, since the tag has no data under it.

In both the quick client and the designer, if you just subscribe to/drag in the tag (marked as DataVariable in the QC, and with the tag icon in the designer), it works fine.

We’ll change it to be less misleading. Also, on a side note, in the newer version you installed the “Use DA 2” has been fixed to affect browsing, so you’re currently using that method. That method of browsing just detects when you’re browsing a tag and returns without error. Now that it’s clear what’s happening, you can switch back to 3 if you want, which is faster.

Regards,

I’m getting the same error but I’m not attempting to expand a base tag like the original poster’s problem appears to be.

I’m using RSLinx and my code is running in RSEmulate instead of a real ControlLogix PLC. Eventually I will be using KepServerEX and a real PLC, so I will report if the issue goes away then. Until I get hardware I’m stuck with RSLogix because it is the only program able to expose the tags in the emulator through OPC.

The path to my tag is something like this:
[PLC]Program:ProgramName.Transactions[X].DataBuffer.Tag1

When I try to expand the DataBuffer (a UDT I created) part of the tree is when I get the exception. In fact, when I try to expand any tag at the same depth as DataBuffer, such as a timer tag, I get the same exception. I created a controller-scoped tag of the same type of DataBuffer but I get the same exception.

THEN I thought my use of custom length strings might be an issue, so I temporarily deleted them from the DataBuffer UDT. At this point the UDT is 2 dints and 2 booleans. Same result.

In fact now that I experiment some more it seems that ANY tag that isn’t a base type (INT, BOOL, etc) or a true folder (like a program) shows an error when I try to expand it. A timer or string tag by itself gives the same result. Issue with RSLinx as an OPC server then?

Hopefully this issue goes away when I get my hardware and can use KepServer, I’ll update here when I know.

My first instinct is to blame Linx, but I suppose it could be something we’re doing. I’ll see if we can mock something up. Switching to kepware will almost certainly solve your problems because in that case everything will be flattened down to basic tags and folders.

I’ll look into this sometime today and post back.

Regards,

Well, it works fine with Kepware and real hardware. Would be nice to be able to hook up Ignition to RSEmulate but other than testing I don’t see a huge need.