I've been thinking that, since many android phones support USB OTG maybe there could be a way to engineer a device that performs special task and uses phone as it's control panel.

But before making this serious idea, I need to know if it can work.

  1. How does android handle unknown USB devices?
  2. Can application use USB directly without ROOT privegies?
  3. As an alternative, does android support virtual COM port?
  4. As the last hope, can applications directly read/set value on headset output? (To use it as digital IO pin)

1 Answer 1


I never tried it but applications can access USB through the following API since android 3.1.
To confirm this there are devices with infrared that you plug to USB in your phone to use it as universal remote control.

  • That looks quite promising! Sep 8, 2014 at 18:24
  • I'm sorry, but I need to test it. I'm not new to stack-exchange so will definitelly remember to mark it as soon as possible. You've earned your points, they're just in the future :) Sep 11, 2014 at 20:52
  • Hi @TomášZato, did you get it to work? I have a requirement at the moment to use a USB device that acts as a virtual COM port under Linux, and need to try it next week when my OTG cables arrive. Oct 4, 2015 at 10:59
  • @user1158559 Hello. With my older device (Huawei) it just plain didn't work, and my new Samsung turned out to have OTG technology disabled, so I couldn't really test it (which is sad because I also wanted to make use of USB virtual COM to make a hardware dedicated for smartphones). Oct 4, 2015 at 17:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .