Recently, I bought a Prolific USB-to-Serial adapter for flashing my Android smartphone that I had accidentally bricked. I found out the RXD, TXD and GND points on the mobile phone, connected them to the Prolific adapter, but the software refused to flash the mobile phone. The reason, that I figured out after many hours of hair pulling, was that the flashing software works only with COM 1, COM 2 and COM 3 while the Prolific USB-to-Serial adapter was selected automatically to use COM 11 in Windows. After changing the adapter port from COM 11 to COM 2, I was finally able to flash the mobile phone.
Some of the software are designed intentionally to work with a selected number of COM ports. In order to work with this type of software, you may have to change the COM port number for a connected device. Here is how you can change the COM port for any connected device in Windows:
How to find your COM Port Windows Vista/7 1. Click on the Start button in the bottom left corner of your screen 2. Then type 'devmgmt.msc', and hit Enter 3. If Windows asks for your permission to continue, click on Continue 4. When the device manager shows up, Find the entry that says 'Ports (COM & LPT)' and click on the beside it to expand it. On Windows 7, 8, and 10, NI-VISA limits the number of COM ports to 256. For the serial ENET products on Windows NT and 2000, NI-VISA limits the number of COM ports to 256. Additional Information.
- Connect the device for which you want to change the port to your PC. Let Windows detect the device. If the device is not PnP ready, then you may have to reboot the PC so that it is recognized.
- Press Win+R hotkey to open the Run dialog. In the Run dialog type devmgmt.msc and press Enter to open the Device Manager.
- In the Device Manager, you will be able to find the connected communication device under the Ports (COM & LPT). Select and right-click on the target device and choose Properties from the context-menu.
- In the Properties window, switch to the Port Settings tab and click on the Advanced button.
- In the Advanced Settings window that opens up, you can choose an available port number from the lower-left corner of the window. In the following screen shot, I have changed the port from COM 11 to COM 2.
- Click on the OK button to save the settings and close the open windows. You may have to remove and re-attach the device for the new settings to take effect.
Conclusion: If an application is not working because your device is not using a particular COM port number, then you can change the port number very easily in Windows. This is specially useful for older devices and applications that make use of the fewer number of COM ports.
Related posts:
Active10 months ago
How do I clean-up these in-use COM ports?
The COM port numbers always seem to be taken up by something and although right now I only have 4 serial ports (3 over Bluetooth and one USB to RS-232), I have numerous COM ports set as in use. I'd like to clean that list up a bit.
Also it seems to me that from time to time, one of the taken COM ports gets freed up and then one of the devices I use will take that number creating confusion, since I'll have to go and hunt its com number in device manager.
UPDATE:
Well I just cleaned up countless USB devices that once were connected to the computer using USBDeview and still the problem still remains.
Journeyman Geek♦115k4646 gold badges227227 silver badges383383 bronze badges
AndrejaKoAndrejaKo15k1818 gold badges6868 silver badges121121 bronze badges
9 Answers
Run Device Manager from elevated command line:
Enable 'Show hidden devices' in the menu, and uninstall grayed-out COM ports.
grawitygrawity267k4242 gold badges557557 silver badges625625 bronze badges
I found a useful answer at How to clear or Reset COM port ?
- Click start → Run → type
regedit
and click OK button - Navigate to
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlCOM Name Arbiter
- Now on the right panel, you can see the key
ComDB
. Right-click it and click modify - In value Data section select all and delete reset to zero (
0
)
Its 32 bytes with 8 bits in each byte in hexadecimal representation. A bit of value 1 makes a port number (1...256) reserved. The first 8 ports are in two leftmost hexadecimal values, bits ascending from lowest to highest right to left, the next 8 ports are in the second two and so on: hexF3 24
would be binary1111 0011 0010 0100
, which means that following ports are used:1, 2, 5, 6, 7, 8
(1111 0011)
and11, 14
(0010 0100)
. - Close the registry editor and then restart your computer. If you set the value to
0
all COM ports are free.
You may need to reinstall any USB-to-serial converter.
hockeyrinkhockeyrink
Thanks for all the advice above. I wrote software to automatically clean up the Registry but though it did adjust the Hardware, Software, and Arbiter sections it did NOT remove the phantom COM port entries. Even a reboot with the 'USB to 2Serial Port' device removed did not clean up the system properly.
However, the instructions on this PDF did work correctly:
For Win7, I adjusted the instructions slightly on that PDF to be:
- click Start / (right click:) Computer / Properties / Advanced System Settings (not Device Manager)
- Click Environment Variables
- Click in the System variables (bottom section) click New
- Enter Variable Name: DEVMGR_SHOW_NONPRESENT_DEVICES
Enter Variable Value: 1 - Click OK (exits Environment)
- Click OK (exits System Properties)
- Click Start. In the command box, type Manage This shows the Computer Management window ...
- Click Device Manager
- Click View and select Show Hidden Devices
- Click Ports (COM & LPT)
Now all the ports, real (black text) and phantom (grayed out text) appear. - One by one, right click the phantom ports, and select Uninstall
This should now have cleared out your system of unwanted phantom USB ports.
Note: after cleaning out all my phantom ports, leaving only 'COM1', I find my Registry shows:
And a right click on Computer / Properties / Device Manager / Ports shows only COM1. Right click on COM1 / Properties / Port Settings / Advanced shows COM1 with COM2 'in use' and COM3 'in use'. All the other settings up to 7 that used to be 'in use' are now freed up. So only the 'Arbiter' setting seems to be telling the Win7 system what is really 'in use'. The Computer Management system has cleaned up the Arbiter, but not cleaned up the Software section...
... many are the mysteries of Microsoft...
Máté Juhász15.9k66 gold badges3737 silver badges5555 bronze badges
Michael HermanMichael Herman
Resolving USB driver issues
Method Using Elevated Command Prompt
ie type cmd in search bar then right click cmd.exe selecting Run as Administrator
• 1st stage As discussed from command prompt type; set devmgr_show_non_present_devices=1 devmgmt.msc
• 2nd Stage Again from Elevated Command Prompt - Remove Driver Packages from drivers store. The driver store is a protected area of the computer that contains device driver packages that have been approved for installation on the computer
Note all oem###.inf instances of the prolific driver where # (hash) is the number.
(use space between exe & - and d & Oem then press enter) Remember to replace # with the number of the inf file you want to delete.
If the computer reports that the driver package is in use by a currently installed device, then you must either uninstall the device first, or use the -f on the pnputil command to force deletion of the package.
Also you may have driver package loaded on as program that may need removal using control panel/programs/uninstall a program.
If you do all that before loading the correct driver package and try to keep the Com device inserted in the same port rather than moving it around your ports you will have fewer problems with the Prolific driver.
AntonyAntony
I found that this tool works excellently for this issue.
Device Removerhttps://www.majorgeeks.com/files/details/device_remover_543c.html
Just load it up, click on 'Display Mode', 'Show only hidden/detached devices', Check 'Ports' (which selects all the unused com ports), then click 'Remove all checked', and confirm the removal when the warning appears.
Cheers!
~Andrew
EmpoweringSolutions.net
EmpoweringSolutions.netEmpoweringSolutions.net
I have a simple solution that worked for me... my count was up to 45 com ports in use!
1) Open Device Manager
2) From the View menu, select 'Show Hidden Devices'
3) Expand 'Ports (COM & LPT)' category from the list
4) Right-click on all the devices and remove them (no need to tick to delete the driver)
5) From the Action menu, select 'Scan for New Devices'
Com Port Settings Windows 7
6) Viola! All the actual devices will be re-allocated from COM1
Paul PritsisPaul Pritsis
These did not work for me. But official Microsoft help page worked for me.
From https://support.microsoft.com/en-us/kb/222018
- In the Printers folder, click Server Properties on the File menu.
- Click the Ports tab, click the port you want to remove, click Delete Port, and then click OK.
Nasif Md. TanjimNasif Md. Tanjim
(For those who came from google)
If previos answer doesn't work and has installed windows mobile 6 SDK. It may be problem with XPVCOM.SYS (this driver reserved 14 COM ports) To uninstall in console
CD Program FilesWindows Mobile 6 SDKToolsCellular Emulator
InstallXPVCom.exe UnInstall
then reboot.
ZtareKQFZtareKQF
For those who do not want to use the CMD line interface I use this in Windows 7.
- Open Control Panel
- Select 'SYSTEM' from the menu
- Select 'ADVANCED SYSTEM SETTINGS' on the left
- Select 'ENVIRONMENT VARIABLES' on the bottom right of the box
- Look for 'DEVMGR_SHOW_NONPRESENT_DEVICES' in the System Variableslist. If it is not there create it and assign it a variable value of
- Back out with OK, OK, OK. You are now back in the Control panel screen.
- Select 'Device Manager' and go to 'View'
- Select 'Show Hidden Devices' and all hidden devices including theComm ports will be shown greyed out or Ghosted.
- Select the ones you want to remove, right click and select'Uninstall'
4,2651111 gold badges3131 silver badges5858 bronze badges
Gary Karli - Com TechGary Karli - Com Tech
protected by Community♦Dec 11 '18 at 9:14
Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).
Would you like to answer one of these unanswered questions instead?
Would you like to answer one of these unanswered questions instead?