This repository have two projects. It makes use of Socket Programming in android to demonstrate communication between different applications on different devices.
- Clone this repository and open client and server in different window on Android Studio
git clone git@github.com:althafvly/Android-Socket-Programming.git
- Change the SERVER_PORT of MainActivity to host in specific PORT
public static final int SERVER_PORT = 5050;
- Change the SERVER_IP and SERVER_PORT of MainActivity to device's IP and hosted PORT
public static final int SERVER_PORT = 5050; public static final String SERVER_IP = "192.168.100.1";
- Connect both device to the same network
- Click on the start server button of the server app
- Click the connect to server button on the Client-side app
- You can now send and receive messages between both apps
This project is mantained by:
- Fork it
- Create your feature branch (git checkout -b my-new-feature)
- Commit your changes (git commit -m 'Add some feature')
- Push your branch (git push origin my-new-feature)
- Create a new Pull Request