1

We are using a USB-to-Serial converter. Windows assigns a COM port number to the serial device. For testing purposes, we need to control the COM port number assigned by Windows. For example, we would like to tell Windows to assign COM 255 to a device rather than have Windows decide what the number is. Is there any way to do this?

3
  • 1
    Assign it programmatically ? if so, what language ? otherwise, you can do it from Device Manager in Windows. Commented Nov 17, 2011 at 15:40
  • 1
    This is the most odd test requirement I've seen in awhile... Commented Nov 17, 2011 at 15:41
  • 1
    It is up to the driver, not Windows. Finding a converter with a driver that lets you do this is going to be hard shopping. The odds that your user will have one are even smaller. Commented Nov 17, 2011 at 15:48

3 Answers 3

4

I do not have to do this programmatically, so Nacereddine is right. My Computer -> Manage -> Device Manager -> Ports -> Communications Port -> Port Settings -> Advanced -> COM Port Number

Sign up to request clarification or add additional context in comments.

1 Comment

My answer basically said the same thing, but without as much detail because the details depend on the driver. If you are going to accept your own answer which says almost the same thing you should specify the device make/model so that people understand that your answer might be specific to that make/model.
1

This normally depends on the driver. Some drivers allow you to edit the COM port number assigned by going into the device properties in device manager and using one of the properties pages to specify the COM port number. If the model you are currently using doesn't support this I suggest finding a model that does.

Comments

1

No, but if you know what device id it reports to the OS then its possible that you could find it programmatically in the device manager.

Here's a link to a code project that may give you some ideas.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.