added a line to disable baud doubling, but commented out for the time being until I can test it on real hardware

This commit is contained in:
Simen Svale Skogsrud 2011-02-11 01:11:33 +01:00
parent 80afa2f403
commit d96e48cecf

View File

@ -43,6 +43,9 @@ void beginSerial(long baud)
UBRR0H = ((F_CPU / 16 + baud / 2) / baud - 1) >> 8; UBRR0H = ((F_CPU / 16 + baud / 2) / baud - 1) >> 8;
UBRR0L = ((F_CPU / 16 + baud / 2) / baud - 1); UBRR0L = ((F_CPU / 16 + baud / 2) / baud - 1);
/* baud doubler off - Only needed on Uno XXX */
// UCSR0A &= ~(1 << U2X0);
// enable rx and tx // enable rx and tx
UCSR0B |= 1<<RXEN0; UCSR0B |= 1<<RXEN0;
UCSR0B |= 1<<TXEN0; UCSR0B |= 1<<TXEN0;