Skip to content

Instantly share code, notes, and snippets.

#define F_CPU 1000000UL
#include <avr/io.h>
#include <util/delay.h>
#include <stdint.h>
#include <stdio.h>
// 2400 baud @ 1 MHz: UBRR = F_CPU/(16*BAUD) - 1 = 25
#define UBRR_VAL 25