diff options
author | Ryan <fauxpark@gmail.com> | 2021-06-10 17:16:09 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-10 17:16:09 +1000 |
commit | b2fdd4874434ef6921a436fc82d9f24909c726f8 (patch) | |
tree | 0348596d5938326e95c09270d209556bbe60ba72 /tmk_core/common | |
parent | cfc7ee61c5cb9822a1195028681b928bbeac2fd3 (diff) | |
download | qmk_firmware-b2fdd4874434ef6921a436fc82d9f24909c726f8.tar.gz qmk_firmware-b2fdd4874434ef6921a436fc82d9f24909c726f8.zip |
Add ST7565 LCD driver (#13089)
Co-authored-by: Joakim Tufvegren <jocke@barbanet.com>
Diffstat (limited to 'tmk_core/common')
-rw-r--r-- | tmk_core/common/keyboard.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tmk_core/common/keyboard.c b/tmk_core/common/keyboard.c index 3d6092e71..249da85bd 100644 --- a/tmk_core/common/keyboard.c +++ b/tmk_core/common/keyboard.c | |||
@@ -85,6 +85,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
85 | #ifdef OLED_DRIVER_ENABLE | 85 | #ifdef OLED_DRIVER_ENABLE |
86 | # include "oled_driver.h" | 86 | # include "oled_driver.h" |
87 | #endif | 87 | #endif |
88 | #ifdef ST7565_ENABLE | ||
89 | # include "st7565.h" | ||
90 | #endif | ||
88 | #ifdef VELOCIKEY_ENABLE | 91 | #ifdef VELOCIKEY_ENABLE |
89 | # include "velocikey.h" | 92 | # include "velocikey.h" |
90 | #endif | 93 | #endif |
@@ -306,6 +309,9 @@ void keyboard_init(void) { | |||
306 | #ifdef OLED_DRIVER_ENABLE | 309 | #ifdef OLED_DRIVER_ENABLE |
307 | oled_init(OLED_ROTATION_0); | 310 | oled_init(OLED_ROTATION_0); |
308 | #endif | 311 | #endif |
312 | #ifdef ST7565_ENABLE | ||
313 | st7565_init(DISPLAY_ROTATION_0); | ||
314 | #endif | ||
309 | #ifdef PS2_MOUSE_ENABLE | 315 | #ifdef PS2_MOUSE_ENABLE |
310 | ps2_mouse_init(); | 316 | ps2_mouse_init(); |
311 | #endif | 317 | #endif |
@@ -470,6 +476,18 @@ MATRIX_LOOP_END: | |||
470 | # endif | 476 | # endif |
471 | #endif | 477 | #endif |
472 | 478 | ||
479 | #ifdef ST7565_ENABLE | ||
480 | st7565_task(); | ||
481 | # ifndef ST7565_DISABLE_TIMEOUT | ||
482 | // Wake up display if user is using those fabulous keys or spinning those encoders! | ||
483 | # ifdef ENCODER_ENABLE | ||
484 | if (matrix_changed || encoders_changed) st7565_on(); | ||
485 | # else | ||
486 | if (matrix_changed) st7565_on(); | ||
487 | # endif | ||
488 | # endif | ||
489 | #endif | ||
490 | |||
473 | #ifdef MOUSEKEY_ENABLE | 491 | #ifdef MOUSEKEY_ENABLE |
474 | // mousekey repeat & acceleration | 492 | // mousekey repeat & acceleration |
475 | mousekey_task(); | 493 | mousekey_task(); |