Browse Source

DOGLCD width/height in Conditionals.h

Scott Lahteine 8 years ago
parent
commit
2690d8568e
1 changed files with 15 additions and 8 deletions
  1. 15
    8
      Marlin/Conditionals.h

+ 15
- 8
Marlin/Conditionals.h View File

@@ -155,23 +155,30 @@
155 155
     #define NEWPANEL
156 156
   #endif
157 157
 
158
+  #if ENABLED(DOGLCD) // Change number of lines to match the DOG graphic display
159
+    #ifndef LCD_WIDTH
160
+      #define LCD_WIDTH 22
161
+    #endif
162
+    #ifndef LCD_HEIGHT
163
+      #define LCD_HEIGHT 5
164
+    #endif
165
+  #endif
166
+
158 167
   #if ENABLED(ULTIPANEL)
159 168
     #define NEWPANEL  //enable this if you have a click-encoder panel
160 169
     #define ULTRA_LCD
161
-    #if ENABLED(DOGLCD) // Change number of lines to match the DOG graphic display
162
-      #define LCD_WIDTH 22
163
-      #define LCD_HEIGHT 5
164
-    #else
170
+    #ifndef LCD_WIDTH
165 171
       #define LCD_WIDTH 20
172
+    #endif
173
+    #ifndef LCD_HEIGHT
166 174
       #define LCD_HEIGHT 4
167 175
     #endif
168 176
   #else //no panel but just LCD
169 177
     #if ENABLED(ULTRA_LCD)
170
-      #if ENABLED(DOGLCD) // Change number of lines to match the 128x64 graphics display
171
-        #define LCD_WIDTH 22
172
-        #define LCD_HEIGHT 5
173
-      #else
178
+      #ifndef LCD_WIDTH
174 179
         #define LCD_WIDTH 16
180
+      #endif
181
+      #ifndef LCD_HEIGHT
175 182
         #define LCD_HEIGHT 2
176 183
       #endif
177 184
     #endif

Loading…
Cancel
Save