Too many serial ports, need to remove them
Posted on 2009-04-12
I work for a company that does mobile phone (cellphone) unloicking - i.e. unlock to all networks. As part of this, they use cables that connect from the various models of phone to the PC via USB. They register as COM devices in Windows. The problem is that because each phone has a different serial number (probably the IMEI of the phone), every phone appears as a new serial device. This means that his unlock machine has over 150 serial port devices that are just sitting around and will never be used again. The software he uses cannot access port 200+, so every unlock he does he has to remove an old unused COM device, plug in the new one, then switch the COM port number of the new device to whatever the one was that he removed. For example, if he removed COM142, he adds the new device and changes the port number to COM142. It's getting rediculous.
I know that Windows XP stores COM device information in the registry, and would like to know if there's anything I can do to remove them all. I can program in VB.NET and C#, so if it's a case of conditionally removing registry entries I'm happy to do so. I have a virtual machine set up to allow me to revert to a snapshot in case I mess up the registry.
Any ideas how I can remove the ports?