UniApp has already connected the data cable of the mobile phone, but the running tool warns that "device has not been detected" (Huawei mobile phone is used as an example to solve it)

Most of the first time to use uni for mobile phone debugging will encounter this problem

First, plug the data cable of the mobile phone into the usb interface of the computer is a prerequisite

Then the permissions of the mobile phone intercepted the device scan, which is why the uni tool could not find the device

After connecting to the mobile phone line, the data will pop up a USB prompt.
insert image description here
After clicking in, we need to set the permission to transfer files. Don’t just charge. The
insert image description here
next operation is how to open the developer mode of Huawei mobile phones. If your mobile phone is different from the steps, you can find some corresponding ones. How to enable developer mode on mobile

Then open the phone's [Settings],
find the bottom of the phone in the settings, click this version information several times in a row until the bottom pops up and prompts you
insert image description here
to be in developer mode.
lock screen password
insert image description here

The above are the operation steps of Huawei mobile phones. If your mobile phone is different, you can find the way to open the developer mode for your mobile phone.

The last step is to search for the developer option in the mobile phone [Settings].
If you don’t turn on the developer mode, you can’t find it in the configuration. Scroll
insert image description here
down to find this USB debugging and turn it on.
insert image description here
Then we can turn it on again and it will work normally.
insert image description here

insert image description here
insert image description here

Guess you like

Origin blog.csdn.net/weixin_45966674/article/details/128810131#comments_26049443