.Net code using Opto22.Controller.dll returning CommunicationFault

Hi, we are using the Opto22.Controller.dll library to communicate with the PAC Controller in all our plants. In one plant only we are getting CommunicationFault errors at least a few times nearly every day.

The following is from the log file of our Windows Forms .Net based BatchTracker application:

001273 2020-04-20 06:56:24 BatchTracker (5) ERR OpenOptoControl: Connection Error: IPAddress=192.168.1.20, Port=22001, TimeOut=1000, ErrCode=CommunicationFault

001274 2020-04-20 06:56:27 BatchTracker (5) ERR OpenOptoControl: Connection Error: IPAddress=192.168.1.20, Port=22001, TimeOut=1000, ErrCode=CommunicationFault

002032 2020-04-20 08:46:52 BatchTracker (5) ERR OpenOptoControl: Connection Error: IPAddress=192.168.1.20, Port=22001, TimeOut=1000, ErrCode=CommunicationFault

002033 2020-04-20 08:46:56 BatchTracker (5) ERR OpenOptoControl: Connection Error: IPAddress=192.168.1.20, Port=22001, TimeOut=1000, ErrCode=CommunicationFault

002588 2020-04-20 09:52:58 BatchTracker (5) ERR GetOptoBatchInfo: Error Opto Read BatchID_Echo

002589 2020-04-20 09:52:59 BatchTracker (5) ERR GetOptoBatchInfo: Error Opto Read TicketID_Echo

002590 2020-04-20 09:52:59 BatchTracker (5) ERR CheckOptoTrigger: [1226] {6524} Opto Read Failed! Trigger_StartBatchSQL, Opto Error Code =CommunicationFault

002591 2020-04-20 09:52:59 BatchTracker (5) ERR CheckOptoTrigger: [1226] {6524} Opto Read Failed! Trigger_ReadyDischargeSQL, Opto Error Code =CommunicationFault

002592 2020-04-20 09:52:59 BatchTracker (5) ERR CheckOptoTrigger: [1226] {6524} Opto Read Failed! Trigger_MixerStartSQL, Opto Error Code =CommunicationFault

002593 2020-04-20 09:52:59 BatchTracker (5) ERR CheckOptoTrigger: [1226] {6524} Opto Read Failed! Trigger_EndBatchSQL, Opto Error Code =CommunicationFault

002594 2020-04-20 09:52:59 BatchTracker (5) ERR CheckOptoTrigger: [1226] {6524} Opto Read Failed! Trigger_AbortBatchSQL, Opto Error Code =CommunicationFault

002670 2020-04-20 10:01:10 BatchTracker (5) ERR OpenOptoControl: Connection Error: IPAddress=192.168.1.20, Port=22001, TimeOut=1000, ErrCode=CommunicationFault

003254 2020-04-20 11:42:33 BatchTracker (5) ERR OpenOptoControl: Connection Error: IPAddress=192.168.1.20, Port=22001, TimeOut=1000, ErrCode=CommunicationFault

003255 2020-04-20 11:42:36 BatchTracker (5) ERR OpenOptoControl: Connection Error: IPAddress=192.168.1.20, Port=22001, TimeOut=1000, ErrCode=CommunicationFault

Any ideas would be appreciated.

Thanks,

-Dale

If the same code is working everywhere else and most of the time in the one place, then you likely have a degrading network connection/link.( Dropping packets).

You can google some ways to test for this using ping and you will see them getting dropped.

Another possibility I can see is perhaps you are overloading the CPU, running to many cycles on it. (not likely)

Jerry

Thanks for the response. We are thinking the same thing.

The weird thing is that we are never seeing any issues on the PAC-Display window. Just in our our associated application’s log file. Is there a log that PAC Display or the OptoOPCServer might record communication faults to?

I will look into testing with ping.

Thanks again.

It depends on how long the timeout lasts for.
PAC Display might just sail through them if they are quick, where your application might trip up straight away.

The longest I have seen seems to be a few seconds judging by the log. I use a 1 second timeout on the OpenOptoControl, so you are probably right. It caused an issue by happening at the wrong time (fixed that). When I checked the log this seems to have been going on for close to a year now. I am thinking maybe some sort of interference or the plant shaking messing with a connection.

I had an intermittent problem like this 20 years ago that turned out to be someone occasionally using an arc welder next to a long ethernet run. Rerouted and it went away.

Because we were not seeing it on PACDisplay, we were questioning whether the error code was for sure correct and wondering if anyone else had seen something like this.

Thanks for the response.