UDP_Peer (FB)
FUNCTION_BLOCK PUBLIC FINAL UDP_Peer EXTENDS LConC IMPLEMENTS IPeer, IOptionConsumer
xEnable to TRUE.itfPeer can be contected with UDP_Receive, UDP_Receiver, UDP_Send and UDP_Sender.Send and Receive methods can also be used as an alternative to the related traditional function blocks.Sending or receiving multicast telegrams is only possible if the input itfMulticast has been assigned accordingly
with an IPAddressSet or IPv4Address.
- InOut:
Scope
Name
Type
Comment
Inherited from
Input
xEnableBOOLTRUE: Activates the defined operationFALSE: Aborts/resets the defined operationLConC
Output
xBusyBOOLTRUE: Operation is runningLConC
xErrorBOOLTRUE: Error condition reachedLConC
eErrorIDLConC
Input Const
itfAsyncPropertyInput
itfIPAddressIP Address of the specific Adpater for Receiving/Sending (The related Networkmask and Broadcast adresses for receiving will be calculated)
uiPortUINTReceive Port
itfMulticastOne or more Multicast Groups (optional)
Output
xActiveBOOLTRUE if the peer context is established
itfPeerThe established context of this peerValid, as longxActive=TRUE
Methods:
Receive
Receive2
Send
SetInitialValue
SetOptionProvider
Structure: