blob: 8e1d0f59a484e0f6295c13e2dcb42c2ac8f76c85 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
#define F_CPU 16000000
#ifdef PROTOTYPING
#define NOPROTO static
#define inline
//delay.h is broken we need to look after it
#define __OPTIMIZE__
#else
#define NOPROTO
#endif
#include <stdio.h>
#include <stdint.h>
#include <avr/io.h>
#include <avr/interrupt.h>
#include <avr/pgmspace.h>
#ifdef PROTOTYPING
#define _delay_ms static _delay_ms
#define _delay_us static _delay_us
#define _delay_loop_1 static _delay_loop_1
#define _delay_loop_2 static _delay_loop_2
#endif
#define __DELAY_BACKWARD_COMPATIBLE__
#include <util/delay.h>
#ifdef PROTOTYPING
#undef _delay_loop_2
#undef _delay_loop_1
#undef _delay_us
#undef _delay_ms
#endif
#include "uart.h"
#define UART_BAUD_RATE 115200
#define WS2812_PORTREG PORTB
#define WS2812_DDRREG DDRB
#define WS2812_PIN 1
#include "lib_ws2812.h"
#define NOUNUSED __attribute__((unused))
#include "prototypes.h"
|