diff --git a/quantum/debounce/asym_eager_defer_pk.c b/quantum/debounce/asym_eager_defer_pk.c index 173c64beed1..88b860545c1 100644 --- a/quantum/debounce/asym_eager_defer_pk.c +++ b/quantum/debounce/asym_eager_defer_pk.c @@ -1,27 +1,11 @@ -/* - * Copyright 2017 Alex Ong - * Copyright 2020 Andrei Purdea - * Copyright 2021 Simon Arlott - * - * 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 . - */ - -/* -Asymetric per-key algorithm. After pressing a key, it immediately changes state, -with no further inputs accepted until DEBOUNCE milliseconds have occurred. After -releasing a key, that state is pushed after no changes occur for DEBOUNCE milliseconds. -*/ +// Copyright 2017 Alex Ong +// Copyright 2020 Andrei Purdea +// Copyright 2021 Simon Arlott +// SPDX-License-Identifier: GPL-2.0-or-later +// +// Asymetric per-key algorithm. After pressing a key, it immediately changes state, +// with no further inputs accepted until DEBOUNCE milliseconds have occurred. After +// releasing a key, that state is pushed after no changes occur for DEBOUNCE milliseconds. #include "debounce.h" #include "timer.h" diff --git a/quantum/debounce/sym_defer_g.c b/quantum/debounce/sym_defer_g.c index a807e3e0bda..4dad528cd95 100644 --- a/quantum/debounce/sym_defer_g.c +++ b/quantum/debounce/sym_defer_g.c @@ -1,22 +1,10 @@ -/* -Copyright 2017 Alex Ong -Copyright 2021 Simon Arlott -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 . -*/ +// Copyright 2017 Alex Ong +// Copyright 2021 Simon Arlott +// SPDX-License-Identifier: GPL-2.0-or-later +// +// Basic global debounce algorithm. Used in 99% of keyboards at time of implementation +// When no state changes have occured for DEBOUNCE milliseconds, we push the state. -/* -Basic global debounce algorithm. Used in 99% of keyboards at time of implementation -When no state changes have occured for DEBOUNCE milliseconds, we push the state. -*/ #include "debounce.h" #include "timer.h" #include diff --git a/quantum/debounce/sym_defer_pk.c b/quantum/debounce/sym_defer_pk.c index 9c1b57db9d8..ba23702c43f 100644 --- a/quantum/debounce/sym_defer_pk.c +++ b/quantum/debounce/sym_defer_pk.c @@ -1,23 +1,10 @@ -/* -Copyright 2017 Alex Ong -Copyright 2020 Andrei Purdea -Copyright 2021 Simon Arlott -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 . -*/ - -/* -Basic symmetric per-key algorithm. Uses an 8-bit counter per key. -When no state changes have occured for DEBOUNCE milliseconds, we push the state. -*/ +// Copyright 2017 Alex Ong +// Copyright 2020 Andrei Purdea +// Copyright 2021 Simon Arlott +// SPDX-License-Identifier: GPL-2.0-or-later +// +// Basic symmetric per-key algorithm. Uses an 8-bit counter per key. +// When no state changes have occured for DEBOUNCE milliseconds, we push the state. #include "debounce.h" #include "timer.h" diff --git a/quantum/debounce/sym_defer_pr.c b/quantum/debounce/sym_defer_pr.c index e0dbd0dceee..98fa3125b77 100644 --- a/quantum/debounce/sym_defer_pr.c +++ b/quantum/debounce/sym_defer_pr.c @@ -1,23 +1,11 @@ -/* -Copyright 2017 Alex Ong -Copyright 2020 Andrei Purdea -Copyright 2021 Simon Arlott -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 . -*/ - -/* -Basic symmetric per-row algorithm. Uses an 8-bit counter per row. -When no state changes have occured for DEBOUNCE milliseconds, we push the state. -*/ +// Copyright 2017 Alex Ong +// Copyright 2020 Andrei Purdea +// Copyright 2021 Simon Arlott +// Copyright @filterpaper +// SPDX-License-Identifier: GPL-2.0-or-later +// +// Basic symmetric per-row algorithm. Uses an 8-bit counter per row. +// When no state changes have occured for DEBOUNCE milliseconds, we push the state. #include "debounce.h" #include "timer.h" diff --git a/quantum/debounce/sym_eager_pk.c b/quantum/debounce/sym_eager_pk.c index b8cddd5c46e..17918fb3889 100644 --- a/quantum/debounce/sym_eager_pk.c +++ b/quantum/debounce/sym_eager_pk.c @@ -87,9 +87,9 @@ bool debounce(matrix_row_t raw[], matrix_row_t cooked[], uint8_t num_rows, bool /** * @brief Updates per-key debounce counters and determines if matrix needs updating. * - * Iterates through each key in the matrix and checks its debounce counter. - * If the debounce period has elapsed for a key, the counter is reset and the matrix is marked for update. - * Otherwise, the counter is decremented by the elapsed time and marked for further updates if needed. + * Iterates through each key in the matrix and checks its debounce counter. If the debounce + * period has elapsed, the counter is reset and the matrix is marked for update. Otherwise, + * the counter is decremented by the elapsed time and marked for further updates if needed. * * @param elapsed_time The time elapsed since the last debounce update, in milliseconds. */ diff --git a/quantum/debounce/sym_eager_pr.c b/quantum/debounce/sym_eager_pr.c index d63da208c04..d047acd1c5a 100644 --- a/quantum/debounce/sym_eager_pr.c +++ b/quantum/debounce/sym_eager_pr.c @@ -1,23 +1,10 @@ -/* -Copyright 2019 Alex Ong -Copyright 2021 Simon Arlott -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 . -*/ - -/* -Basic per-row algorithm. Uses an 8-bit counter per row. -After pressing a key, it immediately changes state, and sets a counter. -No further inputs are accepted until DEBOUNCE milliseconds have occurred. -*/ +// Copyright 2017 Alex Ong +// Copyright 2021 Simon Arlott +// SPDX-License-Identifier: GPL-2.0-or-later +// +// Basic per-row algorithm. Uses an 8-bit counter per key. +// After pressing a key, it immediately changes state, and sets a counter. +// No further inputs are accepted until DEBOUNCE milliseconds have occurred. #include "debounce.h" #include "timer.h"