Go Down

Topic: "com7 already in use" problem (Read 2064 times) previous topic - next topic


I was working with my Arduino Mega (new version) when suddenly I could no longer upload programs to the board.  The error message was "Com 7 already in use"

This problem seemed to occur after I installed two programs on my computer: LabView and Procomm.  I'm not exactly sure if I was able to program the Arduino after these programs were installed.  In any case I uninstalled both programs and got the same error.

I tried reinstalling the USB driver and got the same error.  I tried a second mega and got the same error.  I tried a Duemilanove and got the same error (after changing the board and serial port settings).  I tried a different USB cable and got the same error.  I tried a completely different computer and got the same error.

Any insights would be much appreciated.



I've managed to solve the "com7 not available" problem.

I think that my program was uploading to the board, its just that I was using the Serial functions incorrectly.  I hypothesize that if a Serial function is used incorrectly there is some sort of interaction between the Arduino and the Arduino IDE  that causes the lock-up of the com port.  In my case I was writing a program to use serial port 1 on the Arduino Mega.  I invoked the following function: Serial1.println( );  The Arduino reference does not state that this function is compatible with serial ports other than the standard port 0 found on all boards.  So I presume this command can't be used, it was an error and caused the lockup.  I also got the same behavior when I invoked Serial.write( ); instead of Serial1.write( );  Not a syntax error but a program error because I did not initialize serial port 0.

When the "com 7 not available" problem occurred I managed to regain control by closing the Arduino IDE, pulling the USB cable out of the board and power cycling the external power supply I was using to power circuits connected to the board.  I could then reconnect the board, open the Arduino IDE and I  got my serial port back in action (most of the time).

Hope this help people with similar problems. 

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131