diff options
| author | Purdea Andrei <andrei@purdea.ro> | 2020-09-06 23:13:49 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-09-06 13:13:49 -0700 |
| commit | f7ccbfcea88e127319a4665a6c8ca67883854030 (patch) | |
| tree | 25a2d9f5c7b9b95795d097c9514928af90d5080a /quantum/debounce | |
| parent | 8ac9940a76f09d4a47be342fc123306ecbfb27f3 (diff) | |
| download | qmk_firmware-f7ccbfcea88e127319a4665a6c8ca67883854030.tar.gz qmk_firmware-f7ccbfcea88e127319a4665a6c8ca67883854030.zip | |
quantum/debounce: rename debouncing algorithms (#9564)
* quantum/debounce: rename debouncing algorithms according to Issue 8763
This is the second attempt at implementation, with no ts_ and cy_ prefixes, since those will be implemented with macros.
* Debouncing documentation: Refactor, add some generic info, and merge into a single document
Diffstat (limited to 'quantum/debounce')
| -rw-r--r-- | quantum/debounce/readme.md | 28 | ||||
| -rw-r--r-- | quantum/debounce/sym_defer_g.c (renamed from quantum/debounce/sym_g.c) | 0 | ||||
| -rw-r--r-- | quantum/debounce/sym_defer_pk.c (renamed from quantum/debounce/sym_pk.c) | 0 | ||||
| -rw-r--r-- | quantum/debounce/sym_eager_pk.c (renamed from quantum/debounce/eager_pk.c) | 0 | ||||
| -rw-r--r-- | quantum/debounce/sym_eager_pr.c (renamed from quantum/debounce/eager_pr.c) | 0 |
5 files changed, 0 insertions, 28 deletions
diff --git a/quantum/debounce/readme.md b/quantum/debounce/readme.md deleted file mode 100644 index f77f78c76..000000000 --- a/quantum/debounce/readme.md +++ /dev/null | |||
| @@ -1,28 +0,0 @@ | |||
| 1 | Debounce algorithms belong in this folder. | ||
| 2 | Here are a few ideas | ||
| 3 | |||
| 4 | 1) Global vs Per-Key vs Per-Row | ||
| 5 | * Global - one timer for all keys. Any key change state affects global timer | ||
| 6 | * Per key - one timer per key | ||
| 7 | * Per row - one timer per row | ||
| 8 | |||
| 9 | 2) Eager vs symmetric vs asymmetric | ||
| 10 | * Eager - any key change is reported immediately. All further inputs for DEBOUNCE ms are ignored. | ||
| 11 | * Symmetric - wait for no changes for DEBOUNCE ms before reporting change | ||
| 12 | * Asymmetric - wait for different times depending on key-down/key-up. E.g. Eager key-down, DEBOUNCE ms key up. | ||
| 13 | |||
| 14 | 3) Timestamp vs cycles | ||
| 15 | * old old old code waits n cycles, decreasing count by one each matrix_scan | ||
| 16 | * newer code stores the millisecond the change occurred, and does subraction to figure out time elapsed. | ||
| 17 | * Timestamps are superior, i don't think cycles will ever be used again once upgraded. | ||
| 18 | |||
| 19 | The default algorithm is symmetric and global. | ||
| 20 | Here are a few that could be implemented: | ||
| 21 | |||
| 22 | sym_g.c | ||
| 23 | sym_pk.c | ||
| 24 | sym_pr.c | ||
| 25 | sym_pr_cycles.c | ||
| 26 | eager_g.c | ||
| 27 | eager_pk.c | ||
| 28 | eager_pr.c //could be used in ergo-dox! | ||
diff --git a/quantum/debounce/sym_g.c b/quantum/debounce/sym_defer_g.c index 3ed9055d2..3ed9055d2 100644 --- a/quantum/debounce/sym_g.c +++ b/quantum/debounce/sym_defer_g.c | |||
diff --git a/quantum/debounce/sym_pk.c b/quantum/debounce/sym_defer_pk.c index f404cf9c4..f404cf9c4 100644 --- a/quantum/debounce/sym_pk.c +++ b/quantum/debounce/sym_defer_pk.c | |||
diff --git a/quantum/debounce/eager_pk.c b/quantum/debounce/sym_eager_pk.c index 93a40ad44..93a40ad44 100644 --- a/quantum/debounce/eager_pk.c +++ b/quantum/debounce/sym_eager_pk.c | |||
diff --git a/quantum/debounce/eager_pr.c b/quantum/debounce/sym_eager_pr.c index d12931fdd..d12931fdd 100644 --- a/quantum/debounce/eager_pr.c +++ b/quantum/debounce/sym_eager_pr.c | |||
