dunc

connecting 2 PLC's with a socket connection?

3 posts in this topic

have been trying to get communication between 2 PLCs to transfer a data register. we have a Q01U with a QJ71E71-100 and I want to send a single data register to a Q02(H) with a QJ71E71-100 I have managed to get things working in a really basic program, the data is transferred ok. the issue I have is when I get a fault. I am not sure how to deal with it as it brings up a comm fault on the card and it doesn't appear very simple to restart the communications. the only way I can clear it is to stop writing to the send/receive buffer. close the connection. reset the comm error and then open the connection and restart the send/receive. even when I do this manually it isn't 100% and doesn't always work first time. please see attached of both programs. I just need a way to account for any faults with the connection. can anyone help me out? thankyou

Share this post


Link to post
Share on other sites
You should have a little more logic in your program to compensate for cardReady, OpenOK and so on. I've attached a couple of screenshots from the manual. You should use unpassive or fullpassive on the receiving side of the comm, and use ActiveOpen on the sending side. Don't use the secondpulse or similar to send data, just write logic to send as often as possible (after datasending OK signal, wait one scan then resend). There's no need to wait for a whole second. On the receiving side, make sure you fetch the data as soon as they enter the receiving BFM area. Give it a try, and repost with a more complete program if you need more help.

Share this post


Link to post
Share on other sites
thanks for your help. think i have just about cracked it. i can now uplug the ethernet cable/reset either plc and the connection will re-establish no problem. just need to neaten it up a bit and it should be good to go.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now