From 1658c813df2b638d6ce23d25723c2ad30f2440c9 Mon Sep 17 00:00:00 2001 From: "Jan \"Yenya\" Kasprzak" Date: Sat, 15 Dec 2012 22:22:02 +0100 Subject: [PATCH] buttons.c: longer keypress ... after we have increased the clock frequency --- firmware/buttons.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/firmware/buttons.c b/firmware/buttons.c index 1263fcb..2e80142 100644 --- a/firmware/buttons.c +++ b/firmware/buttons.c @@ -152,16 +152,16 @@ static void handle_button(unsigned char button, unsigned char cur, } else if (!cur && !prev) { // --- is still pressed --- uint16_t duration = jiffies - button_start[button]; - if (duration > 80) { + if (duration > 160) { set_status_led(button, on1_pattern); // acknowledge long press } } else if (cur && !prev) { // --- just released --- uint16_t duration = jiffies - button_start[button]; - if (duration > 6 && duration < 30) { + if (duration > 6 && duration < 60) { short_press(button); - } else if (duration > 80) { + } else if (duration > 160) { set_status_led(button, NULL); long_press(button); } -- 2.39.3