Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions Marlin/src/lcd/ultralcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -777,13 +777,12 @@ void MarlinUI::update() {
static bool wait_for_unclick; // = false

#if ENABLED(TOUCH_BUTTONS)

if (touch_buttons) {
RESET_STATUS_TIMEOUT();
if (buttons & (EN_A | EN_B)) { // Menu arrows, in priority
if (touch_buttons & (EN_A | EN_B)) { // Menu arrows, in priority
if (ELAPSED(ms, next_button_update_ms)) {
encoderDiff = (ENCODER_STEPS_PER_MENU_ITEM) * (ENCODER_PULSES_PER_STEP) * encoderDirection;
if (buttons & EN_A) encoderDiff *= -1;
if (touch_buttons & EN_A) encoderDiff *= -1;
#if ENABLED(AUTO_BED_LEVELING_UBL)
if (external_control) ubl.encoder_diff = encoderDiff;
#endif
Expand Down Expand Up @@ -1246,7 +1245,11 @@ void MarlinUI::update() {
| slow_buttons
#endif
#if ENABLED(TOUCH_BUTTONS) && HAS_ENCODER_ACTION
| touch_buttons
| (touch_buttons
#if HAS_ENCODER_WHEEL
& (~(EN_A | EN_B))
#endif
)
#endif
);

Expand Down Expand Up @@ -1277,7 +1280,7 @@ void MarlinUI::update() {

} // next_button_update_ms

#if HAS_ENCODER_WHEEL && DISABLED(TOUCH_BUTTONS)
#if HAS_ENCODER_WHEEL
static uint8_t lastEncoderBits;

#define encrot0 0
Expand Down