Perhaps the most interesting side project to come out of the QVD is the Qindel sponsored Xvnc Pro. With the goal of making our client software available to as many devices as possible, we set about looking at the state of X for Android. What we found was that, in spite of a valiant effort, we weren’t fully satisfied with the native X client for Android in its current incarnation. So we decided to try a different approach: instead of building a native client from the ground up, we would harness the power of Xvnc, an already stable technology that provides an X server with a virtual display that can be viewed in a standard VNC viewer.
The result was Xvnc Pro, an X server for Android with VNC backend that is trivial to set up and use. Now on version 3.1, the software is mature enough for day to day use and provides one of the best ways to access your X applications from your Android device in the market today. Mindful that the native X server would be the best solution in the longer term, we liaised with the developer of that project and agreed on using the same open intent so that transitioning to the native client will be seamless when that project reaches maturity. Of course, as stated, you will also need a VNC viewer and Xvnc Pro has two options at present, the free android-vnc-viewer, and PocketCloud’s Remote Desktop Pro which will set you back about $14.
Full documentation for the app is available here which covers Xvnc Pro in more detail and includes a coding example for invoking it from your own app. For today I’m just going to show you just how easy it is to access your X applications with a simple example. Install Xvnc Pro (or try out the free Xvnc) from the market. Open up the app, and you will be presented with the following screen:
Select your VNC client (Pro only – Xvnc only supports android-vnc-server), and press the “Install prerequisites” button. This will do two things. Firstly it will copy the Xvnc binary to the local storage, and then, if you haven’t already installed your chosen VNC client, it will now present you with an option to do so now by linking through the Google Play page for the app.
For this example, you’ll also need to install ConnectBot, a free open source ssh client. Once you’ve done that, select “Launch X” in the application, and switch to ConnectBot. Connect to your target machine over ssh, and then disconnect. Long press on the connection you have just made and select “Edit port forwards” and enter the following details:
- A nickname, eg xvnc
- Type: remote
- Source port: 6010
- Destination: localhost:6000