~ruther/qmk_firmware

ea98aa8e5ef8bebac52a76ad22ddd22e6d7f289e — Joel Challis 2 years ago 8213eb7
Reduce includes for dip_switch header (#18951)

2 files changed, 7 insertions(+), 4 deletions(-)

M quantum/dip_switch.c
M quantum/dip_switch.h
M quantum/dip_switch.c => quantum/dip_switch.c +5 -3
@@ 16,14 16,16 @@
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#include <string.h> // for memcpy

#include "dip_switch.h"
#include "gpio.h"
#include "util.h"

#ifdef SPLIT_KEYBOARD
#    include "split_common/split_util.h"
#endif

// for memcpy
#include <string.h>

#if !defined(DIP_SWITCH_PINS) && !defined(DIP_SWITCH_MATRIX_GRID)
#    error "Either DIP_SWITCH_PINS or DIP_SWITCH_MATRIX_GRID must be defined."
#endif

M quantum/dip_switch.h => quantum/dip_switch.h +2 -1
@@ 18,7 18,8 @@

#pragma once

#include "quantum.h"
#include <stdbool.h>
#include <stdint.h>

bool dip_switch_update_kb(uint8_t index, bool active);
bool dip_switch_update_user(uint8_t index, bool active);