Browse Source

Fixed compilation when using avr-gcc

- avr-gcc is more strict than the Arduino IDE, it seems.
pull/1/head
Marcio Teixeira 7 years ago
parent
commit
8db67d1647
  1. 2
      Marlin/src/lcd/dogm/ultralcd_impl_st7920_lite_status_screen.h
  2. 4
      Marlin/src/lcd/dogm/ultralcd_impl_st7920_lite_status_screen_impl.h

2
Marlin/src/lcd/dogm/ultralcd_impl_st7920_lite_status_screen.h

@ -76,7 +76,7 @@ class ST7920_Lite_Status_Screen {
static void draw_fan_speed(uint8_t value); static void draw_fan_speed(uint8_t value);
static void draw_print_time(uint32_t elapsed); static void draw_print_time(uint32_t elapsed);
static void draw_feedrate_percentage(uint8_t percentage); static void draw_feedrate_percentage(uint8_t percentage);
static void draw_status_message(const unsigned char *str); static void draw_status_message(const char *str);
static void draw_position(const float x, const float y, const float z, bool position_known = true); static void draw_position(const float x, const float y, const float z, bool position_known = true);
static bool indicators_changed(); static bool indicators_changed();

4
Marlin/src/lcd/dogm/ultralcd_impl_st7920_lite_status_screen_impl.h

@ -99,7 +99,7 @@ void ST7920_Lite_Status_Screen::write_str(progmem_str str) {
write_str_P((const char*)str); write_str_P((const char*)str);
} }
void ST7920_Lite_Status_Screen::write_number(uint8_t value, uint8_t digits=3) { void ST7920_Lite_Status_Screen::write_number(uint8_t value, uint8_t digits) {
char str[7]; char str[7];
const char *fmt; const char *fmt;
switch(digits) { switch(digits) {
@ -435,7 +435,7 @@ void ST7920_Lite_Status_Screen::draw_feedrate_percentage(uint8_t percentage) {
#endif #endif
} }
void ST7920_Lite_Status_Screen::draw_status_message(const unsigned char *str) { void ST7920_Lite_Status_Screen::draw_status_message(const char *str) {
set_ddram_address(DDRAM_LINE_4); set_ddram_address(DDRAM_LINE_4);
begin_data(); begin_data();
#if ENABLED(STATUS_MESSAGE_SCROLLING) #if ENABLED(STATUS_MESSAGE_SCROLLING)

Loading…
Cancel
Save