diff options
author | Stephan Bösebeck <sb@caluga.de> | 2016-04-16 22:56:33 +0200 |
---|---|---|
committer | Stephan Bösebeck <sb@caluga.de> | 2016-04-16 22:56:33 +0200 |
commit | 38a1d830faa138f6a7e094b3eda33dc528112ec7 (patch) | |
tree | ea7745744f1759741b09577f25faf616fb39dfa7 /quantum/keymap_common.c | |
parent | 990254edecab782d6f2e71ebfc0b0dda4dc0781e (diff) | |
parent | 5f648b6c4060d586c343ea05562c607e2630dfc4 (diff) |
Merge branch 'master' of https://github.com/jackhumbert/qmk_firmware
Diffstat (limited to 'quantum/keymap_common.c')
-rw-r--r-- | quantum/keymap_common.c | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/quantum/keymap_common.c b/quantum/keymap_common.c index ae6cddb343..3a00d36f08 100644 --- a/quantum/keymap_common.c +++ b/quantum/keymap_common.c @@ -33,11 +33,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #include "audio.h" float goodbye[][2] = { - {440.0*pow(2.0,(67)/12.0), 400}, - {0, 50}, - {440.0*pow(2.0,(60)/12.0), 400}, - {0, 50}, - {440.0*pow(2.0,(55)/12.0), 600}, + {440.0*pow(2.0,(67)/12.0), 8}, + {440.0*pow(2.0,(60)/12.0), 8}, + {440.0*pow(2.0,(55)/12.0), 12}, }; #endif @@ -90,7 +88,7 @@ action_t action_for_key(uint8_t layer, keypos_t key) action_t action; clear_keyboard(); #ifdef AUDIO_ENABLE - play_notes(&goodbye, 5, false); + play_notes(&goodbye, 3, false); #endif _delay_ms(250); #ifdef ATREUS_ASTAR @@ -293,3 +291,11 @@ action_t keymap_func_to_action(uint16_t keycode) // For FUNC without 8bit limit return (action_t){ .code = pgm_read_word(&fn_actions[(int)keycode]) }; } + +void update_tri_layer(uint8_t layer1, uint8_t layer2, uint8_t layer3) { + if (IS_LAYER_ON(layer1) && IS_LAYER_ON(layer2)) { + layer_on(layer3); + } else { + layer_off(layer3); + } +} |