Questions tagged [android-connectivitymanager]
The android-connectivitymanager tag has no usage guidance.
android-connectivitymanager
168
questions
0
votes
0
answers
54
views
WiFi connected but no internet access when using ConnectivityManager
I attempted to implement functionality within the app to scan for and connect to WiFi networks using the following three classes
WifiNetworkSpecifier Builer,
NetworkRequest Builder,
...
1
vote
0
answers
40
views
connectivityManager.activeNetwork is null with device in energy saving
in this scenario connectivityManager.activeNetwork is null:
App closed
Push received
Energy saving enabled
connectivityManager.activeNetwork = null
If energy saving is disabled connectivityManager....
1
vote
0
answers
301
views
Android 13 can't connect to wifi programmatically
I'm trying to connect to a wifi (passing the ssid and password). The callback of the function it does return that the wifi is available, put it does not really connect to the wifi. The code does work ...
0
votes
0
answers
85
views
How to get Wifi SSID in API 26 >=
I'm asking about the the best method for obtaining the SSID of the presently connected WiFi network, particularly for Android API versions 26 through 34 ?
We use the Wifimanger getConnectionInfo() ...
0
votes
0
answers
108
views
Phone switches Wifi Network from IOT Wi-fi to known network in Android 14
Our Android app connects to an IOT device Wi-Fi programatically and then communicates over TCP/IP socket.
Connection to IOT Wi-Fi is initiated using ConnectivityManager requestNetwork.
We have a weird ...
0
votes
1
answer
121
views
Incorrect connection state obtained through ConnectivityManager on Android 9
I want to write a broadcast receiver that can get whether wifi is conneted. However, I always get wrong result. How to fix it?
class wifiStateReceiver: BroadcastReceiver() {
override fun onReceive(...
0
votes
1
answer
583
views
Compose TooManyRequestsException when this is not more than 1 callback registered
I used this tutorial to implement internet connection observing in my fully Compose app
Here is my code:
sealed class ConnectionState {
data object Available : ConnectionState()
data object ...
0
votes
0
answers
20
views
Timeout to search network in Android 7
I have an old android device which is running Android 7. I know it is quite old, but is needed to be used in work. The device "seems" would be disconnected for a long time when the available ...
0
votes
0
answers
41
views
How and when to use registerBestMatchingNetworkCallback introduced in Android API 31?
I wanted to connect to wifi from app.
I was looking in to ConnectivityManager docs and came across this method.
public void registerBestMatchingNetworkCallback (NetworkRequest request,
...
0
votes
0
answers
56
views
Monitor/observe hotspot connection status
My app needs to connect to another device via hotspot. It will only form a closed network (no internet access) Internet will be accessed via mobile data. How can I monitor the status of the hotspot ...
0
votes
0
answers
44
views
Why is network status lost when I switch from Cellular to Wifi in Android?
I'm using connectivity manager to check if connection is available, lost, etc. This is my network repository impl
class NetworkRepositoryImpl @Inject constructor(
@ApplicationContext private val ...
0
votes
1
answer
268
views
NetworkCallback with NetworkCapabilities is called only once
I'm tying to get imformation from getLinkDownstreamBandwidthKbps(), getLinkUpstreamBandwidthKbps() and getSignalStrength() of NetworkCapabilities class.
For this I do the following in MainActivity:
...
0
votes
2
answers
846
views
Android ConnectivityManager callbacks not working
I need to check the current internet availability.
Since many of the old calls are deprecated I use the
ConnectivityManager.NetworkCallback()
approach with a callback.
However, when implementing ...
2
votes
0
answers
1k
views
Android ConnectivityService and android.net.ConnectivityManager$TooManyRequestsException
I've collected a lot of crashes about TooManyRequestsException.
Caused by: android.net.ConnectivityManager$TooManyRequestsException
at android.net.ConnectivityManager.convertServiceException(...
-1
votes
2
answers
733
views
How to check if Android 13 app is connected to WIFI with API v33
I have an Android app built with Java, running on Android 13 and API version 33.
The app serves a webView, though I want to be able to serve up a local asset if WIFI is not connected (I do not need to ...