You are not registered yet. Please click here to register!


 
 
plc storereviewsdownloads
This board is for PLC Related Q&A ONLY. Please DON'T use it for advertising, etc.
 
Try our online PLC Simulator- FREE.  Click here now to try it.

New Here? Please read this important info!!!


Go Back   PLCS.net - Interactive Q & A > PLCS.net - Interactive Q & A > LIVE PLC Questions And Answers

Reply
 
Thread Tools Display Modes
Old April 15th, 2021, 10:09 PM   #1
johnlocke
Member
United States

johnlocke is offline
 
Join Date: Apr 2021
Location: Tennessee
Posts: 3
PLC Communication

I am wanting to control one PLC from a separate PLC. They are connected via ethernet cable to a switch. I need to be able to toggle bits in one location from the other location. How do you go about doing something like this in a RSLogix 500?
  Reply With Quote
Old April 15th, 2021, 10:19 PM   #2
PreLC
Member
United States

PreLC is offline
 
PreLC's Avatar
 
Join Date: Apr 2019
Location: Mars
Posts: 340
Quote:
Originally Posted by johnlocke View Post
I am wanting to control one PLC from a separate PLC. They are connected via ethernet cable to a switch. I need to be able to toggle bits in one location from the other location. How do you go about doing something like this in a RSLogix 500?
You need to configure messaging from one PLC to another. Messaging in controllogix can be of two types: implicit or explicit. Read about them here:https://www.google.com/url?sa=t&sour...hfc0-NzK6RxUPZ


In your case, a simple way to do this is going to be to add one PLC to the second PLC's controller organizer, and maybe trigger this msg instruction every 200ms?
__________________
Ask not what your PLC can do for you, ask what you can do for your PLC.
  Reply With Quote
Old April 16th, 2021, 01:20 AM   #3
Saffa
Member
New Zealand

Saffa is offline
 
Join Date: Feb 2012
Location: Bay of Plenty
Posts: 1,212
He's using Logix 500, so I'm assuming micrologix or SLC. The OP might want to post part numbers for the hardware he has.

The MSG instruction is the right tool for this job... set up a data table in the one PLC to receive the data, and the same table in the PLC that is the source of the data.

The MSG instruction is pretty well documented, so take a look, have a go and come back with some questions.

I like to control my message block with a repeating timer, so i have control of how much bandwidth each message will use. If i only have slow changing signals then i fire it off at a suitable rate.

We also do a lot of messaging over slow radio links, so being able to control polling is important.
  Reply With Quote
Old April 16th, 2021, 05:46 AM   #4
alan_505
Lifetime Supporting Member
Australia

alan_505 is offline
 
Join Date: Feb 2007
Location: Melbourne,Victoria,Australia
Posts: 676
And it is best practice to do a message read not a message write.
By doing a read you can see where the data is coming from, with a write you cannot tell what is changing the data, you can document it but when someone comes along later without a commented file it makes it hard to find why bits are changing.

Alan
  Reply With Quote
Old April 16th, 2021, 07:11 AM   #5
geniusintraining
Lifetime Supporting Member + Moderator
United States

geniusintraining is offline
 
geniusintraining's Avatar
 
Join Date: Jun 2005
Location: SC
Posts: 7,454
Alan,

The only issue with a 'read' is that you need to check when the data has changed... I agree with its a pain to find out where the write is coming from but I like to use it to keep the data down on the network, so instead of checking has the bit change.... has the bit changed.... has the bit changed, the way I like to do it is 'if the bit changes' do a write to the other PLC, its a little better if they are using two 5/05's and ethernet but if they are using two 5/03's or 5/04's then I would just like to keep the data down on the network, also depends on how many nodes
__________________
www.PLCCable.com PLC Communication Cables, PLC Trainers, MicroLogix, ControlLogix, Siemens, Allen Bradley and more...OEM and aftermarket supplies... Aftermarket 1784-U2DHP Allen Bradley USB to DH+, new USB to 485 modbus
  Reply With Quote
Old April 16th, 2021, 01:05 PM   #6
johnlocke
Member
United States

