I have 7 different Android phones which all have different Android OS. All of them are facing the same disconnection problem. Devices are being disconnected approx after an hour later. When it's disconnected, Allow USB debugging?
pop-up appears twice and wants me to Allow the computer's RSA key fingerprint which was already approved. Also, under Connection Assistant
, the connected device turns into disconnected
state by Android Studio but adb reports it's in device
state.
Sometimes I can re-connect the device only if I click different USB Preferences. But it disconnects after some time later again.
I tried so many solutions to fix the device connection problem. I used to fix it usually with one of the solutions below. Unfortunately, the problem keeps persisting. I've never faced something like this before.
What I tried:
.android
and delete file named as adbkey
and adbkey.pub
adb kill-server
then adb start-server
Android/sdk/build-tools
and Android/sdk/platform-tools
and reinstalled again.bash_profile
like in below:export ANDROID_HOME=/Users/myMacBook/Library/Android/sdk
export PATH=$PATH:$ANDROID_HOME/emulator
export PATH=$PATH:$ANDROID_HOME/tools
export PATH=$PATH:$ANDROID_HOME/tools/bin
export PATH=$PATH:$ANDROID_HOME/platform-tools
I really don't want to remove Android Studio and re-install it. I hope someone can help me. Thanks in advance!
Versions:
Android Studio Arctic Fox | 2020.3.1 Patch 3
Build #AI-203.7717.56.2031.7784292, built on October 1, 2021
Runtime version: 11.0.10+0-b96-7281165 x86_64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
macOS 11.6
GC: G1 Young Generation, G1 Old Generation
Memory: 3072M
Cores: 8
Registry: external.system.auto.import.disabled=true
Non-Bundled Plugins: org.jetbrains.kotlin
It's fixed after I updated my macBook to macOS Monterey.
EDIT:
I found the real reason why devices are being disconnected. If you try to inspect a webView in Chrome (chrome://inspect/#devices), Studio disconnects the connection of your devices after sometime