diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2017-05-29 20:37:18 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2017-05-29 20:37:18 -0700 |
commit | c05fe9fc9b1c76bb447af8033f9917b1f5d10a1c (patch) | |
tree | 5d6893589bf90ad025ec036b32c3717846e00c5a /android-mobile | |
parent | c8c56b373706ad9be34ba92078e3a457287230a7 (diff) | |
download | subsurface-c05fe9fc9b1c76bb447af8033f9917b1f5d10a1c.tar.gz |
Subsurface-mobile on Android: add USB intent filter
With this a few FTDI based dive computers should be visible from the app.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'android-mobile')
-rw-r--r-- | android-mobile/AndroidManifest.xml | 6 | ||||
-rw-r--r-- | android-mobile/res/xml/device_filter.xml | 14 |
2 files changed, 20 insertions, 0 deletions
diff --git a/android-mobile/AndroidManifest.xml b/android-mobile/AndroidManifest.xml index e00433834..ee035c1ed 100644 --- a/android-mobile/AndroidManifest.xml +++ b/android-mobile/AndroidManifest.xml @@ -70,6 +70,12 @@ <!-- <meta-data android:name="android.app.splash_screen_drawable" android:resource="@drawable/subsurface_mobile_splash" /> --> <meta-data android:name="android.app.splash_screen_drawable" android:resource="@drawable/splash" /> <!-- Splash screen --> + <intent-filter> + <action android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED" /> + </intent-filter> + + <meta-data android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED" + android:resource="@xml/device_filter" /> <!-- support more aspect ratios --> <meta-data android:name="android.max_aspect" android:value="3" /> diff --git a/android-mobile/res/xml/device_filter.xml b/android-mobile/res/xml/device_filter.xml new file mode 100644 index 000000000..fc9333bdb --- /dev/null +++ b/android-mobile/res/xml/device_filter.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8"?> +<resources> + <!-- FTDI Chips --> + <!-- (Smart Interface), Heinrichs Weikamp --> + <usb-device vendor-id="1027" product-id="24577"/> + <usb-device vendor-id="1027" product-id="24592"/> + <usb-device vendor-id="1027" product-id="24593"/> + <!-- Oceanic Custom PID --> + <usb-device vendor-id="1027" product-id="62560"/> + <!-- Suunto Custom PID --> + <usb-device vendor-id="1027" product-id="63104"/> + <!-- Cressi (Leonardo) Custom PID --> + <usb-device vendor-id="1027" product-id="63104"/> +</resources> |