title: UDP Broadcast to All IPs not working in some networks
body: <p>There is a lot of other answers related to this issue, however I believe this is specific.</p>
  
  <p>I am using Delphi XE2 and Indy 10.5.8 and TIdUDPServer</p>
  
  <p>In my local development network I have everything on the same network ip subrange and all connected to the very same Access Point (LinkSys)</p>
  
  <p>I have Androids sendind UDP Broadcast to 255.255.255.255 to request the server ip address that is written in Delphi listening using TIdUDPServer on the port 44444.</p>
  
  <p>The requests get there fine and I can answer back no problem. Works exactly as expected.</p>
  
  <p>However I have noted that in some networks it does not work! It is always simple networks based on an access point, I am not sure but seems that where the problem happens the server PC is connect to the LAN port while the devices are using the wifi, all in the same access point.</p>
  
  <p>Could be the case that the access points do not broadcast the UDP packet by the both LAN and wifi? I know that this kind of broadcast is very limited, but I have not found any information that tell me that in the same access point there is limitations like that.</p>
  
  <p>Is there are ways to test, or workaround? </p>
  
  <p>This solution needs to be strong enough to deal with the many AP out there. </p>
  
  <p>EDIT: For those that want to get the source code for retrieving more information from the network including the broadcast ip as mentioned on the answer below follow this solution, it is all there.</p>
  
  <p><a href="http://www.code10.info/index.php?option=com_content&amp;view=article&amp;id=54:articleretrieve-network-adapter-information&amp;catid=47:cat_coding_algorithms_network&amp;Itemid=78" rel="nofollow">http://www.code10.info/index.php?option=com_content&amp;view=article&amp;id=54:articleretrieve-network-adapter-information&amp;catid=47:cat_coding_algorithms_network&amp;Itemid=78</a></p>