Android的ADK - USB OTG(主机模式) [英] android ADK - USB OTG (Host mode)

查看:406
本文介绍了Android的ADK - USB OTG(主机模式)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚开始进入Android的软开发,将设计辅助硬件接口的Andr​​oid设备。似乎有一些限制在什么的USB模式可以在设备依赖于固件上使用。基于USB上的文件从developer.android.com网站。 USB主机模式仅支持固件版本3.1及以上。但是,看来,三星Galaxy 2支持OTG(主机模式),至少本身,就证明这个YouTube视频:的 SGS2 OTG演示。该手机是在主机为了提供少量功率与我的外部连接的硬件,这一点至关重要。

  1. 任何人都可以验证是否有任何的API接入USB主机模式在Android手机设备?我怀疑上面的Andr​​oid开发人员报价的原因是,有明显主机模式的功能正在演示的SGS2电话。

  2. 如果我不能访问任何的USB主机API功能,有没有什么办法来开发USB外围设备硬件,可与手机沟通?看来,我可以设计一个使用MSD类的硬件,可原生支持上面列出的演示的出现?

  3. 如果没有API的USB主机访问目前,有什么未来的计划将它添加到手机硬件的未来?

解决方案

一个相当广泛的各种硬件设备的支持USB主机(有时只是部分,无需供电),但只有用其他的固件或供应商特定的扩展 - 直到你到达一个API版本它的Andr​​oid的正式组成部分。

很多的视频和网页,你看到的人炫耀自己的自制固件的修改 - 这可以是一个路径,而是一个你的市场,限制了用户愿意mod,设备列表,你证明兼容,或特殊Android设备你卖捆绑你的accesory。

I am just starting to get into android soft dev and will be designing accessory hardware to interface the android device. It appears that there are some limitation in what USB modes can be used on the device dependent on the firmware. Based on a documentation on USB from the developer.android.com site. USB host mode is only supported on firmware versions 3.1 and up. However, it appears that the samsung galaxy 2 supports OTG (host mode), at least natively, as demonstrated in this youtube video : SGS2 OTG demo. It is critical that the phone be the host in order to supply a small amount of power to my externally connected hardware.

  1. Can anyone verify whether there is any API access to USB host mode on android mobile phone devices? The reason that I question the android dev quote above is that there is clearly Host mode functionality being demonstrated on the SGS2 phone.

  2. If I cannot access any of the USB host API functionality, is there any way to develop USB peripheral device hardware that can communicate with the phone? It appears that I could design hardware that uses the MSD classes, as appears to be natively supported in the above listed demo?

  3. If there is no API USB host access currently, are there any future plans to add this to mobile phone hardware in the future?

解决方案

A fairly wide variety of device hardware supports usb host (sometimes only partially, without supplying power) but only with alternative firmware or vendor specific extensions - until you get to an API versions where it's an official part of android.

A lot of the videos and web pages you see are people showing off their custom firmware modifications - which can be a path, but one that restricts your market to users willing to mod, a list of devices you certify compatible, or special android devices you sell bundled with your accesory.

这篇关于Android的ADK - USB OTG(主机模式)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