correctly configured startup song

This commit is contained in:
Valerie Wolfe 2022-05-23 00:46:15 -04:00
parent 78623ec507
commit 795f509a86
2 changed files with 15 additions and 9 deletions

15
preonic/config.h Normal file
View file

@ -0,0 +1,15 @@
#pragma once
#ifdef AUDIO_ENABLE
#define AUDIO_INIT_DELAY
#define NO_MUSIC_MODE
#define BOOT_SONG Q__NOTE(_F5), Q__NOTE(_G5), Q__NOTE(_C6)
#define STARTUP_SONG SONG(BOOT_SONG)
#define TONE_FN S__NOTE(_G5)
#endif
#define MUSIC_MASK (keycode != KC_NO)
#define MIDI_BASIC

View file

@ -53,19 +53,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
#define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_RAINBOW_SWIRL #define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_RAINBOW_SWIRL
#ifdef AUDIO_ENABLE #ifdef AUDIO_ENABLE
#define STARTUP_SONG SONG(PREONIC_SOUND)
#define BOOT_SONG HD_NOTE(_F5), HD_NOTE(_G5), HD_NOTE(_C6)
#define TONE_FN HD_NOTE(_G5)
float boot_song[][2] = SONG(BOOT_SONG);
float tone_fn[][2] = SONG(TONE_FN); float tone_fn[][2] = SONG(TONE_FN);
#endif #endif
void keyboard_post_init_user(void) { void keyboard_post_init_user(void) {
#ifdef BOOT_SONG
PLAY_SONG(boot_song);
#endif
rgblight_disable_noeeprom(); rgblight_disable_noeeprom();
} }