Microchip Technology Inc
151112-corp-bnr-generic-1170x3605641cfcbaee06466808eff0000ac5cb2
 
Menu
 

FAQs

I get an error that indicates “Package com.microchip.android.BasicAccessoryDemo requires unavailable shared library com.android.future.usb.accessory; failing!” What does this mean?
+

The com.android.future.usb.accessory library is an option library in the Android™ OS. This library was added to v2.3.4+ as an optional API plug-in. The support for this library varies depending on the manufacturer and OS release version for each device. Many phones/tablets do not include this library. Applications using this library will not install on devices that do not have this library installed on it. Support for this library can be added or removed on any OS update based on how that release is built.

There is a second library, android.hardware.usb.accessory, which is available in Android version 3.1 or later. You can try using the v3.1 demo app to see if this library is accessible on the phone/tablet. In our experience, this library also has mixed support from device to device.

I want to use the Android™ device as the USB host. Do you an example that I can use?
+

We have an example App showing how to use the USB Host API located in various phones/tablets that support USB host functionality. The App can be downloaded directly from Google Play at the following URL:

https://play.google.com/store/apps/details?id=com.microchip.android.BasicUSBDeviceDemo&feature=search_result#?t=W251bGwsMSwxLDEsImNvbS5taWNyb2NoaXAuYW5kcm9pZC5CYXNpY1VTQkRldmljZURlbW8iXQ."

The source code can be found at “/USB/Device – HID – Custom Demo” folder in the Microchip Application Libraries located at www.microchip.com/mla. This example supports our USB HID Custom demo, LibUSB demo, WinUSB demo, and MCHPUSB demo.

Where can I find the source code for your Android examples?
+

The source code linked from www.microchip.com/android but can be more directly found at www.microchip.com/mla. The Android source code is just a small portion of that distribution. The OpenAccessory firmware and example app code will be in the “/Android Accessories” folder. Examples showing how to use the Android USB Host API are part of the USB stack. The source code can be found at “/USB/Device – HID – Custom Demo” folder.