2020-02-05 10:47:59 +06:00
|
|
|
/*
|
|
|
|
Copyright 2012-2018 Jun Wako, Jack Humbert, Yiancar
|
|
|
|
|
|
|
|
This program is free software: you can redistribute it and/or modify
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
the Free Software Foundation, either version 2 of the License, or
|
|
|
|
(at your option) any later version.
|
|
|
|
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
GNU General Public License for more details.
|
|
|
|
|
|
|
|
You should have received a copy of the GNU General Public License
|
|
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
2020-02-08 08:50:42 +06:00
|
|
|
|
2020-02-05 10:47:59 +06:00
|
|
|
#include "quantum.h"
|
2020-02-08 08:50:42 +06:00
|
|
|
#include "matrix.h"
|
2020-02-05 10:47:59 +06:00
|
|
|
#include "board.h"
|
|
|
|
|
2020-02-08 08:50:42 +06:00
|
|
|
void matrix_init_custom(void) {
|
2020-02-05 10:47:59 +06:00
|
|
|
// initialize key pins
|
|
|
|
board_init();
|
|
|
|
}
|
|
|
|
|
2020-02-08 08:50:42 +06:00
|
|
|
bool matrix_scan_custom(matrix_row_t current_matrix[]) {
|
2020-02-05 10:47:59 +06:00
|
|
|
bool changed = false;
|
|
|
|
|
|
|
|
// Set row, read cols
|
|
|
|
for (uint8_t current_row = 0; current_row < MATRIX_ROWS; current_row++) {
|
2020-02-08 08:50:42 +06:00
|
|
|
changed |= board_read_cols_on_row(current_matrix, current_row);
|
2020-02-05 10:47:59 +06:00
|
|
|
}
|
|
|
|
|
2020-02-08 08:50:42 +06:00
|
|
|
return changed;
|
2020-02-05 10:47:59 +06:00
|
|
|
}
|