Detect HDMI Port in android device

谁说胖子不能爱 提交于 2019-11-30 05:43:33

问题


I am working on a Android development app that needs to detect HDMI Port. Can some one guide me how can i detect HDMI port in andorid device programatically.

Thanks in Advance


回答1:


You could try to listen to the broadcast hidden android intent

"android.intent.action.HDMI_PLUGGED"

if you use android 4.0 or higher or if you use Sony device:

"com.sonyericsson.intent.action.HDMI_EVENT"

Check this tutorial for more information: http://developer.sonymobile.com/2012/05/29/how-to-use-the-hidden-hdmi-api-tutorial/

There are also 3rd party libraires like KernelSwitchObserverLib http://forum.xda-developers.com/showthread.php?t=1963785



来源:https://stackoverflow.com/questions/13430835/detect-hdmi-port-in-android-device

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!