diff options
Diffstat (limited to 'docs/feature_audio.md')
-rw-r--r-- | docs/feature_audio.md | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/docs/feature_audio.md b/docs/feature_audio.md index 50e389605..039c62cdf 100644 --- a/docs/feature_audio.md +++ b/docs/feature_audio.md | |||
@@ -3,6 +3,7 @@ | |||
3 | Your keyboard can make sounds! If you've got a Planck, Preonic, or basically any AVR keyboard that allows access to certain PWM-capable pins, you can hook up a simple speaker and make it beep. You can use those beeps to indicate layer transitions, modifiers, special keys, or just to play some funky 8bit tunes. | 3 | Your keyboard can make sounds! If you've got a Planck, Preonic, or basically any AVR keyboard that allows access to certain PWM-capable pins, you can hook up a simple speaker and make it beep. You can use those beeps to indicate layer transitions, modifiers, special keys, or just to play some funky 8bit tunes. |
4 | 4 | ||
5 | Up to two simultaneous audio voices are supported, one driven by timer 1 and another driven by timer 3. The following pins can be defined as audio outputs in config.h: | 5 | Up to two simultaneous audio voices are supported, one driven by timer 1 and another driven by timer 3. The following pins can be defined as audio outputs in config.h: |
6 | |||
6 | Timer 1: | 7 | Timer 1: |
7 | `#define B5_AUDIO` | 8 | `#define B5_AUDIO` |
8 | `#define B6_AUDIO` | 9 | `#define B6_AUDIO` |
@@ -58,6 +59,13 @@ PLAY_LOOP(my_song); | |||
58 | 59 | ||
59 | It's advised that you wrap all audio features in `#ifdef AUDIO_ENABLE` / `#endif` to avoid causing problems when audio isn't built into the keyboard. | 60 | It's advised that you wrap all audio features in `#ifdef AUDIO_ENABLE` / `#endif` to avoid causing problems when audio isn't built into the keyboard. |
60 | 61 | ||
62 | The available keycodes for audio are: | ||
63 | |||
64 | * `AU_ON` - Turn audio mode on | ||
65 | * `AU_OFF` - Turn audio mode off | ||
66 | * `AU_TOG` - Toggle audio mode | ||
67 | |||
68 | |||
61 | ## Music Mode | 69 | ## Music Mode |
62 | 70 | ||
63 | The music mode maps your columns to a chromatic scale, and your rows to octaves. This works best with ortholinear keyboards, but can be made to work with others. All keycodes less than `0xFF` get blocked, so you won't type while playing notes - if you have special keys/mods, those will still work. A work-around for this is to jump to a different layer with KC_NOs before (or after) enabling music mode. | 71 | The music mode maps your columns to a chromatic scale, and your rows to octaves. This works best with ortholinear keyboards, but can be made to work with others. All keycodes less than `0xFF` get blocked, so you won't type while playing notes - if you have special keys/mods, those will still work. A work-around for this is to jump to a different layer with KC_NOs before (or after) enabling music mode. |
@@ -145,6 +153,23 @@ You can configure the default, min and max frequencies, the stepping and built i | |||
145 | 153 | ||
146 | This is still a WIP, but check out `quantum/keymap_midi.c` to see what's happening. Enable from the Makefile. | 154 | This is still a WIP, but check out `quantum/keymap_midi.c` to see what's happening. Enable from the Makefile. |
147 | 155 | ||
156 | |||
157 | ## Audio Keycodes | ||
158 | |||
159 | |Key |Aliases |Description | | ||
160 | |----------------|---------|----------------------------------| | ||
161 | |`AU_ON` | |Audio mode on | | ||
162 | |`AU_OFF` | |Audio mode off | | ||
163 | |`AU_TOG` | |Toggles Audio mode | | ||
164 | |`CLICKY_TOGGLE` |`CK_TOGG`|Toggles Audio clicky mode | | ||
165 | |`CLICKY_UP` |`CK_UP` |Increases frequency of the clicks | | ||
166 | |`CLICKY_DOWN` |`CK_DOWN`|Decreases frequency of the clicks | | ||
167 | |`CLICKY_RESET` |`CK_RST` |Resets frequency to default | | ||
168 | |`MU_ON` | |Turns on Music Mode | | ||
169 | |`MU_OFF` | |Turns off Music Mode | | ||
170 | |`MU_TOG` | |Toggles Music Mode | | ||
171 | |`MU_MOD` | |Cycles through the music modes | | ||
172 | |||
148 | <!-- FIXME: this formatting needs work | 173 | <!-- FIXME: this formatting needs work |
149 | 174 | ||
150 | ## Audio | 175 | ## Audio |