ADB连接问题
这个问题是关于Android ADB的。我对 Android / ADB 还很陌生。
我的要求是使用 ADB(与设备和托管 PC)建立同步/“连续数据传输”类型的连接。
目前,每次我想向设备发送一些数据/文件时,我都需要调用 ADB shell,是否可以有“连续数据传输”类型的连接。 我研究了端口转发和类似的东西,并了解到您实际上可以在设备+ PC 上配置两个端口来进行连接,但不确定我们是否需要每次都调用 ADB shell。
如果您需要任何进一步的信息,请告诉我。
提前致谢。
This question is on Android ADB. I am fairly new on Android / ADB.
My requirement is to have a synchronous / "continuous data transfer" kind of connection using ADB (with the device and hosted PC).
Currently i need to invoke the ADB shell each and every time when i want to send some data/file to the device, Is it possible to have a "continuous-data-transfer" kind of connection.
I looked into port-forwarding and similar stuffs and got the understanding that you can actually configure two ports on device + PC to have a connection, but not sure if we need to invoke ADB shell each time.
Please let me know if you need any further info on this.
Thanks in Advance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
写一个shell脚本怎么样?在Linux内核中,您可以在adb设备的输出上使用
wc
来查找设备的数量,然后如果设备存在,您可以连接到它,并且在脚本中您可以做任何您想做的事情。这能解决问题吗?
我并不是百分百确定它会起作用,但我只是说这是一个可能的选择。
What about writing a shell script? In linux kernels, you can use
wc
on the output of adb devices, to find the number of devices, and then if the device exist you connect to it and in the script you can do whatever you want to.does this solve the issue??
I am not exactly 100% sure it would work, but i am just saying that its a possible option.