Closed KevinHwangAi closed 4 years ago
Please send a zipped wireshark capture. ec_receive_processdata(EC_TIMEOUTRET); is in principle not blocking. The program should continue.
Here is the Wireshk capture. soem_test.zip
Please do not send wireshark text files, the raw data files are much easier to parse for me with the help of wireshark. So a) capture, b) save (not save-as), c) zip, d) post here.
But nevertheless, the file looks ok. No problems with the slave or on the wire. So there must be something with your implementation or driver. Please try on another computer.
@ArthurKetels ,thanks for you help.I had changed to zip packet. When a message is sent to slave through ec_send_processdata(), there is no response from ec_receive_processdata(). I think it may be the slave sends back a message , but ec_receive_processdata() miss the receiving time? Is it possible?
What I see is a return time for the LRD and LWR packets of a little over 190us. This is quite long for only one slave. So my guess is that there is some packet coalescing going on in your linux NIC driver. See the drvcomment.txt file in the root dir of SOEM.
Even with this time the default timeout setting for SOEM is 2000us. Did you change these values?
Then check the return value of ec_receive_processdata(). A negative value will indicate a timeout. A positive value is the working counter. It should be 3 in your case.
I run the simple_test in ubuntu 18.04, when runs to ec_receive_processdata() ,
the program is blocked there,and the slave's processdata is no longer received.
Please tell me where the problem may be?