The main app

You can directly copy the apk file to your device and install it
Layout for the first screen
Layout for the second screen
UPDATE
The first screen user sees

This is the first screen the user sees. It accepts the user's IP address
in dotted format.
The socket handler

This reads the accelerometer data and on receiving valid data (average
of 4 values) makes a new thread which runs in the background. The new
thread makes the socket connection and transfers the socket to the PC.