Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6612901
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T20:09:11+00:00 2026-05-25T20:09:11+00:00

I am attempting to leverage the USB host capability on the Samsung Galaxy Tablet.

  • 0

I am attempting to leverage the USB host capability on the Samsung Galaxy Tablet. I purchased the attachment dongle from samsung (http://www.samsung.com/us/mobile/galaxy-tab-accessories/EPL-1PL0BEGSTA). When I first connected a usb device via this dongle, I had a high power error from the Galaxy Tablet — FYI use an externally powered USB hub and you can bipass this.

Now that the device itself is acknowledging the existance of a USB peripheral when I attach it, I attempted to use Android’s android.hardware.usb.UsbDevice;
import android.hardware.usb.UsbManager; library. I saw that there are two methods for recognizing a USB device, registering a broadcast receiver to listen for the intents via

IntentFilter usbIntentFilter = new IntentFilter();
usbIntentFilter.addAction("android.hardware.usb.action.USB_DEVICE_ATTACHED");          
usbIntentFilter.addAction("android.hardware.usb.action.USB_DEVICE_DETACHED"); 
registerReceiver(mUsbReceiver,usbIntentFilter);

This is not firing any intents when I attach any devices, strange…ok. So I went on to try the next method: explicitly querying for a device list via the UsbManager — this was accomplished as follows:

HashMap<String, UsbDevice> deviceList = manager.getDeviceList();
    int count = deviceList.size();
    Iterator<UsbDevice> iterator = deviceList.values().iterator();

    if(iterator.hasNext()){
    UsbDevice deviceVal = iterator.next();
    testTxtView1.setText("set device " + deviceVal); 
    }

This would presumably grab the one (only one USB device currently supported per Google Documentation) USB device that is currently connected. To test this I would call the above code upon a button click and display the device results. For some reason, I am getting a device from the device list every time, whether a USB dongle is connected or not. Furthermore, the device is the same every time regardless of the USB dongle (or lack thereof). The output is as follows:

device usbDevice[mName=/dev/bus/usb/001/002,mVendorId=1256,mProductId=27033,mClass=0,mSubClass=0,mProtocol=0,mInterfaces=[Landroid.os.Parcelable;@406ff4d8]

^^ the @406ff4d8 value changes every time I query this code (I just put a single instance of it up)

I have searched everywhere and have not been able to find any similar problems or solutions that may apply to my situation. I have tried implementing google’s USB examples (which is exactly what I have essentially, I ripped theirs) and am running into these problems.

I should also mention the makeup of my manifest:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="edu.mit.ll.drm4000"
  android:versionCode="1"
  android:versionName="1.0">
<uses-feature android:name="android.hardware.usb.host" />
<uses-sdk android:minSdkVersion="12" />

<application android:icon="@drawable/icon" android:label="@string/app_name">


    <activity android:name=".DRM4000Activity"
              android:label="@string/app_name">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>

        <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" />

    </activity>

</application>

and device filter:

(I removed criteria on the device filter but have also tried inserting specific information about the device I am looking for…both to no avail.)

Any help regarding this problem would be much appreciated!


Another update: The device I complained about always being enumerated on the device list

device usbDevice[mName=/dev/bus/usb/001/002,mVendorId=1256,mProductId=27033,mClass=0,mSubClass=0,mProtocol=0,mInterfaces=[Landroid.os.Parcelable;@406ff4d8]

must be the android side usb port or something…because I started attaching a bunch of different devices to my code and found that (similar to this link:
USB_DEVICE_ATTACHED Intent not firing) HID devices, arduino devices..and sadly… my USB device do not appear to fire an intent or get enumerated by the USB hub. I tried with a USB flash drive and it DID enumerate it and worked…however it shows up as the SECOND device on the list, the first being the ever-present usbDevice listed above. Intents do fire with it though.

Does anyone know a workaround to making intents fire with HID devices and other USB devices except the select few android seems to do now?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T20:09:12+00:00Added an answer on May 25, 2026 at 8:09 pm

    SOO unfortunately it looks like the Samsung Galaxy Tablet just does not play nicely with the UsbManager and about half of the USB devices in the world. The kernel in Samsung seems to fire intents for storage devices and the like, but not for HID and other random devices (such as arduino, and my usb sensor, and HID devices as well.) It seems to be a bug in samsung kernel. Interestingly, the HID devices WORK on the tablet, but are not enumerated on the UsbManager. I have found several links of the same problem, and it seems like a kernel patch (or the acer tablet) are the only ways around this atm. hopefully samsung will fix in the future. Here is a link to a guy who did a kernel patch if rebuilding the kernel is your thing and you really need to get UsbManager working. I have not tested but plan to eventually, and will leave a comment on my thoughts.
    http://forum.xda-developers.com/showthread.php?t=1233072

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm attempting to leverage the splicer.dll component from http://splicer.codeplex.com on a windows 2008 server.
Attempting to follow the directions as specified on http://code.google.com/p/gears/wiki/BuildingGearsForWindows my attempts are failing at
Attempting to cache my SSRS reports as referenced in http://blogs.technet.com/b/rob/archive/2010/02/11/caching-ssrs-reports-for-performance.aspx ...I am to understand
Attempting the most basic example of Knockout.js possible on their documentation page: http://knockoutjs.com/documentation/observables.html Looks
Attempting to print out a list of values from 2 different variables that are
Attempting to deploy a MOSS solution to a UAT server from dev server for
Attempting to use the data series from this example no longer passes the JSONLint
Attempting to decide on how to implement our RPC on the server side. From
I attempting to take a response from a REST service that queries an instance
Attempting to learn from doing an implementation of Quicksort, I cannot find out why

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.