Hi,
I want my app could auto find the ip address of server.
I used udp broadcast to remind server then server will send a udb package to my mobile device.
Mobile can refer the source address of the package to setup ip address of server.
My problem is, the general broadcast address(255.255.255.255) cannot work correctly,
I need subnet mask to caculate the broadcast address. For example:
ip address is:192.168.1.1
subnet mask is:255.255.128.0
the broadcast address will be: (192.168.1.1 | (~255.255.128.0)) =192.168.127.255
But unity not implemented System.Net.NetworkInformation.GetAllNetworkInterfaces() on android,
so i cannot get the subnet mask using C#.
Is there any way to get subnet mask on mobile device?