Browse Source

Add code to lcd_update() for GLCD

This code selects between the routines for the GLCD or the char.
display.
pull/1/head
Dirk Eichel 12 years ago
parent
commit
5f1cd70122
  1. 17
      Marlin/ultralcd.cpp

17
Marlin/ultralcd.cpp

@ -747,8 +747,23 @@ void lcd_update()
if (LCD_CLICKED) if (LCD_CLICKED)
timeoutToStatus = millis() + LCD_TIMEOUT_TO_STATUS; timeoutToStatus = millis() + LCD_TIMEOUT_TO_STATUS;
#endif//ULTIPANEL #endif//ULTIPANEL
#ifdef DOGLCD // Changes due to different driver architecture of the DOGM display
blink++; // Variable for fan animation and alive dot
u8g.firstPage();
do {
u8g.setFont(u8g_font_6x10_marlin);
u8g.setPrintPos(125,0);
if (blink % 2) u8g.setColorIndex(1); else u8g.setColorIndex(0); // Set color for the alive dot
u8g.drawPixel(127,63); // draw alive dot
u8g.setColorIndex(1); // black on white
(*currentMenu)();
if (!lcdDrawUpdate) break; // Terminate display update, when nothing new to draw. This must be done before the last dogm.next()
} while( u8g.nextPage() );
#else
(*currentMenu)(); (*currentMenu)();
#endif
#ifdef ULTIPANEL #ifdef ULTIPANEL
if(timeoutToStatus < millis() && currentMenu != lcd_status_screen) if(timeoutToStatus < millis() && currentMenu != lcd_status_screen)
{ {

Loading…
Cancel
Save