wifi

wifiLock and wakeLock not working correctly on Android

安稳与你 提交于 2019-12-29 08:48:07
问题 I am developing an app that needs to use both wifiLock and wakeLock so the audio streaming when the screen is off does not get disturbed. I have tried my app on Android 2.3 and wakeLock and looks like wifiLock work as expected so there is no difference between when the screen is on or off, but the same app on Android 4.2 (Jelly-bean) when the screen goes off is not working as well and the audio gets choppy which shows either wakeLock or wifiLock are not working correctly. Is there any reason

Can I use Wi-Fi Direct and cellular data in an app?

偶尔善良 提交于 2019-12-29 04:57:07
问题 I have two+ Android devices. I would like the devices to send instructions to the other devices using Wi-Fi Direct, while at the same time being able to access the internet via their cellular data connection. It seems that using the Wi-Fi Direct interface is being treated as the primary connection, disabling the other connections, just like how Wi-Fi disables the cellular data connection. How can I programmatically allow both to operate at the same time? Currently the Wi-Fi Direct receiver is

How Android application decide if they want to use network proxy or not

好久不见. 提交于 2019-12-29 01:29:30
问题 I have been running some testing with wifi proxy settings on a Motorola Xoom with Android 3.2. So first of all, it is a big step forward comparing to 2.x releases. now if you set proxy, most of the apps automatically get it (in 2.x, only builtin browser uses it). So I tried things like yahoo finance, bloomberg, etc. and they all going through proxy fine. What I don't get is some browsers like firefox, Opera, will not go through proxy. Any idea how they did that. Basically in my app, how can I

How to get my wifi hotspot ssid in my current android system

耗尽温柔 提交于 2019-12-28 10:05:17
问题 I have a problem that I couldn't find my wifi hotspot ssid in my Android system. I found many information from google, but nothing helpful. Please help me to solve it. 回答1: You can use WifiManager and WifiInfo for getting Wifi SSID WifiManager wifiManager = (WifiManager) getSystemService(WIFI_SERVICE); WifiInfo wifiInfo = wifiManager.getConnectionInfo(); Log.d("wifiInfo", wifiInfo.toString()); Log.d("SSID",wifiInfo.getSSID()); Also add Permission in your Manifest file. <uses-permission

How to connect android wifi to adhoc wifi?

一笑奈何 提交于 2019-12-28 04:52:07
问题 I'm new on the android system. Is this correct, the android 2.2.1 WIFI only detects non-ad hoc wireless network? I was wondering if there's a way to connect my android to an ad hoc network set-up from my laptop. 回答1: You are correct that this is currently not natively supported in Android, although Google has been saying it will be coming ever since Android was officially launched. While not natively supported, the hardware on every android device released to date do support it. It is just

how to solve discovering other device via Wi-Fi (android API)?

喜夏-厌秋 提交于 2019-12-28 04:34:05
问题 recently I follow the steps given from Developer.Android.Com But it seems i have a few luck over there. I tried to discover the available peers nearby, put 'em into the arraylist but seems no luck. I didnt get anything. My Actual 2 Devices are actually android 4.1 and 4.2 Since Wifi Direct is based on API Level 14 which is android 4.0+ so i think my real device is not the problem. The concept I use is using 1 activity and 1 BroadCast Receiver. Please take a look at my code, did I put it

Android 2.2 wifi hotspot API

冷暖自知 提交于 2019-12-28 01:42:51
问题 What is the API call I need to make in Android 2.2 (Froyo) to create a Wifi hotspot (as seen in the Tethering and Portable Hotspot settings item). 回答1: You can call private boolean setWifiApEnabled(WifiConfiguration wifiConfig, boolean enabled); using reflection :) after getting the WifiManager use the reflection to get the WifiManager declared methods, look for this method name setWifiApEnabled and invoke it through the WifiManager object These API are marked as @hide, so currently you

Is there a way to toggle bluetooth and/or wifi on and off programmatically in iOS?

半世苍凉 提交于 2019-12-27 19:12:39
问题 I am looking for an easy way to toggle both bluetooth and wifi between on and off states on iOS 4.x devices (iPhone and iPad). I am constantly toggling these functions as I move between different locations and usage scenarios, and right now it takes multiple taps and visits to the Settings App. I am looking to create a simple App, that lives on Springboard, that I can just tap and it will turn off the wifi if it's on, and vice versa, then immediately quit. Similarly with an App for toggling

How do I get the available wifi APs and their signal strength in .net?

泄露秘密 提交于 2019-12-27 17:04:19
问题 Is there any way to access all WiFi access points and their respective RSSI values using .NET? It would be really nice if I could do it without using unmanaged code or even better if it worked in mono as well as .NET. If it is possible i would appriciate a code sample. Thanks Here are a few similiar stackoverflow questions i found: -Get SSID of the wireless network I am connected to with C# .Net on Windows Vista -Managing wireless network connection in C# -Get BSSID (MAC address) of wireless

How do I get the available wifi APs and their signal strength in .net?

你说的曾经没有我的故事 提交于 2019-12-27 17:03:44
问题 Is there any way to access all WiFi access points and their respective RSSI values using .NET? It would be really nice if I could do it without using unmanaged code or even better if it worked in mono as well as .NET. If it is possible i would appriciate a code sample. Thanks Here are a few similiar stackoverflow questions i found: -Get SSID of the wireless network I am connected to with C# .Net on Windows Vista -Managing wireless network connection in C# -Get BSSID (MAC address) of wireless