So erstellen Sie eine Android WifiConfiguration und wifi-Zugang mit username/Passwort
WifiConfiguration conf = new WifiConfiguration();
conf.SSID = "ssid";
conf.preSharedKey = "\"Passwort\"";
conf.status = WifiConfiguration.Status.AKTIVIERT;
conf.allowedAuthAlgorithms.set(WifiConfiguration.AuthAlgorithm.OPEN);
conf.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.WEP40);
conf.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.WEP104);
conf.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.TKIP);
conf.allowedGroupCiphers.set(WifiConfiguration.GroupCipher.CCMP);
conf.allowedKeyManagement.set(WifiConfiguration.KeyMgmt.NONE);
conf.allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.TKIP);
conf.allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.CCMP);
conf.allowedProtocols.set(WifiConfiguration.Protocol.WPA);
conf.allowedProtocols.set(WifiConfiguration.Protocol.RSN);
int res = wifi.addNetwork(conf);
boolean b = wifi.enableNetwork(res, true);
Diesem wifi-access-point benötigen Sie einen Benutzername + Passwort zu verbinden, aber ich finde keine Möglichkeit, das Passwort zu. Ich denke, das ist das problem, so dass I kann nicht erstellen Sie es erfolgreich.
Bitte helfen Sie mir, dieses. Vielen Dank.
InformationsquelleAutor user378814 | 2010-06-29
Du musst angemeldet sein, um einen Kommentar abzugeben.
den Sie gesetzt haben, WifiConfiguration.wepKeys
hier ist ein wirklich gutes Beispiel.
InformationsquelleAutor ocanal