From b5452581da84842ec1694391b53e7682b11832f9 Mon Sep 17 00:00:00 2001
From: GG <72414103+spbgzh@users.noreply.github.com>
Date: Fri, 29 Jul 2022 07:41:42 +0300
Subject: [PATCH] [Keyboard] fix mistakes in promise87 config (#17830)

---
 keyboards/wuque/promise87/ansi/config.h  | 14 ++++++++++++++
 keyboards/wuque/promise87/ansi/info.json | 12 ++++++------
 keyboards/wuque/promise87/ansi/rules.mk  |  2 +-
 keyboards/wuque/promise87/wkl/config.h   | 14 ++++++++++++++
 keyboards/wuque/promise87/wkl/rules.mk   |  2 +-
 5 files changed, 36 insertions(+), 8 deletions(-)

diff --git a/keyboards/wuque/promise87/ansi/config.h b/keyboards/wuque/promise87/ansi/config.h
index ce76fac578..e51738c13a 100644
--- a/keyboards/wuque/promise87/ansi/config.h
+++ b/keyboards/wuque/promise87/ansi/config.h
@@ -39,3 +39,17 @@
 
 #define LED_CAPS_LOCK_PIN F6
 #define LED_PIN_ON_STATE 0
+
+#define RGB_DI_PIN D2
+#ifdef RGB_DI_PIN
+    #define RGBLED_NUM 1
+    #define RGBLIGHT_HUE_STEP 8
+    #define RGBLIGHT_SAT_STEP 8
+    #define RGBLIGHT_VAL_STEP 8
+    #define RGBLIGHT_LIMIT_VAL 200 /* The maximum brightness level */
+    #define RGBLIGHT_SLEEP  /* If defined, the RGB lighting will be switched off when the host goes to sleep */
+/*======= RGB function=======*/
+#define RGBLIGHT_EFFECT_BREATHING
+#define RGBLIGHT_EFFECT_RAINBOW_MOOD
+#define RGBLIGHT_EFFECT_STATIC_GRADIENT
+#endif
diff --git a/keyboards/wuque/promise87/ansi/info.json b/keyboards/wuque/promise87/ansi/info.json
index e62200480c..cec6fa0d68 100644
--- a/keyboards/wuque/promise87/ansi/info.json
+++ b/keyboards/wuque/promise87/ansi/info.json
@@ -103,7 +103,7 @@
                 { "label": "Alt", "x": 10, "y": 5.25, "w": 1.25 },
                 { "label": "Win", "x": 11.25, "y": 5.25, "w": 1.25 },
                 { "label": "Fn", "x": 12.5, "y": 5.25, "w": 1.25 },
-                { "label": "Alt", "x": 13.75, "y": 5.25, "w": 1.25 },
+                { "label": "Ctrl", "x": 13.75, "y": 5.25, "w": 1.25 },
                 { "label": "\u2190", "x": 15.25, "y": 5.25 },
                 { "label": "\u2193", "x": 16.25, "y": 5.25 },
                 { "label": "\u2192", "x": 17.25, "y": 5.25 }
@@ -200,7 +200,7 @@
                 { "label": "Alt", "x": 10, "y": 5.25, "w": 1.25 },
                 { "label": "Win", "x": 11.25, "y": 5.25, "w": 1.25 },
                 { "label": "Fn", "x": 12.5, "y": 5.25, "w": 1.25 },
-                { "label": "Alt", "x": 13.75, "y": 5.25, "w": 1.25 },
+                { "label": "Ctrl", "x": 13.75, "y": 5.25, "w": 1.25 },
                 { "label": "\u2190", "x": 15.25, "y": 5.25 },
                 { "label": "\u2193", "x": 16.25, "y": 5.25 },
                 { "label": "\u2192", "x": 17.25, "y": 5.25 }
@@ -298,7 +298,7 @@
                 { "label": "Alt", "x": 10, "y": 5.25, "w": 1.25 },
                 { "label": "Win", "x": 11.25, "y": 5.25, "w": 1.25 },
                 { "label": "Fn", "x": 12.5, "y": 5.25, "w": 1.25 },
-                { "label": "Alt", "x": 13.75, "y": 5.25, "w": 1.25 },
+                { "label": "Ctrl", "x": 13.75, "y": 5.25, "w": 1.25 },
                 { "label": "\u2190", "x": 15.25, "y": 5.25 },
                 { "label": "\u2193", "x": 16.25, "y": 5.25 },
                 { "label": "\u2192", "x": 17.25, "y": 5.25 }
@@ -396,7 +396,7 @@
                 { "label": "Alt", "x": 10, "y": 5.25, "w": 1.25 },
                 { "label": "Win", "x": 11.25, "y": 5.25, "w": 1.25 },
                 { "label": "Fn", "x": 12.5, "y": 5.25, "w": 1.25 },
-                { "label": "Alt", "x": 13.75, "y": 5.25, "w": 1.25 },
+                { "label": "Ctrl", "x": 13.75, "y": 5.25, "w": 1.25 },
                 { "label": "\u2190", "x": 15.25, "y": 5.25 },
                 { "label": "\u2193", "x": 16.25, "y": 5.25 },
                 { "label": "\u2192", "x": 17.25, "y": 5.25 }
@@ -494,7 +494,7 @@
                 { "label": "Alt", "x": 10, "y": 5.25, "w": 1.25 },
                 { "label": "Win", "x": 11.25, "y": 5.25, "w": 1.25 },
                 { "label": "Fn", "x": 12.5, "y": 5.25, "w": 1.25 },
-                { "label": "Alt", "x": 13.75, "y": 5.25, "w": 1.25 },
+                { "label": "Ctrl", "x": 13.75, "y": 5.25, "w": 1.25 },
                 { "label": "\u2190", "x": 15.25, "y": 5.25 },
                 { "label": "\u2193", "x": 16.25, "y": 5.25 },
                 { "label": "\u2192", "x": 17.25, "y": 5.25 }
@@ -593,7 +593,7 @@
                 { "label": "Alt", "x": 10, "y": 5.25, "w": 1.25 },
                 { "label": "Win", "x": 11.25, "y": 5.25, "w": 1.25 },
                 { "label": "Fn", "x": 12.5, "y": 5.25, "w": 1.25 },
-                { "label": "Alt", "x": 13.75, "y": 5.25, "w": 1.25 },
+                { "label": "Ctrl", "x": 13.75, "y": 5.25, "w": 1.25 },
                 { "label": "\u2190", "x": 15.25, "y": 5.25 },
                 { "label": "\u2193", "x": 16.25, "y": 5.25 },
                 { "label": "\u2192", "x": 17.25, "y": 5.25 }
diff --git a/keyboards/wuque/promise87/ansi/rules.mk b/keyboards/wuque/promise87/ansi/rules.mk
index 751cdba451..ffe655b21f 100644
--- a/keyboards/wuque/promise87/ansi/rules.mk
+++ b/keyboards/wuque/promise87/ansi/rules.mk
@@ -14,7 +14,7 @@ CONSOLE_ENABLE = yes         # Console for debug
 COMMAND_ENABLE = no         # Commands for debug and configuration
 NKRO_ENABLE = yes           # Enable N-Key Rollover
 BACKLIGHT_ENABLE = no       # Enable keyboard backlight functionality
-RGBLIGHT_ENABLE = no       # Enable keyboard RGB underglow
+RGBLIGHT_ENABLE = yes       # Enable keyboard RGB underglow
 AUDIO_ENABLE = no           # Audio output
 
 LAYOUTS = tkl_f13_ansi tkl_f13_ansi_split_bs_rshift
diff --git a/keyboards/wuque/promise87/wkl/config.h b/keyboards/wuque/promise87/wkl/config.h
index aebcac549e..c8fac0e451 100644
--- a/keyboards/wuque/promise87/wkl/config.h
+++ b/keyboards/wuque/promise87/wkl/config.h
@@ -39,3 +39,17 @@
 
 #define LED_CAPS_LOCK_PIN F6
 #define LED_PIN_ON_STATE 0
+
+#define RGB_DI_PIN D2
+#ifdef RGB_DI_PIN
+    #define RGBLED_NUM 1
+    #define RGBLIGHT_HUE_STEP 8
+    #define RGBLIGHT_SAT_STEP 8
+    #define RGBLIGHT_VAL_STEP 8
+    #define RGBLIGHT_LIMIT_VAL 200 /* The maximum brightness level */
+    #define RGBLIGHT_SLEEP  /* If defined, the RGB lighting will be switched off when the host goes to sleep */
+/*======= RGB function=======*/
+#define RGBLIGHT_EFFECT_BREATHING
+#define RGBLIGHT_EFFECT_RAINBOW_MOOD
+#define RGBLIGHT_EFFECT_STATIC_GRADIENT
+#endif
diff --git a/keyboards/wuque/promise87/wkl/rules.mk b/keyboards/wuque/promise87/wkl/rules.mk
index bc2cad63d3..85a4a905a5 100644
--- a/keyboards/wuque/promise87/wkl/rules.mk
+++ b/keyboards/wuque/promise87/wkl/rules.mk
@@ -14,5 +14,5 @@ CONSOLE_ENABLE = yes         # Console for debug
 COMMAND_ENABLE = no         # Commands for debug and configuration
 NKRO_ENABLE = yes           # Enable N-Key Rollover
 BACKLIGHT_ENABLE = no       # Enable keyboard backlight functionality
-RGBLIGHT_ENABLE = no       # Enable keyboard RGB underglow
+RGBLIGHT_ENABLE = yes       # Enable keyboard RGB underglow
 AUDIO_ENABLE = no           # Audio output