geMeHTop Posted February 4, 2014 Report Share Posted February 4, 2014 Hello! I am new here. I have an object with such structure: Building 1 = Eka1 = E1: V570 - IP address 192.168.186.3 , PLC name = PLC1, can id #1 V120 - can id#2 V120 - can id#3 V120 - can id#4 V120 - can id#5 V120 - can id#6 V120 - can id#7 Building 2 = Eka2 =E2: V350 - IP address 192.168.186.4 , PLC name = PLC2, can id #1 V120 - can id#2 V120 - can id#3 Building 3 = Izolators = Izo: V350 - IP address 192.168.186.5 , PLC name = PLC3, can id #1 V120 - can id#2 V120 - can id#3 V120 - can id#4 Data between V120 and V350, or V120 and V570 sends with Unican. In most cases there is no problems with this transfers, But week ago started problems with UDP_RAW sending between E2 V350 and E1 V570, and between Izo V350 and E1 V570. Here is image of VisiLogic programm: in program i try to UDP_RAW scan IP address 192.168.186.4 (start vector MI1170), but when i online connect to V570 he shows IP address 192.168.186.5?! WHO changes number in MI1173 (i put 4 here , but in online mode 5!!!), if i use this MI only one time in a programm... I checked SB141-146 in Izo_V350 , there was "1" in this system bits. I checked SB141-146 in E1 V570 , there was "1" in this system bits. I think E1 , E2 and Izo connected to a single network with switch. Also PC with 192.168.186.2 IP address connected to this netowrk. I can ping 192.168.186.3, 192.168.186.4, 192.168.186.5 from PC in command line. What i should check next? Ty for advices. P.S. links to images http://s020.radikal.ru/i716/1402/7b/6371416aeafb.png http://s019.radikal.ru/i635/1402/db/fd7f6e267643.png Link to comment Share on other sites More sharing options...
Eyal Koren Posted February 5, 2014 Report Share Posted February 5, 2014 Hi, There can be many reasons for MI values to be changed unwantedly. A common reason can be a request sent to one of the slaves in the UniCAN network, which in returns write a different value to the MI. For keeping your IP adress unchanged you have two options: 1. set your IP as a static adress (and not as MI's). 2. keep your IP in a read-only data table. In that manner it cannot be changed. If the problem persists, feel free to contact us at support@unitronics.com Link to comment Share on other sites More sharing options...
geMeHTop Posted February 5, 2014 Author Report Share Posted February 5, 2014 Hi, There can be many reasons for MI values to be changed unwantedly. A common reason can be a request sent to one of the slaves in the UniCAN network, which in returns write a different value to the MI. For keeping your IP adress unchanged you have two options: 1. set your IP as a static adress (and not as MI's). 2. keep your IP in a read-only data table. In that manner it cannot be changed. If the problem persists, feel free to contact us at support@unitronics.com Hello. I checked UniCAN network controllers (V120), they write data to another MI registers. Can u give me,please, a link to document (documents) describing procedure with static adress. Thank you. Link to comment Share on other sites More sharing options...
Eyal Koren Posted February 5, 2014 Report Share Posted February 5, 2014 No need for any procedure description, just go to TCP/IP Card Init and define a constant IP Link to comment Share on other sites More sharing options...
geMeHTop Posted February 5, 2014 Author Report Share Posted February 5, 2014 No need for any procedure description, just go to TCP/IP Card Init and define a constant IP Static_IP.jpg I made TCP/IP Card init to all PLC (E1 V570, E2 V350, Izo V350) and defined a constant IP adresses. (Numbers In first post) I have a problem with UDP_RAW scan function in E1 V570. I need to write IP of remote PLC in UDP_RAW Scan parameter field Remote IP (The IP of the device that sent the data Note that this will user a vector of 4 MI). I Put IP addres of PLC with data (with power up) in MI1170 (192) ,MI1171 (168) ,MI1172 (186) .MI1173 (4), but when i connect to E1 V570 i see this numbers in MI registers MI1170 (192), MI1171 (168), MI 1172 (186) , MI1173(5). So E1 V570 Scan Izo V350 with IP 192.168.186.5 , not the E2 V350 with IP 192.168.186.4. Thank you. Link to comment Share on other sites More sharing options...
geMeHTop Posted February 5, 2014 Author Report Share Posted February 5, 2014 Here is images Link to comment Share on other sites More sharing options...
Eyal Koren Posted February 5, 2014 Report Share Posted February 5, 2014 I made TCP/IP Card init to all PLC (E1 V570, E2 V350, Izo V350) and defined a constant IP adresses. (Numbers In first post) I have a problem with UDP_RAW scan function in E1 V570. I need to write IP of remote PLC in UDP_RAW Scan parameter field Remote IP (The IP of the device that sent the data Note that this will user a vector of 4 MI). I Put IP addres of PLC with data (with power up) in MI1170 (192) ,MI1171 (168) ,MI1172 (186) .MI1173 (4), but when i connect to E1 V570 i see this numbers in MI registers MI1170 (192), MI1171 (168), MI 1172 (186) , MI1173(5). So E1 V570 Scan Izo V350 with IP 192.168.186.5 , not the E2 V350 with IP 192.168.186.4. Thank you. Obviously MI1173 is being overwritten. Try changing the operands defining the IP adress from MI1170 (to isolate the problem make sure that the new operands aren't defined in any other controllers (E1,E2,IZO)). If the problem persists please send the application to support@unitronics.com Link to comment Share on other sites More sharing options...
geMeHTop Posted February 5, 2014 Author Report Share Posted February 5, 2014 Actually i already tried to change defining IP address from MI. In start it was MI1070 (from E2 V350) and MI1080 (from Izo V350). I putted MI1170(to E2 V350) and MI1080(from Izo V350). Result in MI1170-MI1173 (IP adress from Izo V350, not from E2 V350...). And in 2 x UDP_RAW scans i get data from Izo V350 I putted MI1170(to E2 V350) and MI1180(from Izo V350). Result in MI1180-MI1183 (IP adress from E2 V350, not from Izo V350...). And in 2 x UDP_RAW scans i get data from E2 V350 I use TCP/IP Sock init parameters in all (three) PLC: Socket 3; UDP_RAW; D#20260 In Project=>TCP/IP Project Setting for E1 V570 i have 192.168.186.3 ; TCP; 20256; PLC1 Can u explain me,please, this parameteres Project=>TCP/IP Project Setting, what we configure here.. Also i checked UniCan=>no one use this adresses (MI1070,MI1080,MI1170,MI1180) Also in F1 help about UDP_RAW i found this text: Use this to monitor message status. Is reset by OS when the element activates. If before scan procedure i store number "4" in MI1173, after or during scan procedure i got "5" number in MI1173. Maybe this UDP block make stamp on what data recieved in this MI, or something like this? Thank you Links to blinking from 4 to 5: Link to comment Share on other sites More sharing options...
Eyal Koren Posted February 5, 2014 Report Share Posted February 5, 2014 I think i understand what is happening: You use two consecutive UDP_RAW Scan function blocks that are using the same socket and port (in the same system scan). I suppose that these two are being mixed up somehow and messing up your IP adress. Do the following: 1. disable the rung with the first UDP_RAW Scan function block (the one that refers to MI1170 as the IP adress). Download and run the application. If MI1183 will not change to 5 it means that we found the problem. 2. Add a TCP/IP socket init FB to the application and define it as UDP with an unused socket and port. 3. Define one of the UDP_RAW Scan function blocks with the freshly defined socket parameters. Please let me know if that worked for you Link to comment Share on other sites More sharing options...
geMeHTop Posted February 5, 2014 Author Report Share Posted February 5, 2014 Ok i will try to test it today. Now i lost remote connection with this units, probably because of this sockets... I will be in object soon and try to download new application with different sockets through serial port. I think it will work. I will let u know tomorrow if it will work. So 1 of 4 sockets can only communicate with one device?? Or i need to make logic in programm to communicate through one socket to many devices. (For example first data transfer done , i make second , second done i make third...?) Or i need to use another ports of one socket ? Thank you Link to comment Share on other sites More sharing options...
Eyal Koren Posted February 5, 2014 Report Share Posted February 5, 2014 Ok i will try to test it today. Now i lost remote connection with this units, probably because of this sockets... I will be in object soon and try to download new application with different sockets through serial port. I think it will work. I will let u know tomorrow if it will work. So 1 of 4 sockets can only communicate with one device?? Or i need to make logic in programm to communicate through one socket to many devices. (For example first data transfer done , i make second , second done i make third...?) Or i need to use another ports of one socket ? Thank you In general, when using UDP connection there is no limit to the devices that can communicate over the same socket, although there will be a chance of packets being lost due to the charactheristics of the protocol. As an alternative, you can add a term to the application that will activate only one UDP scan FB every 500mS (for instance). Again, this could mean losing some of the packets being sent from the PLC not being scanned at the moment. The best way will be using a different socket (if you have one to spare). As an alternative, you can change the protocol from UDP to TCP - which means more reliable communication. However, It will take some reprogramming to do... Link to comment Share on other sites More sharing options...
geMeHTop Posted February 6, 2014 Author Report Share Posted February 6, 2014 In general, when using UDP connection there is no limit to the devices that can communicate over the same socket, although there will be a chance of packets being lost due to the charactheristics of the protocol. As an alternative, you can add a term to the application that will activate only one UDP scan FB every 500mS (for instance). Again, this could mean losing some of the packets being sent from the PLC not being scanned at the moment. The best way will be using a different socket (if you have one to spare). As an alternative, you can change the protocol from UDP to TCP - which means more reliable communication. However, It will take some reprogramming to do... Yesterday i downloaded new application with using one socket only one time. From E2 V350 to scada i recieve data through UniOPC i think From Izo V350 i send data to V570 and though UniOPC i recieve data on scada When i came to PC (with scada) seems it was ok, recieved data from all building changed every ~3 seconds (E1, E2, Izo) But today i tried to ping Izo V350 from PC with scada and cant ping it... E2 V350 pings fine E1 V570 pings fine 1) So now i must connect to Izo V350 with serial and check system bits ?? and system integers?? (which) How i can find the problem why i loose connection with Izo V350? 2) Can u give me an example with TCP sending...or check this, please. What i want to do: From E1 V570 i want to send to Izo V350 through socket 3 (master in V570) port 20257 to socket 3 (slave in V350) port 20257 - 10 bytes (5 integer) In E1 V570 i want to recieve data from V350. Socket 2 (slave in V570) port 20256 and socket 2 (master in V350) port 20256 - 54 bytes (27 integer) Is TCP setting ok in this projects..? Thank you V350_TCP_RAW_Master&slave.vlp V570_TCP_RAW_Master&slave.vlp Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now