Tips to quickly re-enable a USB flash drive

Source: Internet
Author: User

In the process of using a USB flash drive, if you "safely remove the hardware" after the USB drive unplugged, and suddenly remembered to continue to use the U disk, what will you do? In general, unplug the plug. Is there a simpler way? But first, a more complicated one:

Right-click on "My Computer"--"properties"--"hardware"--"Device Manager"--expand "Universal Serial Bus Controller" in the list--right click on "USB Root Hub" to select "Deactivate"--then right click to select "Enable". So your USB stick is back. (Note: If you have more than one USB Root Hub, you can disable it and then enable it to try which one is your USB stick.) There are also articles on the Internet that use USB Mass Storage Device, but I found it deactivated, no longer enabled, and prompted to restart the computer. The following are for USB Root Hub)

But who is willing to do such a troublesome thing? So here's a simple one:

With DevCon combined with batch processing, the above complex operations can be achieved with a click. As for DevCon, Microsoft says:

The DevCon utility is a command-line utility that can replace Device Manager. With DevCon, you can enable, disable, restart, update, delete, and query a single device or a group of devices. DevCon also provides information that is relevant to driver developers, but not visible in Device Manager. You can use DevCon for Microsoft Windows 2000, Windows XP, and Windows Server 2003.

Note: The Devcon.exe that comes down is a zip tarball that must be decompressed (available winrar). After decompression there are two folders, I386 in the Devcon.exe is 32-bit machine use, and Ia64 in the 64-bit machine used.

Create a new text file, enter the following code, save the extension to bat, and put it in the same directory as Devcon.exe

@echo off

devcon disable @ "usbroot_hub204&1a2797b1&2"

DevCon enable @ "Usbroot_hub204&1a2797b1&2"

Note: The above code is the first implementation of deactivating USB devices and then enable. After that long list of things you need to modify, by right-clicking on the "USB Root Hub" Select "Properties", and then select "Details", with "Device example ID" replace the above code. The last thing to note is, "@" and double quotes, which is the key to success or failure!

Another: The device instance ID can use the wildcard character "*", which represents any character. For example, if you write a devcon disable @ "usb*", all USB devices (such as USB keyboards, mice, etc.) will be disabled.

Well, after the first paragraph of the article, just click on the batch process will be able to restart the USB flash drive, you can directly unplug the USB flash drive.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.