diff options
Diffstat (limited to 'keyboards/annepro2')
-rw-r--r-- | keyboards/annepro2/annepro2_ble.h | 1 | ||||
-rw-r--r-- | keyboards/annepro2/c15/config.h | 15 | ||||
-rw-r--r-- | keyboards/annepro2/c15/info.json | 125 | ||||
-rw-r--r-- | keyboards/annepro2/c15/rules.mk | 17 | ||||
-rw-r--r-- | keyboards/annepro2/c18/config.h | 13 | ||||
-rw-r--r-- | keyboards/annepro2/c18/info.json | 125 | ||||
-rw-r--r-- | keyboards/annepro2/c18/rules.mk | 17 | ||||
-rw-r--r-- | keyboards/annepro2/info.json | 129 | ||||
-rw-r--r-- | keyboards/annepro2/keymaps/default-full-caps/keymap.c | 4 | ||||
-rw-r--r-- | keyboards/annepro2/keymaps/default-layer-indicators/keymap.c | 4 | ||||
-rw-r--r-- | keyboards/annepro2/keymaps/default/keymap.c | 4 | ||||
-rw-r--r-- | keyboards/annepro2/keymaps/iso_default/keymap.c | 8 | ||||
-rw-r--r-- | keyboards/annepro2/matrix.c | 63 |
13 files changed, 149 insertions, 376 deletions
diff --git a/keyboards/annepro2/annepro2_ble.h b/keyboards/annepro2/annepro2_ble.h index 0cfb68e071..37dd6d31a1 100644 --- a/keyboards/annepro2/annepro2_ble.h +++ b/keyboards/annepro2/annepro2_ble.h @@ -17,7 +17,6 @@ #pragma once #include "annepro2.h" -#include "quantum.h" void annepro2_ble_bootload(void); void annepro2_ble_startup(void); diff --git a/keyboards/annepro2/c15/config.h b/keyboards/annepro2/c15/config.h index 9ffce91957..9745cf50cc 100644 --- a/keyboards/annepro2/c15/config.h +++ b/keyboards/annepro2/c15/config.h @@ -19,27 +19,12 @@ #include "pin_defs.h" -// key matrix size -#define MATRIX_ROWS 5 -#define MATRIX_COLS 14 -// layer size: MATRIX_ROWS * MATRIX_COLS * sizeof(uint16_t) = 140 bytes - #define LINE_UART_TX B0 // Master TX, LED RX #define LINE_UART_RX B1 // Master RX, LED TX #define LINE_BT_UART_TX A4 // Master TX, BLE RX #define LINE_BT_UART_RX A5 // Master RX, BLE TX -// outputs (rows are pulled low) -#define MATRIX_ROW_PINS \ - { C2, C1, B5, B4, C3 } - -// inputs (columns are sampled) -// PORTA 12,13 conflict with SWD - -#define MATRIX_COL_PINS \ - { C4, C5, B10, B11, C0, A15, A8, A10, A11, A12, A13, A14, B2, B3 } - // Obins stock firmware has something similar to this already enabled, but disabled by default in QMK #define PERMISSIVE_HOLD diff --git a/keyboards/annepro2/c15/info.json b/keyboards/annepro2/c15/info.json index b92b446e4e..0f738c0999 100644 --- a/keyboards/annepro2/c15/info.json +++ b/keyboards/annepro2/c15/info.json @@ -3,124 +3,9 @@ "usb": { "pid": "0x8008" }, - "eeprom": { - "driver": "wear_leveling", - "wear_leveling": { - "driver": "spi_flash", - "backing_size": 2048 - } - }, - "rgb_matrix": { - "animations":{ - "alphas_mods": true, - "gradient_up_down": true, - "gradient_left_right": true, - "breathing": true, - "band_sat": true, - "band_val": true, - "band_pinwheel_sat": true, - "band_pinwheel_val": true, - "band_spiral_sat": true, - "band_spiral_val": true, - "cycle_all": true, - "cycle_left_right": true, - "cycle_up_down": true, - "rainbow_moving_chevron": true, - "cycle_out_in": true, - "cycle_out_in_dual": true, - "cycle_pinwheel": true, - "cycle_spiral": true, - "dual_beacon": true, - "rainbow_beacon": true, - "rainbow_pinwheels": true, - "raindrops": true, - "jellybean_raindrops": true, - "hue_breathing": true, - "hue_pendulum": true, - "hue_wave": true, - "pixel_fractal": true, - "pixel_flow": true, - "pixel_rain": true, - "typing_heatmap": true, - "digital_rain": true, - "solid_reactive_simple": true, - "solid_reactive": true, - "solid_reactive_wide": true, - "solid_reactive_multiwide": true, - "solid_reactive_cross": true, - "solid_reactive_multicross": true, - "solid_reactive_nexus": true, - "solid_reactive_multinexus": true, - "splash": true, - "multisplash": true, - "solid_splash": true, - "solid_multisplash": true - }, - "driver": "custom", - "layout": [ - {"matrix": [0, 0], "x": 0, "y": 0, "flags": 4}, - {"matrix": [0, 1], "x": 16, "y": 0, "flags": 4}, - {"matrix": [0, 2], "x": 32, "y": 0, "flags": 4}, - {"matrix": [0, 3], "x": 48, "y": 0, "flags": 4}, - {"matrix": [0, 4], "x": 65, "y": 0, "flags": 4}, - {"matrix": [0, 5], "x": 81, "y": 0, "flags": 4}, - {"matrix": [0, 6], "x": 97, "y": 0, "flags": 4}, - {"matrix": [0, 7], "x": 113, "y": 0, "flags": 4}, - {"matrix": [0, 8], "x": 129, "y": 0, "flags": 4}, - {"matrix": [0, 9], "x": 145, "y": 0, "flags": 4}, - {"matrix": [0, 10], "x": 161, "y": 0, "flags": 4}, - {"matrix": [0, 11], "x": 178, "y": 0, "flags": 4}, - {"matrix": [0, 12], "x": 194, "y": 0, "flags": 4}, - {"matrix": [0, 13], "x": 218, "y": 0, "flags": 4}, - {"matrix": [1, 0], "x": 4, "y": 16, "flags": 4}, - {"matrix": [1, 1], "x": 24, "y": 16, "flags": 4}, - {"matrix": [1, 2], "x": 40, "y": 16, "flags": 4}, - {"matrix": [1, 3], "x": 57, "y": 16, "flags": 4}, - {"matrix": [1, 4], "x": 73, "y": 16, "flags": 4}, - {"matrix": [1, 5], "x": 89, "y": 16, "flags": 4}, - {"matrix": [1, 6], "x": 105, "y": 16, "flags": 4}, - {"matrix": [1, 7], "x": 121, "y": 16, "flags": 4}, - {"matrix": [1, 8], "x": 137, "y": 16, "flags": 4}, - {"matrix": [1, 9], "x": 153, "y": 16, "flags": 4}, - {"matrix": [1, 10], "x": 170, "y": 16, "flags": 4}, - {"matrix": [1, 11], "x": 186, "y": 16, "flags": 4}, - {"matrix": [1, 12], "x": 202, "y": 16, "flags": 4}, - {"matrix": [1, 13], "x": 222, "y": 16, "flags": 4}, - {"matrix": [2, 0], "x": 6, "y": 32, "flags": 4}, - {"matrix": [2, 1], "x": 28, "y": 32, "flags": 4}, - {"matrix": [2, 2], "x": 44, "y": 32, "flags": 4}, - {"matrix": [2, 3], "x": 61, "y": 32, "flags": 4}, - {"matrix": [2, 4], "x": 77, "y": 32, "flags": 4}, - {"matrix": [2, 5], "x": 93, "y": 32, "flags": 4}, - {"matrix": [2, 6], "x": 109, "y": 32, "flags": 4}, - {"matrix": [2, 7], "x": 125, "y": 32, "flags": 4}, - {"matrix": [2, 8], "x": 141, "y": 32, "flags": 4}, - {"matrix": [2, 9], "x": 157, "y": 32, "flags": 4}, - {"matrix": [2, 10], "x": 174, "y": 32, "flags": 4}, - {"matrix": [2, 11], "x": 190, "y": 32, "flags": 4}, - {"matrix": [2, 12], "x": 216, "y": 32, "flags": 4}, - {"matrix": [3, 0], "x": 10, "y": 48, "flags": 1}, - {"matrix": [3, 2], "x": 36, "y": 48, "flags": 4}, - {"matrix": [3, 3], "x": 52, "y": 48, "flags": 4}, - {"matrix": [3, 4], "x": 69, "y": 48, "flags": 4}, - {"matrix": [3, 5], "x": 85, "y": 48, "flags": 4}, - {"matrix": [3, 6], "x": 101, "y": 48, "flags": 4}, - {"matrix": [3, 7], "x": 117, "y": 48, "flags": 4}, - {"matrix": [3, 8], "x": 133, "y": 48, "flags": 4}, - {"matrix": [3, 9], "x": 149, "y": 48, "flags": 4}, - {"matrix": [3, 10], "x": 165, "y": 48, "flags": 4}, - {"matrix": [3, 11], "x": 182, "y": 48, "flags": 4}, - {"matrix": [3, 12], "x": 212, "y": 48, "flags": 1}, - {"matrix": [4, 0], "x": 2, "y": 64, "flags": 1}, - {"matrix": [4, 2], "x": 22, "y": 64, "flags": 1}, - {"matrix": [4, 3], "x": 42, "y": 64, "flags": 1}, - {"matrix": [4, 6], "x": 103, "y": 64, "flags": 4}, - {"matrix": [4, 9], "x": 163, "y": 64, "flags": 1}, - {"matrix": [4, 10], "x": 184, "y": 64, "flags": 1}, - {"matrix": [4, 11], "x": 204, "y": 64, "flags": 1}, - {"matrix": [4, 12], "x": 224, "y": 64, "flags": 1} - ], - "led_flush_limit": 40 - }, - "community_layouts": ["60_ansi"] + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["C4", "C5", "B10", "B11", "C0", "A15", "A8", "A10", "A11", "A12", "A13", "A14", "B2", "B3"], + "rows": ["C2", "C1", "B5", "B4", "C3"] + } } diff --git a/keyboards/annepro2/c15/rules.mk b/keyboards/annepro2/c15/rules.mk index 374d844338..f35d9002ef 100644 --- a/keyboards/annepro2/c15/rules.mk +++ b/keyboards/annepro2/c15/rules.mk @@ -13,25 +13,8 @@ BOARD = ANNEPRO2_C15 BOOTLOADER = custom PROGRAM_CMD = annepro2_tools --boot $(BUILD_DIR)/$(TARGET).bin -# Build Options -# change yes to no to disable -# -BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite -MOUSEKEY_ENABLE = no # Mouse keys -EXTRAKEY_ENABLE = yes # Audio control and System control -CONSOLE_ENABLE = no # Console for debug -COMMAND_ENABLE = no # Commands for debug and configuration -NKRO_ENABLE = no # Enable N-Key Rollover - -# Custom RGB matrix handling -RGB_MATRIX_ENABLE = yes - -# Keys -CUSTOM_MATRIX = lite - # Anne Pro 2 SRC = \ - matrix.c \ annepro2_ble.c \ ap2_led.c \ protocol.c \ diff --git a/keyboards/annepro2/c18/config.h b/keyboards/annepro2/c18/config.h index 7010f19a3f..dfc550160c 100644 --- a/keyboards/annepro2/c18/config.h +++ b/keyboards/annepro2/c18/config.h @@ -19,25 +19,12 @@ #include "pin_defs.h" -// key matrix size -#define MATRIX_ROWS 5 -#define MATRIX_COLS 14 -// layer size: MATRIX_ROWS * MATRIX_COLS * sizeof(uint16_t) = 140 bytes - #define LINE_UART_TX B0 #define LINE_UART_RX B1 #define LINE_BT_UART_TX A4 // Master TX, BLE RX #define LINE_BT_UART_RX A5 // Master RX, BLE TX -// outputs (rows are pulled low) -#define MATRIX_ROW_PINS \ - { B5, B4, B3, B2, D1 } - -// inputs (columns are sampled) -#define MATRIX_COL_PINS \ - { C4, C5, D0, B15, C11, A15, C12, C13, A8, A10, A11, A14, D2, D3 } - // Obins stock firmware has something similar to this already enabled, but disabled by default in QMK #define PERMISSIVE_HOLD diff --git a/keyboards/annepro2/c18/info.json b/keyboards/annepro2/c18/info.json index 390dd81941..b3f3d367fe 100644 --- a/keyboards/annepro2/c18/info.json +++ b/keyboards/annepro2/c18/info.json @@ -3,124 +3,9 @@ "usb": { "pid": "0x8009" }, - "eeprom": { - "driver": "wear_leveling", - "wear_leveling": { - "driver": "spi_flash", - "backing_size": 2048 - } - }, - "rgb_matrix": { - "animations":{ - "alphas_mods": true, - "gradient_up_down": true, - "gradient_left_right": true, - "breathing": true, - "band_sat": true, - "band_val": true, - "band_pinwheel_sat": true, - "band_pinwheel_val": true, - "band_spiral_sat": true, - "band_spiral_val": true, - "cycle_all": true, - "cycle_left_right": true, - "cycle_up_down": true, - "rainbow_moving_chevron": true, - "cycle_out_in": true, - "cycle_out_in_dual": true, - "cycle_pinwheel": true, - "cycle_spiral": true, - "dual_beacon": true, - "rainbow_beacon": true, - "rainbow_pinwheels": true, - "raindrops": true, - "jellybean_raindrops": true, - "hue_breathing": true, - "hue_pendulum": true, - "hue_wave": true, - "pixel_fractal": true, - "pixel_flow": true, - "pixel_rain": true, - "typing_heatmap": true, - "digital_rain": true, - "solid_reactive_simple": true, - "solid_reactive": true, - "solid_reactive_wide": true, - "solid_reactive_multiwide": true, - "solid_reactive_cross": true, - "solid_reactive_multicross": true, - "solid_reactive_nexus": true, - "solid_reactive_multinexus": true, - "splash": true, - "multisplash": true, - "solid_splash": true, - "solid_multisplash": true - }, - "driver": "custom", - "layout": [ - {"matrix": [0, 0], "x": 0, "y": 0, "flags": 4}, - {"matrix": [0, 1], "x": 16, "y": 0, "flags": 4}, - {"matrix": [0, 2], "x": 32, "y": 0, "flags": 4}, - {"matrix": [0, 3], "x": 48, "y": 0, "flags": 4}, - {"matrix": [0, 4], "x": 65, "y": 0, "flags": 4}, - {"matrix": [0, 5], "x": 81, "y": 0, "flags": 4}, - {"matrix": [0, 6], "x": 97, "y": 0, "flags": 4}, - {"matrix": [0, 7], "x": 113, "y": 0, "flags": 4}, - {"matrix": [0, 8], "x": 129, "y": 0, "flags": 4}, - {"matrix": [0, 9], "x": 145, "y": 0, "flags": 4}, - {"matrix": [0, 10], "x": 161, "y": 0, "flags": 4}, - {"matrix": [0, 11], "x": 178, "y": 0, "flags": 4}, - {"matrix": [0, 12], "x": 194, "y": 0, "flags": 4}, - {"matrix": [0, 13], "x": 218, "y": 0, "flags": 4}, - {"matrix": [1, 0], "x": 4, "y": 16, "flags": 4}, - {"matrix": [1, 1], "x": 24, "y": 16, "flags": 4}, - {"matrix": [1, 2], "x": 40, "y": 16, "flags": 4}, - {"matrix": [1, 3], "x": 57, "y": 16, "flags": 4}, - {"matrix": [1, 4], "x": 73, "y": 16, "flags": 4}, - {"matrix": [1, 5], "x": 89, "y": 16, "flags": 4}, - {"matrix": [1, 6], "x": 105, "y": 16, "flags": 4}, - {"matrix": [1, 7], "x": 121, "y": 16, "flags": 4}, - {"matrix": [1, 8], "x": 137, "y": 16, "flags": 4}, - {"matrix": [1, 9], "x": 153, "y": 16, "flags": 4}, - {"matrix": [1, 10], "x": 170, "y": 16, "flags": 4}, - {"matrix": [1, 11], "x": 186, "y": 16, "flags": 4}, - {"matrix": [1, 12], "x": 202, "y": 16, "flags": 4}, - {"matrix": [1, 13], "x": 222, "y": 16, "flags": 4}, - {"matrix": [2, 0], "x": 6, "y": 32, "flags": 4}, - {"matrix": [2, 1], "x": 28, "y": 32, "flags": 4}, - {"matrix": [2, 2], "x": 44, "y": 32, "flags": 4}, - {"matrix": [2, 3], "x": 61, "y": 32, "flags": 4}, - {"matrix": [2, 4], "x": 77, "y": 32, "flags": 4}, - {"matrix": [2, 5], "x": 93, "y": 32, "flags": 4}, - {"matrix": [2, 6], "x": 109, "y": 32, "flags": 4}, - {"matrix": [2, 7], "x": 125, "y": 32, "flags": 4}, - {"matrix": [2, 8], "x": 141, "y": 32, "flags": 4}, - {"matrix": [2, 9], "x": 157, "y": 32, "flags": 4}, - {"matrix": [2, 10], "x": 174, "y": 32, "flags": 4}, - {"matrix": [2, 11], "x": 190, "y": 32, "flags": 4}, - {"matrix": [2, 12], "x": 216, "y": 32, "flags": 4}, - {"matrix": [3, 0], "x": 10, "y": 48, "flags": 1}, - {"matrix": [3, 2], "x": 36, "y": 48, "flags": 4}, - {"matrix": [3, 3], "x": 52, "y": 48, "flags": 4}, - {"matrix": [3, 4], "x": 69, "y": 48, "flags": 4}, - {"matrix": [3, 5], "x": 85, "y": 48, "flags": 4}, - {"matrix": [3, 6], "x": 101, "y": 48, "flags": 4}, - {"matrix": [3, 7], "x": 117, "y": 48, "flags": 4}, - {"matrix": [3, 8], "x": 133, "y": 48, "flags": 4}, - {"matrix": [3, 9], "x": 149, "y": 48, "flags": 4}, - {"matrix": [3, 10], "x": 165, "y": 48, "flags": 4}, - {"matrix": [3, 11], "x": 182, "y": 48, "flags": 4}, - {"matrix": [3, 12], "x": 212, "y": 48, "flags": 1}, - {"matrix": [4, 0], "x": 2, "y": 64, "flags": 1}, - {"matrix": [4, 2], "x": 22, "y": 64, "flags": 1}, - {"matrix": [4, 3], "x": 42, "y": 64, "flags": 1}, - {"matrix": [4, 6], "x": 103, "y": 64, "flags": 4}, - {"matrix": [4, 9], "x": 163, "y": 64, "flags": 1}, - {"matrix": [4, 10], "x": 184, "y": 64, "flags": 1}, - {"matrix": [4, 11], "x": 204, "y": 64, "flags": 1}, - {"matrix": [4, 12], "x": 224, "y": 64, "flags": 1} - ], - "led_flush_limit": 40 - }, - "community_layouts": ["60_ansi", "60_iso"] + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": ["C4", "C5", "D0", "B15", "C11", "A15", "C12", "C13", "A8", "A10", "A11", "A14", "D2", "D3"], + "rows": ["B5", "B4", "B3", "B2", "D1"] + } } diff --git a/keyboards/annepro2/c18/rules.mk b/keyboards/annepro2/c18/rules.mk index 2c9a9077da..b310454c5d 100644 --- a/keyboards/annepro2/c18/rules.mk +++ b/keyboards/annepro2/c18/rules.mk @@ -13,25 +13,8 @@ BOARD = ANNEPRO2_C18 BOOTLOADER = custom PROGRAM_CMD = annepro2_tools --boot $(BUILD_DIR)/$(TARGET).bin -# 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 = no # Console for debug -COMMAND_ENABLE = no # Commands for debug and configuration -NKRO_ENABLE = no # Enable N-Key Rollover - -# Custom RGB matrix handling -RGB_MATRIX_ENABLE = yes - -# Keys -CUSTOM_MATRIX = lite - # Anne Pro 2 SRC = \ - matrix.c \ annepro2_ble.c \ ap2_led.c \ protocol.c \ diff --git a/keyboards/annepro2/info.json b/keyboards/annepro2/info.json index d06fe5bed4..8c7041005f 100644 --- a/keyboards/annepro2/info.json +++ b/keyboards/annepro2/info.json @@ -6,6 +6,135 @@ "vid": "0xAC20", "device_version": "13.3.7" }, + "build": { + "lto": true + }, + "eeprom": { + "driver": "wear_leveling", + "wear_leveling": { + "driver": "spi_flash", + "backing_size": 2048 + } + }, + "features": { + "bootmagic": true, + "mousekey": true, + "extrakey": true, + "rgb_matrix": true + }, + "rgb_matrix": { + "animations":{ + "alphas_mods": true, + "gradient_up_down": true, + "gradient_left_right": true, + "breathing": true, + "band_sat": true, + "band_val": true, + "band_pinwheel_sat": true, + "band_pinwheel_val": true, + "band_spiral_sat": true, + "band_spiral_val": true, + "cycle_all": true, + "cycle_left_right": true, + "cycle_up_down": true, + "rainbow_moving_chevron": true, + "cycle_out_in": true, + "cycle_out_in_dual": true, + "cycle_pinwheel": true, + "cycle_spiral": true, + "dual_beacon": true, + "rainbow_beacon": true, + "rainbow_pinwheels": true, + "raindrops": true, + "jellybean_raindrops": true, + "hue_breathing": true, + "hue_pendulum": true, + "hue_wave": true, + "pixel_fractal": true, + "pixel_flow": true, + "pixel_rain": true, + "typing_heatmap": true, + "digital_rain": true, + "solid_reactive_simple": true, + "solid_reactive": true, + "solid_reactive_wide": true, + "solid_reactive_multiwide": true, + "solid_reactive_cross": true, + "solid_reactive_multicross": true, + "solid_reactive_nexus": true, + "solid_reactive_multinexus": true, + "splash": true, + "multisplash": true, + "solid_splash": true, + "solid_multisplash": true + }, + "driver": "custom", + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0, "flags": 4}, + {"matrix": [0, 1], "x": 16, "y": 0, "flags": 4}, + {"matrix": [0, 2], "x": 32, "y": 0, "flags": 4}, + {"matrix": [0, 3], "x": 48, "y": 0, "flags": 4}, + {"matrix": [0, 4], "x": 65, "y": 0, "flags": 4}, + {"matrix": [0, 5], "x": 81, "y": 0, "flags": 4}, + {"matrix": [0, 6], "x": 97, "y": 0, "flags": 4}, + {"matrix": [0, 7], "x": 113, "y": 0, "flags": 4}, + {"matrix": [0, 8], "x": 129, "y": 0, "flags": 4}, + {"matrix": [0, 9], "x": 145, "y": 0, "flags": 4}, + {"matrix": [0, 10], "x": 161, "y": 0, "flags": 4}, + {"matrix": [0, 11], "x": 178, "y": 0, "flags": 4}, + {"matrix": [0, 12], "x": 194, "y": 0, "flags": 4}, + {"matrix": [0, 13], "x": 218, "y": 0, "flags": 4}, + {"matrix": [1, 0], "x": 4, "y": 16, "flags": 4}, + {"matrix": [1, 1], "x": 24, "y": 16, "flags": 4}, + {"matrix": [1, 2], "x": 40, "y": 16, "flags": 4}, + {"matrix": [1, 3], "x": 57, "y": 16, "flags": 4}, + {"matrix": [1, 4], "x": 73, "y": 16, "flags": 4}, + {"matrix": [1, 5], "x": 89, "y": 16, "flags": 4}, + {"matrix": [1, 6], "x": 105, "y": 16, "flags": 4}, + {"matrix": [1, 7], "x": 121, "y": 16, "flags": 4}, + {"matrix": [1, 8], "x": 137, "y": 16, "flags": 4}, + {"matrix": [1, 9], "x": 153, "y": 16, "flags": 4}, + {"matrix": [1, 10], "x": 170, "y": 16, "flags": 4}, + {"matrix": [1, 11], "x": 186, "y": 16, "flags": 4}, + {"matrix": [1, 12], "x": 202, "y": 16, "flags": 4}, + {"matrix": [1, 13], "x": 222, "y": 16, "flags": 4}, + {"matrix": [2, 0], "x": 6, "y": 32, "flags": 4}, + {"matrix": [2, 1], "x": 28, "y": 32, "flags": 4}, + {"matrix": [2, 2], "x": 44, "y": 32, "flags": 4}, + {"matrix": [2, 3], "x": 61, "y": 32, "flags": 4}, + {"matrix": [2, 4], "x": 77, "y": 32, "flags": 4}, + {"matrix": [2, 5], "x": 93, "y": 32, "flags": 4}, + {"matrix": [2, 6], "x": 109, "y": 32, "flags": 4}, + {"matrix": [2, 7], "x": 125, "y": 32, "flags": 4}, + {"matrix": [2, 8], "x": 141, "y": 32, "flags": 4}, + {"matrix": [2, 9], "x": 157, "y": 32, "flags": 4}, + {"matrix": [2, 10], "x": 174, "y": 32, "flags": 4}, + {"matrix": [2, 11], "x": 190, "y": 32, "flags": 4}, + {"matrix": [2, 12], "x": 216, "y": 32, "flags": 4}, + {"matrix": [3, 0], "x": 10, "y": 48, "flags": 1}, + {"matrix": [3, 2], "x": 36, "y": 48, "flags": 4}, + {"matrix": [3, 3], "x": 52, "y": 48, "flags": 4}, + {"matrix": [3, 4], "x": 69, "y": 48, "flags": 4}, + {"matrix": [3, 5], "x": 85, "y": 48, "flags": 4}, + {"matrix": [3, 6], "x": 101, "y": 48, "flags": 4}, + {"matrix": [3, 7], "x": 117, "y": 48, "flags": 4}, + {"matrix": [3, 8], "x": 133, "y": 48, "flags": 4}, + {"matrix": [3, 9], "x": 149, "y": 48, "flags": 4}, + {"matrix": [3, 10], "x": 165, "y": 48, "flags": 4}, + {"matrix": [3, 11], "x": 182, "y": 48, "flags": 4}, + {"matrix": [3, 12], "x": 212, "y": 48, "flags": 1}, + {"matrix": [4, 0], "x": 2, "y": 64, "flags": 1}, + {"matrix": [4, 2], "x": 22, "y": 64, "flags": 1}, + {"matrix": [4, 3], "x": 42, "y": 64, "flags": 1}, + {"matrix": [4, 6], "x": 103, "y": 64, "flags": 4}, + {"matrix": [4, 9], "x": 163, "y": 64, "flags": 1}, + {"matrix": [4, 10], "x": 184, "y": 64, "flags": 1}, + {"matrix": [4, 11], "x": 204, "y": 64, "flags": 1}, + {"matrix": [4, 12], "x": 224, "y": 64, "flags": 1} + ], + "led_flush_limit": 40 + }, + "community_layouts": ["60_ansi", "60_iso"], "layouts": { "LAYOUT_60_ansi": { "layout": [ diff --git a/keyboards/annepro2/keymaps/default-full-caps/keymap.c b/keyboards/annepro2/keymaps/default-full-caps/keymap.c index cb6147d40a..7d517a179a 100644 --- a/keyboards/annepro2/keymaps/default-full-caps/keymap.c +++ b/keyboards/annepro2/keymaps/default-full-caps/keymap.c @@ -97,10 +97,10 @@ enum anne_pro_layers { */ [FN2] = LAYOUT_60_ansi( /* FN2 */ _______, KC_AP2_BT1, KC_AP2_BT2, KC_AP2_BT3, KC_AP2_BT4, _______, _______, _______, _______, KC_AP_RGB_MOD, KC_AP_RGB_TOG, KC_AP_RGB_VAD, KC_AP_RGB_VAI, _______, - MO(FN2), _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, _______, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_INS, KC_DEL, _______, - _______, _______, _______, _______, _______, MO(FN1), MO(FN2), _______ + _______, _______, _______, _______, _______, _______, _______, _______ ), }; // clang-format on diff --git a/keyboards/annepro2/keymaps/default-layer-indicators/keymap.c b/keyboards/annepro2/keymaps/default-layer-indicators/keymap.c index ca042dcd32..298f44398b 100644 --- a/keyboards/annepro2/keymaps/default-layer-indicators/keymap.c +++ b/keyboards/annepro2/keymaps/default-layer-indicators/keymap.c @@ -97,10 +97,10 @@ enum anne_pro_layers { */ [FN2] = LAYOUT_60_ansi( /* FN2 */ _______, KC_AP2_BT1, KC_AP2_BT2, KC_AP2_BT3, KC_AP2_BT4, _______, _______, _______, _______, KC_AP_RGB_MOD, KC_AP_RGB_TOG, KC_AP_RGB_VAD, KC_AP_RGB_VAI, _______, - MO(FN2), _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, _______, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_INS, KC_DEL, _______, - _______, _______, _______, _______, _______, MO(FN1), MO(FN2), _______ + _______, _______, _______, _______, _______, _______, _______, _______ ), }; // clang-format on diff --git a/keyboards/annepro2/keymaps/default/keymap.c b/keyboards/annepro2/keymaps/default/keymap.c index 8af2d9a32c..38be6ec54a 100644 --- a/keyboards/annepro2/keymaps/default/keymap.c +++ b/keyboards/annepro2/keymaps/default/keymap.c @@ -97,10 +97,10 @@ enum anne_pro_layers { */ [FN2] = LAYOUT_60_ansi( /* FN2 */ _______, KC_AP2_BT1, KC_AP2_BT2, KC_AP2_BT3, KC_AP2_BT4, _______, _______, _______, _______, KC_AP_RGB_MOD, KC_AP_RGB_TOG, KC_AP_RGB_VAD, KC_AP_RGB_VAI, _______, - MO(FN2), _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, _______, + _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_INS, KC_DEL, _______, - _______, _______, _______, _______, _______, MO(FN1), MO(FN2), _______ + _______, _______, _______, _______, _______, _______, _______, _______ ), }; // clang-format on diff --git a/keyboards/annepro2/keymaps/iso_default/keymap.c b/keyboards/annepro2/keymaps/iso_default/keymap.c index 4c1b259504..a495390603 100644 --- a/keyboards/annepro2/keymaps/iso_default/keymap.c +++ b/keyboards/annepro2/keymaps/iso_default/keymap.c @@ -76,9 +76,9 @@ enum anne_pro_layers { [FN1] = LAYOUT_60_iso( /* FN1 */ KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, - MO(FN1), KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, _______, _______, KC_VOLU, KC_VOLD, KC_MUTE, _______, _______, _______, _______, _______, KC_INS, KC_DEL, _______, - _______, _______, _______, _______, KC_APP, MO(FN1), MO(FN2), _______ + _______, _______, _______, _______, KC_APP, _______, MO(FN2), _______ ), /* * Layer FN2 @@ -98,9 +98,9 @@ enum anne_pro_layers { [FN2] = LAYOUT_60_iso( /* FN2 */ _______, KC_AP2_BT1, KC_AP2_BT2, KC_AP2_BT3, KC_AP2_BT4, _______, _______, _______, _______, KC_AP_RGB_MOD, KC_AP_RGB_TOG, KC_AP_RGB_VAD, KC_AP_RGB_VAI, _______, _______, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, KC_PSCR, KC_HOME, KC_END, - MO(FN1), KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, + _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_PGUP, KC_PGDN, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_INS, KC_DEL, _______, - _______, _______, _______, _______, KC_APP, MO(FN1), MO(FN2), _______ + _______, _______, _______, _______, KC_APP, _______, _______, _______ ), }; // clang-format on diff --git a/keyboards/annepro2/matrix.c b/keyboards/annepro2/matrix.c deleted file mode 100644 index a1585e4ddf..0000000000 --- a/keyboards/annepro2/matrix.c +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright (c) 2018 Charlie Waters - * - * 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/>. - */ - -#include <stdint.h> -#include <stdbool.h> -#include <string.h> -#include <hal.h> -#include "timer.h" -#include "wait.h" -#include "print.h" -#include "matrix.h" -#include "annepro2.h" - -pin_t row_list[MATRIX_ROWS] = MATRIX_ROW_PINS; -pin_t col_list[MATRIX_COLS] = MATRIX_COL_PINS; - -bool matrix_scan_custom(matrix_row_t current_matrix[]) { - bool matrix_has_changed = false; - // cache of input ports for columns - static uint16_t port_cache[4]; - // scan each row - for (int row = 0; row < MATRIX_ROWS; row++) { - palClearLine(row_list[row]); - __NOP(); - __NOP(); - __NOP(); - __NOP(); - // read i/o ports - port_cache[0] = palReadPort(IOPORTA); - port_cache[1] = palReadPort(IOPORTB); - port_cache[2] = palReadPort(IOPORTC); - port_cache[3] = palReadPort(IOPORTD); - palSetLine(row_list[row]); - - // get columns from ports - matrix_row_t data = 0; - for (int col = 0; col < MATRIX_COLS; ++col) { - pin_t line = col_list[col]; - uint16_t port = port_cache[HT32_PAL_IDX(PAL_PORT(line))]; - data |= (((port & (1 << PAL_PAD(line))) ? 0 : 1) << col); - } - - if (current_matrix[row] != data) { - current_matrix[row] = data; - matrix_has_changed = true; - } - } - return matrix_has_changed; -}
\ No newline at end of file |