blob: 9e82554a67b3299b35990133a23fc7fad913053c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
#include "project.h"
void
setup_clocks (void)
{
#ifdef __AVR_ATtiny10__
CCP = 0xD8; // configuration change protection, write signature
CLKPSR = 0; // set cpu clock prescaler =1 (8Mhz) (attiny 4/5/9/10)
#else
CLKPR = _BV (CLKPCE);
CLKPR = 0; // set clock prescaler to 1 (attiny 25/45/85/24/44/84/13/13A)
#endif
}
|