diff options
Diffstat (limited to 'keyboards/planck/keymaps/jetpacktuxedo/keymap.c')
| -rw-r--r-- | keyboards/planck/keymaps/jetpacktuxedo/keymap.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/keyboards/planck/keymaps/jetpacktuxedo/keymap.c b/keyboards/planck/keymaps/jetpacktuxedo/keymap.c index 132405686..b344bd076 100644 --- a/keyboards/planck/keymaps/jetpacktuxedo/keymap.c +++ b/keyboards/planck/keymaps/jetpacktuxedo/keymap.c | |||
| @@ -188,15 +188,24 @@ uint16_t muse_counter = 0; | |||
| 188 | uint8_t muse_offset = 70; | 188 | uint8_t muse_offset = 70; |
| 189 | uint16_t muse_tempo = 20; | 189 | uint16_t muse_tempo = 20; |
| 190 | 190 | ||
| 191 | extern float clicky_rand; | ||
| 192 | |||
| 191 | void encoder_update(bool clockwise) { | 193 | void encoder_update(bool clockwise) { |
| 192 | if (is_clicky_on()) { | 194 | if (is_clicky_on()) { |
| 193 | if (clockwise) { | 195 | if (IS_LAYER_ON(_RAISE)) { |
| 194 | clicky_freq_up(); | 196 | if (clockwise) { |
| 197 | clicky_rand += 0.5f; | ||
| 198 | } else { | ||
| 199 | clicky_rand -= 0.5f; | ||
| 200 | } | ||
| 195 | } else { | 201 | } else { |
| 196 | clicky_freq_down(); | 202 | if (clockwise) { |
| 203 | clicky_freq_up(); | ||
| 204 | } else { | ||
| 205 | clicky_freq_down(); | ||
| 206 | } | ||
| 197 | } | 207 | } |
| 198 | } else | 208 | } else if (muse_mode) { |
| 199 | if (muse_mode) { | ||
| 200 | if (IS_LAYER_ON(_RAISE)) { | 209 | if (IS_LAYER_ON(_RAISE)) { |
| 201 | if (clockwise) { | 210 | if (clockwise) { |
| 202 | muse_offset++; | 211 | muse_offset++; |
| @@ -255,7 +264,8 @@ void dip_update(uint8_t index, bool active) { | |||
| 255 | stop_all_notes(); | 264 | stop_all_notes(); |
| 256 | #endif | 265 | #endif |
| 257 | } | 266 | } |
| 258 | case 2: | 267 | break; |
| 268 | case 3: | ||
| 259 | if (active) { | 269 | if (active) { |
| 260 | clicky_on(); | 270 | clicky_on(); |
| 261 | } else { | 271 | } else { |
