]> git.donarmstrong.com Git - qmk_firmware.git/blobdiff - keyboards/planck/keymaps/pete/keymap.c
DO NOT USE Merge branch 'master' into debounce_refactor
[qmk_firmware.git] / keyboards / planck / keymaps / pete / keymap.c
index d991bece13aa0bf608da341e73226e4022a668dd..faf41302eb828a10281669bc18216b4b38e29196 100644 (file)
@@ -1,6 +1,5 @@
-// This is the canonical layout file for the Quantum project. If you want to add another keyboard,
-// this is the style you want to emulate.
 
+#pragma message "You may need to add LAYOUT_planck_grid to your keymap layers - see default for an example"
 #include "planck.h"
 #include "action_layer.h"
 #ifdef AUDIO_ENABLE
@@ -118,9 +117,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
 };
 
 int currentOs = _MAC;
-const uint16_t PROGMEM fn_actions[] = {
-
-};
 
 #ifdef AUDIO_ENABLE
 
@@ -154,7 +150,7 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
         case _QWERTY:
           if (record->event.pressed) {
             #ifdef AUDIO_ENABLE
-              PLAY_NOTE_ARRAY(tone_qwerty, false, 0);
+              PLAY_SONG(tone_qwerty);
             #endif
             persistent_default_layer_set(1UL<<_QWERTY);
           }
@@ -162,7 +158,7 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
         case _COLEMAK:
           if (record->event.pressed) {
             #ifdef AUDIO_ENABLE
-              PLAY_NOTE_ARRAY(tone_colemak, false, 0);
+              PLAY_SONG(tone_colemak);
             #endif
             persistent_default_layer_set(1UL<<_COLEMAK);
           }
@@ -170,7 +166,7 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
         case _DVORAK:
           if (record->event.pressed) {
             #ifdef AUDIO_ENABLE
-              PLAY_NOTE_ARRAY(tone_dvorak, false, 0);
+              PLAY_SONG(tone_dvorak);
             #endif
             persistent_default_layer_set(1UL<<_DVORAK);
           }
@@ -211,7 +207,7 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
             unregister_code(KC_RCTL);
             unregister_code(KC_RALT);
             unregister_code(KC_RGUI);
-          } 
+          }
         break;
         case _OS:
           if (record->event.pressed) {
@@ -229,7 +225,7 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
             layer_off(currentOs);
             currentOs = id;
           }
-        break;        
+        break;
       }
     return MACRO_NONE;
 };
@@ -237,14 +233,14 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
 void matrix_init_user(void) {
   #ifdef AUDIO_ENABLE
     _delay_ms(20); // stops the tick
-    PLAY_NOTE_ARRAY(tone_startup, false, 0);
+    PLAY_SONG(tone_startup);
   #endif
 }
 
 #ifdef AUDIO_ENABLE
 void play_goodbye_tone()
 {
-  PLAY_NOTE_ARRAY(goodbye, false, 0);
+  PLAY_SONG(goodbye);
   _delay_ms(150);
 }