Create or delete ADS routes manually
This step describes how you can manually create or delete an ADS route directly from TwinCAT/BSD. To configure ADS routes from TwinCAT/BSD, the tool ads
can be used. The command ads
displays all available parameters. Already existing ADS routes are listed in the file StaticRoutes.xml
.
These settings are alternatively possible via the web interface of the Beckhoff Device Manager (see: Beckhoff Device Manager: web interface).
Proceed as follows:
- 1. Create the ADS route according to the following pattern:
[<target[:port]>] [OPTIONS...] <command> [CMD_OPTIONS...] [<command_parameter>...]
- 2. At
<target>
, use the host name, IP address, or Ams Net Id of the target system to create a new ADS route. - 3. For
<command>
use the commandaddroute
and the following options:
--addr=<hostname> or IP address of the routes destination
--netid=<AmsNetId> of the routes destination
--password=<password> for the user on the remote TwinCAT system
--username=<user> on the remote TwinCAT system (optional, defaults to Administrator)
--routename=<name> of the new route on the remote TwinCAT system (optional, defaults to --addr)
- 4. Enter the command
ads 192.168.0.231 addroute --addr=192.168.0.1 --netid=192.168.0.1.1.1 --password=1
--routename
=example.beckhoff.com
in the console.
- Create new ADS routes according to the pattern shown or delete the unneeded ADS routes in the file
StaticRoutes.xml
under the entries<Route>
.
---snipped---
<?xml version="1.0"?>
<TcConfig xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<RemoteConnections>
<Route>
<Name>example.beckhoff.com</Name>
<Address>192.168.0.1
</Address>
<NetId>192.168.0.1.1.1
</NetId>
<Type>TCP_IP</Type>
<Flags>64</Flags>
</Route>
<Route>
<Name>DESKTOP-RUCO4K9</Name>
<Address>192.168
.40.88</Address>
<NetId>192.168.
2.15.1.1</NetId>
<Type>TCP_IP</Type>
<Flags>64</Flags>
</Route>
</RemoteConnections>
</TcConfig>
---snipped---