added confirm character for messages which waits for user to press the knob

This commit is contained in:
PavelSindler 2017-09-13 15:41:19 +02:00
parent c3e01dd449
commit 827a9ce6cb
2 changed files with 33 additions and 8 deletions

View File

@ -2123,6 +2123,9 @@ void lcd_show_fullscreen_message_and_wait_P(const char *msg)
while (lcd_clicked()) ; while (lcd_clicked()) ;
delay(10); delay(10);
while (lcd_clicked()) ; while (lcd_clicked()) ;
lcd_set_custom_characters();
lcd_update_enable(true);
lcd_update(2);
KEEPALIVE_STATE(IN_HANDLER); KEEPALIVE_STATE(IN_HANDLER);
return; return;
} }
@ -2131,6 +2134,18 @@ void lcd_show_fullscreen_message_and_wait_P(const char *msg)
if (msg_next == NULL) if (msg_next == NULL)
msg_next = msg; msg_next = msg;
msg_next = lcd_display_message_fullscreen_P(msg_next); msg_next = lcd_display_message_fullscreen_P(msg_next);
if (msg_next == NULL) {
lcd_set_custom_characters_nextpage();
lcd.setCursor(19, 3);
// Display the confirm char.
lcd.print(char(2));
}
}
else {
lcd_set_custom_characters_nextpage();
lcd.setCursor(19, 3);
// Display the confirm char.
lcd.print(char(2));
} }
} }
} }

View File

@ -491,8 +491,18 @@ void lcd_set_custom_characters_nextpage()
B01010, B01010,
B00100 B00100
}; };
byte confirm[8] = {
B00000,
B00001,
B00011,
B10110,
B11100,
B01000,
B00000
};
lcd.createChar(1, arrdown); lcd.createChar(1, arrdown);
lcd.createChar(2, confirm);
} }
void lcd_set_custom_characters_degree() void lcd_set_custom_characters_degree()