Jacek
-
Posts
4 -
Joined
-
Last visited
Content Type
Profiles
Forums
Gallery
Events
Blogs
Downloads
Articles
Media Demo
Posts posted by Jacek
-
-
It should work,
Some remarks you'll find in the attachment
Thank you for your help - that really worked. The problem was that i didn't have the CARD INIT and SOCK INIT FB in one rung but in two separate rungs. Strange, because both were executed with "power-up" bit. And not very intuitive...
Thanks again
-
I just looked deeper into your code:
All initiate functions have to be 1 scan operation and you set for every scan. The best way is to use SB2 (PowerUp) as a condition
Thank you for you replay. I realized that by mistake I have attached wrong PLC project - it was the first version of the program (stupid of me ). Then I cut everything that was not necessary.
If you could see the project I attach now I would be really grateful. Here, executing the “connect†FB the PLC does not send a single frame through ethernet communication link.
-
Modbus TCP problem - the master does not establish the connection (Vision280)
As mentioned in the topic, my goal is to establish a Modbus TCP communication between two Vision280 but have some problems. I can do the “slave part†- with proper socket initialization and Scan_EX the PLC responds to Modbus TCP requests sent from a PC with TopServer. However, after hours of trying, I cannot start up the Master device. It seems that the Master does not even send a single datagram in order to establish a connection with the slave device.
I would appreciate any kind of help. And this is what I did...
Master PLC program:
- “Card init†with proper IP addresses.
- “TCP/IP Sock Init†for TCP protocol and “masterâ€.
- “Modbus IP config†with one slave defined.
- When: “Card Initialized AND Socket Initialized AND NOT Function in Progress AND NOT Socket Connected†I execute the TCP/IP Connect with proper remote IP and port.
- Then I have a Modbus IP R.H.R and Close socket but those FBs are never called.
Effect:
- after successful configuration (anyway, it seems so) the master does not send a single frame. I am sure of that as I connected my PC with point-to-point ethernet cable and used Wireshark to monitor the ethernet communication.
Trials:
- Both PLCs seems to be in order. Both could operate as slaves with no problem (I tested it with TopServer).
- During configuration I tried different Modbus IDs (also the stupid ones from the point of view of modbus communication network), that is: Master as 255 and Slave as 1, Master as 10 and Slave as 1, Master as 10 and Slave 255, Master and Slave 255.
- With direct connection of PC and PLC I couldn't detect any kind of PLC activity while invoking the “TCP/IP connect†FB.
- Even thought the 3 point, I tried the PLC to PLC communication – of course with no success. (“Ping†between the devices was OK).
System data I checked:
- SDW 39 (ethernet general error counters). If I am not very much mistaken (I cannot check it now) the counters were equal 0.
- SI 145 and SI 147 (those sockets I tried). After socket initialization the state was 14 (UDP ready). It was strange for me because I surly initialized the sockets for TCP protocol. So that part I do not understand...
I have to add that it is the first time when I use Unitronics so maybe I do not do some crucial initialization of something.
I would appreciate any kind of help of even hints about some more test I could perform. Maybe there are some more status words or error reports which I do not know about.
Modbus TCP - problem with Master
in Vision & Samba PLC + HMI Controllers & VisiLogic Software
Posted
Thank you for your remarks and information about SI145.
I've checked that underscore in the plc name doesn't matter.
There were no RHR function because i cut everything that was not crucial (anyway in the second plc project i've sent)
I appreciate your help