Skip to content

Instantly share code, notes, and snippets.

@001SPARTaN
Created June 3, 2022 15:32
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 001SPARTaN/0accbb6ddb52021d31ea6ee3541f18b6 to your computer and use it in GitHub Desktop.
Save 001SPARTaN/0accbb6ddb52021d31ea6ee3541f18b6 to your computer and use it in GitHub Desktop.
Vial port for Sol 3. Place these in vial-qmk/keyboards/rgbkb/sol3/keymaps/vial and run `make rgbkb/sol3:vial`.
/*
* ----------------------------------------------------------------------------
* "THE BEER-WARE LICENSE" (Revision 42):
* <https://github.com/Legonut> wrote this file. As long as you retain this
* notice you can do whatever you want with this stuff. If we meet some day, and
* you think this stuff is worth it, you can buy me a beer in return. David Rauseo
* ----------------------------------------------------------------------------
*/
#pragma once
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
#define RGB_MATRIX_KEYPRESSES
// 20m timeout (20m * 60s * 1000mil)
#define RGB_DISABLE_TIMEOUT 1800000
#define RGB_DISABLE_WHEN_USB_SUSPENDED
#define STM32_ONBOARD_EEPROM_SIZE 2048
#define VIAL_KEYBOARD_UID {0x65, 0xA0, 0x5D, 0x37, 0xDA, 0x13, 0x6E, 0x3F}
/* RGB LED Configuration */
#define RGB_DI_PIN B5
#define RGBLED_NUM 156
#define RGBLED_SPLIT { 78, 78 }
#define RGBLIGHT_LIMIT_VAL 255
// RGB Lighting Animation modes. Explicitly enabled
// For full list of effects, see:
// https://docs.qmk.fm/#/feature_rgblight?id=effect-and-animation-toggles
#define RGBLIGHT_EFFECT_BREATHING
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
#define RGBLIGHT_EFFECT_RAINBOW_SWIRL
#define RGBLIGHT_EFFECT_SNAKE
#define RGBLIGHT_EFFECT_KNIGHT
#define RGBLIGHT_EFFECT_CHRISTMAS
#define RGBLIGHT_EFFECT_STATIC_GRADIENT
#define RGBLIGHT_EFFECT_RGB_TEST
#define RGBLIGHT_EFFECT_ALTERNATING
#define RGBLIGHT_EFFECT_TWINKLE
#define DRIVER_LED_TOTAL RGBLED_NUM
#define RGB_MATRIX_SPLIT RGBLED_SPLIT
#define RGB_MATRIX_CENTER { 81, 28 }
#define RGB_MATRIX_MAXIMUM_BRIGHTNESS RGBLIGHT_LIMIT_VAL
#define RGB_MATRIX_LED_FLUSH_LIMIT 33
#define RGB_MATRIX_LED_PROCESS_LIMIT 10
#define RGB_DISABLE_WHEN_USB_SUSPENDED
// RGB Matrix Animation modes. Explicitly enabled
// For full list of effects, see:
// https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects
#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_CYCLE_OUT_IN
#define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
#define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL
#define ENABLE_RGB_MATRIX_CYCLE_SPIRAL
#define ENABLE_RGB_MATRIX_DUAL_BEACON
#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_HUE_BREATHING
#define ENABLE_RGB_MATRIX_HUE_PENDULUM
#define ENABLE_RGB_MATRIX_HUE_WAVE
#define ENABLE_RGB_MATRIX_PIXEL_RAIN
#define ENABLE_RGB_MATRIX_PIXEL_FLOW
#define ENABLE_RGB_MATRIX_PIXEL_FRACTAL
// enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
#define ENABLE_RGB_MATRIX_TYPING_HEATMAP
#define ENABLE_RGB_MATRIX_DIGITAL_RAIN
// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined
#define RGB_MATRIX_KEYPRESSES
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
#define ENABLE_RGB_MATRIX_SOLID_REACTIVE
#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
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
VIA_ENABLE = yes
VIAL_ENABLE = yes
VIAL_INSECURE = yes
VIALRGB_ENABLE = yes
# MCU name
MCU = STM32F303
# Bootloader selection
BOOTLOADER = stm32-dfu
# Touch encoder needs
VPATH += keyboards/rgbkb/common
SRC += touch_encoder.c
SRC += common_oled.c
QUANTUM_LIB_SRC += i2c_master.c
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite
MOUSEKEY_ENABLE = no # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = no # Commands for debug and configuration
NKRO_ENABLE = yes # Enable N-Key Rollover
AUDIO_ENABLE = yes # Audio output
AUDIO_DRIVER = dac_additive
DYNAMIC_MACRO_ENABLE = yes
DIP_SWITCH_ENABLE = yes
WS2812_DRIVER = pwm
RGBLIGHT_ENABLE = no
RGB_MATRIX_ENABLE = yes
RGB_MATRIX_DRIVER = WS2812
OLED_ENABLE = yes
OLED_DRIVER = SSD1306 # Enable the OLED Driver
ENCODER_ENABLE = yes
SPLIT_KEYBOARD = yes
SERIAL_DRIVER = usart
LTO_ENABLE = yes
OPT = 3
OPT_DEFS += -DOLED_FONT_H=\"keyboards/rgbkb/common/glcdfont.c\"
{
"lighting": "vialrgb",
"matrix": {
"rows": 12,
"cols": 8
},
"layouts": {
"keymap":
[
[
{
"w": 1.5
},
"0,0",
"0,1",
"0,2",
"0,3",
"0,4",
"0,5",
"0,6",
{
"x": 4.5
},
"6,6",
"6,5",
"6,4",
"6,3",
"6,2",
"6,1",
{
"w": 1.5
},
"6,0"
],
[
{
"w": 1.5
},
"1,0",
"1,1",
"1,2",
"1,3",
"1,4",
"1,5",
"1,6",
{
"x": 4.5
},
"7,6",
"7,5",
"7,4",
"7,3",
"7,2",
"7,1",
{
"w": 1.5
},
"7,0"
],
[
{
"w": 1.5
},
"2,0",
"2,1",
"2,2",
"2,3",
"2,4",
"2,5",
"2,6",
{
"x": 4.5
},
"8,6",
"8,5",
"8,4",
"8,3",
"8,2",
"8,1",
{
"w": 1.5
},
"8,0"
],
[
{
"w": 1.5
},
"3,0",
"3,1",
"3,2",
"3,3",
"3,4",
"3,5",
"3,6",
{
"x": 4.5
},
"9,6",
"9,5",
"9,4",
"9,3",
"9,2",
"9,1",
{
"w": 1.5
},
"9,0"
],
[
{
"w": 1.5
},
"4,0",
"4,1",
"4,2",
"4,3",
"4,4",
{
"x": 8.5
},
"10,4",
"10,3",
"10,2",
"10,1",
{
"w": 1.5
},
"10,0"
],
[
{
"r": 30,
"rx": 6.5,
"ry": 4.25,
"x": 1,
"h": 2
},
"4,5",
"4,6"
],
[
{
"x": 2
},
"4,7"
],
[
{
"r": -30,
"rx": 13,
"x": -3
},
"10,6",
{
"h": 2
},
"10,5"
],
[
{
"x": -3
},
"10,7"
]
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment