In Android ICS, Wireless P2P (WiFi Direct) API is provided.
I tried to develop an Application which can connect 2 phones via Wireless P2P automatically if the MAC address match.
From SDK documentation, I have to following steps:
- Turn on WiFi Direct from Setting.
- Initialize P2P connection. - initialize()
- Discover Peer. - discoverPeers()
- See if the MAC address matched.
- Connect to the discovered Peer. - connect()
Once, the connect() API is called, Farside phone will Pop Up a connection Authentication Dialog. (Depending on WifiP2pConfig)
Is there anyway to connect automatically, without having Farside to popup the Dialog?