diff options
author | Joel Challis <git@zvecr.com> | 2020-02-21 03:49:33 +0000 |
---|---|---|
committer | Drashna Jael're <drashna@live.com> | 2020-03-26 00:42:12 -0700 |
commit | 583bd29a60abf3e6b94a258e1f7dfa2e63a47bdc (patch) | |
tree | 55dacbaeaee370d14f212ad17f2e1e45b3aab144 /quantum/matrix_common.c | |
parent | 31d15910e7e0ca75a055c9de498bddf7e96d6cc0 (diff) |
Allow 30us matrix delay to be keyboard/user overridable (#8216)
* Allow 30us matrix delay to be configurable via define
* Move wait logic to matrix_common
* Move wait logic to matrix_common - fix wait includes
Diffstat (limited to 'quantum/matrix_common.c')
-rw-r--r-- | quantum/matrix_common.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/quantum/matrix_common.c b/quantum/matrix_common.c index c326e59ca3..de62b80705 100644 --- a/quantum/matrix_common.c +++ b/quantum/matrix_common.c @@ -1,8 +1,13 @@ #include "matrix.h" #include "debounce.h" +#include "wait.h" #include "print.h" #include "debug.h" +#ifndef MATRIX_IO_DELAY +# define MATRIX_IO_DELAY 30 +#endif + /* matrix state(1:on, 0:off) */ matrix_row_t raw_matrix[MATRIX_ROWS]; matrix_row_t matrix[MATRIX_ROWS]; @@ -78,6 +83,8 @@ uint8_t matrix_key_count(void) { return count; } +__attribute__((weak)) void matrix_io_delay(void) { wait_us(MATRIX_IO_DELAY); } + // CUSTOM MATRIX 'LITE' __attribute__((weak)) void matrix_init_custom(void) {} |