aboutsummaryrefslogtreecommitdiff
path: root/users/drashna/oled_stuff.c
diff options
context:
space:
mode:
Diffstat (limited to 'users/drashna/oled_stuff.c')
-rw-r--r--users/drashna/oled_stuff.c20
1 files changed, 17 insertions, 3 deletions
diff --git a/users/drashna/oled_stuff.c b/users/drashna/oled_stuff.c
index 0bdd0212b..7811cabc6 100644
--- a/users/drashna/oled_stuff.c
+++ b/users/drashna/oled_stuff.c
@@ -62,6 +62,9 @@ void add_keylog(uint16_t keycode, keyrecord_t *record) {
62 return; 62 return;
63 } 63 }
64 } 64 }
65 if (keycode > 0xFF) {
66 return;
67 }
65 68
66 for (uint8_t i = 1; i < KEYLOGGER_LENGTH; i++) { 69 for (uint8_t i = 1; i < KEYLOGGER_LENGTH; i++) {
67 keylog_str[i - 1] = keylog_str[i]; 70 keylog_str[i - 1] = keylog_str[i];
@@ -250,6 +253,17 @@ extern bool tap_toggling;
250#endif 253#endif
251 254
252void render_user_status(void) { 255void render_user_status(void) {
256#ifdef AUDIO_ENABLE
257 bool is_audio_on = false, is_clicky_on = false;
258# ifdef SPLIT_KEYBOARD
259
260 is_audio_on = user_state.audio_enable;
261 is_clicky_on = user_state.audio_clicky_enable;
262# else
263 is_audio_on = is_audio_on();
264 is_clicky_on = is_clicky_on();
265# endif
266#endif
253 oled_write_P(PSTR(OLED_RENDER_USER_NAME), false); 267 oled_write_P(PSTR(OLED_RENDER_USER_NAME), false);
254#if !defined(OLED_DISPLAY_128X64) 268#if !defined(OLED_DISPLAY_128X64)
255 oled_write_P(PSTR(" "), false); 269 oled_write_P(PSTR(" "), false);
@@ -265,11 +279,11 @@ void render_user_status(void) {
265#endif 279#endif
266#ifdef AUDIO_ENABLE 280#ifdef AUDIO_ENABLE
267 static const char PROGMEM audio_status[2][3] = {{0xE0, 0xE1, 0}, {0xE2, 0xE3, 0}}; 281 static const char PROGMEM audio_status[2][3] = {{0xE0, 0xE1, 0}, {0xE2, 0xE3, 0}};
268 oled_write_P(audio_status[is_audio_on()], false); 282 oled_write_P(audio_status[is_audio_on], false);
269 283
270# ifdef AUDIO_CLICKY 284# ifdef AUDIO_CLICKY
271 static const char PROGMEM audio_clicky_status[2][3] = {{0xF4, 0xF5, 0}, {0xF6, 0xF7, 0}}; 285 static const char PROGMEM audio_clicky_status[2][3] = {{0xF4, 0xF5, 0}, {0xF6, 0xF7, 0}};
272 oled_write_P(audio_clicky_status[is_clicky_on() && is_audio_on()], false); 286 oled_write_P(audio_clicky_status[is_clicky_on && is_audio_on], false);
273# if !defined(OLED_DISPLAY_128X64) 287# if !defined(OLED_DISPLAY_128X64)
274 oled_write_P(PSTR(" "), false); 288 oled_write_P(PSTR(" "), false);
275# endif 289# endif
@@ -370,7 +384,7 @@ void render_status_secondary(void) {
370 /* Show Keyboard Layout */ 384 /* Show Keyboard Layout */
371 render_layer_state(); 385 render_layer_state();
372 render_mod_status(get_mods() | get_oneshot_mods()); 386 render_mod_status(get_mods() | get_oneshot_mods());
373#if !defined(OLED_DISPLAY_128X64) && defined(WPM_ENABLE) 387#if !defined(OLED_DISPLAY_128X64) && defined(WPM_ENABLE) && !defined(CONVERT_TO_PROTON_C)
374 render_wpm(2); 388 render_wpm(2);
375#endif 389#endif
376 // render_keylock_status(host_keyboard_leds()); 390 // render_keylock_status(host_keyboard_leds());