TOC
Xcode or Android Studio is unable to list my iPhone device
I encountered an issue where my iPhone12 device was not listed in Android Studio while I was developing.
The issue was dispeared after I restart my macOS, but it occurred again when I reopened my MacBook Pro from sleep mode.
I noticed a new process running in Activity Monitor
during the issue occurred.
Here is the process list while android Studio is able to detect my iPhone device:
- xcdevice
- AMPDevicesAgent
- MobileDeviceUpdater
- findmydevice-user-agent
- AMPDeviceDiscoveryAgent
- AppleMobileDeviceHelper
Following is the process list when Android Studio can not list my iPhone device:
- xcdevice
- AMPDevicesAgent
- MobileDeviceUpdater
- findmydevice-user-agent
- AMPDeviceDiscoveryAgent
- AppleMobileDeviceHelper
- devicecheckd
When the issue occurred, I discovered a new process called devicecheckd
. After forcing the devicecheckd
process to quit, Android Studio list my iPhone devices again. :)
If you encounter the same issue, you can press cmd+space
, type Activity Monitor
and search devicecheckd
in Activity Monitor
search bar. If you find the devicecheckd
process, select it and right-click to select force quit
, then see if the issue is resolved.
My development Environment:
- macOS Monterey Version: 12.6.3 (21G419)
- Android Studio Version: Electric Eel | 2022.1.1 Patch 2 Build #AI-221.6008.13.2211.9619390, built on February 17, 2023
- XCode Version: Version 14.2 (14C18)
- iPhone12 iOS Version: 16.1
Other methods
If the above steps do not work, please try the following:
1.Stop all xcdevice
processes in Activity Monitor;
2.Disconnect the iPhone cable;
3.Stop the findmydevice-user-agent
in Activity Monitor;
4.Reconnect the iPhone device to the Mac;
5.Wait for the Android Studio device bar to refresh;
在macOS上,Xcode或Android Studio无法检测到我的iPhone设备
最近在我进行开发时,我遇到了一个问题,就是我的iPhone 12设备在Android Studio中没有被列出来。
在我重新启动了macbook pro后问题消失了,但是当我从睡眠模式中重新唤醒MacBook Pro时,问题再次发生。
我注意到问题发生期间Activity Monitor中有一个新的进程在运行。
以下是在Android Studio能够检测到我的iPhone设备时包含evice
的进程列表:
- xcdevice
- AMPDevicesAgent
- MobileDeviceUpdater
- findmydevice-user-agent
- AMPDeviceDiscoveryAgent
- AppleMobileDeviceHelper
以下是在Android Studio能够没有列出我的iPhone设备时包含evice
的进程列表:
- xcdevice
- AMPDevicesAgent
- MobileDeviceUpdater
- findmydevice-user-agent
- AMPDeviceDiscoveryAgent
- AppleMobileDeviceHelper
- devicecheckd
对比下,我发现,出问题时多了devicecheckd的进程, 强制退出devicecheckd进程后,Android Studio能够再次列出我的iPhone设备了 :)
如果你遇到了同样的问题,你可以按下cmd+space
,输入Activity Monitor
并在其中搜索evice
。如果你找到了devicecheckd
进程,选择它并右键选择“强制退出”,看看有没恢复。
出问题时,系统及软件版本如下:
- macOS Monterey Version: 12.6.3 (21G419)
- Android Studio Version: Electric Eel | 2022.1.1 Patch 2 Build #AI-221.6008.13.2211.9619390, built on February 17, 2023
- XCode Version: Version 14.2 (14C18)
- iPhone12 iOS Version: 16.1
其他方法
如果上面的步骤没生效,试下以下的步骤:
1.停止Activity Monitor
所有xcdevice
的进程;
2.拔出iPhone连接线;
3.停止Activity Monitor
的findmydevice-user-agent
;
4.重新连接iPhone设备到Mac上;
5.等待Android studio设备栏刷新;
「点个赞」
点个赞
使用微信扫描二维码完成支付
