Processing.app.serialexception Error Opening Serial Port

Serial: Port busy. Tasm_Devil. May 2014 Error opening serial port /dev/ttyACM0: Error opening serial port /dev/ttyACM0: Port busy at processing.serial.Serial.

Error when opening COM port. processing.app.SerialException: Error when Arduino COM port. SerialException: Error when opening serial port /dev.

Error opening serial port '/dev/ttyUSBx' on Ubuntu

Helge Milde

Hi.

I m suddenly having problems uploading/communicating with my Arduino board via the Arduino Java IDE.. The strange thing is it happened after working for 2 days straight..

I was editing a program, continously uploading and testing it, when I clicked the Serial Monitor button so I could debug which had worked fine just minutes ago.

First I get a lot of weird char s, like you d get trying to Serial.print a non-alphanumeric byte although it was an int - then, after fiddeling with the Serial rate from the IDE while the Arduino program was still running, I got an error.

Ctrl c. /arduino and Upload to I/O Board Still get an error.

I ve tried rebooting Ubuntu, reinstalling the software, removing all components and reprogrammed the Blink-example with my Windows machine which worked - so I doubt the board is damaged.

Below is the full error message. I m 100 sure the usb-device is correct.

processing.app.SerialException: Error opening serial port /dev/ttyUSB0.

    at processing.app.Serial. Serial.java:142

    at processing.app.Serial. Serial.java:72

    at processing.app.Uploader.flushSerialBuffer Uploader.java:66

    at processing.app.AvrdudeUploader.uploadViaBootloader AvrdudeUploader.java:73

    at processing.app.AvrdudeUploader.uploadUsingPreferences AvrdudeUploader.java:48

    at processing.app.Sketch.upload Sketch.java:1632

    at processing.app.Sketch.exportApplet Sketch.java:1701

    at processing.app.Editor 41.run Editor.java:2004

    at java.awt.event.InvocationEvent.dispatch InvocationEvent.java:209

    at java.awt.EventQueue.dispatchEvent EventQueue.java:597

    at java.awt.EventDispatchThread.pumpOneEventForFilters EventDispatchThread.java:273

    at java.awt.EventDispatchThread.pumpEventsForFilter EventDispatchThread.java:183

    at java.awt.EventDispatchThread.pumpEventsForHierarchy EventDispatchThread.java:173

    at java.awt.EventDispatchThread.pumpEvents EventDispatchThread.java:168

    at java.awt.EventDispatchThread.pumpEvents EventDispatchThread.java:160

    at java.awt.EventDispatchThread.run EventDispatchThread.java:121

Caused by: gnu.io.UnsupportedCommOperationException: Invalid Parameter

    at gnu.io.RXTXPort.setSerialPortParams RXTXPort.java:171

    at processing.app.Serial. Serial.java:132

    15 more

gnu_linux

dmesg

should show messages like these when you connect your device

usb 2-6: new full speed USB device using ohci_hcd and address 5

usb 2-6: configuration 1 chosen from 1 choice

ftdi_sio 2-6:1.0: FTDI USB Serial Device converter detected

ftdi_sio: Detected FT232RL

usb 2-6: FTDI USB Serial Device converter now attached to ttyUSB0

usb 2-6: New USB device found, idVendor 0403, idProduct 6001

usb 2-6: New USB device strings: Mfr 1, Product 2, SerialNumber 3

usb 2-6: Product: TTL232R

usb 2-6: Manufacturer: FTDI

usb 2-6: SerialNumber: FTDxxxxx

Sometimes the device may not be ttyUSB0, it could be ttyUSB1 ttyUSB2 and so on

Andy Mac

Ubuntu 9.10

Arduino Uno 0022

It appears to be intermittent, the menu is 10 seconds behind and sometimes the serial port is there and sometimes it dont

yesterday it eventually stabilised, many unplugs reboots etc etc  and i ran it all day no probs, i assumed it was because i ran arduino as root which seemed to help but today it s not having any.

sudo. /arduino

terminal implied it was a permission issue so i chowned it to me anyways

sudo chown username  /dev/ttyACM0

it shows no serial port but i can upload. and fails only when i try to open the serial monitor

i get this message sometimes serial port already in use so i rm the lock and try again but i am going in circles

when run sudo. /arduino i get this in the terminal window, it implies my port isn t there

Native lib Version RXTX-2.1-7

Java lib Version   RXTX-2.1-7

RXTX Warning:  Removing stale lock file. /var/lock/LCK..ttyACM0

Binary sketch size: 7564 bytes of a 32256 byte maximum

processing.app.SerialNotFoundException: Serial port /dev/ttyACM0 not found.  Did you select the right one from the Tools Serial Port menu.

     at processing.app.Serial. Serial.java:153

     at processing.app.Serial. Serial.java:76

     at processing.app.debug.Uploader.flushSerialBuffer Uploader.java:75

     at processing.app.debug.AvrdudeUploader.uploadViaBootloader AvrdudeUploader.java:93

     at processing.app.debug.AvrdudeUploader.uploadUsingPreferences AvrdudeUploader.java:56

     at processing.app.Sketch.upload Sketch.java:1603

     at processing.app.Sketch.exportApplet Sketch.java:1568

     at processing.app.Sketch.exportApplet Sketch.java:1524

     at processing.app.Editor DefaultExportHandler.run Editor.java:2293

     at java.lang.Thread.run Thread.java:636

i don t know the answer but hope there is a fix for this one day

i got it working briefly today by sudo. /arduino then pasting in my code into the default and empty sketch and saved then uploaded it without looking at the selected Serial port, Yay success, but the next upload a minute later failed with the old Serial port /dev/ttyACM0 not found nutmeg

aaaaagggghh

simulation

kubuntu 9.10

arduino-0022

arduino-0021 .

i have the exact same problem. it started yesterday when i tried arduino-0022 to play with my new ethernet/sd shield. there is a huge lag in the java application and i cannot choose a serial port.

i deleted the preference file, but it did not help. i used a fresh sketchbook folder. i was not able to change/see the serial port and it complained com1 was busy. my serial port is /dev/ttyACM0. i closed the application and edited the serial device in the preference file. when i started the application, it automatically had chosen the duemilanove instead of uno and i could see/set the serial port. i changed it to uno and the serial port was gone.

it is not usable at all anymore and the application is really, really slow/nonresponding

sorry, i did not realise that this is an ancient thread. should we open up a new one for this, even if it seems to be related.

also i found that after i manage to upload a sketch without serial output, all seems to be fine again. if i upload one of the basic examples without all seems ok i tried blink and can use the software again. if i upload basic-analogreadserial it is broken again.

i will need serial output soon though. :/.

The Arduino IDE seems to work just fine otherwise. processing.app.SerialException: Error opening serial serial port unless serial monitor is open.

Nov 25, 2012  Fix Ubuntu Error Opening serial port /dev processing.app.SerialException: Error opening serial port /dev Error opening serial port.

Serial Port closes with error when uploading or opening a serial monitor when serial.debug_rate 38400 processing.app.SerialException: Error opening serial port.