I have an HTC HD2 with a completely busted screen, I tried repairing it with a replacement screen but broke the ribbon cable to the screen (oops) sad day,

I've got two of these and I've been running them as servers and ipcam cameras.

I started using qtadb, which did work on my phone despite a broken screen. I installed droid VNC Server beta using the file manager on qtadb. I grabbed the app's manifest:

<?xml version="1.0" encoding="utf-8"?>
<manifest android:versionCode="52" android:versionName="0.991" package="org.onaips.vnc"  xmlns:android="http://schemas.android.com/apk/res/android">
    <uses-sdk android:minSdkVersion="3" />
<application android:label="droid VNC server" android:icon="@drawable/icon" android:name="MainApplication" android:debuggable="false">
    <activity android:label="@string/app_name" android:icon="@drawable/icon" android:name=".MainActivity" android:launchMode="singleInstance">
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
    <activity android:label="Preferences" android:name="preferences" />
    <meta-data android:name="com.mobclix.APPLICATION_ID" android:value="1F34160B-63BB-4854-BDB7-D46B7EADBF06" />
    <activity android:name="com.mobclix.android.sdk.MobclixBrowserActivity" />
    <service android:name="StartAtBootService">
            <action android:name="org.onaips.vnc.StartAtBootService" />
    <receiver android:name="StartAtBootServiceReceiver">
            <action android:name="android.intent.action.BOOT_COMPLETED" />
            <category android:name="android.intent.category.HOME" />
    <service android:name="avncservice" />
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission android:name="android.permission.ACCESS_SUPERUSER" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.GET_TASKS" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />

and I have tried several things to start and run the service using the console on qtadb. I have tried running:

am start -a android.intent.action.MAIN -n org.onaips.vnc/com.mobclix.android.sdk.MobclixBrowserActivity

am start -a android.intent.action.MAIN -n org.onaips.vnc/org.onaips.vnc.MainActivity

am start -n org.onaips.vnc/com.mobclix.android.sdk.MobclixBrowserActivity

am start -n org.onaips.vnc/org.onaips.vnc.MainActivity

am startservice -a android.intent.action.MAIN -n org.onaips.vnc/com.mobclix.android.sdk.MobclixBrowserActivity

am startservice -a android.intent.action.MAIN -n org.onaips.vnc/org.onaips.vnc.MainActivity


I test each time by NMAPing my device's ip address, no new ports show up. (I don't have a firewall)

But on a working phone, it doesn't start when you run the app; it starts when you press the run button. So How do I press the run button with a broken screen?

I just need vnc server to run so i can actually do some config things to run debian and my video server on it.

4 Answers 4


Use adb shell am start -a android.intent.action.Main -n org.onaips.vnc/.MainActivity outside the shell, and the VNC server will start.


This answer was suggested as an edit by an anonymous user, but should stand on its own.

First you have to locate the droidvncserver executable file on your device. On a Nexus S it's in this directory:


Then you have to set the execution right on the executable file (it's a UNIX subutility) from PC using adb.exe. In a command line window (from the appropriate Android SDK folder) you can type :

adb.exe shell chmod 766 /data/data/org.onaips.vnc/files/androidvncserver

(this has to be to done only once, for further detail on chmod command type man chmod in google)

Then you'll be able to launch vnc server directly from your PC using adb.exe:

adb.exe shell /data/data/org.onaips.vnc/files/androidvncserver

Additionnaly to connect your VncViewer using the USB cable type in another command line window:

adb.exe forward tcp:5901 tcp:5901

Vysor is the answer! It's a Chrome app with a built-in VNC server that launches automatically. It even works on Android 6+. Find it here.

adb shell
cd /data/data/org.onaips.vnc/files
chmod 766 androidvncserver
  • 2
    No explanations, nothing! Care to elaborate more about this for the benefit of end user reading this?
    – t0mm13b
    Oct 15, 2012 at 13:41
  • You'll need to do adb shell am start -a android.intent.action.Main -n org.onaips.vnc/.MainActivity first.
    – user199543
    Mar 4, 2017 at 5:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .