In file included from sketch/ConfigurationStore.cpp:4:0:
sketch/ultralcd.h:40:15: warning: 'void lcd_selftest_v()' declared 'static' but never defined [-Wunused-function]
static void lcd_selftest_v();
^
sketch/ultralcd.h:42:15: warning: 'bool lcd_selfcheck_endstops()' declared 'static' but never defined [-Wunused-function]
static bool lcd_selfcheck_endstops();
^
sketch/ultralcd.h:45:15: warning: 'void reset_crash_det(char)' declared 'static' but never defined [-Wunused-function]
static void reset_crash_det(char axis);
^
sketch/ultralcd.h:46:15: warning: 'bool lcd_selfcheck_axis_sg(char)' declared 'static' but never defined [-Wunused-function]
static bool lcd_selfcheck_axis_sg(char axis);
^
sketch/ultralcd.h:47:15: warning: 'bool lcd_selfcheck_axis(int, int)' declared 'static' but never defined [-Wunused-function]
static bool lcd_selfcheck_axis(int _axis, int _travel);
^
sketch/ultralcd.h:54:15: warning: 'bool lcd_selfcheck_check_heater(bool)' declared 'static' but never defined [-Wunused-function]
static bool lcd_selfcheck_check_heater(bool _isbed);
^
sketch/ultralcd.h:55:15: warning: 'int lcd_selftest_screen(int, int, int, bool, int)' declared 'static' but never defined [-Wunused-function]
static int lcd_selftest_screen(int _step, int _progress, int _progress_scale, bool _clear, int _delay);
^
sketch/ultralcd.h:56:15: warning: 'void lcd_selftest_screen_step(int, int, int, const char*, const char*)' declared 'static' but never defined [-Wunused-function]
static void lcd_selftest_screen_step(int _row, int _col, int _state, const char *_name, const char *_indicator);
^
sketch/ultralcd.h:57:15: warning: 'bool lcd_selftest_manual_fan_check(int, bool)' declared 'static' but never defined [-Wunused-function]
static bool lcd_selftest_manual_fan_check(int _fan, bool check_opposite);
^
sketch/ultralcd.h:58:15: warning: 'bool lcd_selftest_fan_dialog(int)' declared 'static' but never defined [-Wunused-function]
static bool lcd_selftest_fan_dialog(int _fan);
^
sketch/ultralcd.h:59:15: warning: 'bool lcd_selftest_fsensor()' declared 'static' but never defined [-Wunused-function]
static bool lcd_selftest_fsensor();
^
sketch/ultralcd.h:60:15: warning: 'void lcd_selftest_error(int, const char*, const char*)' declared 'static' but never defined [-Wunused-function]
static void lcd_selftest_error(int _error_no, const char *_error_1, const char *_error_2);
sketch/ultralcd.h:68:24: warning: 'blink' defined but not used [-Wunused-variable]
static unsigned char blink = 0; // Variable for visualization of fan rotation in GLCD
sketch/ultralcd.h:222:13: warning: 'void lcd_colorprint_change()' declared 'static' but never defined [-Wunused-function]
static void lcd_colorprint_change();
^
sketch/ultralcd.h:223:12: warning: 'int get_ext_nr()' declared 'static' but never defined [-Wunused-function]
static int get_ext_nr();
^
sketch/ultralcd.h:225:13: warning: 'void extr_adj_0()' declared 'static' but never defined [-Wunused-function]
static void extr_adj_0();
^
sketch/ultralcd.h:226:13: warning: 'void extr_adj_1()' declared 'static' but never defined [-Wunused-function]
static void extr_adj_1();
^
sketch/ultralcd.h:227:13: warning: 'void extr_adj_2()' declared 'static' but never defined [-Wunused-function]
static void extr_adj_2();
^
sketch/ultralcd.h:228:13: warning: 'void extr_adj_3()' declared 'static' but never defined [-Wunused-function]
static void extr_adj_3();
^
sketch/ultralcd.h:229:13: warning: 'void fil_load_menu()' declared 'static' but never defined [-Wunused-function]
static void fil_load_menu();
^
sketch/ultralcd.h:230:13: warning: 'void fil_unload_menu()' declared 'static' but never defined [-Wunused-function]
static void fil_unload_menu();
^
sketch/ultralcd.h:231:13: warning: 'void extr_unload_0()' declared 'static' but never defined [-Wunused-function]
static void extr_unload_0();
^
sketch/ultralcd.h:232:13: warning: 'void extr_unload_1()' declared 'static' but never defined [-Wunused-function]
static void extr_unload_1();
^
sketch/ultralcd.h:233:13: warning: 'void extr_unload_2()' declared 'static' but never defined [-Wunused-function]
static void extr_unload_2();
^
sketch/ultralcd.h:234:13: warning: 'void extr_unload_3()' declared 'static' but never defined [-Wunused-function]
static void extr_unload_3();
^
sketch/ultralcd.h:235:13: warning: 'void lcd_disable_farm_mode()' declared 'static' but never defined [-Wunused-function]
static void lcd_disable_farm_mode();
^
sketch/ultralcd.h:236:13: warning: 'void lcd_set_fan_check()' declared 'static' but never defined [-Wunused-function]
static void lcd_set_fan_check();
^
sketch/ultralcd.h:240:13: warning: 'char snmm_stop_print_menu()' declared 'static' but never defined [-Wunused-function]
static char snmm_stop_print_menu();
^
sketch/ultralcd.h:242:14: warning: 'void lcd_sort_type_set()' declared 'static' but never defined [-Wunused-function]
static void lcd_sort_type_set();
^
sketch/ultralcd.h:244:14: warning: 'float count_e(float, float, float)' declared 'static' but never defined [-Wunused-function]
static float count_e(float layer_heigth, float extrusion_width, float extrusion_length);
^
sketch/ultralcd.h:245:13: warning: 'void lcd_babystep_z()' declared 'static' but never defined [-Wunused-function]
static void lcd_babystep_z();
^
sketch/ultralcd.h:290:13: warning: 'void lcd_send_status()' declared 'static' but never defined [-Wunused-function]
static void lcd_send_status();
^
sketch/ultralcd.h:291:13: warning: 'void lcd_connect_printer()' declared 'static' but never defined [-Wunused-function]
static void lcd_connect_printer();
sketch/ultralcd.h:227:13: warning: 'char snmm_stop_print_menu()' declared 'static' but never defined [-Wunused-function]
static char snmm_stop_print_menu();
^
sketch/ultralcd.h:229:14: warning: 'void lcd_sort_type_set()' declared 'static' but never defined [-Wunused-function]
static void lcd_sort_type_set();
^
sketch/ultralcd.h:231:14: warning: 'float count_e(float, float, float)' declared 'static' but never defined [-Wunused-function]
static float count_e(float layer_heigth, float extrusion_width, float extrusion_length);
^
sketch/ultralcd.h:232:13: warning: 'void lcd_babystep_z()' declared 'static' but never defined [-Wunused-function]
static void lcd_babystep_z();
In file included from sketch/ConfigurationStore.cpp:4:0:
sketch/ultralcd.h:12:14: warning: 'void lcd_language_menu()' declared 'static' but never defined [-Wunused-function]
static void lcd_language_menu();
In file included from sketch/ConfigurationStore.cpp:3:0:
sketch/temperature.h:193:14: warning: 'temp_runaway_status' defined but not used [-Wunused-variable]
static float temp_runaway_status[4];
^
sketch/temperature.h:194:14: warning: 'temp_runaway_target' defined but not used [-Wunused-variable]
static float temp_runaway_target[4];
^
sketch/temperature.h:195:14: warning: 'temp_runaway_timer' defined but not used [-Wunused-variable]
static float temp_runaway_timer[4];
^
sketch/temperature.h:196:12: warning: 'temp_runaway_error_counter' defined but not used [-Wunused-variable]
static int temp_runaway_error_counter[4];
In file included from sketch/ConfigurationStore.cpp:5:0:
sketch/ConfigurationStore.h: In function 'uint8_t calibration_status_store(uint8_t)':
sketch/ConfigurationStore.h:24:124: warning: no return statement in function returning non-void [-Wreturn-type]
inline uint8_t calibration_status_store(uint8_t status) { eeprom_update_byte((uint8_t*)EEPROM_CALIBRATION_STATUS, status); }
In file included from sketch/BlinkM.cpp:5:0:
sketch/Marlin.h:422:13: warning: 'void print_time_remaining_init()' declared 'static' but never defined [-Wunused-function]
static void print_time_remaining_init();
Make local functions static. Saves 6B of flash.
It manifested istself as following compiler warnings:
sketch/Marlin_main.cpp: In function 'void print_physical_coordinates()':
sketch/Marlin_main.cpp:9065:86: warning: pointer to a function used in arithmetic [-Wpointer-arith]
printf_P(_N("physical coordinates: (%.3f, %.3f, %.3f)\n"), st_get_position_mm[X_AXIS], st_get_position_mm[Y_AXIS], st_get_position_mm[Z_AXIS]);
^
sketch/Marlin_main.cpp:9065:114: warning: pointer to a function used in arithmetic [-Wpointer-arith]
printf_P(_N("physical coordinates: (%.3f, %.3f, %.3f)\n"), st_get_position_mm[X_AXIS], st_get_position_mm[Y_AXIS], st_get_position_mm[Z_AXIS]);
^
sketch/Marlin_main.cpp:9065:142: warning: pointer to a function used in arithmetic [-Wpointer-arith]
printf_P(_N("physical coordinates: (%.3f, %.3f, %.3f)\n"), st_get_position_mm[X_AXIS], st_get_position_mm[Y_AXIS], st_get_position_mm[Z_AXIS]);
^
sketch/Marlin_main.cpp:9066:1: warning: pointer offset from symbol maybe incorrect [enabled by default]
}
^
_Z18st_get_position_mmh+2
sketch/Marlin_main.cpp:9066:1: warning: pointer offset from symbol maybe incorrect [enabled by default]
_Z18st_get_position_mmh+2
sketch/Marlin_main.cpp:9066:1: warning: pointer offset from symbol maybe incorrect [enabled by default]
_Z18st_get_position_mmh+1
sketch/Marlin_main.cpp:9066:1: warning: pointer offset from symbol maybe incorrect [enabled by default]
_Z18st_get_position_mmh+1
sketch/adc.c: In function 'adc_init':
sketch/adc.c:20:2: warning: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
printf(("adc_init\n"));
^
sketch/adc.c:20:2: warning: incompatible implicit declaration of built-in function 'printf' [enabled by default]
modified to update the external flash memory on Einsy boards.
Due to a bug in the USB to serial converter firmware on the Prusa Einsy
boards, the STK500 protocol has been modified to never send semicolon
characters towards the main processor.
This firmware updater is compatible with a modified avrdude using
the "arduino" protocol, see the following commit.
https://github.com/prusa3d/Slic3r/tree/fwupdater_languages
printf float library enabled - platform.txt must be modified!
+flash usage optimalization - printing to serial line
current flash usage: 253206bytes (MK3 + ML support)
platform.txt original line 20:
compiler.c.elf.flags=-w -Os -Wl,--gc-sections
platform.txt modified line 20 (enable printf float library)
compiler.c.elf.flags=-w -Os -Wl,-u,vfprintf -lprintf_flt -lm -Wl,--gc-sections
Another fix from PR https://github.com/prusa3d/Prusa-Firmware/pull/138 and discussed in Issue https://github.com/prusa3d/Prusa-Firmware/issues/807
Ardunio IDE 1.6.8 and 1.8.5 result with Compiler warnings set to "More" or "All"
´´´
sketch\mesh_bed_calibration.cpp: In function 'sample_mesh_and_store_reference':
sketch\mesh_bed_calibration.cpp:2852:53: warning: 'zmax' may be used uninitialized in this function [-Wmaybe-uninitialized]
zmax = min(zmax, mbl.z_values[j][i]);
^
sketch\mesh_bed_calibration.cpp:2848:15: note: 'zmax' was declared here
float zmax = zmax;
^
´´´