Skip to content
This repository has been archived by the owner on May 18, 2021. It is now read-only.

USB Host detection #4

Open
fcorneli opened this issue Mar 16, 2016 · 3 comments
Open

USB Host detection #4

fcorneli opened this issue Mar 16, 2016 · 3 comments

Comments

@fcorneli
Copy link
Contributor

Via:
http://developer.android.com/reference/android/content/pm/PackageManager.html#hasSystemFeature%28java.lang.String%29
we can detected whether an Android device supports USB Host mode:
http://developer.android.com/reference/android/content/pm/PackageManager.html#FEATURE_USB_HOST

We could extend the cordova-plugin-chrome-apps-usb Cordova plugin with an API for this. For example:

chrome.usb.cordova.hasUsbHostFeature(function (result) {
    console.log("USB Host supported: " + result);
});
@agrieve
Copy link
Member

agrieve commented Mar 16, 2016

sounds good to me!

@fcorneli
Copy link
Contributor Author

@agrieve before or after a 1.1.1?

@fcorneli
Copy link
Contributor Author

@agrieve I've tried to do a PR between my unregisterReceiverFix branch and my issue4 branch. But then the PR ends up at my repository instead of @ MobileChromeApps. See:
e-Contract#1

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants