Round all floats in string conversion functions (#10566)

This commit is contained in:
Scott Lahteine
2018-04-29 00:51:36 -05:00
committed by GitHub
parent 3f68203324
commit 9e0d99c0c6
6 changed files with 22 additions and 22 deletions

View File

@ -343,7 +343,7 @@ static void lcd_implementation_status_screen() {
if (page.page == 0) {
strcpy(xstring, ftostr4sign(LOGICAL_X_POSITION(current_position[X_AXIS])));
strcpy(ystring, ftostr4sign(LOGICAL_Y_POSITION(current_position[Y_AXIS])));
strcpy(zstring, ftostr52sp(FIXFLOAT(LOGICAL_Z_POSITION(current_position[Z_AXIS]))));
strcpy(zstring, ftostr52sp(LOGICAL_Z_POSITION(current_position[Z_AXIS])));
#if ENABLED(FILAMENT_LCD_DISPLAY)
strcpy(wstring, ftostr12ns(filament_width_meas));
strcpy(mstring, itostr3(100.0 * (

View File

@ -4829,7 +4829,6 @@ void kill_screen(const char* lcd_msg) {
} \
typedef void _name
DEFINE_MENU_EDIT_TYPE(uint32_t, long5, ftostr5rj, 0.01);
DEFINE_MENU_EDIT_TYPE(int16_t, int3, itostr3, 1);
DEFINE_MENU_EDIT_TYPE(uint8_t, int8, i8tostr3, 1);
DEFINE_MENU_EDIT_TYPE(float, float3, ftostr3, 1.0);
@ -4839,6 +4838,7 @@ void kill_screen(const char* lcd_msg) {
DEFINE_MENU_EDIT_TYPE(float, float51, ftostr51sign, 10.0);
DEFINE_MENU_EDIT_TYPE(float, float52, ftostr52sign, 100.0);
DEFINE_MENU_EDIT_TYPE(float, float62, ftostr62rj, 100.0);
DEFINE_MENU_EDIT_TYPE(uint32_t, long5, ftostr5rj, 0.01);
/**
*

View File

@ -676,7 +676,7 @@ static void lcd_implementation_status_screen() {
lcd_moveto(LCD_WIDTH - 8, 1);
_draw_axis_label(Z_AXIS, PSTR(MSG_Z), blink);
lcd_put_u8str(ftostr52sp(FIXFLOAT(LOGICAL_Z_POSITION(current_position[Z_AXIS]))));
lcd_put_u8str(ftostr52sp(LOGICAL_Z_POSITION(current_position[Z_AXIS])));
#if HAS_LEVELING && !TEMP_SENSOR_BED
lcd_put_wchar(planner.leveling_active || blink ? '_' : ' ');