Beckhoff / ADS

Beckhoff protocol to communicate with TwinCAT devices.
MIT License
502 stars 194 forks source link

Port 0x353 is out of range (only on linux) #97

Closed michieldwitte closed 4 years ago

michieldwitte commented 4 years ago

I have a working example on windows to read out a variable by name. I can not seem to get this to work on linux. The contents of the requests looks the same in wireshark. The PLC echo's the Linux AMS Request, the windows request receives a valid answer.

I've tried using the example.cpp and the pyads wrapper. This leads to the same output:

2019-08-21T14:47:32+0200 Info: Connected to 10.0.0.48
2019-08-21T14:47:32+0200 Warning: Port 0x353 is out of range
2019-08-21T14:47:32+0200 Warning: No response pending

wireshark captures.zip

Am I missing something here?

pbruenn commented 4 years ago

Your linux.pcapng looks weird. AMS NetId and Port should change between sender and target but in both of your packets they keep the same, even if the IP and MAC address changes. Could you elaborate a little more about your setup?

michieldwitte commented 4 years ago

I rechecked the routing and manually re-entered it and it solved the problem, thanks and sorry for wasting your time.