Go Down

Topic: Is my Arduino broken? [serial port already in use problem] (Read 9010 times) previous topic - next topic

senti

Hi.

I've been making an Arduino program since few weeks. I had no problems with connection or enything else, but today my problem started and I'm starting to feel helpless...

I have Arduino Mega. The problem is, when i want to upload a program [it compiles, no erros etc] an error appears:



This error started to harass me today, after 2 months of making a C# programe that communicate with Arduino without any problems.
My C# program is not opened when i try to upload (Even the M. Visual C++ Studio is off). So there is nothing on COM3 working. I tried to reset the Arduino with a reset button - still the same. I tried uplugging/plugging, I turned off COM & LPT Ports in Control Panel -> Device Manager. I've even removed the driver and installed it back. I tried to change COMS, got 3rd, changed to 7th and back etc - error still appears.Changing Arduino bps, moving back to default settings. Nothing. Not mentioning of xxx times restarting computer...
I'm working on Windows 7, Arduino 1.0.

Please tell me, it is possible to fix this problem. I hope my Mega isn't broken

zoomkat

Have you tried rebooting your computer? Have you looked in the arduino IDE to see if there is another available serial port?
Google forum search: Use Google Advanced Search and use Http://forum.arduino.cc/index in the "site or domain:" box.

senti

Yes, i reboot computer houndreds times.
Arduino IDE sees only one port: COM3
changing it's name (/numer, for example to COM12) in device manager makes no diffrance while uploading:/

senti

Another 2 things i can say:

1. It's not the wire - i've checked other one, still nothing.
2. I've cleaned the com port in regedit (http://blog.cognitioninfotech.com/2009/01/how-to-clear-or-reset-com-port.html), after that I removed Arduino from COM3 in COM & LPT Ports in Device Manager, reboot computer, instal it back with the driver, reboot computer again and...? Still:

'COM3' already in use. :(

I'm starting to think, that the next step would be the system format :/

lesto

this is an OS fault, your arduino is fine. format our OS if it come to this.
sei nuovo? non sai da dove partire? leggi qui: http://playground.arduino.cc/Italiano/Newbie

Sacman

This happens to me all the time in WinXP. If I have one Arduino attached and I have been programming then all is ok. If I use that same port for something else and then forget to plug in the arduino before trying to send a program, I get that error. Plugging the Arduino back in never works. The only way I've been able to clear it is to reboot. It has always gone away. 

So I agree that it is an OS problem. You may have actually made it worse by clearing the registry. Try using another usb port. You may have to reinstall the drivers.


Luck,

Wade

senti

I tried using another USB.
I've also reinstalled drivers :/ even couple of times

Guess what, now the new problem appeared. I tried to program Arduino on another computer (just the 'blink' example) and I got the same error i used to have on my netbook (belive me, everything needed was done to program it). Now I'm seriously thinking it's Ardu's fault :/

PaulS

Quote
Now I'm seriously thinking it's Ardu's fault :/

Fine. End your frustration. Just put the Arduino back in its box and forget about it.

It can't possibly tie up the PC end of the serial port, but, if you want to blame the Arduino, go ahead.

PM me, and I'll send you an address. You can send me the Arduino for my collection.

lesto

#8
Nov 26, 2012, 12:40 pm Last Edit: Nov 26, 2012, 12:43 pm by lesto Reason: 1
"port in use" is a Operative System fault, your PC didn't even tried to communicate with arduino. if the same problem is on the netbook, and the netbook has the c# program, then probably it doesn't shut down properly and so it doesn't remove lock on serial port.

Technically Serial protocol doesn't have a way to tell if the bus is occupied, because there should be only one thing on the bus. the lock is a way to prevent program that try to share the same serial with catastrophic fail (shared serial buffer)

edit: take a look here: http://www.tomshardware.co.uk/forum/148519-35-application-port, maybe a malware, maybe some phone/bluethoot/modem software, maybe microsoft ActiveScan

@PaulS: why so rude?
sei nuovo? non sai da dove partire? leggi qui: http://playground.arduino.cc/Italiano/Newbie

senti

#9
Nov 26, 2012, 04:34 pm Last Edit: Nov 26, 2012, 04:39 pm by senti Reason: 1
@PaulS: After looking at your number of posts i thought your statement would be helpful or useful. In return, it was just poor demonstration of failed irony. I think showing off is not a reason this forum was created for.

@lesto: Thanks for your interest in my problem. I went through the url you had given. I tried the "serial" in Process Explorer. Nothing found.
I don't have Microsoft ActiveSync on my computer too. The url's methods didn't help, but it was worth trying:)


"port in use" is a Operative System fault, your PC didn't even tried to communicate with arduino. if the same problem is on the netbook, and the netbook has the c# program, then probably it doesn't shut down properly and so it doesn't remove lock on serial port.


C# Program closes serial connection every time it is closed itself. But it doesn't even matter, yesterday, before i wrote the post i had been trying to program Arduino on my brother's computer without this program even on disc space.

Tomorrow my friend will lend me his Arduino Uno. If an error appear while programming, that will mean it is the OS problem.

Joaquins

I'd like to know how it ends, I get my arduino yesterday after a month waiting for it, I'd run a couple of examples on it and play a little bit with them... changing pins and simple stuff to check everything was warking, then I start trying to read serial port with max5 first and with processing later. With max I get it working, but when I tried with processing put me a couple of errors, didn't read the serial port... I get it working after a while.

When I came back to Arduino to load a new program it start saying me that same message:

"processing.app.SerialException: Serial port '/dev/tty.usbmodem3d11' already in use. Try quiting any programs that may be using it."

The last program uploaded to arduino is still working, ('AnalogInOutSerial')
I tried a lot of things, restarting the computer and starting the arduino with anything else opened, also restarting SMC and PRAM just in case... anything work so far... I trash all processing and max files I had on the computer, nothing yet. I tried with other computers but I couldn't make it work, but other 2 are PCs in bad working condition so no reference here... one is an i3 with W7 last a life to open 'tools tab' and didn't let me open the 'serial port' tab (grey text instead of black).

I'm working with a MacBook with Mac OS X 10.5.8 (I wish this donesn't matter) and arduino 1.0.2 with an Arduino Mega2560

