Skip to content

Commit

Permalink
TWEAK runout sensor bool menu items
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed Dec 20, 2018
1 parent b2db6d3 commit eaee9b1
Show file tree
Hide file tree
Showing 10 changed files with 40 additions and 37 deletions.
8 changes: 4 additions & 4 deletions A10D_marlin1.1.8/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3686,6 +3686,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3711,9 +3714,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4528,7 +4528,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A10M_marlin1.1.8/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3914,6 +3914,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3939,9 +3942,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4761,7 +4761,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A10M_marlin1.1.8_3Dtouch/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3914,6 +3914,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3939,9 +3942,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4761,7 +4761,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A10_marlin1.1.8/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3688,6 +3688,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3713,9 +3716,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4535,7 +4535,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A10_marlin1.1.8_3DTtouch/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3688,6 +3688,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3713,9 +3716,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4535,7 +4535,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A20M_Marlin-1.1.x12864/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3914,6 +3914,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3939,9 +3942,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4760,7 +4760,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A20M_Marlin-1.1.x12864_3DTouch/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3914,6 +3914,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3939,9 +3942,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4760,7 +4760,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A20_Marlin-1.1.x12864/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3688,6 +3688,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3713,9 +3716,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4534,7 +4534,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
8 changes: 4 additions & 4 deletions A20_Marlin-1.1.x12864_3DTouch/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3688,6 +3688,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand All @@ -3713,9 +3716,6 @@ void kill_screen(const char* lcd_msg) {
#endif // EXTRUDERS > 1
}

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

END_MENU();
}

Expand Down Expand Up @@ -4534,7 +4534,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down
5 changes: 4 additions & 1 deletion MeCreator2_marlin1.1.8/Marlin/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3683,6 +3683,9 @@ void kill_screen(const char* lcd_msg) {
START_MENU();
MENU_BACK(MSG_CONTROL);

// Filament Runout Sensors
MENU_ITEM_EDIT(bool, MSG_RUNOUT_SENSORS, &filament_runout_enabled);

#if ENABLED(LIN_ADVANCE)
MENU_ITEM_EDIT(float3, MSG_ADVANCE_K, &planner.extruder_advance_k, 0, 999);
#endif
Expand Down Expand Up @@ -4521,7 +4524,7 @@ void kill_screen(const char* lcd_msg) {

#endif // SDSUPPORT

void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr ^= true; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_bool(const char* pstr, bool* ptr) { UNUSED(pstr); *ptr = !*ptr; lcdDrawUpdate = LCDVIEW_CLEAR_CALL_REDRAW; }
void menu_action_setting_edit_callback_bool(const char* pstr, bool* ptr, screenFunc_t callback) {
menu_action_setting_edit_bool(pstr, ptr);
(*callback)();
Expand Down

0 comments on commit eaee9b1

Please sign in to comment.