This repository has been archived by the owner on Aug 11, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 46
/
README
73 lines (58 loc) · 2.84 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
APK download: http://sourceforge.net/projects/synergyandroid/files/
Introduction
-----------------------------------------------------------------------
SynergyAndroid is a port of the synergy client to the Android platform.
See http://synergy-project.org for detail. Currently in the planning stage.
New developers are very welcome to join in.
Pre-requirements
-----------------------------------------------------------------------
We use the uinput module for user space input driver, so you must have
a modded Android with access to /dev/uinput (Like Cyanogen). That means
your android must have /dev/uinput module and this file can be RW by app.
You can follow blow steps to set a custom android emulator for testing:
1. Clone the android kernel source from android.git.kernel.org
#git clone git://android.git.kernel.org/kernel/common.git
2. Check out the emulator branch
#git checkout -t origin/android-goldfish-2.6.29 -b goldfish
3. Generate the kernel configuration for emulator
#make ARCH=arm goldfish_defconfig
or get a config copy from a exist emulator rom.
#adb pull /proc/config.gz
4. Edit the .config file, make sure
CONFIG_INPUT_UINPUT=y
5. Compile the kernel using cross toolchain (you can get prebuilt
cross toolchain from android source repo or just
#git clone git://android.git.kernel.org/platform/prebuilt.git
all platform cross chain are there.)
#make ARCH=arm CROSS_COMPILE=prebuilt/YOUR_PLATFORM/toolchain/arm-eabi-4.2.1/bin/arm-eabi-
6. Now, the kernel built is in the arch/arm/boot/ folder.
You can start the emulator with this kernel
#emulator -avd YOUR_AVD -kernel ANDROID_KERNEL_PATH/arch/arm/boot/zImage
7. At last, you should make sure your app can read and write /dev/uinput
#adb shell chmod 660 /dev/uinput
8. Now, you can build the project and test it.
Building the project
-----------------------------------------------------------------------
SynergyAndroid use the jni to access the /dev/uinput module, so you must
compile the jni source by NDK firstly. And then you can directly build
and debug the project in eclipse.
#./build_jni.sh <NDK Base>
then just build the whole project in eclipse.
Running
-------------------------------------------------------------------------
Reminder: you should build the jni source first and chmod 666 /dev/uinput
Then you can:
1. just run the project in eclipse or
2. install the PROJECT_PATH/bin/Synergy.apk to emulator/device.
#adb install PROJECT_PATH/bin/Synergy.apk
TODOs
----------------------------------------------------------------------
Client reconnect
Proper handling of shift, alt, caps lock... etc.
Options to Implement
-------------------------
Logging level
Port number
Retry interval ?
Key Translation
------------------------