From 4f124574f1087ab40c2630adc10e492f895cefdb Mon Sep 17 00:00:00 2001 From: jpe230 Date: Wed, 29 Jun 2022 20:07:43 -0500 Subject: (develop)AP2: Enable support for WL EEPROM Driver (#17506) --- keyboards/annepro2/c15/config.h | 18 ++++++++++++++++++ keyboards/annepro2/c15/rules.mk | 4 ++++ 2 files changed, 22 insertions(+) (limited to 'keyboards/annepro2/c15') diff --git a/keyboards/annepro2/c15/config.h b/keyboards/annepro2/c15/config.h index ff92aeea8e..2ebb962efb 100644 --- a/keyboards/annepro2/c15/config.h +++ b/keyboards/annepro2/c15/config.h @@ -49,3 +49,21 @@ // Obins stock firmware has something similar to this already enabled, but disabled by default in QMK #define PERMISSIVE_HOLD + +// SPI configuration +#define SPI_DRIVER SPID1 +#define SPI_SCK_PIN A0 +#define SPI_MOSI_PIN A1 +#define SPI_MISO_PIN A2 + +// Flash configuration +#define EXTERNAL_FLASH_SPI_SLAVE_SELECT_PIN B6 +#define EXTERNAL_FLASH_SPI_CLOCK_DIVISOR 16 +#define EXTERNAL_FLASH_PAGE_SIZE 256 +#define EXTERNAL_FLASH_SECTOR_SIZE 4096 +#define EXTERNAL_FLASH_BLOCK_SIZE 4096 +#define EXTERNAL_FLASH_SIZE (256 * 1024) // 2M-bit flash size + +// Wear-leveling driver configuration +#define WEAR_LEVELING_LOGICAL_SIZE 1024 +#define WEAR_LEVELING_BACKING_SIZE (WEAR_LEVELING_LOGICAL_SIZE * 2) diff --git a/keyboards/annepro2/c15/rules.mk b/keyboards/annepro2/c15/rules.mk index 2c518b6339..302aeecbe6 100644 --- a/keyboards/annepro2/c15/rules.mk +++ b/keyboards/annepro2/c15/rules.mk @@ -26,6 +26,10 @@ BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow AUDIO_ENABLE = no # Audio output +# Wear-levelling driver +EEPROM_DRIVER = wear_leveling +WEAR_LEVELING_DRIVER = spi_flash + # Custom RGB matrix handling RGB_MATRIX_ENABLE = yes RGB_MATRIX_DRIVER = custom -- cgit v1.2.1 From 30796913913c0f6dc0cce317ad8249de2b602294 Mon Sep 17 00:00:00 2001 From: Ryan Date: Sun, 14 Aug 2022 10:47:05 +1000 Subject: Move keyboard USB IDs and strings to data driven, pass 2: 0-9, A (#17941) --- keyboards/annepro2/c15/config.h | 6 ------ keyboards/annepro2/c15/info.json | 6 ++++++ 2 files changed, 6 insertions(+), 6 deletions(-) create mode 100644 keyboards/annepro2/c15/info.json (limited to 'keyboards/annepro2/c15') diff --git a/keyboards/annepro2/c15/config.h b/keyboards/annepro2/c15/config.h index ff92aeea8e..0869ad1773 100644 --- a/keyboards/annepro2/c15/config.h +++ b/keyboards/annepro2/c15/config.h @@ -20,12 +20,6 @@ #include "pin_defs.h" #include "config_led.h" -/* USB Device descriptor parameter */ -#define VENDOR_ID 0xfeed -#define PRODUCT_ID 0xac15 -#define DEVICE_VER 0x1337 -#define MANUFACTURER Obins -#define PRODUCT Anne Pro 2 QMK // key matrix size #define MATRIX_ROWS 5 #define MATRIX_COLS 14 diff --git a/keyboards/annepro2/c15/info.json b/keyboards/annepro2/c15/info.json new file mode 100644 index 0000000000..c8c637ccfb --- /dev/null +++ b/keyboards/annepro2/c15/info.json @@ -0,0 +1,6 @@ +{ + "keyboard_name": "Anne Pro 2 C15 (QMK)", + "usb": { + "pid": "0xAC15" + } +} -- cgit v1.2.1