Browse Source

Tweak scrolling message code

pull/1/head
Scott Lahteine 8 years ago
parent
commit
789b2928a8
  1. 4
      Marlin/ultralcd_impl_DOGM.h
  2. 4
      Marlin/ultralcd_impl_HD44780.h

4
Marlin/ultralcd_impl_DOGM.h

@ -410,8 +410,8 @@ inline void lcd_implementation_status_message() {
const uint8_t slen = lcd_strlen(lcd_status_message);
if (slen > LCD_WIDTH) {
// Skip any non-printing bytes
while (!PRINTABLE(lcd_status_message[status_scroll_pos])) ++status_scroll_pos;
if (++status_scroll_pos > slen - LCD_WIDTH) status_scroll_pos = 0;
while (!PRINTABLE(lcd_status_message[status_scroll_pos++])) { /* nada */ }
if (status_scroll_pos > slen - LCD_WIDTH) status_scroll_pos = 0;
}
#else
lcd_print_utf(lcd_status_message);

4
Marlin/ultralcd_impl_HD44780.h

@ -829,8 +829,8 @@ static void lcd_implementation_status_screen() {
const uint8_t slen = lcd_strlen(lcd_status_message);
if (slen > LCD_WIDTH) {
// Skip any non-printing bytes
while (!PRINTABLE(lcd_status_message[status_scroll_pos])) ++status_scroll_pos;
if (++status_scroll_pos > slen - LCD_WIDTH) status_scroll_pos = 0;
while (!PRINTABLE(lcd_status_message[status_scroll_pos++])) { /* nada */ }
if (status_scroll_pos > slen - LCD_WIDTH) status_scroll_pos = 0;
}
#else
lcd_print_utf(lcd_status_message);

Loading…
Cancel
Save