Android Diagnostic Mode - How to Enable it?

我怕爱的太早我们不能终老 提交于 2019-12-06 05:16:44

问题


I would Like to enable Diagnostic (DIAG) Mode on Android. I have the following questions about the same.

  1. How is DIAG mode helpful ?
  2. Is Rooting the Device necessary to enable DIAG Mode ?
  3. How to verify if DIAG mode is enabled ?
  4. Is it reversible ? Can i go back to Normal Mode ?

I'm using Google Nexus 5.

I'm fairly new to Android Development. Any help would be appreciated.


回答1:


1- I personally use DM to collect and analyse the messages between a mobile (UE) and a network. I use it with Qualcomm QXDM and QPST tools to analyse wireless protocol stack messages. With commercial phones, usually the DM is blocked as a security measure as it allows you to decapsulate the messages sent/received by the UE. I haven't heard about another use for it until now.

2- Yes all the commercial UEs I worked with ( mostly with Sony Xperia and currently with Xperia Ray) are rooted.

3- If DIAG mode is enabled, you can see it in your Device Manager. Here is a snapshot of mine. That means you have to install the correct drivers for the device (which was tricky with many phones). The device should has Qualcomm Chipset!

4- Yes you can unroot the device. Never tried with Nexus myself.

Can I ask what is the purpose of using it for you? I mean it's strictly working with protocol stacks.

Hope it helps! Cheers




回答2:


  1. Diagnostics Mode can be used to change your device's radio band & modem settings and other stuff like changing IMEI address or MAC Address, if you have appropriate software like DFS CDMA Tool or QPST.

  2. You can enable it only if your phone is rooted.

Make sure Qualcomm drivers for your phone are installed in computer.

Enter this in Terminal Emulator in your device:

su
setprop sys.usb.config diag,adb

Note: This will work only if your phone's ramdisk has the appropriate configs enabled for the 'diag,adb' property. If that didn't work, better open /init.xxxxxxx.usb.rc (xxxxxxx represents your device's codename or chipname or whatever) and check for properties related to 'diag'.

  1. To verify if it's working, just check the Device Manager or the tool you're using & check if your phone gets connected.

  2. Yes, it's reversible. To get back to normal mode, just type this in Terminal Emulator:

setprop sys.usb.config mtp

You'll get back to MTP mode :)




回答3:


If you mean the developer options, then as of Android 4.2 I believe, one of the things about the developer options is that the menu is just hidden now. You have to purposely enable the menu to access the options.

  1. It's helpful because you need it to help debug your apps while it's connected to your computer and the SDK. There are a lot of options there, depending on what kind of app you are making. Enabling the menu by itself does not do anything to your device.
  2. No it's not necessary.
  3. If you see developer options in the settings menu, then you know it's enabled.
  4. All you are doing is unhiding the hidden developer menu. Not really anything to reverse. You can just turn off the options you turned on during development.



回答4:


I dont know much about DIAG mode but it's used when you want to read data from phone using qualcomm settings. To get into DIAG mode use ##3424# or *#7284#. And enable DM+MOdem+.. on.




回答5:


If the following command does not work:

su setprop sys.usb.config diag,adb

You can try:

su setprop sys.usb.config diag,serial_cdev,rmnet,adb

Both set of commands require root. The difference has to do with modem processors.



来源:https://stackoverflow.com/questions/24006903/android-diagnostic-mode-how-to-enable-it

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