RTC Forums
May 04, 2024, 09:30:03 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
 
   Home   Help Login Register  
Pages: [1]
  Print  
Author Topic: BroadCast UDP in localhost  (Read 3538 times)
paulo goncalves
Newbie
*
Posts: 2


« on: January 22, 2015, 09:51:03 PM »

Hi.
Is there a way to use the TRtcUdpServer / TRtcUdpClient to broadcast only on localhost?
Must notify several events of different ranks at the same time and I think the UDP can help me in this case.

Thanks.
Logged
D.Tkalcec (RTC)
Administrator
*****
Posts: 1881


« Reply #1 on: January 22, 2015, 10:29:26 PM »

UdpMultiCastMaxHops property on the UDP Client component should define how many "hops" is a multicast UDP packet allowed to make before it has to stop. This value is usually reffered to as "TTL" in documentation about UDP broadcasting. Using a value of 0 would limit broadcasting to the local machine, while a value of 1 means the 1st router, and so on.

You will also need to specify a Port number and set the broadcasting Address in the ServerAddr property for the UDP Client component. For example, 255.255.255.255 is for the whole network and 127.255.255.255 is for the local machine only.

On the UDP Server component, you will need to specify the same Port as on the Client and set the UdpReuseAddr property to TRUE if more than one Application using the UDP Server component is expected to run on the same PC (which I expect is the case, or you would not be asking about broadcasting to localhost).

Best Regards,
Danijel Tkalcec
Logged
paulo goncalves
Newbie
*
Posts: 2


« Reply #2 on: January 23, 2015, 12:14:02 PM »

Thanks.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.022 seconds with 18 queries.