500: UDP theoretical question
Posted on 2006-03-31
I have heard that UDP is conectionless and that a connection is only made when sending data.
However, is it actually possible to create a connection with an UDP socket and hold that connection even if no data is to be sent for a little while i.e connect, wait few seconds then send data....?
The reason I ask is: I want PC1 to connect to PC2 and then after a few seconds, have PC2 to stream video to PC1.
Problem is: I can't make PC1 connect to PC2 straight off since PC2 has a non-routable ip address. With TCP, this is simple to achieve- make tcp socket connection from PC2 to PC1 then send data from PC2 to PC1. BUT can it be implemented with UDP????
Also, can a TCP client connect to UDP or does e.g to have a tcp connection then you need tcp socket on server side and client side?