First step: View USB Device information
In terminal input: System_profiler Spusbdatatype can view information for connected USB devices
For example, my USB information is as follows (part of the content):
View the vendor id:0x04e8 on my Android phone, which is a unique identifier for the phone associated with the computer.
Step Two: Create and modify the Adb_usb.ini file
Enter: VI ~/.android/adb_usb.ini command, add the vendor id:0x04e8 in the first step in the open Adb_usb.ini file, and then save the exit
My device has only one, so after adding the content of the file is as follows:
1
0x22d9
If there are multiple, the INI file format is as follows (not tested):
10x22d92
......
(Note: Please ensure that there is no blank line in INI, otherwise there will be error ADB server didn ' t ack)
Note: The first time you add, the Adb_usb.ini file does not, you need to create one yourself, enter the content and save it. VI will not be used, directly into the corresponding directory to modify the file can also, the corresponding path is as follows:
\users\ Your users \.android\adb_usb.ini
Note:
The. Android directory is hidden and requires the hidden directory display to be turned on.
command line input command to display Mac hidden files: Defaults write Com.apple.finder appleshowallfiles-bool true
(Hide Mac hidden files command: Defaults write Com.apple.finder appleshowallfiles-bool false??)
After you lose, click Enter, exit the terminal, restart the finder on it?? Restart Finder: Mouse click the Apple flag in the upper-left corner of the window and force exit-->finder--> restart.
Step Three: Restart ADB (if the "command not found" prompt appears, the SDK environment variable is not configured.) )
ADB kill-server
ADB start-server
ADB devices
You can see the list!
Fourth: Enter the DDMS, already can find my Android phone, start debugging it!
Sometimes the ADB devices can not display the connection device, need to unplug the data cable, plug in several times, and exit the terminal, and then re-open, and then enter the command to find the connected device.
How to configure Android phone debugging under Mac (add test Phone to debug list on Mac system)