An analysis of Android phone assistant identification model

Source: Internet
Author: User

Recently in doing a pad project, QA submitted a bug, with itools management pad, itools display equipment and target models of equipment model inconsistent, in other pea pods, Baidu and other mobile phone assistants did not encounter this problem. To resolve this problem, first query the Prop.build in the machine system directory for the device's description if there is any impact. Mainly includes:

Ro.product.model= Model _modle

Ro.product.brand= Brand _brand

Ro.product.name= Phone name _name

......

ro.product.cpu.abi=armeabi-v7a

Ro.product.cpu.abi2=armeabi

ro.product.manufacturer= manufacturer _manufacturer

However, it is found that the identified device name is a different brand and can be determined that the brand is not obtained through the Prop.build file. In addition, in the testing process found that if the network is disconnected, the device name will be the same as the model name, so you can know that itools based on an ID, in their own online database to find the corresponding device model.

By using Usblayzer to view the USB vid,pid, and corresponding to the vid in Http://www.linux-usb.org/usb.ids, the vid is found to be a manufacturer of vid, so the estimated itools is based on the USB vid,pid to obtain the corresponding device name. So we changed the original vid pid to the vid and PID of the Taiwan Electric Pad, because the Taiwan power in the case of the network and networking in the identification is consistent with the model name. Through the query can know VID=18D1 is Google, PID is 0007. So modify the android4.4/device/softwinner/fiber-a31stm init.sun6i.usb.rc file:

On PROPERTY:SYS.USB.CONFIG=MTP

Write/sys/class/android_usb/android0/enable 0

Write/sys/class/android_usb/android0/idvendor 18D1

Write/sys/class/android_usb/android0/idproduct 0007

Write/sys/class/android_usb/android0/functions ${sys.usb.config}

Write/sys/class/android_usb/android0/enable 1

SetProp Sys.usb.state ${sys.usb.config}

.......
All of the vid in this file will have to be changed to the same 18d1,pid can be staggered, but not with Google's registration device conflict. As follows:

Vid->18d1 Google Inc.

pid-> 0d02 Celkon A88

2d00 android-powered device in accessory mode

2D01 android-powered device in accessory mode WITHADB support

4e11 Nexus One

4e12 Nexus One (debug)

4e13 Nexus One (tether)

4e20 Nexus S (fastboot)

4e21 Nexus S

4e22 Nexus S (Debug)

4e24 Nexus S (tether)

4e40 Nexus 7 (fastboot)

4e41 Nexus 7 (MTP)

4e42 Nexus 7 (Debug)

4e43 Nexus 7 (PTP)

4ee1 Nexus 4/10

4ee2 Nexus 4 (Debug)

4ee3 Nexus 4 (tether)

4ee4 Nexus 4 (debug + tether)

7102 Toshiba Thrive Tablet

b004 pandigital/b&n novel 9 "tablet

d109 LG g2x MTP

d10a LG g2x MTP (Debug)


After modification, the device name is the same as the model name.

Summary: Itools connection, will first use the Usbvid PID to their network database matching device name, if there is a network and database data, then the use of network data, if there is no network or network but the database does not correspond to the vid PID, then there is model consistent model.



An analysis of Android phone assistant identification model

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.