UDP Data 'Connections'
|Top Previous Next|
The notion of data connection is native to TCP/IP since this is a connection-based protocol. UDP/IP, however, is a connection-less protocol in which all packets (UDP datagrams) are independent from each other. How, then, the term "DS data connection" applies to the UDP transport protocol?
With UDP transport protocol true data connections (in the "TCP sense" of this term) are not possible (hence, quote marks around the word "connection"). The DS, however, attempts to mimic the behavior of TCP data connection whenever possible. Follows is the detailed description of UDP "connections" and their similarities and differences from TCP connections.
Incoming "connections"*. There is no connection establishment phase in UDP so an incoming UDP "connection" is considered to be "established" when the first UDP packet is received by the DS from the network host (on the port defined by the Data Port Number (PN) setting). Similarity with TCP is in that after having received the packet from the network host the DS knows who to send its own UDP packets to. [V3.24/3.54]: When Current Source IP Filtering [setting/parameter] is 1 (enabled) the DS ignores UDP datagrams that arrive from any IP-address other than the one matching current Destination IP-address (DI) [setting/parameter/instruction] (unless Destination IP-address is set to 255.255.255.255- see broadcast UDP communications).
Outgoing "connections"**. The DS establishes outgoing UDP connection by sending a UDP datagram to the targeted destination (defined by the current Destination IP-address (DI) [setting/parameter/instruction] and current Destination Data Port (DP) [setting/parameter/instruction]). If there is a data that the DS needs to send to the network host then the DS sends the first UDP datagram with (part of) this data. If there is no immediate data that needs to be sent to the network host then the DS sends the first UDP datagram of zero length. This happens when the Connection Mode (CM) setting is 0 (connect immediately). The purpose of this is to let the other side know the MAC-address, IP-address, and the data port of the DS.
Data transmission and destination switchover. Once the "connection" is established the DS and the network host can exchange the data. The difference with TCP is that if another network host sends a datagram to the DS then the DS will interpret this as a new incoming "connection"*, forget about the IP-address of the first network host and start sending its own UDP datagrams to the IP-address of the second network host. In other words, the DS will always send its own UDP datagrams to the IP-address of the "most recent sender". The only exception is the case when the current Destination IP-address is 255.255.255.255- see broadcast UPD communications.
"Connection" termination. There is no connection termination phase in UDP so DS "terminates" its UDP connections by simply "forgetting" about them and the only event that can trigger UDP "connection" termination is connection timeout (defined by the Connection Timeout (CT) setting).
* Assuming that incoming connections are allowed (i.e. current Routing Mode [setting/parameter] is either "server", or "server/client") AND [V3.24/3.54]: Current Source IP Filtering [setting/parameter] is 0 (disabled)