Andmote is a java client for an Android device I wrote to use the device as a wireless mouse (this is for lazy people like me so I can lye in bed and put a film). It works by simply pressing and holding your finger on the screen (of presumably your phone) and dragging your finger around. This movement is sent to your computer and moves the mouse cursor, simples!

However, there is a 'but'; I was so excited with my idea of writing the Android client app and wanted to spend as little time as possible on the receiver end to run on the desktop so I just hashed one up in VB6 (classic RAD!). This means it can only be used to control a Windows desktop at the moment but I will write a back end in java sooner or later for multiplatform support.

Here is the latest compiled Android app

Here is the latest java source package

Here is the latest compiled desktop app

Here is the latest VB6 source code

The code is commented but I will give an explanation here:

Andmote connects to the desktop end via TCP, at home my Android phone is always connect to my wireless so this seemed like a good way of communicating between the two. I'm sure bluetooth and other methods would work fine but I don't have bluethooth on my computer; the Andmote app just creates a TCP socket, ignorant of the physical medium used for connectivity. Admote will connect to the listening server and then start a new activity which extends the view of the new activity with a blank one and captures all user input. Simply drag your finger across the screen to move the mouse on your desktop.

Once your finger goes down on the screen a timer starts and polls for the touch event until you lift your finger and the timer stops. During the timers 'tick' it grabs the current X and Y values of your finger and compares them to where they were last at the last tick. It is the difference between these to values which is sent to the server, this is in essence how far you have moved your finger. At the server end the X and Y values of the mouse cursor are incremented by these values giving movement. Whilst connected, the handset volume buttons can change a sensitivity multiplier on the server end (which is done on the desktop by moving the slider).

Andmote connection screen and desktop application:

Version 1.3 - 04-2011

-Added options to VB app; minimise to tray, minimise on start up, and listen on start up (now the app listens on start up and is minimised straight to the tray out of the way)
-Added the ability to run shell commands from the Java client on the desktop machine
-Cleaned the Java client code and added comments
-Moved the TCP socket on the Java client to a separate thread
-Changed hard coded values to strings in Java app (finished)

Version 1.2 - 03-2011

-Added Menu with "Right click" and "Task Manager" options to java app and matching VB actions
-Changed hard coded values to strings in java app (not quite finished yet) 

Version 1.1 - 02-2011

-Fixed view on java app
-Fixed Back and Menu button unwanted event captures
-Cleaned up and commented code (both java app and VB app) 

Version 1.0 - 01-2011

-Basic app that connects over TCP and moves cursor

Previous page: ETHX EFM Modems
Next page: Audio Streamer