Hi all. I can't seem to read or write to sd card when PWM is set to 62500. The txt file gets written every time no problem but the content will either be empty or filled with gibberish. For confirmation, I can read and write if the timer is unchanged no problem. What can I do to get it to work at this higher timer setting?
#include <SPI.h>
#include <SD.h>
File myFile;
void setup() {
TCCR0B = TCCR0B & 0b11111000 | 0x01;
Serial.begin(9600);
while (!Serial) {
;
}
myFile = SD.open("test.txt", FILE_WRITE);
myFile.println("testing 1, 2, 3.");
myFile.close();
}
void loop() {
;
}