Arduino application will not run OSX

I started to get compiling errors on the Firmata sketches I was trying to load, so I attempted to uninstall/reinstall the Arduino application thinking that I might have some library files in the wrong place. Now the Arduino application won’t run at all. I feel like I might have deleted something vital somewhere. How do I figure out what’s wrong? I’m using an Arduino Uno, OSX 10.5.8.

You may have a corrupt preferences.txt file.

The location of this file is described here: http://arduino.cc/en/Hacking/Preferences

Find the location of this file on your system and delete it. Then try to launch the IDE.

Thanks for the reply, but that folder isn't there on my computer. Any other ideas? This is a freshly formatted computer, yet the program won't run.

Don't know if it's useful, but the system console reads this when I attempt to launch the Arduino application:

5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] [JavaAppLauncher Error] CallStaticVoidMethod() threw an exception 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] Exception in thread "main" java.lang.NoClassDefFoundError: javax/swing/filechooser/FileNameExtensionFilter 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] at java.lang.Class.forName0(Native Method) 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] at java.lang.Class.forName(Class.java:242) 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] at apple.launcher.LaunchRunner.loadMainMethod(LaunchRunner.java:55) 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] at apple.launcher.LaunchRunner.run(LaunchRunner.java:111) 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] at apple.launcher.LaunchRunner.callMain(LaunchRunner.java:50) 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] at apple.launcher.JavaApplicationLauncher.launch(JavaApplicationLauncher.java:52)

I have a similar problem on 10.7.5.

sh-3.2# uname -a
Darwin sport.local 11.4.2 Darwin Kernel Version 11.4.2: Thu Aug 23 16:25:48 PDT 2012; root:xnu-1699.32.7~1/RELEASE_X86_64 x86_64

Tried several versions of the IDE, but no luck with any of them. They all crash on start.

Here’s the crash report is attached, maybe it will help diagnose and fix this.

P.S. I got it to work on a Linux VM, under OS X host, but it would be nice to be able to run directly in OSX.

arduinoIDE_crash_report.txt (33 KB)

You may have a corrupt preferences.txt file. The location of this file is described ...

that folder isn't there on my computer.

Yes it is. It's just that Apple decided to make it "hidden" in recent versions of MacOS, so you need to either make it visible (https://discussions.apple.com/thread/4176215?start=0&tstart=0 ) or access it via a Terminal window instead of via the finder. I've had this problem, and it's ALWAYS been caused by the preferences or by boards.txt in ~/Documents/Arduino/hardware/

Hi westfw,

I am thoroughly familiar with .hidden files on *NIX-like systems, unfortunately, no such file on my MBP.

sh-3.2# ls -al /Users/ms/Library/Arduino
ls: /Users/ms/Library/Arduino: No such file or directory
sh-3.2# ls -al ~/.arduino
ls: /var/root/.arduino: No such file or directory
sh-3.2# ls -al /Users/ms/.arduino
ls: /Users/ms/.arduino: No such file or directory

Cheers, Matt

Well, there’s always brute force:

BillW-MacOSX-2<5002> cd
BillW-MacOSX-2<5003> find . -name preferences.txt
./Library/Arduino/preferences.txt

Indeed. Or the lazier version:

sh-3.2# locate preferences.txt
sh-3.2#

But then... no dice is no dice, regardless of how you arrive at the table.

Cheers, Matt

Well, I've got no further suggestions. As far as I know, your old version of Arduino should have created preferences.txt (it writes it every time you exit) (actually, from the console log it doesn't really look like you're getting as far as the Arduino IDE itself. Maybe your java installation is broken.)

Check with java version you are running, at the terminal: java -version

For reference I am running on 10.8.3:

MacBook-Awesome:Arduino james$ java -version
java version "1.6.0_45"
Java(TM) SE Runtime Environment (build 1.6.0_45-b06-451-11M4406)
Java HotSpot(TM) 64-Bit Server VM (build 20.45-b01-451, mixed mode)

Also, try running the IDE from a folder other than Applications.

Lastly, you might try shutting off Gatekeeper temporarily (System Preferences -> Security & Privacy -> General -> Anywhere), assuming you are certain you downloaded the binary from arduino.cc/googlecode.com.

My security preferences are correct. I tried launching from outside of /Applications, no joy.

Same Java version here:

bash-3.2$ java -version
java version "1.6.0_45"
Java(TM) SE Runtime Environment (build 1.6.0_45-b06-451-11M4406)
Java HotSpot(TM) 64-Bit Server VM (build 20.45-b01-451, mixed mode)

I know it’s probably something ridiculously mundane, yet cannot put my finger on it… VM Linux for now.

Cheers,
Matt

fetalharpoon: Don't know if it's useful, but the system console reads this when I attempt to launch the Arduino application:

5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] [JavaAppLauncher Error] CallStaticVoidMethod() threw an exception 5/22/13 6:47:27 PM [0x0-0x2f02f].cc.arduino.Arduino[636] Exception in thread "main" java.lang.NoClassDefFoundError: javax/swing/filechooser/FileNameExtensionFilter [...]

I experienced this as well when attempting to upgrade from Arduino 1.0.4 to 1.0.5 on my (old) Mac OS X system: 1.0.5 would not launch, dying immediately with that same error.

I determined that the version of Java on my system did not have an implementation of FileNameExtensionFilter, and my system is too old to support a more recent version of Java. However, the code for FileNameExtensionFilter is available at http://grepcode.com, so I compiled it and added it to java's classes.jar, which solved the problem.

My issue has been solved, maybe this can help you -> http://forum.arduino.cc/index.php?topic=169590.new;topicseen#new

Cheers, Matt

My issue has been solved, maybe this can help you -> http://forum.arduino.cc/index.php?topic=169590.new;topicseen#new

Cheers, Matt