Network Variable Publisher

The BeckhoffTwinCAT Real-Time Ethernet solution contains from TwinCAT v2.9 on the ability to configure variables for deterministic data exchange between several TwinCAT-based controllers. The last could be other TwinCAT PCs or CX controllers. These variables are the so-called Network Variables. For this solution it is required to configure the Ethernet Miniport (Real-Time) I/O device type at first.

For an Overview of TwinCAT Real-Time Ethernet devices, see..

The Publisher is the send-type network variable. It sends its information out without waiting for acknowledgement. The communication is only monitored by the Subscriber.

"General" dialog

Network Variable Publisher 1:

Standard dialog as for all TwinCAT I/O devices. Nevertheless, a descriptive name for this Publisher (sender) should be edited here. Additionally, a useful comment (i.e. about the target/subscriber this publisher sends its data to) could be very helpful.

Id: A Real-Time Ethernet Publisher ident. number.

Network Variable Publisher 2:

If several Publisher variables must be set up in same network at other TwinCAT controllers, make sure that they all have network-unique Id's (means in above case for instance, that '1' is already in use and can't be assigned to a second Publisher network variable).

"Publish" dialog

Network Variable Publisher 3:

Sending Options

Broadcast: If this option is selected and the node receives the Ethernet frame in its receiving queue, it evaluates whether the data is addressed to him or not. This is not a very "economical" way of communication.

Multicast: If this option is selected, the Ethernet frame is getting evaluated by all attached nodes of the subnet. But instead of processing it with the receive queue, the Ethernet controller detects whether the data is for "him" or not.

Unicast: If selected, the switch opens parallel communication paths and forwards the Ethernet frame directly to the appropriate Subscriber (receiver).

MAC Address: Subscriber MAC Address. For further information, see: Ethernet Miniport (Real-Time)

AMS Netid: ...

Data Exchange: see:BK9000

BK9000

VLAN Support: see: BK9000

BK9000

Diagnosis

Network Variable Publisher 4:
Inputs

Variable

Description

FrameState

Real-Time Ethernet frame status information as WORD (or UINT) variable, assumes the following values:


0x0001 = Not sent (frame skipped), means FrameCtrl is currently = '1'
0x0002 = Error (frame oversized)

Outputs

Variable

Description

FrameCtrl

Real-Time Ethernet frame control as WORD (or UINT) variable, accepts the following values:


0x0001 = Disable sending

If FrameCtrl receives above value (e.g. from mapped PLC variable), this frame doesn't get sent. The sending will be continued if FrameCtrl has been released again (= '0'). The FrameState variable assumes the value '1' in the meantime. The related subscriber variables CycleIndex and Quality will notice on the other side that the frame transmission has been suppressed.

Context menu

Network Variable Publisher 5:

Insert Network Variable: Please see description under Subscriber

Other items: Please see Adding Input/Output Modules

Publisher variable - Outputs

Network Variable Publisher 6:

Requirements

Variable

Data type

Description

VarCtrl

UINT

Can be set to 0x0001 = Disable publishing

The transmission of this publisher variable is suppressed in above case (until VarCtrl becomes '0' again). The subscriber CycleIndex variable stays static and the Quality counts up (to a maximum of 65535).

VarData

as specified

To be linked to the output variable (e.g. PLC output) to be transmitted via TwinCAT Real-Time Ethernet.