Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a pc at work which its com port always hangs on boot up. It is windows 7. In order to get it to work you need to disable and enable the com port manually. This is not an option for the setup of the computer.

Does any one have a script or have the code which will allow me to disable and enable a com port?

I want to run the script on start up to automatically disable and enable the port.

share|improve this question

migrated from stackoverflow.com Jan 21 '13 at 10:38

This question came from our site for professional and enthusiast programmers.

1  
you cant disable the port in BIOS? –  Keltari Jan 21 '13 at 10:52
add comment

1 Answer 1

Microsoft's comdisable.

For example, to enable COM port 2:

Use:

comdisable /enable com2

There is a disable as well and listing of ports.

You can disable before the computer shutsdown.

EDIT: You can try and call the script at startup but it might not work if Windows holds before.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.