2021-12-30 05:17:34 +01:00
|
|
|
// Copyright 2020 Christopher Courtney, aka Drashna Jael're (@drashna) <drashna@live.com>
|
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
2020-10-17 20:46:57 +02:00
|
|
|
|
2018-07-17 03:04:32 +02:00
|
|
|
#pragma once
|
2018-03-25 22:01:15 +02:00
|
|
|
|
2019-09-07 17:57:30 +02:00
|
|
|
// Use custom magic number so that when switching branches, EEPROM always gets reset
|
2022-07-03 04:55:46 +02:00
|
|
|
#define EECONFIG_MAGIC_NUMBER (uint16_t)0x1339
|
2019-09-07 17:57:30 +02:00
|
|
|
|
2021-12-30 05:17:34 +01:00
|
|
|
#ifdef IS_COMMAND
|
2022-07-03 04:55:46 +02:00
|
|
|
# undef IS_COMMAND
|
2021-12-30 05:17:34 +01:00
|
|
|
#endif
|
|
|
|
#define IS_COMMAND() (((get_mods() | get_oneshot_mods()) & MOD_MASK_SHIFT) == MOD_MASK_SHIFT)
|
|
|
|
|
2019-09-07 17:57:30 +02:00
|
|
|
|
2021-02-23 19:57:24 +01:00
|
|
|
#if defined(SPLIT_KEYBOARD)
|
2022-08-28 21:55:19 +02:00
|
|
|
# include "split/split_config.h"
|
|
|
|
#endif
|
|
|
|
#ifdef RGBLIGHT_ENABLE
|
|
|
|
# include "rgb/rgblight_config.h"
|
|
|
|
#endif // RGBLIGHT_ENABLE
|
|
|
|
|
|
|
|
#ifdef RGB_MATRIX_ENABLE
|
|
|
|
# include "rgb/rgb_matrix_config.h"
|
|
|
|
#endif // RGB_MATRIX_ENABLE
|
|
|
|
|
|
|
|
#ifdef OLED_ENABLE
|
|
|
|
# include "oled/oled_config.h"
|
2021-01-22 17:23:03 +01:00
|
|
|
#endif
|
|
|
|
|
2021-11-29 08:41:59 +01:00
|
|
|
#if defined(WPM_ENABLE)
|
|
|
|
// # define WPM_LAUNCH_CONTROL
|
|
|
|
// # define WPM_ALLOW_COUNT_REGRESSOIN
|
|
|
|
// # define WPM_UNFILTERED
|
2022-07-03 04:55:46 +02:00
|
|
|
# define WPM_SAMPLE_SECONDS 10
|
|
|
|
# define WPM_SAMPLE_PERIODS 50
|
2022-05-31 07:02:55 +02:00
|
|
|
# define WPM_ESTIMATED_WORD_SIZE 5
|
2021-11-29 08:41:59 +01:00
|
|
|
#endif
|
|
|
|
|
2018-03-25 22:01:15 +02:00
|
|
|
#ifdef AUDIO_ENABLE
|
2019-07-23 05:22:33 +02:00
|
|
|
# define AUDIO_CLICKY
|
|
|
|
# define AUDIO_CLICKY_FREQ_RANDOMNESS 1.5f
|
|
|
|
|
2021-07-01 09:42:32 +02:00
|
|
|
# ifdef USER_SONG_LIST
|
|
|
|
# define STARTUP_SONG SONG(RICK_ROLL)
|
|
|
|
# define GOODBYE_SONG SONG(SONIC_RING)
|
|
|
|
# define DEFAULT_LAYER_SONGS \
|
|
|
|
{ SONG(QWERTY_SOUND), SONG(COLEMAK_SOUND), SONG(DVORAK_SOUND), SONG(OVERWATCH_THEME) }
|
2022-07-03 04:55:46 +02:00
|
|
|
# define UNICODE_SONG_MAC SONG(MARIO_THEME)
|
|
|
|
# define UNICODE_SONG_LNX SONG(MARIO_POWERUP)
|
|
|
|
# define UNICODE_SONG_WIN SONG(MARIO_ONEUP)
|
|
|
|
# define UNICODE_SONG_BSD SONG(RICK_ROLL)
|
2021-07-01 09:42:32 +02:00
|
|
|
# define UNICODE_SONG_WINC SONG(RICK_ROLL)
|
|
|
|
# else
|
|
|
|
# define STARTUP_SONG SONG(STARTUP_SOUND)
|
|
|
|
# define GOODBYE_SONG SONG(GOODBYE_SOUND)
|
|
|
|
# define DEFAULT_LAYER_SONGS \
|
|
|
|
{ SONG(QWERTY_SOUND), SONG(COLEMAK_SOUND), SONG(DVORAK_SOUND), SONG(WORKMAN_SOUND) }
|
2022-07-03 04:55:46 +02:00
|
|
|
# define UNICODE_SONG_MAC SONG(QWERTY_SOUND)
|
|
|
|
# define UNICODE_SONG_LNX SONG(COLEMAK_SOUND)
|
|
|
|
# define UNICODE_SONG_WIN SONG(DVORAK_SOUND)
|
|
|
|
# define UNICODE_SONG_BSD SONG(WORKMAN_SOUND)
|
2021-07-01 09:42:32 +02:00
|
|
|
# define UNICODE_SONG_WINC SONG(PLOVER_GOODBYE_SOUND)
|
|
|
|
# endif
|
2022-07-03 04:55:46 +02:00
|
|
|
#endif // !AUDIO_ENABLE
|
2021-07-01 09:42:32 +02:00
|
|
|
|
2021-12-15 05:53:36 +01:00
|
|
|
#define UNICODE_SELECTED_MODES UC_WINC, UC_MAC
|
2018-03-25 22:01:15 +02:00
|
|
|
|
2021-11-17 21:45:50 +01:00
|
|
|
// #define WPM_ESTIMATED_WORD_SIZE 5
|
|
|
|
#define WPM_ALLOW_COUNT_REGRESSION
|
|
|
|
// #define WPM_UNFILTERED
|
|
|
|
// #define WPM_SAMPLE_SECONDS 5
|
|
|
|
// #define WPM_SAMPLE_PERIODS 50
|
|
|
|
// #define WPM_LAUNCH_CONTROL
|
|
|
|
|
2018-03-25 22:01:15 +02:00
|
|
|
#ifndef ONESHOT_TAP_TOGGLE
|
2019-07-23 05:22:33 +02:00
|
|
|
# define ONESHOT_TAP_TOGGLE 2
|
2022-07-03 04:55:46 +02:00
|
|
|
#endif // !ONESHOT_TAP_TOGGLE
|
2018-03-25 22:01:15 +02:00
|
|
|
|
|
|
|
#ifndef ONESHOT_TIMEOUT
|
2019-07-23 05:22:33 +02:00
|
|
|
# define ONESHOT_TIMEOUT 3000
|
2022-07-03 04:55:46 +02:00
|
|
|
#endif // !ONESHOT_TIMEOUT
|
2018-03-25 22:01:15 +02:00
|
|
|
|
2022-08-28 21:55:19 +02:00
|
|
|
#if defined(PER_KEY_TAPPING)
|
|
|
|
# define IGNORE_MOD_TAP_INTERRUPT_PER_KEY
|
|
|
|
# define PERMISSIVE_HOLD_PER_KEY
|
|
|
|
# define TAPPING_FORCE_HOLD_PER_KEY
|
|
|
|
# define HOLD_ON_OTHER_KEY
|
|
|
|
# define RETRO_TAPPING_PER_KEY
|
|
|
|
# define HOLD_ON_OTHER_KEY_PRESS_PER_KEY
|
|
|
|
# define TAPPING_TERM_PER_KEY
|
|
|
|
#else
|
|
|
|
# define IGNORE_MOD_TAP_INTERRUPT
|
|
|
|
# undef PERMISSIVE_HOLD
|
|
|
|
#endif
|
2021-11-10 15:10:00 +01:00
|
|
|
|
2018-03-25 22:01:15 +02:00
|
|
|
#ifndef TAPPING_TOGGLE
|
2019-07-23 05:22:33 +02:00
|
|
|
# define TAPPING_TOGGLE 1
|
2018-03-25 22:01:15 +02:00
|
|
|
#endif
|
|
|
|
|
2019-04-22 20:55:55 +02:00
|
|
|
#define TAP_CODE_DELAY 5
|
2019-05-07 07:34:09 +02:00
|
|
|
|
|
|
|
/* Disable unused and unneeded features to reduce on firmware size */
|
|
|
|
#ifdef LOCKING_SUPPORT_ENABLE
|
2019-07-23 05:22:33 +02:00
|
|
|
# undef LOCKING_SUPPORT_ENABLE
|
2019-05-07 07:34:09 +02:00
|
|
|
#endif
|
|
|
|
#ifdef LOCKING_RESYNC_ENABLE
|
2019-07-23 05:22:33 +02:00
|
|
|
# undef LOCKING_RESYNC_ENABLE
|
2019-05-07 07:34:09 +02:00
|
|
|
#endif
|
2021-02-23 19:57:24 +01:00
|
|
|
|
|
|
|
#ifdef CONVERT_TO_PROTON_C
|
|
|
|
// pins that are available but not present on Pro Micro
|
2022-07-03 04:55:46 +02:00
|
|
|
# define A3 PAL_LINE(GPIOA, 3)
|
|
|
|
# define A4 PAL_LINE(GPIOA, 4)
|
|
|
|
# define A5 PAL_LINE(GPIOA, 5)
|
|
|
|
# define A6 PAL_LINE(GPIOA, 6)
|
|
|
|
# define A7 PAL_LINE(GPIOA, 7)
|
|
|
|
# define A8 PAL_LINE(GPIOA, 8)
|
2021-02-23 19:57:24 +01:00
|
|
|
# define A13 PAL_LINE(GPIOA, 13)
|
|
|
|
# define A14 PAL_LINE(GPIOA, 14)
|
|
|
|
# define A15 PAL_LINE(GPIOA, 15)
|
|
|
|
# define B10 PAL_LINE(GPIOB, 10)
|
|
|
|
# define B11 PAL_LINE(GPIOB, 11)
|
|
|
|
# define B12 PAL_LINE(GPIOB, 12)
|
|
|
|
# define C13 PAL_LINE(GPIOC, 13)
|
|
|
|
# define C14 PAL_LINE(GPIOC, 14)
|
|
|
|
# define C15 PAL_LINE(GPIOC, 15)
|
|
|
|
#endif
|
2022-01-22 04:36:52 +01:00
|
|
|
|
2022-05-31 07:02:55 +02:00
|
|
|
|
|
|
|
#define ENABLE_COMPILE_KEYCODE
|
|
|
|
|
|
|
|
#define BOTH_SHIFTS_TURNS_ON_CAPS_WORD
|