Difference between revisions of "VNC (Virtual Network Computing)"

From WebOS Internals
Jump to navigation Jump to search
Line 8: Line 8:
  
 
1. [http://predev.wikidot.com/rooting Root the Pre].
 
1. [http://predev.wikidot.com/rooting Root the Pre].
 +
 
2. [http://predev.wikidot.com/debian Install Debian chroot].
 
2. [http://predev.wikidot.com/debian Install Debian chroot].
  
Line 28: Line 29:
  
 
5. Modify the source of dfb.c (use vi). Remove lines 29, 33, 44, 69 and 83. Here's what each of the lines contains, so you know what we're deleting:
 
5. Modify the source of dfb.c (use vi). Remove lines 29, 33, 44, 69 and 83. Here's what each of the lines contains, so you know what we're deleting:
> 29: IDirectFBInputDevice    *mouse; #We don't have a mouse.
+
> 29: IDirectFBInputDevice    *mouse; #We don't have a mouse.
> 33: DFBCardCapabilities caps; #Won't compile with this line.
+
> 33: DFBCardCapabilities caps; #Won't compile with this line.
> 44: DFBCHECK(DirectFBSetOption ("quiet", "")); #Won't compile with this line, either.
+
> 44: DFBCHECK(DirectFBSetOption ("quiet", "")); #Won't compile with this line, either.
> 69: DFBCHECK(dfb->GetInputDevice( dfb, DIDID_MOUSE, &mouse )); #We don't have a mouse
+
> 69: DFBCHECK(dfb->GetInputDevice( dfb, DIDID_MOUSE, &mouse )); #We don't have a mouse
> 83: mouse->Release( mouse ); #We don't have a mouse
+
> 83: mouse->Release( mouse ); #We don't have a mouse
  
 
As you can see, we're removing code that will support a mouse and other things that cause the source not to compile. I haven't figured out how to get mouse control. Maybe someone can write a mouse driver that uses the touchscreen. :)
 
As you can see, we're removing code that will support a mouse and other things that cause the source not to compile. I haven't figured out how to get mouse control. Maybe someone can write a mouse driver that uses the touchscreen. :)

Revision as of 18:39, 22 July 2009

VNC on the Palm Pre

NOTE: As an alternative to enabling VNC by following this tutorial, one can use PalmVNC in the Classic emulator with full control. You may download PalmVNC at: http://palmvnc2.free.fr/download.php

The following is a proof of concept:

Prerequisites:

1. Root the Pre.

2. Install Debian chroot.

Demos:

Instructions:

1. Download the source tarball, directvnc_0.7.5.orig.tar.gz. NOTE: There is a newer version of directvnc at http://code.google.com/p/directvnc-rev/ ( tarball at http://directvnc-rev.googlecode.com/files/directvnc-0.7.5-test-051207.tar.gz ) that has a feature that might be very useful on the pre, keyboard remapping - http://code.google.com/p/directvnc-rev/wiki/KeyboardMapping - as well as a few others - http://code.google.com/p/directvnc-rev/wiki/NewFeatures - also if someone wants to get GGI working with DirectFB, ggivnc is under current development (unlike even directvnc-rev which is untouched since 2007) - http://www.lysator.liu.se/~peda/ggivnc/ - ggivnc's author is on #ggi on freenode irc. Another option would be to try a GTK-based VNC client, as with vala-terminal.

2. Move the tarball to /usr/local/src/

3. Run the following command from /usr/local/src/:

tar zxvf directvnc_0.7.5.orig.tar.gz

4. A new directory structure should be created. cd to /usr/local/src/directvnc-0.7.5/src/

5. Modify the source of dfb.c (use vi). Remove lines 29, 33, 44, 69 and 83. Here's what each of the lines contains, so you know what we're deleting:

> 29: IDirectFBInputDevice    *mouse;				#We don't have a mouse.
> 33: DFBCardCapabilities caps;					#Won't compile with this line.
> 44: DFBCHECK(DirectFBSetOption ("quiet", ""));			#Won't compile with this line, either.
> 69: DFBCHECK(dfb->GetInputDevice( dfb, DIDID_MOUSE, &mouse ));	#We don't have a mouse
> 83: mouse->Release( mouse );					#We don't have a mouse

As you can see, we're removing code that will support a mouse and other things that cause the source not to compile. I haven't figured out how to get mouse control. Maybe someone can write a mouse driver that uses the touchscreen. :)

6. Change back to /usr/local/src/directvnc-0.7.5/

7. Run the following command, it will run some checks against the system and get things moving:

NOTE: If any dependencies are missing, let us know in irc.freenode.net #webos-internals, we'll update the wiki.

./configure

8. Run the following command, it will compile the source code:

make && make install

9. Connect to your VNC host:

/usr/local/bin/directvnc <host><:display>

NOTE: I've noticed some hosts don't display until there has been some activity with the section the client is focused on

Vnc.jpg