]> git.donarmstrong.com Git - qmk_firmware.git/blobdiff - quantum/visualizer/lcd_keyframes.c
[Keyboard] Added RAMA KOYU (#5512)
[qmk_firmware.git] / quantum / visualizer / lcd_keyframes.c
index c6e04d0ca437e0a4b6aed374057cf05535f3c619..75eb457001c321f65bd799ea292e8c5655c389a2 100644 (file)
@@ -18,6 +18,7 @@
 #include <string.h>
 #include "action_util.h"
 #include "led.h"
+#include "resources/resources.h"
 
 bool lcd_keyframe_display_layer_text(keyframe_animation_t* animation, visualizer_state_t* state) {
     (void)animation;
@@ -124,8 +125,8 @@ static void get_led_state_string(char* output, visualizer_state_t* state) {
        pos += 5;
     }
     if (state->status.leds & (1u << USB_LED_KANA)) {
-       memcpy(output + pos, "KANA ", 5);
-       pos += 5;
+       memcpy(output + pos, "KANA", 4);
+       pos += 4;
     }
     output[pos] = 0;
 }
@@ -154,6 +155,24 @@ bool lcd_keyframe_display_layer_and_led_states(keyframe_animation_t* animation,
     return false;
 }
 
+bool lcd_keyframe_draw_logo(keyframe_animation_t* animation, visualizer_state_t* state) {
+    (void)state;
+    (void)animation;
+    // Read the uGFX documentation for information how to use the displays
+    // http://wiki.ugfx.org/index.php/Main_Page
+    gdispClear(White);
+
+    // You can use static variables for things that can't be found in the animation
+    // or state structs, here we use the image
+
+    //gdispGBlitArea is a tricky function to use since it supports blitting part of the image
+    // if you have full screen image, then just use LCD_WIDTH and LCD_HEIGHT for both source and target dimensions
+    gdispGBlitArea(GDISP, 0, 0, LCD_WIDTH, LCD_HEIGHT, 0, 0, LCD_WIDTH, (pixel_t*)resource_lcd_logo);
+
+    return false;
+}
+
+
 bool lcd_keyframe_disable(keyframe_animation_t* animation, visualizer_state_t* state) {
     (void)animation;
     (void)state;