diff options
Diffstat (limited to 'keyboards/handwired/frenchdev/matrix.c')
| -rw-r--r-- | keyboards/handwired/frenchdev/matrix.c | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/keyboards/handwired/frenchdev/matrix.c b/keyboards/handwired/frenchdev/matrix.c index 26c2b3126..c9c7e94ae 100644 --- a/keyboards/handwired/frenchdev/matrix.c +++ b/keyboards/handwired/frenchdev/matrix.c | |||
| @@ -35,9 +35,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
| 35 | #include "util.h" | 35 | #include "util.h" |
| 36 | #include "matrix.h" | 36 | #include "matrix.h" |
| 37 | #include "frenchdev.h" | 37 | #include "frenchdev.h" |
| 38 | #ifdef DEBUG_MATRIX_SCAN_RATE | ||
| 39 | #include "timer.h" | ||
| 40 | #endif | ||
| 41 | 38 | ||
| 42 | /* | 39 | /* |
| 43 | * This constant define not debouncing time in msecs, but amount of matrix | 40 | * This constant define not debouncing time in msecs, but amount of matrix |
| @@ -66,12 +63,6 @@ static void select_row(uint8_t row); | |||
| 66 | 63 | ||
| 67 | static uint8_t mcp23018_reset_loop; | 64 | static uint8_t mcp23018_reset_loop; |
| 68 | 65 | ||
| 69 | #ifdef DEBUG_MATRIX_SCAN_RATE | ||
| 70 | uint32_t matrix_timer; | ||
| 71 | uint32_t matrix_scan_count; | ||
| 72 | #endif | ||
| 73 | |||
| 74 | |||
| 75 | __attribute__ ((weak)) | 66 | __attribute__ ((weak)) |
| 76 | void matrix_init_user(void) {} | 67 | void matrix_init_user(void) {} |
| 77 | 68 | ||
| @@ -120,13 +111,7 @@ void matrix_init(void) | |||
| 120 | matrix_debouncing[i] = 0; | 111 | matrix_debouncing[i] = 0; |
| 121 | } | 112 | } |
| 122 | 113 | ||
| 123 | #ifdef DEBUG_MATRIX_SCAN_RATE | ||
| 124 | matrix_timer = timer_read32(); | ||
| 125 | matrix_scan_count = 0; | ||
| 126 | #endif | ||
| 127 | |||
| 128 | matrix_init_quantum(); | 114 | matrix_init_quantum(); |
| 129 | |||
| 130 | } | 115 | } |
| 131 | 116 | ||
| 132 | void matrix_power_up(void) { | 117 | void matrix_power_up(void) { |
| @@ -140,12 +125,6 @@ void matrix_power_up(void) { | |||
| 140 | matrix[i] = 0; | 125 | matrix[i] = 0; |
| 141 | matrix_debouncing[i] = 0; | 126 | matrix_debouncing[i] = 0; |
| 142 | } | 127 | } |
| 143 | |||
| 144 | #ifdef DEBUG_MATRIX_SCAN_RATE | ||
| 145 | matrix_timer = timer_read32(); | ||
| 146 | matrix_scan_count = 0; | ||
| 147 | #endif | ||
| 148 | |||
| 149 | } | 128 | } |
| 150 | 129 | ||
| 151 | uint8_t matrix_scan(void) | 130 | uint8_t matrix_scan(void) |
| @@ -165,20 +144,6 @@ uint8_t matrix_scan(void) | |||
| 165 | } | 144 | } |
| 166 | } | 145 | } |
| 167 | 146 | ||
| 168 | #ifdef DEBUG_MATRIX_SCAN_RATE | ||
| 169 | matrix_scan_count++; | ||
| 170 | |||
| 171 | uint32_t timer_now = timer_read32(); | ||
| 172 | if (TIMER_DIFF_32(timer_now, matrix_timer)>1000) { | ||
| 173 | print("matrix scan frequency: "); | ||
| 174 | pdec(matrix_scan_count); | ||
| 175 | print("\n"); | ||
| 176 | |||
| 177 | matrix_timer = timer_now; | ||
| 178 | matrix_scan_count = 0; | ||
| 179 | } | ||
| 180 | #endif | ||
| 181 | |||
| 182 | for (uint8_t i = 0; i < MATRIX_ROWS; i++) { | 147 | for (uint8_t i = 0; i < MATRIX_ROWS; i++) { |
| 183 | select_row(i); | 148 | select_row(i); |
| 184 | wait_us(30); // without this wait read unstable value. | 149 | wait_us(30); // without this wait read unstable value. |
