Jump to content

Recommended Posts

Hi all,

Hoping for some assistance here.  I have a new remote IO unit that I'm trying to bring online.  The issues I'm having appear to be with the TCP connection, I've attached a sample program of my main routine and modbus.  I have green/red flashing light on mod, green on link & solid red on IOS, on first startup I get a few flashes on active. 

Things to note;

- I have remote access setup on the same socket & it still functions ok - I have tried removing that port init with no luck.

- I can ping both the CPU & URB IO controller from my PC so no issue with actual network connectivity.

- I haven't looked  too much into the modbus code because the Socket is not healthy & that is holding those rungs out anyway.

- When I don't have a program attempting to make a TCP connection I have A green light on IOS,LINK & MOD

- I have verified the project with URB configuration & also attached that file.FORUPLOAD.vlp

Here are some pictures of what I am experiencing when I'm online.

Any help would be much appreciated.

Cheers,

Sam

IMG_2315.jpg

IMG_2314.jpg

IMG_2313.jpg

IMG_2312.jpg

Link to post
Share on other sites

Without looking at your program, your screenshots show some things that appear odd to me.  Why the use of SB13 on socket 3?  Are you changing that socket often?  It appears that you are using a set/reset system of latches to do your calling, but what runs/sequences them in the first place.  To me you are likely getting clashes in everything where the plc doesn't know what to do, or can't do it when asked.

I'd go back to basics and simply do one thing at a time.  Get the link going first and then build on that.

cheers, Aus

Link to post
Share on other sites
17 hours ago, Ausman said:

Why the use of SB13 on socket 3?

It looks to me like he's using it as a fallback to re-connect if the connection is lost for whatever reason. Since SB 150 is in series, SB 13 will do nothing as long as the connection is maintained.

Link to post
Share on other sites

I see that, I was more concerned he was using it in a repetitive socket change situation that might have been creating issues by things happening concurrently, hence the clarification wanted.

cheers, Aus

Link to post
Share on other sites
  • 2 weeks later...

Gents,

Still having issues with this TCP connection.  Ausman I took your advice and removed all of the code besides the TCP connect & I cannot get a connection (see photos)

I can ping both the CPU and URB-TCP no problem so I feel like it's something silly like a local port wrong?  

I know socket 3 functions ok because I can ping it & utilise remote operator on another port, what I'm unsure about is if it's working ok on port 502 & is my URB-TCP module definitely configured for local port #502?  I can't see anywhere that can be changed in the URB configuration? 

SB142 & 150 are showing an unhealthy condition?

Any help would be much appreciated.

Many thanks!!

 

IMG_2419.jpg.a927fdf9f22d06dd261a3922370c6009.jpgIMG_2418.jpg.2d28bda194780c01c2daf73fd1ba4e44.jpgIMG_2417.jpg.fe9c16a9b76a7087a005375e974b1896.jpgIMG_2420.jpg.0c0cb60a1849d9bae0e91965ed216c93.jpg

Link to post
Share on other sites

I might be misreading something here, but aren't your ports different?    20257 vs 502

Also, what happens if you split up your SB2 rung a fair bit.  Don't do everything related to an SB2 call in one rung.  ie  try just the TCP stuff in one rung, SD PWD in another etc.  It looks  like it should work ok, but in practice perhaps there is too much going on. 

A favourite saying here is that Unitronics doesn't charge for rungs.  Splitting things into separate rungs often makes trouble shooting much easier as well.

cheers, Aus

Link to post
Share on other sites

Hard to tell if this is the source of the problem, but you are using poor form with the MODBUS IP Connect sequence. It should look like the picture below. Note that you should Set a bit once the Configuration has occurred and Reset the bit after completion of the connection. Note also that the Function in Progress bit should be in series with the connection sequence.

image.png.8ebe1a8ed58837bb28293bf531ec3626.png

Link to post
Share on other sites

This is actually a Visilogic topic but we'll leave it here because it's already rolling.

Do NOT use the same socket for Remote Operator and Modbus communications.  You have four sockets available.  Set up socket 3 for 20257 and socket 2 for 502 and leave them be.

Using the new Ethernet I/O with Vision was added to Visilogic 9.8.90 and higher.  It's a bit of a complicated dance over Modbus TCP in the Vision, and there are some additional tools added to the Visilogic Tools menu, specifically "URB Remote I/O Configurator".  This creates some special xml files with the .urli extension that are imported into the Vision project that set the Struct blocks up to properly interface the the I/O's block sizes.

There's more to it than just verifying the URB I/O in that tool.  If you don't get all Struct blocks configured correctly then the I/O drop will barf because you're asking for things that don't exist.

@Sam.Newtouni - I looked at your FORUPLOAD program and there is way too much going on in there to focus on troubleshooting this problem, although it does look like you started by faithfully following the new Example project Unitronics provides. 

I was able to get a V350 talking to the new Remote I/O using the Unitronics example and modifying it to my configuration.  I have attached my example files.

For now, strip the serial modem stuff out of your program, re-compile everything,  and upload the following:

- specific details about your network - IP address of PLC and Remote I/O drop

- .vlp file

- .URCP file

- /Inputs/Inputs.ulri file

- /Output/Outputs.urli file

 

Joe T.

 

 

V350 Ethernet IO Demo.zip

Link to post
Share on other sites

Gents, 

I really appreciate all of the assistance here.  After reading your replies I'm now  almost positive my issue is around the socket - I was under the impression I had to use the same socket (3) and that it was a physical address (socket on the v1210) rather than a software address which I  now understand.  I'll also take your advice and tidy up the sequencing of everything.

I shall report back early next week - hopefully with a good result.

Many thanks!

Link to post
Share on other sites
On 9/6/2020 at 8:15 PM, Sam.Newtouni said:

I also took the time to tidy up the sequencing and make the improvements that you all mentioned.

You're still missing a few concepts. You need the Function in Progress bit in series with the Connect function. You also need the trigger bit, MB 3231 to be a Direct Contact, not a Positive Transition. Further, the Comms reset bit, MB 3230, should be a Positive Transition, though it really doesn't matter since you reset it at the end of the ladder rung (it's just poor form).

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...