Androidpn Environment
Androidpn pushes text messages from the server to the Android mobile platform. Here we will briefly describe the installation process of androidpn.
Download androidpn-client-0.5.0.zipand androidpn-server-0.5.0-bin.zip
Web: http://sourceforge.net/projects/androidpn/
Decompress two packages, import eclipse to the client, configure the target platform, and open the raw/androidpn. properties file,
Apikey = 1234567890
Xmpphost = 10.0.2.2
X mppport = 5222
For a simulator to run the clientProgramConfigure xmpphost to 10.0.2.2 (the simulator considers 10.0.2.2 as the address of the host, and 127.0.0.1 as the loopback address of the simulator ).
Xmppport = 5222 is the XMPP service listening port of the server.
Run androidpn-server-0.5.0 \ bin \ Run. bat starts the server and accesses http: // 127.0.0.1: 7070/index from the browser. do (androidpn server has a lightweight web server that listens to requests on port 7070 and receives text messages from users)
When a client is running, the client initiates a connection request to the server. After successful registration, the server can identify the client and maintain a persistent connection with the client's IP address.
Enter the notifications page and enter the message to send.
The simulator client receives messages pushed to the server.
In this way, the androidpn environment is ready. Next, I will study and implement the XMPP protocol in depth.
Xiaobai
DevXiaobai@gmail.com