Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Example explanation of adb devices instruction

2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

Before giving this instruction, I first started a mobile phone simulator called "Galaxy_Nexus_4.4.2" (sometimes we also call it an Android virtual device) and connected my mobile device to PC through a USB cable, then I used the "Android Screen Monitor" tool to capture my physical phone screen information, and the running phone simulator and physical phone screen display, as shown in figure 3-7.

Usually when we are testing, the most common thing to use is to check the relevant information of the equipment. With what instructions can we know the relevant information of our physical testing equipment or simulator?

I can give you an instruction, which is the "adb devices" instruction, through which users can get information about the status of the currently connected device / simulator. You can enter "adb devices" in the command line console, and the display information is shown in figure 3-8.

From figure 3-8, we can see that the output information mainly includes two columns, the first column is the serial number information of the device, and the second column is the status information of the device.

The serial number of a device is a string of characters used to uniquely represent a simulator or physical device. Usually the simulator takes the form of "-" as its serial number. The "5554:Galaxy_Nexus_4.4.2" shown in figure 3-8 indicates that the type of device is "Galaxy_Nexus_4.4.2" and is listening on the simulator instance of port 5554. And "4df7b6be03f2302b" represents the serial number of the physical mobile device connected to our PC.

Figure 3-7 display information after the execution of "adb help"

Figure 3-8 display information after the execution of "adbdevices"

The status information may contain the following three different states.

(1) device status: this status indicates that the device or simulator is connected to the adb server. However, this state does not mean that the physical mobile phone device or simulator has been started and can be operated, because the Android system will first connect to the adb server when it is started, but the device or simulator is usually in this state after the android system is started.

(2) offline status: this status indicates that the device or emulator is not connected to the adb server or is not responding.

(3) no device status: this state indicates that there is no physical device or simulator connection.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report