qmk_firmware

QMK firmware for my keyboards (Corne, Sweep Ferris) and trackball (Ploopy Adept)
Log | Files | Refs | Submodules | LICENSE

debounce.h (512B)


      1 #pragma once
      2 
      3 #include <stdint.h>
      4 #include <stdbool.h>
      5 #include "matrix.h"
      6 
      7 /**
      8  * @brief Debounce raw matrix events according to the choosen debounce algorithm.
      9  *
     10  * @param raw The current key state
     11  * @param cooked The debounced key state
     12  * @param changed True if raw has changed since the last call
     13  * @return true Cooked has new keychanges after debouncing
     14  * @return false Cooked is the same as before
     15  */
     16 bool debounce(matrix_row_t raw[], matrix_row_t cooked[], bool changed);
     17 
     18 void debounce_init(void);