My Macbook Pro (13-inch, mid 2009, Intel Core 2 Duo) has an odd problem with the USB ports. Occasionally, when plugging in, removing or restarting a microcontroller such as the Arudino or Teensy, the computer abruptly turns off and restarts. Afterwards, the computer displays a gray screen that says "Your computer restarted because of a problem... etc."
I'm not quite sure if this is related to a problem with my computer, an issue with the microcontrollers drawing too much current or my battery. I know that microcontrollers are sometimes forced to restart if they are asked to source too much current. eg. powering a servo. However, I would expect that a laptop would be able to source enough current to a bare microcontroller to avoid being shut off.
I also should mention that my battery condition is "replace now". I can still use it for ~30 minutes without the power cord, and as far as my memory goes, my computer was always plugged in when this problem occurs.
I read that one problem might be that my PCU might need to be reset. I believe that I reset it using the "SCOP" keyboard shortcut on start-up but the computer gives no indication of this.