我认为有一种方法可以通过Wi-Fi测试开发中的应用程序。这可能吗?

我希望能够解开我的手机,无线开发。


当前回答

1-为此,我认为你已经安装了最新版本的Android studio。如果没有,你可以从这里下载。

2 -可以在“环境变量”中设置平台工具路径(可选)。

3 -确保你的设备和电脑连接到同一个网络。

plug in the data cable from pc to device. Now, type adb tcpip 5555 remove data cable. Then type adb connect 192.168.43.95 here 5555 is the port number and 192.168.43.95 is the ip address of the mobile device you can get id address from the mobile settings . Then go to About device and go to status you can see the ip address of the device. You can connect multiple device from different ports which can give ease in development. Or you can go to this link for brief description with screenshots. http://blogssolutions.co.in/connect-your-android-phone-wirelessly-by-adb

其他回答

虽然有这么多好的答案,这里是我对未来的我的两点意见:P和任何想要快速简单的人。

Mac:

首先使用USB连接设备,并确保调试工作正常。断开任何其他设备并退出模拟器。 打开终端,运行以下脚本 Adb tcpip 5555 Adb connect $(Adb shell ifconfig | grep "inet " | grep -v 127.0.0.1 | awk '{print $2}' | cut -d: -f2):5555 断开USB连接,设备应可进行WiFi调试

解释:

Adb tcpip 5555命令设备开始监听端口5555上的连接

Adb connect $(_ip_address_fetched_):5555表示连接到_ip_address_fetched_地址的5555端口

其中_ip_address_fetched_包含以下内容:

Adb shell ifconfig使用Adb shell获取Internet配置

Grep "inter "过滤任何以inter开头的行

排除本地主机。

此时,输出应该是这样的:

inet addr :###.###.#.# # #广播地址 :###.###.#.# # #面具:255.255.255.0

awk '{print $2}'获取组件数组的第二部分,用空格分隔(我使用zsh)。

到此为止的输出是

addr :###.###.#.###

Cut -d: -f2用分隔符分割字符串,然后取第二部分。它只会接收你的设备IP地址

我使用adb shell ip -f inet addr show wlan0来查找adb tcpip 5555之后的设备ip。

新版本已弃用adb netcfg。因此,当接口名称为wlan0(默认接口名称)时,这是查找设备ip的正确方法。

在设备设置->“开发人员选项”->“撤销USB调试授权”。 通过USB连接设备并确保调试工作正常。 Adb tcpip 5555 adb connect <DEVICE_IP_ADDRESS>:5555 断开USB 亚洲开发银行设备

对于安卓11手机和安卓工作室大黄蜂版本,有新的更新。你只需要从安卓手机上扫描二维码就可以了 繁荣!它是相连的。

节省复制粘贴过程的时间。 有用的官方文件在这里

在游戏商店下载应用程序Wifi ADB。非常容易使用,工作就像一个魅力!:)