Serial port already in use - OSX Mavericks [solved]

Since upgrading my iMac to OSX Mavericks (10.9.4), I have been having some trouble, uploading sketches to Arduino 32u4 based boards; Leonardo, Yun (over the serial port) and a Pro MIcro. The Arduino error report indicates attempts to touch the device file are failing, due to the port being in use and the device file locked. Rebooting the 32u4 board, by unplugging or resetting, appears to recreate the device files but does not remove the locks. Rebooting the iMac will clear the locks but heck, that takes far too long.

I have found manually deleting and recreating the device files is a much quicker alternative to rebooting. For example, the board I have connected at the moment has created two device files called, cu,usbmodemfa1311 and and tty.usbmodemfa1311.

  1. Open a terminal window
sudo rm /dev/tty.usbmodemfa1311
sudo rm /dev/cu.usbmodemfa1311
  1. Reset the 32u4 board to recreate the dev files.
  2. Uploading from Arduino.app is working once again.

I should mention that I primarily develop for Arduino using Atmel Studio 6.1, with the Visual Micro plug in, within a VMWare Fusion virtual PC, running Windows XP, which may be what causes the device files to get locked in the first place.

Anyhow. Just thought I would make a note on the forum, in case anyone else is having a similar issue.

Thanks for this post! I had that exact problem!