|
@@ -262,8 +262,7 @@ static void lcd_goto_menu(menuFunc_t menu, const uint32_t encoder=0, const bool
|
262
|
262
|
}
|
263
|
263
|
|
264
|
264
|
/* Main status screen. It's up to the implementation specific part to show what is needed. As this is very display dependent */
|
265
|
|
-static void lcd_status_screen()
|
266
|
|
-{
|
|
265
|
+static void lcd_status_screen() {
|
267
|
266
|
encoderRateMultiplierEnabled = false;
|
268
|
267
|
|
269
|
268
|
#ifdef LCD_PROGRESS_BAR
|
|
@@ -296,15 +295,7 @@ static void lcd_status_screen()
|
296
|
295
|
#endif
|
297
|
296
|
#endif //LCD_PROGRESS_BAR
|
298
|
297
|
|
299
|
|
- if (lcd_status_update_delay)
|
300
|
|
- lcd_status_update_delay--;
|
301
|
|
- else
|
302
|
|
- lcdDrawUpdate = 1;
|
303
|
|
-
|
304
|
|
- if (lcdDrawUpdate) {
|
305
|
298
|
lcd_implementation_status_screen();
|
306
|
|
- lcd_status_update_delay = 10; /* redraw the main screen every second. This is easier then trying keep track of all things that change on the screen */
|
307
|
|
- }
|
308
|
299
|
|
309
|
300
|
#ifdef ULTIPANEL
|
310
|
301
|
|
|
@@ -1298,8 +1289,6 @@ void lcd_update() {
|
1298
|
1289
|
}
|
1299
|
1290
|
}
|
1300
|
1291
|
#endif//CARDINSERTED
|
1301
|
|
-
|
1302
|
|
- static uint8_t dotcounter = 63;
|
1303
|
1292
|
|
1304
|
1293
|
uint32_t ms = millis();
|
1305
|
1294
|
if (ms > lcd_next_update_millis) {
|
|
@@ -1351,27 +1340,33 @@ void lcd_update() {
|
1351
|
1340
|
} // encoderRateMultiplierEnabled
|
1352
|
1341
|
#endif //ENCODER_RATE_MULTIPLIER
|
1353
|
1342
|
|
1354
|
|
- lcdDrawUpdate = 1;
|
1355
|
1343
|
encoderPosition += (encoderDiff * encoderMultiplier) / ENCODER_PULSES_PER_STEP;
|
1356
|
1344
|
encoderDiff = 0;
|
1357
|
1345
|
}
|
1358
|
1346
|
timeoutToStatus = ms + LCD_TIMEOUT_TO_STATUS;
|
|
1347
|
+ lcdDrawUpdate = 1;
|
1359
|
1348
|
}
|
1360
|
|
-
|
1361
|
1349
|
#endif //ULTIPANEL
|
1362
|
1350
|
|
|
1351
|
+ if (currentMenu == lcd_status_screen) {
|
|
1352
|
+ if (!lcd_status_update_delay) {
|
|
1353
|
+ lcdDrawUpdate = 1;
|
|
1354
|
+ lcd_status_update_delay = 10; /* redraw the main screen every second. This is easier then trying keep track of all things that change on the screen */
|
|
1355
|
+ }
|
|
1356
|
+ else {
|
|
1357
|
+ lcd_status_update_delay--;
|
|
1358
|
+ }
|
|
1359
|
+ }
|
1363
|
1360
|
#ifdef DOGLCD // Changes due to different driver architecture of the DOGM display
|
1364
|
|
- blink++; // Variable for fan animation and alive dot
|
1365
|
|
- u8g.firstPage();
|
1366
|
|
- (*currentMenu)();
|
1367
|
1361
|
if (lcdDrawUpdate) {
|
|
1362
|
+ blink++; // Variable for fan animation and alive dot
|
|
1363
|
+ u8g.firstPage();
|
1368
|
1364
|
do {
|
1369
|
|
- if (!dotcounter) dotcounter = 63;
|
1370
|
1365
|
lcd_setFont(FONT_MENU);
|
1371
|
1366
|
u8g.setPrintPos(125, 0);
|
1372
|
|
- // if (blink % 2) u8g.setColorIndex(1); else u8g.setColorIndex(0); // Set color for the alive dot
|
1373
|
|
- u8g.drawPixel(127, dotcounter--); // draw alive dot
|
1374
|
|
- // u8g.setColorIndex(1); // black on white
|
|
1367
|
+ if (blink % 2) u8g.setColorIndex(1); else u8g.setColorIndex(0); // Set color for the alive dot
|
|
1368
|
+ u8g.drawPixel(127, 63); // draw alive dot
|
|
1369
|
+ u8g.setColorIndex(1); // black on white
|
1375
|
1370
|
(*currentMenu)();
|
1376
|
1371
|
} while( u8g.nextPage() );
|
1377
|
1372
|
}
|