I found this issue raised multiple times but I do not find a solution for this.
I am getting Configure encapsulation Layer on EIP product while using with CODESYS V3.5 SP22.
This product works well with Rockwell, Omron, Mithshibishi PLCs. The same device, same eds file, same EIP configuration does not work with CODESYS.
That message usually means the scanner never got past the CIP encapsulation session itself, so at this point it is more of a connection problem than an assembly mapping problem. The fact that the same device works fine with Rockwell and Omron actually points in the same direction, since those scanners tend to be more forgiving about session setup.
First thing I would check is the plain network side. Make sure the PFC and the device are really in the same subnet, and ping the device from the PFC if you can. I have lost an embarrassing amount of time to a wrong subnet mask on a PFC200 before, and the symptom looked exactly like this.
Then check whether anything else still owns the device. A lot of EtherNet/IP adapters only accept one exclusive-owner connection, so if the Rockwell or Omron test setup is still connected, or the device was never power-cycled after that test, CODESYS simply cannot get a session. Power-cycle the device, make sure no other scanner is talking to it, and try again.
If that still fails, look at the connection settings for the device under the scanner: target IP, connection type (Exclusive Owner versus Input Only) and the RPI. I would copy the exact assembly instances and sizes from the working Rockwell configuration into the CODESYS connection and compare them with what the EDS import created, since the EDS does not always map the config assembly the way you expect. The logger in CODESYS usually prints an extended CIP error code next to that diagnostic, and that code tells you whether it is a timeout, a refused session or a rejected Forward Open, which narrows it down a lot.
One more thing worth trying is a Wireshark capture on the link, just watching TCP port 44818. If you never see a Register Session response, the device is not reachable or is refusing the session, and no amount of assembly tuning will fix it.
Do all of this on the bench first, by the way, before the link goes anywhere near a running machine. And keep any safety function hardwired rather than depending on this EtherNet/IP link.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I found this issue raised multiple times but I do not find a solution for this.
I am getting Configure encapsulation Layer on EIP product while using with CODESYS V3.5 SP22.
This product works well with Rockwell, Omron, Mithshibishi PLCs. The same device, same eds file, same EIP configuration does not work with CODESYS.
Can someone please guide me here?
more posts ...
That message usually means the scanner never got past the CIP encapsulation session itself, so at this point it is more of a connection problem than an assembly mapping problem. The fact that the same device works fine with Rockwell and Omron actually points in the same direction, since those scanners tend to be more forgiving about session setup.
First thing I would check is the plain network side. Make sure the PFC and the device are really in the same subnet, and ping the device from the PFC if you can. I have lost an embarrassing amount of time to a wrong subnet mask on a PFC200 before, and the symptom looked exactly like this.
Then check whether anything else still owns the device. A lot of EtherNet/IP adapters only accept one exclusive-owner connection, so if the Rockwell or Omron test setup is still connected, or the device was never power-cycled after that test, CODESYS simply cannot get a session. Power-cycle the device, make sure no other scanner is talking to it, and try again.
If that still fails, look at the connection settings for the device under the scanner: target IP, connection type (Exclusive Owner versus Input Only) and the RPI. I would copy the exact assembly instances and sizes from the working Rockwell configuration into the CODESYS connection and compare them with what the EDS import created, since the EDS does not always map the config assembly the way you expect. The logger in CODESYS usually prints an extended CIP error code next to that diagnostic, and that code tells you whether it is a timeout, a refused session or a rejected Forward Open, which narrows it down a lot.
One more thing worth trying is a Wireshark capture on the link, just watching TCP port 44818. If you never see a Register Session response, the device is not reachable or is refusing the session, and no amount of assembly tuning will fix it.
Do all of this on the bench first, by the way, before the link goes anywhere near a running machine. And keep any safety function hardwired rather than depending on this EtherNet/IP link.