MDM USB How-to

来源:互联网 发布:八百字淘宝导购 编辑:程序博客网 时间:2024/05/16 01:03
1 How-to
# cat /sbin/usb/target
# cd /sys/class/android_usb/android0

# cat functions


The shell shows that QCOM’s default configuration


Usage: usb_composition [Pid] [HSIC] [PERSISTENT] [IMMEDIATE] [FROM_ADBD]

usb_composition 9025 n y y


Then this script will call
/sbin/usb/compositions/$pid n 0.2 $from_adb
ARG1: means path of /sys/class/android_usb/androidX, X = 0 if ARG1 is‘n’
ARG2: delay seconds, for example, sleep 0.2

ARG3: firstly kill adbd and then start adbd when ARG3 is‘n’


2 Where are all the USB and adbd cmds compiled in

USB slave:
system/core/usb/start_usb ---> /etc/rcS.d/S30usb,
system/core/usb/usb_composition ---> /sbin/usb_composition
system/core/usb/compositions ---> /sbin/usb/compositions

/sbin/usb/compositions/$PID ---> /sbin/usb/boot_hsusb_composition


adbd:
system/core/adb/start_adbd ---> /etc/init.d/adbd
system/core/adb/adbd ---> /sbin/adbd


bitbake file: oe-core/meta-msm/recipes/system-core/system-core_git.bb

原创粉丝点击