gehe zur Dokumentation dieser Datei
56 #define LCD_INIT {(LCD_4BIT | LCD_2LINE | LCD_5X7), 0}
59 #define LCD_DEV 0x40 // LCD Device Address
60 #define LCD_LINES 2 // Total LCD Lines
61 #define LCD_CHARS 8 // Maximal LCD characters each line
63 #define LCD_LINE1 0x00 // This should be 0x00 on all displays
64 #define LCD_LINE2 0x40 // Change this to the address for line 2 on your display
65 #define LCD_LINE3 0x10 // Change this to the address for line 3 on your display
66 #define LCD_LINE4 0x50 // Change this to the address for line 4 on your display
70 #define LD4 MY_LCD_LD4 // Pin to Data Bus 4
71 #define LD5 MY_LCD_LD5 // Pin to Data Bus 5
72 #define LD6 MY_LCD_LD6 // Pin to Data Bus 6
73 #define LD7 MY_LCD_LD7 // Pin to Data Bus 7
75 #define LRS MY_LCD_LRS // Pin to RS Pin (Register Select)
76 #define LRW MY_LCD_LRW // Pin to Read/Write Pin
77 #define LEN MY_LCD_LEN // Pin to Enable Pin
78 #define LBL MY_LCD_LBL // Backlight Pin
84 #define LCD_D0 (1 << LD4)
85 #define LCD_D1 (1 << LD5)
86 #define LCD_D2 (1 << LD6)
87 #define LCD_D3 (1 << LD7)
89 #define LCD_D4 (1 << LD4)
90 #define LCD_D5 (1 << LD5)
91 #define LCD_D6 (1 << LD6)
92 #define LCD_D7 (1 << LD7)
94 #define LCD_RS (1 << LRS)
95 #define LCD_RW (1 << LRW)
96 #define LCD_EN (1 << LEN)
97 #define LCD_BL (1 << LBL)
107 #define LCD_CLEAR 0x01 // Clear Screen
108 #define LCD_HOME 0x02 // Cursor Home
110 #define LCD_ENTRYMODE 0x04 // Set entrymode
111 #define LCD_INCREASE (LCD_ENTRYMODE | 0x02) // Set cursor move direction -- Increase
112 #define LCD_DECREASE (LCD_ENTRYMODE | 0x00) // Set cursor move direction -- Decrease
113 #define LCD_DISPLAYSHIFTON (LCD_ENTRYMODE | 0x01) // Display is shifted
114 #define LCD_DISPLAYSHIFTOFF (LCD_ENTRYMODE | 0x00) // Display is not shifted
116 #define LCD_DISPLAYMODE 0x08 // Set displaymode
117 #define LCD_DISPLAYON (LCD_DISPLAYMODE | 0x04) // Display on
118 #define LCD_DISPLAYOFF (LCD_DISPLAYMODE | 0x00) // Display off
119 #define LCD_CURSORON (LCD_DISPLAYMODE | 0x02) // Cursor on
120 #define LCD_CURSOROFF (LCD_DISPLAYMODE | 0x00) // Cursor off
121 #define LCD_BLINKINGON (LCD_DISPLAYMODE | 0x01) // Blinking on
122 #define LCD_BLINKINGOFF (LCD_DISPLAYMODE | 0x00) // Blinking off
124 #define LCD_SHIFTMODE 0x10 // Set shiftmode
125 #define LCD_DISPLAYSHIFT (LCD_SHIFTMODE | 0x08) // Display shift
126 #define LCD_CURSORMOVE (LCD_SHIFTMODE | 0x00) // Cursor move
127 #define LCD_RIGHT (LCD_SHIFTMODE | 0x04) // Right shift
128 #define LCD_LEFT (LCD_SHIFTMODE | 0x00) // Left shift
130 #define LCD_CONFIGURATION 0x20 // Set function
131 #define LCD_8BIT (LCD_CONFIGURATION | 0x10) // 8 bits interface
132 #define LCD_4BIT (LCD_CONFIGURATION | 0x00) // 4 bits interface
133 #define LCD_2LINE (LCD_CONFIGURATION | 0x08) // 2 line display
134 #define LCD_1LINE (LCD_CONFIGURATION | 0x00) // 1 line display
135 #define LCD_5X10 (LCD_CONFIGURATION | 0x04) // 5 X 10 dots
136 #define LCD_5X7 (LCD_CONFIGURATION | 0x00) // 5 X 7 dots
138 #define LCD_CGRAM 0x40 // DD RAM Address Set
139 #define LCD_DDRAM 0x80 // DD RAM Address Set
142 #define LCD_KEY_YELLOW (1<<PD6)
143 #define LCD_KEY_RED (1<<PD2)
144 #define LCD_KEY_BLUE (1<<PB3)
179 void SetIOLCD(
unsigned char setCommand,
unsigned char bits);
194 void SetCursorLCD(
unsigned char cursor,
unsigned char line);
229 void PrintLCD(
char *
string,
unsigned char wrap);
238 void PrintSetLCD(
unsigned char cursor,
unsigned char line,
char *
string);
254 void PrintAlignLCD(
unsigned char line,
unsigned char alignment,
char *
string);
262 #define PrintLCD_P(_str) PrintLCD_p(PSTR(_str))
270 void SetCharLCD_p(
unsigned char AsciiCode,
const char *progmem_s);
271 #define SetCharLCD_P(_asc, _str) SetCharLCD_p(_asc, PSTR(_str))