Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Timed out" Issue #39

Open
A-Badkoubeh opened this issue Feb 10, 2018 · 4 comments
Open

"Timed out" Issue #39

A-Badkoubeh opened this issue Feb 10, 2018 · 4 comments

Comments

@A-Badkoubeh
Copy link

I am using the example for Micrologix PLC. After a few minutes, I am getting "timed out". Any ideas what potentially can cause this "timed out"?

@A-Badkoubeh A-Badkoubeh changed the title "Timeed out" Issue "Timed out" Issue Feb 10, 2018
@lynnlinse
Copy link

You didn't give much info, but keep in mind that if you are 'routing' to get to the PLC, for example from your desk or control room to a factory floor, then a TCP/IP socket will likely 'die' very ungracefully if it is idle for 5 minutes. This is a router/firewall thing, unrelated to CIP timeouts. So if you are polling once a minute, then this isn't the problem, but if you have been idle, then try to talk, the socket might now be broken. You'd need to enable 'TCP keepalive' on the socket.

@A-Badkoubeh
Copy link
Author

A-Badkoubeh commented Feb 11, 2018

How can I enable 'TCP keepalive' on the socket?
Second, I need to reach 1ms speed for reading one Integer (e.g. N7:0) is it possible to reach this cycle time using Pycomm?
Thank you very much.

@davisjosephh
Copy link

If you get those kinds of speeds let me know what you did. As is, I struggle to keep my reads under 1s.

@Nsp2121
Copy link

Nsp2121 commented Aug 8, 2018

I have the same issue with this
for reading one tag it takes about 60-70 ms and i am reading 18 tags in a while loop
the problem arise when i write a plc tag from another script and just after writing tag, on the first script its throws :

Traceback (most recent call last):
File "experiment-initial-screen.py", line 18, in
valve_class = c.read_tag('N7:2')#old N7:3
File "/home/hydro/.local/lib/python2.7/site-packages/pycomm/ab_comm/slc.py", line 271, in read_tag
addr_data=self._target_cid,)):
File "/home/hydro/.local/lib/python2.7/site-packages/pycomm/cip/cip_base.py", line 590, in send_unit_data
self._receive()
File "/home/hydro/.local/lib/python2.7/site-packages/pycomm/cip/cip_base.py", line 770, in _receive
raise CommError(e)
pycomm.cip.cip_base.CommError: timed out

it happens every time i do a read or write operation simultaneously
any ideas?
Actual visualization : Stackoverflow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants