Kernel Panic while using the Arduino IDE

I've looked for answers to this, and can't seem to find any.

I am using a 2009 MacBook Pro running Mavericks and the newest Arduino IDE (1.5). Randomly, when uploading a program to my board, the IDE will crash. And not just crash, but it'll take down the whole entire computer. I've tried removing and reinstalling the Arduino IDE, and i've tried both versions available. I loose all my unsaved changes every time this happens.

Any ideas? It appears that all the low-level drivers and handled by the IDE and don't need any extra installation.

I use the same exact code on a Windows XP computer running the IDE and everything goes fine.

Thanks!

Collins

I'm using the arduino UNO board, of which I have tried multiple boards and multiple USB cables.

Does mac have a safe zone or sandbox you could run it in. Not ideal but might stop crashing the whole computer, and maybe give a clearer hint as to what is happening.

Do you get any error messages before the computer crashes?
Look at the system event log. Power failures might appear when the CPU usage spikes and draws more current. I'm not a mac owner so I can't give any solid advice, however there is a very good chance this has happened to someone else. Google up a storm, might even be worth looking for fatal java errors on mac.

Same thing happened to me 4 times today. My 2008 Macbook Pro crashed while uploading a sketch to an Arduino UNO R3. I am running Mavericks 10.9.1.
Still trying to get the Mac back to life since the last crash this afternoon :frowning:
Andre
Vermont

A quick correction and more details:

  • The Macbook Pro is a 2010 model not 2008
  • Below is a copy of the sketch that I was uploading when the Mac last crashed (it's from a web tutorial). I have had no problems with sketches that do not use the serial communication library, so maybe the issue is related to that?

/*

  • Counting presses
    */

int switchPin = 2; // switch is connected to pin 2
int val; // variable for reading the pin status
int buttonState; // variable to hold the button state
int buttonPresses = 0; // how many times the button has been pressed

void setup() {
pinMode(switchPin, INPUT); // Set the switch pin as input

Serial.begin(9600); // Set up serial communication at 9600bps
buttonState = digitalRead(switchPin); // read the initial state
}
void loop(){
val = digitalRead(switchPin); // read input value and store it in val

if (val != buttonState) { // the button state has changed!
if (val == LOW) { // check if the button is pressed
buttonPresses++; // increment the buttonPresses variable
Serial.print("Button has been pressed ");
Serial.print(buttonPresses);
Serial.println(" times");
}
}
buttonState = val; // save the new state in our variable
}

Thanks,
Andre

alini:
Same thing happened to me 4 times today. My 2008 Macbook Pro crashed while uploading a sketch to an Arduino UNO R3. I am running Mavericks 10.9.1.
Still trying to get the Mac back to life since the last crash this afternoon :frowning:
Andre
Vermont

I believe the problem is the serial communication. The same thing happens to me with a Macbook when I use the serial communication through the USB. I have heard that the problem does not occur with a powered USB hub. I have obtained an Anker USB hub and the couple of times I have used it there has not been a problem.