Hi,
I am not able to get,
What is the purpose of Creating the MulticastLock used with WifiManager in android.
Can any body clarify me what exactly it means and when to use...
Any help much appreciated..
thanks rakesh
Hi,
I am not able to get,
What is the purpose of Creating the MulticastLock used with WifiManager in android.
Can any body clarify me what exactly it means and when to use...
Any help much appreciated..
thanks rakesh
Well, you might want to read the Android documentation on it.
But that doc doesn't say a lot, and might not be helpful, if you don't dig Multicast. See: http://en.wikipedia.org/wiki/IP_multicast
Multicast protocols are application-specific. Are you just curious, or do you have an application in mind ?
IP multicast is a method for sending a packet to a group of interested receivers with only one transmission. Normal unicast requires sending the packet once per recipient. Broadcasting it delivers it to everyone on the same subnet.
The wifi interface on Android phones will drop multicast packets automatically to save power. Thus, if you want to be able to receive multicast packets, you need to grab the multicast lock which has the effect of telling the wifi driver to not drop multicast packets.
Only use it if you are actually joining a multicast group, e.g., using MulticastSocket instead of DatagramSocket or Socket in Java/Android.