When the screen of Xiaomi’s smartphone is broken or no longer responsive to touch, but the device itself is functioning, it is one of the most stressful for the owner. Often at this point there is an urgent need to access files, make a backup of contacts or simply save important photos stored in internal memory. However, the standard path through the settings menu is blocked due to the inability to control the sensor. This is where the debugging mode on USB comes to the scene, allowing the computer to control the phone and bypass the broken touchscreen.
Unfortunately, enabling this feature from scratch on a locked device without the use of special hardware adapters or pre-configured cloud services is extremely difficult due to Android security. However, there are a number of proven methods that allow you to bypass the restrictions. In this article, we will discuss in detail how to activate debugging using external peripherals, Mi Cloud services and specialized utilities that will help you regain control of the device.
Before you start to take action, you need to understand that the success of the operation depends on the degree of damage to the display. If the matrix is intact and you can see the image, but the sensor does not work, the chances of success are close to 100%. If the screen is completely black, but the phone gives signs of life (vibration, charging sound), you will need a method of blind connection or use of the device. OTG-Critical: If the phone was reset to factory settings after the screen broke, it's almost impossible to restore access to data without first activating the debugging.
Use of the OTG-adapter and computer mouse
The most reliable and time-tested way to unlock access to the settings menu is to use an adapter. OTG (This small adapter allows you to connect a regular computer to your smartphone. USB-If your Xiaomi screen shows an image but the sensor doesn't respond, the mouse cursor will appear on the display, allowing you to fully control the interface. You'll need the adapter itself (usually a Type-C or Micro-USB depending on the model) and any wired mouse.
The connection process is simple: insert the adapter into the phone's charging connector and plug a mouse into it. The cursor should appear on the screen. Using the left mouse button for clicks and the right (or wheel) for navigation, you need to go the way: Settings → The phone. → Version. MIUI (to activate the developer mode) or immediately go to Advanced Settings → For developers, this is the switch you want. USB-debugging.
Not all Xiaomi models support image output or peripheral operation through the charging port when turned off, but most modern devices react instantly. If the cursor does not appear, try restarting the device with the mouse connected. Also keep in mind that a work permit may be required to use USB-devices that sometimes pop up on the lock screen.
- 🖱️ Find the right one. OTG-Adapter: new models need Type-C, old models need Micro-USB.
- 🔌 Connect a regular computer mouse to an adapter and insert it into your phone.
- ⚙️ Use the cursor to navigate the menu and enable debugging in the developer section.
💡
If you have a wireless mouse with USB-The recipient must also earn money through OTG-Adapter, which eliminates the need to pull wires.
Blind activation method through ADB commands
If the screen is completely black, but you know for sure that the phone is on and charged, you can try the blind command method. This method requires that the Xiaomi drivers and the ADB utility are already installed on the computer. The essence of the method is that we send a debugging activation command blindly, hoping that the system will accept it even if the function is turned off. This does not work on all versions of MIUI, but it is worth trying.
First, connect your phone to your PC through USB-Open the command line on your computer in the folder with ADB. You will need to enter a command to emulate the click on the screen in a certain coordinate, where the debugging button should theoretically be located, or use special scripts to activate the mode. However, it is more effective to use the command to reboot to recovery mode or the bootloader if the goal is to flash the flash.
adb shell input tap x yWhere x and y are the coordinates of the dot on the screen. It's difficult to hit the exact blind spot, so this method is often combined with the previous one (via the mouse) to activate the debugging first, and then control the phone from the PC. If debugging was on before, but the computer can't see the device, try the adb device command and check if it requires confirmation on the screen (which you can't see), in which case only the mouse method will help.
Why can't ADB see the phone?
Use of the Mi Cloud cloud service
Xiaomi device owners are more fortunate than other brands thanks to the deeply integrated Mi Cloud service, which means that if you have the Internet and Mi Account on a broken phone, you can remotely control the device via a browser, which does not require cable connection and works even with a black screen, as long as the phone is online.
Go to the official cloud.mi.com website and log in to your account. From the menu, select Find your device. If your phone is selected, you'll have a range of features: location, beep, lock and, most importantly, remote control. Remote control allows you to see the screen of your phone in your browser and control it with a mouse, emulating touch.
This interface allows you to go into settings and enable USB debugging or simply copy important data to the cloud, which is the perfect way for those who have taken care of synchronization beforehand. However, if the remote control function was not activated in security settings before it broke, this method may not work, since modern versions of Android require prior permission for remote access.
- ☁️ Go to the Mi Cloud website from a computer or other phone.
- 🔐 Log in to your Mi Account that was used on the broken device.
- 💻 Select the “Find Device” function and try to start remote control.
💡
Mi Cloud is the only way to access data without physically connecting the cable, as long as the feature has been configured in advance.
Comparison of debugging activation methods
The choice of method depends on the specific state of your device and the tools available at hand. To make it easier for you to navigate, we have compiled a comparison table that will help you assess the chances of success in each case. Note that the effectiveness of methods can vary depending on the version of the MIUI shell and the model of the smartphone.
| Method | Equipment required | Requires a screen on | Efficiency |
|---|---|---|---|
| OTG + Mouse | adapter OTG, USB-mouse | Preferably (for visual inspection) | Tall. |
| Mi Cloud | Internet, Mi Account | No (works remotely) | Medium (depending on settings) |
| ADB (blind input) | PC, cable, drivers | No. | Low (no root license) |
| Donor display | Work screen, tools | No (screen replacement) | 100% |
As can be seen from the table, the use of OTG-The adapter is the most versatile solution for situations where the touchscreen doesn't work, but the matrix is intact. Cloud methods are good for preventive measures or if the screen is completely black, but the phone is online. ADB without visible interfaces require high qualifications and are often useless for the average user without root rights.
Connecting to PC and managing files
Once you have enabled debugging mode, you can have a wide range of options to manage your device, you can have full access to your phone's file system, and you can use programs like Mi PC Suite (although old versions are no longer supported, new versions are working) or Windows standard Explorer if you select file transfer mode (MTP).
For more advanced management, including app installation, screenshot capture, and screen recording, you can use third-party utilities like Scrcpy or Vysor. These programs stream your phone screen to your computer monitor and let you control your mouse and keyboard with minimal latency. This is especially handy if your phone's home screen is shattered, but you've connected it via OTG or just want to work with more comfort.
When you first connect to a new computer, a request for debugging permission will appear on the phone screen (or where it should be) if you use the mouse method, just press OK. If the screen is black, you may have to rely on the permission given earlier, or use the adb shell command to check status. Remember that transferring large amounts of data can take time, so make sure the phone battery is charged.
☑️ Connection check ADB
Possible problems and ways to solve them
You may encounter a number of difficulties in restoring access to Xiaomi, and it is often the case that a computer sees a device as an “Unknown Device” or simply starts charging it, ignoring commands, which may be due to damage to the USB controller in the phone itself or the use of a poor-quality cable that does not support data transfer.
Another common problem is that you lock your Mi Account. If you try to reset your phone through Recovery Mode, when you turn on, the device will require you to enter the password from the account that was previously tied, which is anti-theft protection, and it's extremely difficult to get around it without a password. So if you can, it's better not to do a full reset, but to try to save the data through debugging.
⚠️ Warning: Do not attempt to disassemble the phone and close contacts on the board to enable debugging unless you are a professional engineer.
If nothing works, and data is critical, the last option is to temporarily replace the display, and service centers can plug the desktop screen on weight without gluing it so you can unlock the phone, enable debugging and copy information, which is a paid service, but it guarantees results where software methods are powerless.
⚠️ Note: When using third-party software to manage your phone, download them only from official websites. Fake versions of unlocking utilities often contain password-stealing viruses.