plc_begginer Posted February 15, 2023 Report Posted February 15, 2023 Hello. I'm begginier PLC Proggamer, and I need your advice ;) I have a problem a machine which has a PLC Controller Omron NJ101-9000 address IP: 192.168.250.1 Omron NA5-7W001 address IP: 192.168.250.2 2 x Keyence SR-751 Code readers : Keyence SR-751(communication EtherNET/IP) address IP: 192.168.250.31 and address second reader: 192.168.250.32 Communication device NU-EP1 (communication EtherNET/IP) adres IP : 192.168.250.30 Converter ADA RS232/485 / communication (EtherNET/IP) : 192.168.250.33 (for this device is connected manual code reader ) And added new device Zebra Printer ZT411 communication (EtherNET/IP) And now I want try nearest my problem... There is appearance problem with communication between devices. I looked that, this problem is between plc drvier, hmi, converter ADA, and Zebra printer. 1. When PLC devices has connection with Zebra it is possible send a few times data frame that a print label and after returned ErrorID in block SktTCPRcv. Errors code are : 2003, 2006, 2007. Problem is apperance independently, once communication power on without disconnect for 15 minutes, after returned is error and I have to restart connection. With manual reader code is similar situation, and they told me, that problem looked when printer has been added. 2. If I am in monitoring mode with PLC Program (computer is connection with network (I have changed a few many times address IP, but it not help)) panel is power on with a big latency, but when I disconnected problem dissapear. 3. When I change only for example one switch from NO contact to NC contact and I am online and I want to download my changes I waste communication between PLC and HMI, and after I have to restart whole machine... I'm waiting for you answer. Thank you very much! Best regards.
pturmel Posted February 15, 2023 Report Posted February 15, 2023 You'll probably have to share your program to get detailed help with such a complex problem. First, though, check that you haven't misconfigured the two EtherNet/IP ports on the PLC--they cannot be in the same subnet, IIRC. Second,, you might have set your RPI for one or more devices unrealistically fast, and are bogging down your network. This would not usually be a problem if using a performant network switch, but old ethernet hubs would suffer. When Sysmac Studio is online, it generates a great deal of traffic to the PLC.
plc_begginer Posted February 16, 2023 Author Report Posted February 16, 2023 17 hours ago, pturmel said: You'll probably have to share your program to get detailed help with such a complex problem. First, though, check that you haven't misconfigured the two EtherNet/IP ports on the PLC--they cannot be in the same subnet, IIRC. Second,, you might have set your RPI for one or more devices unrealistically fast, and are bogging down your network. This would not usually be a problem if using a performant network switch, but old ethernet hubs would suffer. When Sysmac Studio is online, it generates a great deal of traffic to the PLC. Hello, Thank for you answer. I will show you my device settings and my code which is responsible on communication with other devices. 1. My settings RPI Keyence devices (maybe I should set more value RPI? : 2. My fragment code comunication between PLC and Converter ADA RS232/485 in which is connected manual code reader. 3. My fragment code comunication between PLC and Zebra ZT411 printer 4. Other setting which in my opinion could have a influence work this PLC controller (maybe I should change this value / settings?): 5. Maybe I should more up values : System service execution interval and System service execution time ratio? What do you think?
pturmel Posted February 16, 2023 Report Posted February 16, 2023 1. Those are reasonable RPIs. 2. Didn't look close. Probably not a factor. 3. Same 4. That is a reasonable task time, unless the monitoring page shows little leeway. If so, consider adding a periodic task at about ½ your RPIs to run the logic for the EtherNet/IP devices. 5. Possibly a larger %. I've not had to change those, but I don't have much in the field yet using this processor family.
JYG Posted February 20, 2023 Report Posted February 20, 2023 With TCP you must care of socket status and close the socket if it's not _ESTABLISHED. Take care with SktTCPGetStatus() because the outputs are valid only when Done flag is TRUE and the socket is not closed. Use WireShark software to see what is the problem.
pturmel Posted February 20, 2023 Report Posted February 20, 2023 When using the built-in EtherNet/IP support, one doesn't use the socket instructions at all.
Michael Walsh Posted March 15, 2023 Report Posted March 15, 2023 On 2/19/2023 at 5:30 PM, pturmel said: When using the built-in EtherNet/IP support, one doesn't use the socket instructions at all. This is a true statement, but this also might point to his problem. He is using TCP Socket instructions in his code. These questions need to be answered: Are you intending to use EtherNet/IP Comms? If so, are you trying to use implicit or explicit communications? Or are you intending to use raw TCP/IP Commands? It looks like your code is using TCP/IP Commands, but your other comments imply that you are trying to use EtherNet/IP Communications. These are two different things.
JYG Posted March 15, 2023 Report Posted March 15, 2023 That's why I commented but I don't know what he want to do.
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