Modicon M221 on VPN, communication error

lesmar96

Lifetime Supporting Member
Join Date
May 2017
Location
PA
Posts
520
Good Morning,

I have two Schneider PLCs, M221s, communication over Modbus TCP/IP. They are linked together over an IPSec VPN tunnel between two cellular routers. Once we got the VPN setup correctly, we used standard Modbus TCP/IP programming for the communication. The problem is that if for some reason the VPN link drops out, like just a electronic glitch, the communication function block in my plc program does not error out on an error or timeout. It just acts like everything is fine even if it has no connection to the other PLC because the VPN tunnel shutdown. Programming done in SoMachine Basic v1.5. I was using the MSG3 function block for communication. Any inputs on how to better monitor the status of the communication would be greatly appreciated.
 
It sounds like you need a heartbeat signal into the PLC. This is usually just a simple on delay timer. The remote PLC will turn on a bit in the local. The local will reset the bit and start a timer. If the timer expires before the remote turns on the bit, you know that a communication error has occurred.

Regards,
 
that is a great suggestion. This project is to monitor the level in a remote water tank and when the comm failed, the level would just stay the same for hours and therefore would not control the pumps at all.
 

Similar Topics

Hey Programmers, Heres todays puzzle I was trying to solve... I have a Modbus TCP network with two Modicon M221 controllers live on my work bench...
Replies
0
Views
450
Hey everyone! I have trouble making sense of the math conversion in this seconds tag of the Modicon M221 Real Time Clock. I thought I understood...
Replies
4
Views
1,557
Hi all, i am trying to scale a 0 - 1000 analogue input to a -10000 to 10000 output with 0-500 been -10000 to 0 and 501-1000 to 0-1000 is there...
Replies
7
Views
2,855
Hi All, I'm looking for some insight into what the SHORT instruction does. The help file wasn't very useful, as I found the explanation to be...
Replies
4
Views
1,449
Hi all. I’m currently trying to combine 3 memory words in to a single display on a weintek hmi as I want to display running time. I have the...
Replies
4
Views
1,785
Back
Top Bottom