繁体   English   中英

如何在真实设备上运行 Android 应用程序?

[英]How do I run an Android app on a real device?

我正在使用 nodejs、mysql、Android 堆栈。

我想在真实设备上测试我的 android 应用程序,并在同一 WIFI 网络上连接我的笔记本电脑和手机,并在使用 Volley 库时在 URL 中指定 IP 地址

url是:http://ipaddress:8080 8080是nodejs服务器端口

但是当我运行我的 android 应用程序时,它不会在 nodejs 服务器上运行。尽管请求是从 android 端发送的,但在 nodejs 服务器上没有处理请求

我尝试了很多链接,但没有一个起作用。 任何帮助表示赞赏

I have the answer to my question
I tried the following link and it worked for me
https://stackoverflow.com/a/17603378/8101634

what it states is.
1) Connecting android device through USB cable to laptop
2) Switching USB tethering on android device
3) Go to network and sharing center.
4) It will show you the device and click on it.
5) Click on details
6) Take the Ipv4 address from there and use it as URL in android app
7) Re-run your android application

It works

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM