I played with CLKPR in order to measure actual current consumption in different modes (Arduino Pro Mini 16Mhz 5V) And I accidentally load tis code, which left my clock rate at 2 Mhz. Now I can't connect to the Arduino, device is not recognized.
Any advice how to connects to the board again and change the code?
The code:
void setup() {
// Setting prescaler
noInterrupts();
CLKPR = (1 << CLKPCE); // enable a change to CLKPR
CLKPR = 8; // set the CLKDIV to 8 (8=0100b = 16MHz/ 8 = 2MHz)
interrupts();
}
void loop()
{
}
ie Your code and any error messages should always be placed between [code]code tags[/code]. Posting it inline as you have done makes it much harder to read or copy and paste for diagnosis, and often also corrupts the code with italics or smilies.
It's still not too late to edit your post and do this. You'll make potential helpers much happier.