diff options
Diffstat (limited to 'keyboards/rgbkb/sol3/rev1')
-rw-r--r-- | keyboards/rgbkb/sol3/rev1/info.json | 15 | ||||
-rw-r--r-- | keyboards/rgbkb/sol3/rev1/rev1.c | 13 |
2 files changed, 18 insertions, 10 deletions
diff --git a/keyboards/rgbkb/sol3/rev1/info.json b/keyboards/rgbkb/sol3/rev1/info.json index 046a56f390..77116bb733 100644 --- a/keyboards/rgbkb/sol3/rev1/info.json +++ b/keyboards/rgbkb/sol3/rev1/info.json @@ -8,6 +8,15 @@ "pid": "0x3510", "device_version": "0.0.1" }, + "ws2812": { + "pin": "B5", + "driver": "pwm" + }, + "matrix_pins": { + "cols": ["A6", "A7", "B0", "B2", "B1", "B9", "B3", "B4"], + "rows": ["B15", "A8", "A15", "B12", "A3", null] + }, + "diode_direction": "COL2ROW", "encoder": { "rotary": [ {"pin_a": "A1", "pin_b": "A2"}, @@ -25,6 +34,12 @@ {"pin_a": "B3", "pin_b": "B13"} ] } + }, + "matrix_pins": { + "right": { + "cols": ["B9", "B8", "B4", "A6", "A3", "B10", "B12", "B11"], + "rows": ["B15", "B14", "A8", "A13", "A7", null] + } } }, "processor": "STM32F303", diff --git a/keyboards/rgbkb/sol3/rev1/rev1.c b/keyboards/rgbkb/sol3/rev1/rev1.c index de5836e061..ff330a83d6 100644 --- a/keyboards/rgbkb/sol3/rev1/rev1.c +++ b/keyboards/rgbkb/sol3/rev1/rev1.c @@ -57,10 +57,7 @@ bool dip_switch_update_kb(uint8_t index, bool active) { } case 1: { // Handle RGB Encoder switch press - action_exec((keyevent_t){ - .key = (keypos_t){.row = isLeftHand ? 4 : 10, .col = 6}, - .pressed = active, .time = (timer_read() | 1) /* time should not be 0 */ - }); + action_exec(MAKE_KEYEVENT(isLeftHand ? 4 : 10, 6, active)); break; } } @@ -68,15 +65,11 @@ bool dip_switch_update_kb(uint8_t index, bool active) { } static void process_encoder_matrix(encodermap_t pos) { - action_exec((keyevent_t){ - .key = (keypos_t){.row = pos.r, .col = pos.c}, .pressed = true, .time = (timer_read() | 1) /* time should not be 0 */ - }); + action_exec(MAKE_KEYEVENT(pos.r, pos.c, true)); #if TAP_CODE_DELAY > 0 wait_ms(TAP_CODE_DELAY); #endif - action_exec((keyevent_t){ - .key = (keypos_t){.row = pos.r, .col = pos.c}, .pressed = false, .time = (timer_read() | 1) /* time should not be 0 */ - }); + action_exec(MAKE_KEYEVENT(pos.r, pos.c, false)); } bool encoder_update_kb(uint8_t index, bool clockwise) { |