[an error occurred while processing this directive]
|
//UART0 initialisation
// desired baud rate: 9600
// actual: baud rate:9615 (0,2%)
// char size: 8 bit
// parity: Disabled
void uart0_init(void)
{
UCSR0B = 0x00; //disable while setting baud rate
UCSR0A = 0x00; //disable while setting baud rate
UBRR0L =0x19; //set baud rate
UBRR0H = 0x00;
UCSR0C = 0x06;
UCSR0A = 0x00; //enable
UCSR0B = 0xD8; //enable
}
E-mail: info@telesys.ru