]> git.donarmstrong.com Git - qmk_firmware.git/blobdiff - docs/feature_encoders.md
Cleanup rules.mk for 32U4 keyboards, 0-9 (#6789)
[qmk_firmware.git] / docs / feature_encoders.md
index 6eab402ef94f846a03943d46db974481514aa217..cbf72914e9288626b0ba1a53ae4ed2733805013f 100644 (file)
@@ -6,7 +6,6 @@ Basic encoders are supported by adding this to your `rules.mk`:
 
 and this to your `config.h`:
 
-    #define NUMBER_OF_ENCODERS 1
     #define ENCODERS_PAD_A { B12 }
     #define ENCODERS_PAD_B { B13 }
 
@@ -21,6 +20,15 @@ Additionally, the resolution can be specified in the same file (the default & su
 
     #define ENCODER_RESOLUTION 4
 
+## Split Keyboards
+
+If you are using different pinouts for the encoders on each half of a split keyboard, you can define the pinout for the right half like this:
+
+```c
+#define ENCODERS_PAD_A_RIGHT { encoder1a, encoder2a }
+#define ENCODERS_PAD_B_RIGHT { encoder1b, encoder2b }
+```
+
 ## Callbacks
 
 The callback functions can be inserted into your `<keyboard>.c`:
@@ -38,7 +46,7 @@ or `keymap.c`:
         } else {
           tap_code(KC_PGUP);
         }
-      } else if (index == 2) {
+      } else if (index == 1) { /* Second encoder */  
         if (clockwise) {
           tap_code(KC_UP);
         } else {