|
|
@ -190,7 +190,9 @@ char lcd_printPGM(const char* str) {
|
|
|
|
return n;
|
|
|
|
return n;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
static bool show_splashscreen = true;
|
|
|
|
#if ENABLED(SHOW_BOOTSCREEN)
|
|
|
|
|
|
|
|
static bool show_bootscreen = true;
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
/* Warning: This function is called from interrupt context */
|
|
|
|
/* Warning: This function is called from interrupt context */
|
|
|
|
static void lcd_implementation_init() {
|
|
|
|
static void lcd_implementation_init() {
|
|
|
@ -220,7 +222,7 @@ static void lcd_implementation_init() {
|
|
|
|
u8g.setRot270(); // Rotate screen by 270°
|
|
|
|
u8g.setRot270(); // Rotate screen by 270°
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
// Show splashscreen
|
|
|
|
#if ENABLED(SHOW_BOOTSCREEN)
|
|
|
|
int offx = (u8g.getWidth() - START_BMPWIDTH) / 2;
|
|
|
|
int offx = (u8g.getWidth() - START_BMPWIDTH) / 2;
|
|
|
|
#if ENABLED(START_BMPHIGH)
|
|
|
|
#if ENABLED(START_BMPHIGH)
|
|
|
|
int offy = 0;
|
|
|
|
int offy = 0;
|
|
|
@ -232,7 +234,7 @@ static void lcd_implementation_init() {
|
|
|
|
|
|
|
|
|
|
|
|
u8g.firstPage();
|
|
|
|
u8g.firstPage();
|
|
|
|
do {
|
|
|
|
do {
|
|
|
|
if (show_splashscreen) {
|
|
|
|
if (show_bootscreen) {
|
|
|
|
u8g.drawBitmapP(offx, offy, START_BMPBYTEWIDTH, START_BMPHEIGHT, start_bmp);
|
|
|
|
u8g.drawBitmapP(offx, offy, START_BMPBYTEWIDTH, START_BMPHEIGHT, start_bmp);
|
|
|
|
lcd_setFont(FONT_MENU);
|
|
|
|
lcd_setFont(FONT_MENU);
|
|
|
|
#ifndef STRING_SPLASH_LINE2
|
|
|
|
#ifndef STRING_SPLASH_LINE2
|
|
|
@ -244,7 +246,12 @@ static void lcd_implementation_init() {
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} while (u8g.nextPage());
|
|
|
|
} while (u8g.nextPage());
|
|
|
|
show_splashscreen = false;
|
|
|
|
|
|
|
|
|
|
|
|
if (show_bootscreen) {
|
|
|
|
|
|
|
|
delay(1000);
|
|
|
|
|
|
|
|
show_bootscreen = false;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
static void lcd_implementation_clear() { } // Automatically cleared by Picture Loop
|
|
|
|
static void lcd_implementation_clear() { } // Automatically cleared by Picture Loop
|
|
|
|