我需要就如何通过wifi处理android上的数据的教程。铁,我需要发送一些信息给PC和接受其他一些消息。我应该如何建立连接?我应该怎么做才能够传输数据,以及如何?
I need a tutorial on how to process data on android via wifi. F.e., I need to send some message to PC and receive some other message. How should I establish the connection? What should I do to be able to transfer data and how?
抱歉哑问题,但我不能找到很好的手册。我会感激的详细手册越好,或用于etablishing wifi连接和发送OME简单的例子/接收简单mesages。
Sorry for the dummy question, but I can't find good manual. I'll be grateful for as detailed manual as possible, or for ome simple example on etablishing wifi connection and sending/receiving simple mesages.
推荐答案您不必使用任何API的连接上WIFI其唯一的要求,如果你想手动启动装置中的无线网络,包括
只要确保你的设备具有WiFi支持,并做好简单的TCP / IP套接字应用程序。有了这个,你可以与你的系统和设备,并使用系统的公共IP通信,就可以与您的系统。
Just make sure your device has a WiFi enable, and make a simple TCP/IP Socket application. With this you can communication with your system and device, And Use System's public IP to connect with your system.
另外不要忘了给允许网络在清单文件。
Also don't forget to give permission Internet in your manifest file..
下面一些不错的链接套接字编程的机器人。
Here some nice links for Socket Programing in Android..
Simple连接例如第二部分 - TCP通信
网络与Android
简易通信使用的java.Socket
www.anddev/tcp_sockets-t276.html
www.anddev/socket_programming-t325-s30.html
修改:: Android的无线网络的例子,
: Android WiFi examples,
扫描无线网络
使用WiFi API
SO问题Android:有没有办法得到通知时,已知的WiFi网络获取输入/输出范围?
更多推荐
通过Android的WiFi连接
发布评论