johnlocke is offline
 
Join Date: Apr 2021
Location: Tennessee
Posts: 3
So some questions here are how do you use a message to toggle these bits? I need to use an input on one PLC and have that generate a signal that is messaged to the other PLC where it can be read to toggle and input on that program.
  Reply With Quote
Old April 16th, 2021, 01:19 PM   #7
OkiePC
Lifetime Supporting Member
United States

OkiePC is offline
 
OkiePC's Avatar
 
Join Date: Mar 2005
Location: ENE of Nowhere Oklahoma
Posts: 10,943
Quote:
Originally Posted by johnlocke View Post
So some questions here are how do you use a message to toggle these bits? I need to use an input on one PLC and have that generate a signal that is messaged to the other PLC where it can be read to toggle and input on that program.
Your best bet is to mark off a block of integers (N file or B file) in each PLC to be reserved for this transfer of data.

Map the other data points to these reserved areas. By reserved, I mean you have made notes and commented the bits and words for your use...strictly documentation.

It is always my preference to use the same addresses on each end of a RSLogix 500 message. It is nice if N20:0/3 is a copy of N20:0/3 from the other end, rather than some other file and word location. Then your comments can be copied between the two projects with a minor edit notating the direction of the data transfer.

Then set up the MSG instruction to read (and/or write) from that area. I prefer to trigger MSGs that need to be frequently repeating to run from timer that gets reset when the previous message is ERrrored or DoNe. Some folks like to just MSG over and over again as fast as possible but that is rarely a good idea.

If the process needs to know for sure that the data from the other PLC is fresh and that the other PLC has not faulted out, send a heartbeat integer along with your control bits and use that in the other PLC to monitor for stale data. A copy of S:4 is like a random number. If it stops changing, then the MSGs stopped happening.

Sometimes it is best for the process to fire the message only when the data changes so that the information is updated as soon as it changes, but not more often than necessary. If you do this, then the "heartbeat" logic may need some rethinking...maybe send data every 5 seconds and instantly upon change...maybe something different.

The MSG instruction can't do single bits, the smallest amount of data would be a single 16 bit "word". But the overhead to do a single word is large enough that I typically do at least ten integers even if 9 and a half of them are spares for future use.

You cannot edit a MSG instruction online in a Micrologix (but you can with a SLC).

The way the message instruction behaves is pretty much the same for all RSLogix 500 processors, but the details of setting them up vary widely when you move from a SLC to a Micrologix, so we need to know exactly what CPU types you're connecting to advise further.
__________________
You've been taken, but you don't know it yet.
  Reply With Quote
Old April 16th, 2021, 05:02 PM   #8
johnlocke
Member
United States

johnlocke is offline
 
Join Date: Apr 2021
Location: Tennessee
Posts: 3
It is 2 SLC 500 processors. I’m trying to conserve as much memory as possible here. Would Remote I/O be another good way of going about this?
  Reply With Quote
Old April 19th, 2021, 12:12 AM   #9
RET
Member
United States

RET is offline
 
Join Date: Feb 2015
Location: Houston, TX
Posts: 257
Convert the slave plc rack into a remote i/o rack for the master processor.
__________________
This statement is false.
  Reply With Quote
Reply
Jump to Live PLC Question and Answer Forum

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Topics
Thread Thread Starter Forum Replies Last Post
S7-1200 to S7-300 Plc Communication TAMILARASAN LIVE PLC Questions And Answers 10 December 28th, 2017 12:48 AM
PLC to PLC communication shailesh_vb LIVE PLC Questions And Answers 2 January 28th, 2017 07:10 AM
RS-485 2-wire communication from S7-1200 PLC (CM 1241) Fahadamir LIVE PLC Questions And Answers 0 May 27th, 2016 07:13 AM
omron cp1h plc communication issue prusty.purna1 LIVE PLC Questions And Answers 2 March 14th, 2013 09:09 PM
[S5-155U CPU948]About PLC Communication Question. apple LIVE PLC Questions And Answers 2 July 20th, 2006 06:07 AM


All times are GMT -4. The time now is 04:15 AM.


.