]> www.fi.muni.cz Git - tinyboard.git/blob - projects/rgb-led-string/rgbstring.h
rgb-led-string: single-direction white stars
[tinyboard.git] / projects / rgb-led-string / rgbstring.h
1 #ifndef LIGHTS_H__
2 #define LIGHTS_H__ 1
3
4 #define N_PWMLED_MODES 3
5
6 /* logging.c */
7 #ifdef USE_LOGGING
8 void init_log();
9 void log_set_state(unsigned char val);
10 void log_flush();
11 void log_byte(unsigned char byte);
12 void log_word(uint16_t word);
13 #else
14 void inline init_log() { }
15 void inline log_set_state(unsigned char val) { }
16 void inline log_flush() { }
17 void inline log_byte(unsigned char byte) { }
18 void inline log_word(uint16_t word) { }
19 #endif
20
21 /* serial.c */
22 #define STRIP_SIZE 160
23 void init_serial();
24 void zero_frame();
25 void end_frame();
26 void send_rgb(unsigned char r, unsigned char g, unsigned char b);
27
28 #endif /* !LIGHTS_H__ */
29