diff options
Diffstat (limited to 'src/inc/spi/dev/display_dogm.h')
-rwxr-xr-x | src/inc/spi/dev/display_dogm.h | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/inc/spi/dev/display_dogm.h b/src/inc/spi/dev/display_dogm.h new file mode 100755 index 0000000..d9cf560 --- /dev/null +++ b/src/inc/spi/dev/display_dogm.h | |||
@@ -0,0 +1,31 @@ | |||
1 | #ifndef DISPLAY_DOGM_H | ||
2 | #define DISPLAY_DOGM_H | ||
3 | |||
4 | #include <avr/io.h> | ||
5 | #include <util/delay.h> | ||
6 | #include "../spi.h" | ||
7 | |||
8 | #define CONTAST 3 | ||
9 | |||
10 | #define CMD_FUNCTION_SET 32 + 16 + 8 + 0 + 1 | ||
11 | #define CMD_POWER_CONTROL 64 + 0 + 16 + 0 + 4 + CONTAST | ||
12 | #define CMD_FOLLOWER_CONTROL 0x6E | ||
13 | |||
14 | #define CMD_ENTRY_MODE_SET 4 + 2 + 0 | ||
15 | #define CMD_DISPLAY_HOME 0 + 2 + 0 | ||
16 | #define CMD_DISPLAY_CLEAR 0 + 0 + 1 | ||
17 | |||
18 | #define CMD_CONTRAST_SET 0x7F | ||
19 | #define CMD_FUNCTION_SET2 0x38 | ||
20 | #define CMD_DISPLAY_ONOFF 0x0C | ||
21 | #define CMD_DISPLAY_POS 0x80 | ||
22 | |||
23 | //#define display_dogm_enable() PORTD &= ~(1<<PD7); PORTD |= (1<<PD6); // <XDCS> | ||
24 | //#define display_dogm_disable() PORTD |= (1<<PD7); PORTD &= ~(1<<PD6); // </XDCS> | ||
25 | |||
26 | |||
27 | void display_dogm_init(); | ||
28 | void display_dogm_putc(char); | ||
29 | void display_dogm_exec(char); | ||
30 | |||
31 | #endif | ||