summaryrefslogtreecommitdiff
path: root/keyboards
diff options
context:
space:
mode:
authorJoel Challis <git@zvecr.com>2021-02-28 15:52:43 +0000
committerGitHub <noreply@github.com>2021-02-28 15:52:43 +0000
commit415a8bc249d5c366487f69b3547198d17044a5de (patch)
treeb77c0de78b3b847c32a4dfdfca79aeeada179271 /keyboards
parenta3cbc8a004f6ec5b0e1df326353a2a2fc8221129 (diff)
ARM - Refactor SLEEP_LED to support more platforms (#8403)
* Initial refactor of ARM SLEEP_LED to enable more platforms * fix build issues * Disable SLEEP_LED for boards with no caps lock code * Enable GPT14 for boards with caps lock code and SLEEP_LED enabled * Enable GPT for boards with caps lock code and SLEEP_LED enabled
Diffstat (limited to 'keyboards')
-rw-r--r--keyboards/aeboards/ext65/rev2/config.h2
-rw-r--r--keyboards/aeboards/ext65/rev2/halconf.h2
-rw-r--r--keyboards/aeboards/ext65/rev2/mcuconf.h2
-rw-r--r--keyboards/cannonkeys/an_c/rules.mk2
-rw-r--r--keyboards/cannonkeys/chimera65/rules.mk2
-rw-r--r--keyboards/cannonkeys/instant60/rules.mk2
-rw-r--r--keyboards/cannonkeys/iron165/rules.mk2
-rw-r--r--keyboards/cannonkeys/satisfaction75/rules.mk2
-rw-r--r--keyboards/cannonkeys/savage65/rules.mk2
-rw-r--r--keyboards/cannonkeys/tmov2/rules.mk2
-rw-r--r--keyboards/cannonkeys/tsukuyomi/rules.mk2
-rw-r--r--keyboards/daji/seis_cinco/rules.mk2
-rw-r--r--keyboards/handwired/ck4x4/rules.mk2
-rw-r--r--keyboards/handwired/onekey/rules.mk4
-rw-r--r--keyboards/projectkb/alice/config.h3
-rw-r--r--keyboards/projectkb/alice/halconf.h2
-rw-r--r--keyboards/projectkb/alice/mcuconf.h2
-rw-r--r--keyboards/projectkb/signature87/rules.mk2
-rw-r--r--keyboards/ramonimbao/wete/config.h2
-rw-r--r--keyboards/ramonimbao/wete/halconf.h2
-rw-r--r--keyboards/ramonimbao/wete/mcuconf.h2
-rw-r--r--keyboards/westfoxtrot/prophet/config.h2
-rw-r--r--keyboards/westfoxtrot/prophet/halconf.h27
-rw-r--r--keyboards/westfoxtrot/prophet/mcuconf.h5
24 files changed, 63 insertions, 16 deletions
diff --git a/keyboards/aeboards/ext65/rev2/config.h b/keyboards/aeboards/ext65/rev2/config.h
index 541f07ee98..dc1bfb71c2 100644
--- a/keyboards/aeboards/ext65/rev2/config.h
+++ b/keyboards/aeboards/ext65/rev2/config.h
@@ -74,3 +74,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define BACKLIGHT_LEVELS 6
#define BACKLIGHT_BREATHING
#define BREATHING_PERIOD 6
+
+#define SLEEP_LED_GPT_DRIVER GPTD1
diff --git a/keyboards/aeboards/ext65/rev2/halconf.h b/keyboards/aeboards/ext65/rev2/halconf.h
index 6e2f536400..9fa1eca60b 100644
--- a/keyboards/aeboards/ext65/rev2/halconf.h
+++ b/keyboards/aeboards/ext65/rev2/halconf.h
@@ -27,5 +27,7 @@
#define HAL_USE_SPI TRUE
+#define HAL_USE_GPT TRUE
+
#include_next <halconf.h>
diff --git a/keyboards/aeboards/ext65/rev2/mcuconf.h b/keyboards/aeboards/ext65/rev2/mcuconf.h
index 26ce806150..43d53d4f2d 100644
--- a/keyboards/aeboards/ext65/rev2/mcuconf.h
+++ b/keyboards/aeboards/ext65/rev2/mcuconf.h
@@ -32,3 +32,5 @@
#undef STM32_SPI_USE_SPI2
#define STM32_SPI_USE_SPI2 TRUE
+#undef STM32_GPT_USE_TIM1
+#define STM32_GPT_USE_TIM1 TRUE
diff --git a/keyboards/cannonkeys/an_c/rules.mk b/keyboards/cannonkeys/an_c/rules.mk
index 8ed2d0ead7..7309744d1e 100644
--- a/keyboards/cannonkeys/an_c/rules.mk
+++ b/keyboards/cannonkeys/an_c/rules.mk
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
BACKLIGHT_ENABLE = yes
diff --git a/keyboards/cannonkeys/chimera65/rules.mk b/keyboards/cannonkeys/chimera65/rules.mk
index 4d940da78d..a08f2fa49d 100644
--- a/keyboards/cannonkeys/chimera65/rules.mk
+++ b/keyboards/cannonkeys/chimera65/rules.mk
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
BACKLIGHT_ENABLE = yes
diff --git a/keyboards/cannonkeys/instant60/rules.mk b/keyboards/cannonkeys/instant60/rules.mk
index 0973ad9547..e5ba2903b6 100644
--- a/keyboards/cannonkeys/instant60/rules.mk
+++ b/keyboards/cannonkeys/instant60/rules.mk
@@ -10,7 +10,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
BACKLIGHT_ENABLE = yes
diff --git a/keyboards/cannonkeys/iron165/rules.mk b/keyboards/cannonkeys/iron165/rules.mk
index 3925458dda..9de75a6149 100644
--- a/keyboards/cannonkeys/iron165/rules.mk
+++ b/keyboards/cannonkeys/iron165/rules.mk
@@ -9,7 +9,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
BACKLIGHT_ENABLE = yes
diff --git a/keyboards/cannonkeys/satisfaction75/rules.mk b/keyboards/cannonkeys/satisfaction75/rules.mk
index e3abea5463..3861b4849f 100644
--- a/keyboards/cannonkeys/satisfaction75/rules.mk
+++ b/keyboards/cannonkeys/satisfaction75/rules.mk
@@ -15,7 +15,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
ENCODER_ENABLE = yes
diff --git a/keyboards/cannonkeys/savage65/rules.mk b/keyboards/cannonkeys/savage65/rules.mk
index 8e1b984fd4..2454573d2f 100644
--- a/keyboards/cannonkeys/savage65/rules.mk
+++ b/keyboards/cannonkeys/savage65/rules.mk
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
BACKLIGHT_ENABLE = yes
diff --git a/keyboards/cannonkeys/tmov2/rules.mk b/keyboards/cannonkeys/tmov2/rules.mk
index 9b29e8fd17..294c873eec 100644
--- a/keyboards/cannonkeys/tmov2/rules.mk
+++ b/keyboards/cannonkeys/tmov2/rules.mk
@@ -11,7 +11,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
BACKLIGHT_ENABLE = yes
diff --git a/keyboards/cannonkeys/tsukuyomi/rules.mk b/keyboards/cannonkeys/tsukuyomi/rules.mk
index ce881f1986..4e7791a79f 100644
--- a/keyboards/cannonkeys/tsukuyomi/rules.mk
+++ b/keyboards/cannonkeys/tsukuyomi/rules.mk
@@ -10,7 +10,7 @@ EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
NKRO_ENABLE = yes # USB Nkey Rollover
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
diff --git a/keyboards/daji/seis_cinco/rules.mk b/keyboards/daji/seis_cinco/rules.mk
index fa34092cd7..768e50069c 100644
--- a/keyboards/daji/seis_cinco/rules.mk
+++ b/keyboards/daji/seis_cinco/rules.mk
@@ -11,7 +11,7 @@ EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = no # Console for debug
COMMAND_ENABLE = no # Commands for debug and configuration
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
NKRO_ENABLE = yes # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
diff --git a/keyboards/handwired/ck4x4/rules.mk b/keyboards/handwired/ck4x4/rules.mk
index 0709f341bf..e5785270bd 100644
--- a/keyboards/handwired/ck4x4/rules.mk
+++ b/keyboards/handwired/ck4x4/rules.mk
@@ -10,7 +10,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
CUSTOM_MATRIX = no # Custom matrix file
diff --git a/keyboards/handwired/onekey/rules.mk b/keyboards/handwired/onekey/rules.mk
index 259050d553..df2ec1ecf4 100644
--- a/keyboards/handwired/onekey/rules.mk
+++ b/keyboards/handwired/onekey/rules.mk
@@ -7,9 +7,9 @@ EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
CONSOLE_ENABLE = yes # Console for debug(+400)
COMMAND_ENABLE = no # Commands for debug and configuration
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
-NKRO_ENABLE = yes # USB Nkey Rollover
+NKRO_ENABLE = yes # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config)
diff --git a/keyboards/projectkb/alice/config.h b/keyboards/projectkb/alice/config.h
new file mode 100644
index 0000000000..95fb682e17
--- /dev/null
+++ b/keyboards/projectkb/alice/config.h
@@ -0,0 +1,3 @@
+#pragma once
+
+#define SLEEP_LED_GPT_DRIVER GPTD1
diff --git a/keyboards/projectkb/alice/halconf.h b/keyboards/projectkb/alice/halconf.h
index b17808ffeb..0016e53ba8 100644
--- a/keyboards/projectkb/alice/halconf.h
+++ b/keyboards/projectkb/alice/halconf.h
@@ -27,5 +27,7 @@
#define HAL_USE_SPI TRUE
+#define HAL_USE_GPT TRUE
+
#include_next <halconf.h>
diff --git a/keyboards/projectkb/alice/mcuconf.h b/keyboards/projectkb/alice/mcuconf.h
index 4bfc7f9465..6e0f1a50d8 100644
--- a/keyboards/projectkb/alice/mcuconf.h
+++ b/keyboards/projectkb/alice/mcuconf.h
@@ -32,3 +32,5 @@
#undef STM32_SPI_USE_SPI2
#define STM32_SPI_USE_SPI2 TRUE
+#undef STM32_GPT_USE_TIM1
+#define STM32_GPT_USE_TIM1 TRUE
diff --git a/keyboards/projectkb/signature87/rules.mk b/keyboards/projectkb/signature87/rules.mk
index fe0d976d11..caad4c83c2 100644
--- a/keyboards/projectkb/signature87/rules.mk
+++ b/keyboards/projectkb/signature87/rules.mk
@@ -9,7 +9,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
COMMAND_ENABLE = yes # Commands for debug and configuration
-SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
NKRO_ENABLE = yes # USB Nkey Rollover
BACKLIGHT_ENABLE = no
diff --git a/keyboards/ramonimbao/wete/config.h b/keyboards/ramonimbao/wete/config.h
index 5d68a7efd7..3d89550090 100644
--- a/keyboards/ramonimbao/wete/config.h
+++ b/keyboards/ramonimbao/wete/config.h
@@ -46,6 +46,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGBLED_NUM 24
#define RGBLIGHT_ANIMATIONS
+#define SLEEP_LED_GPT_DRIVER GPTD1
+
/* define if matrix has ghost */
//#define MATRIX_HAS_GHOST
diff --git a/keyboards/ramonimbao/wete/halconf.h b/keyboards/ramonimbao/wete/halconf.h
index c43440a459..b3de873be1 100644
--- a/keyboards/ramonimbao/wete/halconf.h
+++ b/keyboards/ramonimbao/wete/halconf.h
@@ -23,5 +23,7 @@
#define HAL_USE_PWM TRUE
+#define HAL_USE_GPT TRUE
+
#include_next <halconf.h>
diff --git a/keyboards/ramonimbao/wete/mcuconf.h b/keyboards/ramonimbao/wete/mcuconf.h
index b7f2c481c6..7a2e877763 100644
--- a/keyboards/ramonimbao/wete/mcuconf.h
+++ b/keyboards/ramonimbao/wete/mcuconf.h
@@ -35,3 +35,5 @@
#undef STM32_SPI_USE_SPI2
#define STM32_SPI_USE_SPI2 TRUE
+#undef STM32_GPT_USE_TIM1
+#define STM32_GPT_USE_TIM1 TRUE
diff --git a/keyboards/westfoxtrot/prophet/config.h b/keyboards/westfoxtrot/prophet/config.h
index 4f447e4ca0..0f2ddc1dc1 100644
--- a/keyboards/westfoxtrot/prophet/config.h
+++ b/keyboards/westfoxtrot/prophet/config.h
@@ -30,3 +30,5 @@
#define LOCKING_SUPPORT_ENABLE
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE
+
+#define SLEEP_LED_GPT_DRIVER GPTD1
diff --git a/keyboards/westfoxtrot/prophet/halconf.h b/keyboards/westfoxtrot/prophet/halconf.h
new file mode 100644
index 0000000000..cbfd1307f1
--- /dev/null
+++ b/keyboards/westfoxtrot/prophet/halconf.h
@@ -0,0 +1,27 @@
+/* Copyright 2020 QMK
+ *
+ * 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/>.
+ */
+
+/*
+ * This file was auto-generated by:
+ * `qmk chibios-confmigrate -i keyboards/projectkb/alice/halconf.h -r platforms/chibios/common/configs/halconf.h`
+ */
+
+#pragma once
+
+#define HAL_USE_GPT TRUE
+
+#include_next <halconf.h>
+
diff --git a/keyboards/westfoxtrot/prophet/mcuconf.h b/keyboards/westfoxtrot/prophet/mcuconf.h
index 2665f9c9e4..550141af6b 100644
--- a/keyboards/westfoxtrot/prophet/mcuconf.h
+++ b/keyboards/westfoxtrot/prophet/mcuconf.h
@@ -23,6 +23,5 @@
#include_next <mcuconf.h>
-#undef STM32_PWM_USE_TIM3
-#define STM32_PWM_USE_TIM3 TRUE
-
+#undef STM32_GPT_USE_TIM1
+#define STM32_GPT_USE_TIM1 TRUE