A communication interface (for now only PROFINET, other protocols are not supported) needs to be defined in a module in the *.hwl.json. There are two types of interfaces available, either a built-in interface or a pluggable interface:
- Built-in interface: An interface that is integrated into the module and will always be present. It is identified by the
Labelproperty which typically corresponds the label printed on the physical module. - Pluggable interface: An interface that can be plugged into the module. It is identified by a type identifier.
An interface has an optional Slot property defining the location of an interface within the device. It can only be interpreted in the case of built-in interface. If the Slot property is not defined, the interface will be plugged in the first free slot.
An interface has an optional Addresses property as well for defining the addresses of that interface. Within the Addresses object, there can be configured/hard-coded addresses.
The Configured property is a list of objects. Each of these objects defines a single address and has a single property denoting the type of address being configured. For now, only the following is supported:
-
IPv4: An IPv4 address must be configured with an associated subnet mask in Classless Inter-Domain Routing (CIDR) notation (e.g.192.168.0.10/16which corresponds to255.255.0.0as subnet mask). -
ProfinetDeviceName: Profinet device name (or "Name of Station")- DCP Utility can be used to discover or set Profinet device names.
- If no
ProfinetDeviceNameis set, a default name will be assigned- Distributed IO devices will be assigned the head module as Profinet device name
- Controllers will get assigned a Profinet device name of
<DEVICE NAME>.<INTERFACE NAME>
{
"Devices": [
{
"Name": "1500",
"Modules": [
{
"Name": "PLC_1",
"TypeIdentifier": {
"OrderNumber": "6ES7 516-3AN01-0AB0",
"Version": "V2.9"
},
"AccessProtection": {
"AccessLevel": "NoAccess"
},
"Interfaces": [
{
"Name": "BuiltIn_Interface",
"Label": "X1",
"Addresses": {
"Configured": [
{ "IPv4": "192.168.0.10/24" },
{ "ProfinetDeviceName": "plc_2.builtin_interface" }
]
}
},
{
"Name": "Interface2",
"Label": "X2"
}
]
}
]
}
]
}