summaryrefslogtreecommitdiffstats
path: root/keyboards/ergodox_ez/config.h
diff options
context:
space:
mode:
authorErez Zukerman <bulk@ezuk.org>2018-11-22 16:51:20 +0100
committerGitHub <noreply@github.com>2018-11-22 16:51:20 +0100
commit48262bdce0666442850125d7f0298fb5e0044b0e (patch)
tree220a0f200bfe2586c6653721f96ae6c92b7168d9 /keyboards/ergodox_ez/config.h
parentb7dd415c9787c4300db1c31740fa94b93c68c2ac (diff)
parentad91454574ad1f0fad73923d04d6d1e037e45fed (diff)
downloadqmk_firmware-48262bdce0666442850125d7f0298fb5e0044b0e.tar.gz
qmk_firmware-48262bdce0666442850125d7f0298fb5e0044b0e.tar.xz
Merge pull request #4454 from trunneml/improveddebounce
Adaptive debounce logic
Diffstat (limited to 'keyboards/ergodox_ez/config.h')
-rw-r--r--keyboards/ergodox_ez/config.h17
1 files changed, 10 insertions, 7 deletions
diff --git a/keyboards/ergodox_ez/config.h b/keyboards/ergodox_ez/config.h
index 7a350183b..ee768853a 100644
--- a/keyboards/ergodox_ez/config.h
+++ b/keyboards/ergodox_ez/config.h
@@ -85,17 +85,20 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGBW 1
-/* "debounce" is measured in keyboard scans. Some users reported
- * needing values as high as 15, which was at the time around 50ms.
+/*
+ * The debounce filtering reports a key/switch change directly,
+ * without any extra delay. After that the debounce logic will filter
+ * all further changes, until the key/switch reports the same state for
+ * the given count of scans.
+ * So a perfect switch will get a short debounce period and
+ * a bad key will get a much longer debounce period.
+ * The result is an adaptive debouncing period for each switch.
+ *
* If you don't define it here, the matrix code will default to
* 5, which is now closer to 10ms, but still plenty according to
* manufacturer specs.
- *
- * Default is quite high, because of reports with some production
- * runs seeming to need it. This may change when configuration for
- * this is more directly exposed.
*/
-#define DEBOUNCE 15
+#define DEBOUNCE 10
#define USB_MAX_POWER_CONSUMPTION 500