diff options
Diffstat (limited to 'quantum/split_common/matrix.c')
| -rw-r--r-- | quantum/split_common/matrix.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/quantum/split_common/matrix.c b/quantum/split_common/matrix.c index d6636b886..039e7d977 100644 --- a/quantum/split_common/matrix.c +++ b/quantum/split_common/matrix.c | |||
| @@ -43,6 +43,7 @@ extern matrix_row_t matrix[MATRIX_ROWS]; // debounced values | |||
| 43 | uint8_t thisHand, thatHand; | 43 | uint8_t thisHand, thatHand; |
| 44 | 44 | ||
| 45 | // user-defined overridable functions | 45 | // user-defined overridable functions |
| 46 | __attribute__((weak)) void matrix_slave_scan_kb(void) { matrix_slave_scan_user(); } | ||
| 46 | __attribute__((weak)) void matrix_slave_scan_user(void) {} | 47 | __attribute__((weak)) void matrix_slave_scan_user(void) {} |
| 47 | 48 | ||
| 48 | static inline void setPinOutput_writeLow(pin_t pin) { | 49 | static inline void setPinOutput_writeLow(pin_t pin) { |
| @@ -129,9 +130,7 @@ static bool read_cols_on_row(matrix_row_t current_matrix[], uint8_t current_row) | |||
| 129 | 130 | ||
| 130 | // Unselect row | 131 | // Unselect row |
| 131 | unselect_row(current_row); | 132 | unselect_row(current_row); |
| 132 | if (current_row + 1 < MATRIX_ROWS) { | 133 | matrix_output_unselect_delay(); // wait for all Col signals to go HIGH |
| 133 | matrix_output_unselect_delay(); // wait for row signal to go HIGH | ||
| 134 | } | ||
| 135 | 134 | ||
| 136 | // If the row has changed, store the row and return the changed flag. | 135 | // If the row has changed, store the row and return the changed flag. |
| 137 | if (current_matrix[current_row] != current_row_value) { | 136 | if (current_matrix[current_row] != current_row_value) { |
| @@ -191,9 +190,7 @@ static bool read_rows_on_col(matrix_row_t current_matrix[], uint8_t current_col) | |||
| 191 | 190 | ||
| 192 | // Unselect col | 191 | // Unselect col |
| 193 | unselect_col(current_col); | 192 | unselect_col(current_col); |
| 194 | if (current_col + 1 < MATRIX_COLS) { | 193 | matrix_output_unselect_delay(); // wait for all Row signals to go HIGH |
| 195 | matrix_output_unselect_delay(); // wait for col signal to go HIGH | ||
| 196 | } | ||
| 197 | 194 | ||
| 198 | return matrix_changed; | 195 | return matrix_changed; |
| 199 | } | 196 | } |
| @@ -284,7 +281,7 @@ bool matrix_post_scan(void) { | |||
| 284 | } else { | 281 | } else { |
| 285 | transport_slave(matrix + thatHand, matrix + thisHand); | 282 | transport_slave(matrix + thatHand, matrix + thisHand); |
| 286 | 283 | ||
| 287 | matrix_slave_scan_user(); | 284 | matrix_slave_scan_kb(); |
| 288 | } | 285 | } |
| 289 | 286 | ||
| 290 | return changed; | 287 | return changed; |
