Sign in to follow this  
Followers 0
Mike Sisk

How to move data from CLX to PLC 5 over ethernet

4 posts in this topic

I need to send a dint from a clx proccesor to a plc 5 using an ethernet connection, any suggestions?

Share this post


Link to post
Share on other sites
MSG instruction will work. Keep in mind DINT is 32 bits and PLC-5 is 16-bit memory. So the data will occupy two words in the PLC-5. Do you need to do this transfer when the data changes in the CLX or would it suffice to have the PLC-5 read the data from the CLX every xx seconds? The answer to this determines whether you use a MSG Write in the CLX or a MSG Read in the PLC-5. If you need more details on MSG configuration, I can help. Let me know which way (Write or Read) you want to do it. Bill Edited by Bill Linne

Share this post


Link to post
Share on other sites
There are several examples in the AB knowledgebase. Have you looked there?

Share this post


Link to post
Share on other sites
Greetings Mike ... see if this helps ... the basic idea is to take the BIT PATTERN from a DINT (tagname: My_DINT) in the CLX - and have the CLX write the bit pattern into two consecutive Integer locations (N7:0 and N7:1) in the PLC-5 ... the SWPB instruction swaps the bytes in the original My_DINT tag around - and stores them in a new DINT (tagname: Send_DINT) before the values are transmitted ... that way the bits are in the correct order when they land in the PLC-5 ... note that the bits might not make any sense NUMERICALLY/MATHEMATICALLY - but they should at least be in the correct/same order as they were in the original My_DINT tag ... that's what you wanted, right? ... now the big question is what do you plan to do with that BIT PATTERN – since it's now been split into TWO locations rather than one? ... let's assume that you've got that piece of the puzzle already figured out – and see if this part moves you further along ... depending on what you plan to do with this data, you might want to post again and tell us what you're planning ... remember that the MSG command is NOT synchronized with the rest of the scan - so it's possible to run into a timing problem and transmit gibberish to the PLC-5 ... give me a phone call if you have questions about this example ... I've got more time to talk these days than I do to type ... Off Topic: both of the attachments below were uploaded the same way ... both got automatically "reduced" in size by the forum (not that there's anything wrong with that) ... to re-enlarge the first one, you have to click the black bar at the top - not the image itself ... but ... to re-enlarge the second one, you have to click the image - not the black border around the image ... no problem - just weird ... Edited by Ron Beaufort

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
Sign in to follow this  
Followers 0