Any other tips will be apreciated.

JS

eried

For XP you can try: http://arduino.cc/forum/index.php/topic,118440.0.html

I tried to solve this problem in that mod updating several things and adding a wrapper to avrdude, for sure is not a Windows problem. Please post the experience (if the problem goes away or not).
My website: http://ried.cl

Joaquins

#12
Dec 29, 2012, 10:07 am Last Edit: Dec 29, 2012, 06:34 pm by Joaquins Reason: 1
Today I get it working on the i3... Really hard to get drivers working in W7 if you are not used to that SO...

Still can't do my mac close the app that is using the serial port, it only use it when arduino is connected, I can use mouse or annything in all USB, but when arduino connected to any USB it start runing something on it, still if arduino isn't sending data, 'Blink' loaded with the i3 and the problem persist.

I'll look for a solution in some mac forums because is a SO issue and not an arduino, maybe some mac users around could help, but I guess a mac forum will be more helpfull.

JS

EDIT: solved here http://arduino.cc/forum/index.php/topic,49173.0.html

GUC-MD

#13
Feb 19, 2013, 11:22 am Last Edit: Feb 19, 2013, 11:31 am by GUC-MD Reason: 1
Hello everybody!

Same problem. Since days I haven't found a solution.

Error message: "Serial port 'NameMac' already in use. Try quiting any programs that may be using it."

System(s): iMac Mac OS X, 10.5.8, and same error on MacBookPro 10.7.5

Arduino version(s): Duemilanove, 1.0.2 as well as 1.0.3

Previous attempts, no solution:
- There is no rxtx.jar or comm.jar files in the Java Extensions folder (it's EMPTY actually)
- rebooted, un/plugged
- When trying to write in the terminal "$ sudo mkdir /var/lock" and "sudo chmod 777 /var/lock" then my password fails o0
- Crying a lot and smoking cigarettes afterwards
- Last thing I tried was this, it didn't work either: https://gist.github.com/jens-a-e/1419677

Also if this post is kinda often asked, I still can't find a proper answer to my problem. Do you?

Thank you!

GUC-MD

I HAVE FOUND A SOLUTION

on http://geekscape.posterous.com/mac-os-x-17-lion-upgrading-ftdi-usb-serial-dr

:%

Go Up