ADS
The ADS (automation device specification) describes a device-independent and fieldbus independent interface for communication between Beckhoff automation devices running TwinCAT and other devices implementing this interface.
To enable ADS, add the following lines to your configuration.yaml
file:
# Example configuration.yaml entry
ads:
device: '127.0.0.1.1.1'
port: 48898
Service
The ADS component will register the service write_by_name
allowing you to write a value to a variable on your ADS device.
{
"adsvar": ".myvariable",
"adstype": "int",
"value": 123
}
Service parameters:
- adsvar: Name of the variable on the ADS device. To access global variables on TwinCAT2 use a prepending dot
.myvariable
, for TwinCAT3 useGBL.myvariable
. - adstype: Specify the type of the variable. Use one of the following:
int
,byte
,uint
,bool
- value: The value that will be written in the variable.