Ah ok. I'm building a robot with an onboard 12v NiMh battery. I was powering the motors with that and using a 5v output from one of the motor controllers to power the Arduino. I'd wired that 5v into the 5v pin of the Mega which was clearly a mistake.
What's the best setup to achieve what I'm trying to do? Should I wire the 12v battery direct to the DC jack input (or Vin does it matter?) of Arduino? if I do this, do I still need to be careful to disconnect when I plug in the USB? If there's a good article on this feel free to point me in the right direction.
As a side note, how repairable is my old Mega - the rest of it seems fine, it still plays the last script I guess I fried the serial comms...
Many thanks,
Simon