Jump to content

Recommended Posts

I have three V430-J-RH6 PLC's, they will be communicating via RS-485. Each of these plc's are running two pumps for that specific unit.

My end game is to make sure that none of the units have pumps running at the same time so we don't have power issues, ex. Unit 1 is running a pump so unit 2 and unit 3 cannot run their pumps until unit 1 is finished etc. I know how to program that part in but my struggle at the moment is with how to best get that information to each PLC.

I need each PLC to have constant feedback of information from each other PLC. I need each unit to know when the other units are on and off. Is a struct command the best way to do this? If not what is, and how do I implement it? I have looked into the help files on Modbus master and slave for sharing information (read holding registers, and preset holding registers) but it doesn't look like they can share MB's between plc's? I also don't quite understand how those work.

Any help in this would be greatly appreciated!!

Thank you!

Unit 1 Governor Pump_7.31.18.vlp

Unit 2 Governor Pump_7.31.18.vlp

Unit 3 Governor Pump_7.31.18.vlp

Share this post


Link to post
Share on other sites

MODBUS command #1 is Read Coils. Coils are MBs.

Also, look into "Read/Write Mixed Data". It is unique to data exchange between Unitronics PLCs and is usually the simplest solution for exchanging data via MODBUS.

Share this post


Link to post
Share on other sites

I don't have time right now to go through all three programs in detail, but at first glance I'll say don't try to communicate on every PLC scan. Put a timer or SB 7 in front of the Read/Write Mixed Data block.

There are example programs that came with your VisiLogic installation. Review the ones for MODBUS communications to learn proper technique.

Share this post


Link to post
Share on other sites

I have attached a photo of my Master Main Routine. Does anyone see an issue with what I have here? It was partially working this morning and now it isn't working at all.

modbus Issues.png

Share this post


Link to post
Share on other sites

You're still trying to communicate on every PLC cycle (for 100ms at a time). Try using a positive transition on SB 7 in rung 3 and a negative transition in rung 4.

Share this post


Link to post
Share on other sites

Your COM INIT and Modbus Config timeout is longer than your poll time.  If you block gets an error you're not allowing it to "cool off".

I'd stretch out the poll time to at least 5 seconds for starters and stagger the R/W block calls - don't tell the PLC to do more than one thing at once.

Post one copy of your current code. 

Joe T.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...