Beckhoff PLC
A Beckhoff CX controller or Industrial PC running TwinCAT can communicate with Reniway Edge through the TwinCAT ADS connector. This example walks through the PLC-side ADS route first, then the Reniway Edge connector setup.
What you need
| Necessities | Description |
|---|---|
| Reniway Edge | The edge device or server that will connect to the PLC. |
| Network connection | Ethernet connection between Reniway Edge and the Beckhoff PLC network. |
| Beckhoff PLC or IPC | A Beckhoff controller running TwinCAT. |
| PLC IP address | Static or reserved IP address of the Beckhoff PLC. |
| PLC AMS Net ID | The AMS Net ID of the Beckhoff PLC. |
| Reniway AMS Net ID | The local AMS Net ID configured for Reniway Edge. |
| ADS route access | Access to the Beckhoff Device Manager, TwinCAT XAE, or another route manager on the PLC. |
| PLC runtime ADS port | Usually 851 for TwinCAT 3 PLC runtime 1, or 801 for TwinCAT 2 PLC runtime 1. |
Example values
Use the values from the customer network. The table below is only an example layout.
| Item | Example value |
|---|---|
| Reniway Edge IP address | 192.168.101.50 |
| Reniway AMS Net ID | 192.168.101.50.1.1 |
| Beckhoff PLC IP address | 192.168.101.207 |
| Beckhoff PLC AMS Net ID | 192.168.101.207.1.1 |
| PLC runtime ADS port | 851 |
Preparing the Beckhoff PLC
Start by making sure the PLC and Reniway Edge can reach each other on the network. The PLC should have a stable IP address and the Reniway Edge IP address should not change after the route is created.
Find the PLC AMS Net ID
Open the Beckhoff Device Manager or TwinCAT route configuration for the PLC and note the PLC AMS Net ID.
On TwinCAT/BSD systems, the Beckhoff Device Manager is available in a browser:
https://[plc-ip-address]
In the Device Manager, open TwinCAT and then Connectivity. The PLC AMS Net ID is shown on the same page where ADS routes are managed.
Check the Reniway AMS Net ID
Open Reniway Edge and go to Settings > Connectors > TwinCAT ADS Connector.
Copy the Local ADS Net ID. This is the AMS Net ID that must be entered in the Beckhoff PLC route table. If you change it, apply the setting before creating or updating the PLC route.
For more details, see TwinCAT ADS Connector settings.
Add the ADS route on the PLC
In the Beckhoff Device Manager, open TwinCAT > Connectivity and add a route for Reniway Edge.
Fill in the route settings:
| Setting | Value |
|---|---|
| Route Name | A clear name, for example Reniway Edge. |
| AMS Net ID | The Reniway AMS Net ID, for example 192.168.101.50.1.1. |
| Transport Type | TCP_IP. |
| Address | The Reniway Edge IP address or hostname. |
| Connection Timeout (ms) | Use the site standard, for example 5000. |
| Temporary | Leave disabled so the route remains after a restart. |
Save the route. If the PLC asks for a restart of TwinCAT, the ADS router, or the controller, schedule it with the machine owner before continuing.
Check ADS network access
The PLC must accept ADS traffic from Reniway Edge. For classic ADS/TCP, the firewall path to the PLC must allow TCP port 48898.
Do not confuse this with the Reniway connector Port field. In the Reniway connector, 851 means "TwinCAT 3 PLC runtime 1". The TCP firewall port for ADS/TCP is normally 48898.
On TwinCAT/BSD systems, unencrypted ADS/TCP can be disabled by firewall policy. If the connection times out even though the route is correct, check the Beckhoff firewall and site security policy.
Reniway Edge connection
Open Reniway Edge and add a new field connector.
Fill in the connector settings:
| Setting | Value |
|---|---|
| Name | A clear name, for example Beckhoff PLC. |
| Type | TwinCAT ADS. |
| IP Address | The IP address of the Beckhoff PLC. |
| PLC Net ID | The AMS Net ID of the Beckhoff PLC. |
| Port | The PLC runtime ADS port, usually 851 for TwinCAT 3 runtime 1. |
Save the connector and start the connection.
Add PLC properties
After the connector is connected, add the PLC symbols that Reniway Edge should read.
Typical first test symbols are simple scalar values from the PLC program, for example:
| PLC symbol | Example purpose |
|---|---|
MAIN.MachineState | Current machine state number. |
MAIN.MotorTemperature | Live motor temperature. |
MAIN.ProductCounter | Produced-parts counter. |
MAIN.ScrapCounter | Scrap-parts counter. |
Use symbol names that exist in the deployed TwinCAT PLC project. If a symbol cannot be read, verify the PLC project, symbol visibility, runtime state, and the selected ADS port.
Validation
After the connector is connected, check a few live values in Reniway Edge:
- The connector status is connected.
- The PLC symbols return values instead of errors.
- Values update when the PLC program changes them.
- Counters increase when the machine or test program runs.
- The connector reconnects after a short PLC or network interruption.
Troubleshooting
| Symptom | Possible cause | Solution |
|---|---|---|
| Reniway Edge cannot connect | Missing route on the Beckhoff PLC | Add a route on the PLC that points to the Reniway AMS Net ID and IP address. |
| Connection times out | ADS/TCP is blocked by firewall or routing | Verify network routing and allow TCP 48898 to the PLC for classic ADS/TCP. |
| Connection is rejected | Wrong Reniway AMS Net ID in the PLC route | Compare the route AMS Net ID with Settings > Connectors > TwinCAT ADS Connector in Reniway Edge. |
| Connector connects to the wrong runtime | Wrong ADS port | Use 851 for TwinCAT 3 PLC runtime 1, or the runtime-specific port used by the PLC project. |
| Symbols cannot be read | Wrong symbol name or PLC project state | Verify the symbol path in TwinCAT and confirm the PLC runtime is running. |
| Works until restart | Route was temporary | Recreate the route with Temporary disabled. |
Result
The Beckhoff PLC is now prepared for TwinCAT ADS communication and can be used as a live PLC data source in Reniway Edge.