3 const byte PS_128 = (1 << ADPS2) | (1 << ADPS1) | (1 << ADPS0);
4 const byte PS_16 = (1 << ADPS2);
8 ADCSRA &= ~PS_128; // remove prescale of 128
9 ADCSRA |= PS_16; // add prescale of 16 (1MHz)
12 Serial.println(PS_128, 2);
13 Serial.println(PS_16, 2);
14 Serial.println("Starting Test");
15 long startTime = millis();
19 for (i = 0; i < 1000000; i ++)
24 long endTime = millis();
26 Serial.println("Finished Test");
27 Serial.print("Seconds taken: ");
28 Serial.println((endTime - startTime) / 1000l);