|
#1 |
Lifetime Supporting Member
Join Date: Feb 2015 Location: Yokohama Posts: 1,230 |
ADS Error 1861, TwinCAT Hello: I have a TwinCAT embedded PLC and for years I was able to access it through the AMS NetID. Recently updated Windows 10 and I was not able to communicate with the PLC from the TwinCAT engineering tool which is running on this Windows 10 workstation. Somewhere in the web I read there are problems with some of the latest Windows 10 updates (which I install regularly), and the article suggested that Beckhoff would provide a fix, so I downloaded and installed TC31-Full-Setup.3.1.4024. 10 but still get the same error (before that version I used TC31-Full-Setup.3.1.4024. 4 for several months). I am sure the PLC is working OK because I do have one Windows 10 workstation which can actually communicate with this PLC. But the two workstations which I use the most can’t. |
|
|
|
#2 |
Lifetime Supporting Member
Join Date: Feb 2015 Location: Yokohama Posts: 1,230 |
I add a bit more information… |
|
|
|
#3 |
Member
Join Date: Jan 2019 Location: Finland Posts: 61 |
Try to add route with ip address noy hostname. Don’t know if that is the issue, but i use always ip address. |
|
|
|
#4 |
Member
Join Date: Apr 2020 Location: Davenport, Iowa Posts: 62 |
I don’t know your software, but one thought with windows 10 is firewall, I have had issues with win 10 firewall, shut down and worked for me then went back and did allow certain programs thru firewall in settings, just a thought. |
|
|
|
#5 |
Lifetime Supporting Member
Join Date: Feb 2015 Location: Yokohama Posts: 1,230 |
Quote: Originally Posted by Jkoso Try to add route with ip address noy hostname. Don’t know if that is the issue, but i use always ip address. Hello. I tried both, same result. |
|
|
|
#6 |
Lifetime Supporting Member
Join Date: Feb 2015 Location: Yokohama Posts: 1,230 |
Quote:
Originally Posted by AkaHammer I don’t know your software, but one thought with windows 10 is firewall, I have had issues with win 10 firewall, shut down and worked for me then went back and did allow certain programs thru firewall in settings, just a thought. Hello: Disabling the firewall does not do the trick. |
|
|
|
#7 |
Lifetime Supporting Member
Join Date: Feb 2015 Location: Yokohama Posts: 1,230 |
This is an old post but since I found the solution I wanted to post it here as this is likely to happen, so i hope it can be helpful. Beckhoff Japan provided this very useful advice and I was able to connect the TwinCAT engineering environment with the runtime TwinCAT in the PLC. This ADS error occurs when the network route is physically disconnected or blocked by firewall. For ADS connection, 48898/TCP and 48899/UDP are required the exception. Secure ADS can not establish connection with Build 4022 and lower. I found that I needed to open ports in the the firewall settings on both the actual IPC and the Windows 10 workstation hosting the TwinCAT engineering tool. I hope this is useful to TwinCAT users. |
|
|
After trying to start the run mode, I get a fatal error on the target system :
Init7IO: Set State TComObj PREOP OP >> AdsWarning: 1861 (0x745, ADS
ERROR: timeout elapsed) Anyone of you know how to fix it??
Joe Mayo
7,4817 gold badges42 silver badges60 bronze badges
asked Jun 16, 2018 at 23:23
Is your target system running Windows 10? Has it recently been updated (Windows Update) to version 1803? If so, the problem is because TwinCAT is not compatible with the 1803-version of W10. Beckhoff did release an updated TwinCAT version 3.1.4022.20, but removed it as it caused other problems. They will release a new version in the coming days.
answered Jun 17, 2018 at 8:20
JakobJakob
1,2387 silver badges13 bronze badges
3
That often occurs when you have EtherCAT bus in the system and there are problems. For example you could have an EtherCAT slave configured and it is not found when trying to start the system. So check you I/O configuration.
Of course, the problem could also be the one that Jakob described.
answered Jun 18, 2018 at 6:24
QuirzoQuirzo
1,0518 silver badges9 bronze badges
1
We ran into intermittent 1861 (0x745) errors with Twincat2 on Win10 version 1809 communicating with a CX8090. We did not see the intermittent 1861 errors on Win10 version 1709.
Based off of Jakob’s, answer we tried updating the TcAdsDll.dll and AdsDll.dll from the latest Twincat 2.11 x64 Engineering release install (which was 2305) and it resolved our intermittent 1861 errors.
I’m not sure if anyone else out there still uses Twincat2, but this might help someone else searching for a solution to the 1861 error code.
answered Oct 31, 2019 at 15:27
JoelJoel
1372 silver badges7 bronze badges
Yes, your issues sounds related. I will answer here and close #56 as duplicate.
Do you use AdsSetLocalAddress()
to set your AdsLib AmsNetId?
void AdsSetLocalAddress(AmsNetId ams); |
Check which AmsNetId your local TwinCAT router would use when you connect using «direct-fb»(TcAdsDll.dll). Either look into the routing table of your TwinCAT server or check the router setting on the client like this:
Then before you open any AdsPort in your AdsLib example. Call AdsSetLocalAddress()
with that AmsNetId
diff --git a/example/example.cpp b/example/example.cpp
index fe893a2..833fa4c 100644
--- a/example/example.cpp
+++ b/example/example.cpp
@@ -180,6 +180,8 @@ void runExample(std::ostream& out)
static const AmsNetId remoteNetId { 192, 168, 0, 231, 1, 1 };
static const char remoteIpV4[] = "ads-server";
+ AdsSetLocalAddress({192, 168, 0, 114, 1, 1});
+
// add local route to your EtherCAT Master
if (AdsAddRoute(remoteNetId, remoteIpV4)) {
out << "Adding ADS route failed, did you specified valid addresses?n";
For more background see commit c1bfedd and let me know if this didn’t fix your issue.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.