neatorobito / Salut

A nice library for working with WiFi P2P service discovery on Android.
MIT License
297 stars 88 forks source link

Wifi P2P Group Details #41

Closed hjoshi123 closed 5 years ago

hjoshi123 commented 5 years ago

Can I get info of the WiFi P2p group created which includes SSID and passphrase?

neatorobito commented 5 years ago

Yup, you'll need to fork and likely add a public field to the Salut instance though. It depends on how you want to access the information.

Perhaps add a field called currentGroup and set it to the group object passed into the onGroupInfoAvailable callback.

Then you can use currentGroup.getNetworkName() and other functions as described [here](https://developer.android.com/reference/android/net/wifi/p2p/WifiP2pGroup.html#getNetworkName()).

hjoshi123 commented 5 years ago

Hey I got another error.. I am working on kotlin.. I am receiving the following error.. @incognitorobito Screenshot 2019-03-12 at 13 37 26

Could you check this out?