forked from mirrors/qmk_userspace
Add a test fixture
It only initializes QMK once, and clears the matrix after each test.
This commit is contained in:
parent
e85b185796
commit
36f820be7e
6 changed files with 80 additions and 15 deletions
|
@ -22,7 +22,7 @@
|
|||
static matrix_row_t matrix[MATRIX_ROWS] = {};
|
||||
|
||||
void matrix_init(void) {
|
||||
memset(matrix, 0, sizeof(matrix));
|
||||
clear_all_keys();
|
||||
matrix_init_quantum();
|
||||
}
|
||||
|
||||
|
@ -54,3 +54,7 @@ void press_key(uint8_t col, uint8_t row) {
|
|||
void release_key(uint8_t col, uint8_t row) {
|
||||
matrix[row] &= ~(1 << col);
|
||||
}
|
||||
|
||||
void clear_all_keys(void) {
|
||||
memset(matrix, 0, sizeof(matrix));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue