157 lines
5.5 KiB
C
157 lines
5.5 KiB
C
/*
|
|
Copyright 2021 Sadek Baroudi <sadekbaroudi@gmail.com>
|
|
|
|
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 <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
/* key matrix size */
|
|
#define MATRIX_ROWS 9
|
|
#define MATRIX_COLS 8
|
|
|
|
// SHIFT REGISTER
|
|
// Only needed for matrix_74hc595_spi.c
|
|
#define SHIFTREG_MATRIX_COL_CS GP21
|
|
#define SHIFTREG_DIVISOR 8
|
|
#define MATRIX_ROW_PINS_SR { GP4, GP5, GP6, GP8, GP24, GP11, GP0, GP10, GP7 }
|
|
|
|
// SPI config for shift register
|
|
#define SPI_DRIVER SPID0
|
|
#define SPI_SCK_PIN GP22
|
|
#define SPI_MOSI_PIN GP23
|
|
#define SPI_MISO_PIN GP20
|
|
|
|
// VIK pin config
|
|
#define VIK_SPI_DRIVER SPID0
|
|
#define VIK_SPI_SCK_PIN GP22
|
|
#define VIK_SPI_MOSI_PIN GP23
|
|
#define VIK_SPI_MISO_PIN GP20
|
|
#define VIK_SPI_CS GP9
|
|
#define VIK_I2C_DRIVER I2CD1
|
|
#define VIK_I2C_SDA_PIN GP2
|
|
#define VIK_I2C_SCL_PIN GP3
|
|
#define VIK_GPIO_1 GP26
|
|
#define VIK_GPIO_2 GP27
|
|
#define VIK_WS2812_DI_PIN GP25
|
|
|
|
/* COL2ROW, ROW2COL*/
|
|
#define DIODE_DIRECTION COL2ROW
|
|
|
|
/* encoder config */
|
|
#define ENCODERS_PAD_A {GP1, GP13}
|
|
#define ENCODERS_PAD_B {GP14, GP12}
|
|
#define ENCODER_RESOLUTION 2
|
|
|
|
#define WS2812_DI_PIN GP25
|
|
#ifdef RGBLIGHT_ENABLE
|
|
#define RGBLIGHT_LED_COUNT 66
|
|
#define RGBLIGHT_HUE_STEP 16
|
|
#define RGBLIGHT_SAT_STEP 16
|
|
#define RGBLIGHT_VAL_STEP 16
|
|
#define RGBLIGHT_LIMIT_VAL 100 /* The maximum brightness level for RGBLIGHT_ENABLE */
|
|
#define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
|
|
#define RGBLIGHT_EFFECT_ALTERNATING
|
|
#define RGBLIGHT_EFFECT_BREATHING
|
|
#define RGBLIGHT_EFFECT_CHRISTMAS
|
|
#define RGBLIGHT_EFFECT_KNIGHT
|
|
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
|
|
#define RGBLIGHT_EFFECT_RAINBOW_SWIRL
|
|
#define RGBLIGHT_EFFECT_SNAKE
|
|
#define RGBLIGHT_EFFECT_STATIC_GRADIENT
|
|
#define RGBLIGHT_EFFECT_TWINKLE
|
|
#endif
|
|
|
|
#ifdef RGB_MATRIX_ENABLE
|
|
#define RGB_MATRIX_LED_COUNT 66
|
|
#define RGB_MATRIX_CENTER {100, 32}
|
|
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 100 /* The maximum brightness level for RGB_MATRIX */
|
|
#define RGB_MATRIX_STARTUP_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS // Sets the default brightness value, if none has been set
|
|
#define RGB_MATRIX_KEYPRESSES
|
|
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
|
|
#define RGB_MATRIX_KEYREACTIVE_ENABLED
|
|
#define ENABLE_RGB_MATRIX_ALPHAS_MODS
|
|
#define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN
|
|
#define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
|
|
#define ENABLE_RGB_MATRIX_BREATHING
|
|
#define ENABLE_RGB_MATRIX_BAND_SAT
|
|
#define ENABLE_RGB_MATRIX_BAND_VAL
|
|
#define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
|
|
#define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
|
|
#define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT
|
|
#define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL
|
|
#define ENABLE_RGB_MATRIX_CYCLE_ALL
|
|
#define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
|
|
#define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN
|
|
#define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
|
|
#define ENABLE_RGB_MATRIX_DUAL_BEACON
|
|
#define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL
|
|
#define ENABLE_RGB_MATRIX_CYCLE_SPIRAL
|
|
#define ENABLE_RGB_MATRIX_RAINBOW_BEACON
|
|
#define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS
|
|
#define ENABLE_RGB_MATRIX_RAINDROPS
|
|
#define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
|
|
#define ENABLE_RGB_MATRIX_DIGITAL_RAIN
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
|
|
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
|
|
#define ENABLE_RGB_MATRIX_SPLASH
|
|
#define ENABLE_RGB_MATRIX_MULTISPLASH
|
|
#define ENABLE_RGB_MATRIX_SOLID_SPLASH
|
|
#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
|
|
#endif
|
|
|
|
#ifdef AUDIO_ENABLE
|
|
#define AUDIO_VOICES
|
|
#define AUDIO_PIN GP18
|
|
#define AUDIO_PWM_DRIVER PWMD1
|
|
#define AUDIO_PWM_CHANNEL RP2040_PWM_CHANNEL_A
|
|
// #define AUDIO_PWM_PAL_MODE 42 // only if using AUDIO_DRIVER = pwm_hardware
|
|
// #define NO_MUSIC_MODE
|
|
#define AUDIO_ENABLE_TONE_MULTIPLEXING
|
|
#define AUDIO_TONE_MULTIPLEXING_RATE_DEFAULT 10
|
|
#define FP_AUDIO_MOUSE_BUTTONS
|
|
#define FP_AUDIO_CUT_COPY_PASTE
|
|
#define FP_AUDIO_SAVE
|
|
#define FP_STARTUP_LIGHT_EXT HALF_NOTE(_E6), HALF_NOTE(_F6), HALF_NOTE(_C6), WHOLE_NOTE(_A5), WHOLE_DOT_NOTE(_F5), WHOLE_DOT_NOTE(_D5), WHOLE_DOT_NOTE(_G5), WHOLE_DOT_NOTE(_C5),
|
|
#define STARTUP_SONG SONG(FP_STARTUP_LIGHT_EXT)
|
|
#define DEFAULT_LAYER_SONGS \
|
|
{ SONG(QWERTY_SOUND), SONG(COLEMAK_SOUND) }
|
|
#endif
|
|
|
|
#ifdef HAPTIC_ENABLE
|
|
#define FB_ERM_LRA 1
|
|
#define FB_BRAKEFACTOR 3 // For 1x:0, 2x:1, 3x:2, 4x:3, 6x:4, 8x:5, 16x:6, Disable Braking:7
|
|
#define FB_LOOPGAIN 1 // For Low:0, Medium:1, High:2, Very High:3
|
|
#define RATED_VOLTAGE 2
|
|
#define V_PEAK 2.8
|
|
#define V_RMS 2.0
|
|
#define F_LRA 150 // resonance freq
|
|
#define DRV_GREETING alert_750ms
|
|
#define FP_HAPTIC_MOUSE_BUTTONS
|
|
#define FP_HAPTIC_CUT_COPY_PASTE
|
|
#define FP_HAPTIC_SAVE
|
|
#endif
|
|
|
|
#ifdef VIK_PMW3360
|
|
#define POINTING_DEVICE_INVERT_Y
|
|
#endif
|
|
|
|
#include "keyboards/fingerpunch/src/config_post.h"
|