From 7e0299117b389b1c7fcdfa2f20891ba2287ea771 Mon Sep 17 00:00:00 2001 From: Ryan Date: Sun, 26 Feb 2023 09:45:12 +1100 Subject: [PATCH] Move encoder config to data driven (#19923) Co-authored-by: Nick Brassel --- keyboards/0xcb/1337/config.h | 3 - keyboards/0xcb/1337/info.json | 5 ++ keyboards/0xcb/static/config.h | 3 - keyboards/0xcb/static/info.json | 5 ++ keyboards/10bleoledhub/config.h | 5 -- keyboards/10bleoledhub/info.json | 5 ++ keyboards/1upkeyboards/pi40/config.h | 3 - keyboards/1upkeyboards/pi40/info.json | 5 ++ keyboards/1upkeyboards/super16v2/config.h | 4 -- keyboards/1upkeyboards/super16v2/info.json | 6 ++ keyboards/25keys/aleth42/rev0/config.h | 3 - keyboards/25keys/aleth42/rev0/info.json | 6 ++ keyboards/25keys/aleth42/rev1/config.h | 3 - keyboards/25keys/aleth42/rev1/info.json | 6 ++ keyboards/25keys/cassette42/config.h | 4 -- keyboards/25keys/cassette42/info.json | 6 ++ keyboards/2key2crawl/config.h | 5 -- keyboards/2key2crawl/info.json | 5 ++ keyboards/45_ats/config.h | 4 -- keyboards/45_ats/info.json | 5 ++ keyboards/7c8/framework/config.h | 3 - keyboards/7c8/framework/info.json | 5 ++ keyboards/abacus/config.h | 4 -- keyboards/abacus/info.json | 5 ++ keyboards/abstract/ellipse/rev1/config.h | 4 -- keyboards/abstract/ellipse/rev1/info.json | 13 ++++- keyboards/acheron/shark/alpha/config.h | 5 -- keyboards/acheron/shark/alpha/info.json | 5 ++ keyboards/acheron/shark/beta/config.h | 3 - keyboards/acheron/shark/beta/info.json | 5 ++ keyboards/adafruit/macropad/config.h | 4 -- keyboards/adafruit/macropad/info.json | 5 ++ keyboards/adpenrose/akemipad/config.h | 6 -- keyboards/adpenrose/akemipad/info.json | 5 ++ keyboards/adpenrose/kintsugi/config.h | 6 -- keyboards/adpenrose/kintsugi/info.json | 5 ++ keyboards/adpenrose/obi/config.h | 6 -- keyboards/adpenrose/obi/info.json | 5 ++ keyboards/aidansmithdotdev/fine40/config.h | 5 -- keyboards/aidansmithdotdev/fine40/info.json | 5 ++ keyboards/aleblazer/zodiark/config.h | 6 -- keyboards/aleblazer/zodiark/info.json | 14 ++++- keyboards/ano/config.h | 5 -- keyboards/ano/info.json | 5 ++ keyboards/aplyard/aplx6/rev2/config.h | 5 -- keyboards/aplyard/aplx6/rev2/info.json | 5 ++ keyboards/arrayperipherals/1x4p1/config.h | 22 ------- keyboards/arrayperipherals/1x4p1/info.json | 5 ++ keyboards/atlantis/ak81_ve/config.h | 5 -- keyboards/atlantis/ak81_ve/info.json | 5 ++ keyboards/atlantis/encoder_actions.c | 15 ++--- keyboards/atreyu/rev1/config.h | 7 --- keyboards/atreyu/rev1/info.json | 14 +++++ keyboards/atreyu/rev2/config.h | 5 -- keyboards/atreyu/rev2/info.json | 6 ++ keyboards/avalanche/v2/config.h | 4 -- keyboards/avalanche/v2/info.json | 5 ++ keyboards/avalanche/v3/config.h | 4 -- keyboards/avalanche/v3/info.json | 5 ++ keyboards/avalanche/v4/config.h | 4 -- keyboards/avalanche/v4/info.json | 5 ++ keyboards/bandominedoni/config.h | 13 +---- keyboards/bandominedoni/info.json | 9 ++- keyboards/basekeys/trifecta/config.h | 4 -- keyboards/basekeys/trifecta/info.json | 7 +++ keyboards/basketweave/config.h | 3 - keyboards/basketweave/info.json | 5 ++ keyboards/bbrfkr/dynamis/config.h | 4 -- keyboards/bbrfkr/dynamis/info.json | 5 ++ keyboards/bluebell/swoop/config.h | 6 -- keyboards/bluebell/swoop/info.json | 14 ++++- keyboards/bobpad/config.h | 3 - keyboards/bobpad/info.json | 5 ++ keyboards/bolsa/damapad/config.h | 4 -- keyboards/bolsa/damapad/info.json | 5 ++ keyboards/boston/config.h | 6 -- keyboards/boston/info.json | 5 ++ keyboards/boston_meetup/2019/config.h | 3 - keyboards/boston_meetup/2019/info.json | 5 ++ keyboards/cannonkeys/balance/config.h | 4 -- keyboards/cannonkeys/balance/info.json | 5 ++ keyboards/cannonkeys/ortho75/config.h | 3 - keyboards/cannonkeys/ortho75/info.json | 5 ++ keyboards/cannonkeys/satisfaction75/config.h | 5 -- keyboards/cannonkeys/satisfaction75/info.json | 5 ++ keyboards/capsunlocked/cu7/config.h | 6 -- keyboards/capsunlocked/cu7/info.json | 5 ++ .../checkerboards/phoenix45_ortho/config.h | 5 -- .../checkerboards/phoenix45_ortho/info.json | 5 ++ keyboards/checkerboards/quark/config.h | 5 -- keyboards/checkerboards/quark/info.json | 5 ++ keyboards/checkerboards/quark_plus/config.h | 4 -- keyboards/checkerboards/quark_plus/info.json | 8 +++ .../checkerboards/quark_squared/config.h | 4 -- .../checkerboards/quark_squared/info.json | 5 ++ keyboards/checkerboards/snop60/config.h | 3 - keyboards/checkerboards/snop60/info.json | 5 ++ keyboards/cherrybstudio/cb65/config.h | 5 -- keyboards/chocofly/v1/config.h | 4 -- keyboards/chocofly/v1/info.json | 5 ++ keyboards/chromatonemini/info.json | 2 +- keyboards/ck60i/config.h | 3 - keyboards/ck60i/info.json | 5 ++ keyboards/ckeys/thedora/config.h | 5 -- keyboards/ckeys/thedora/info.json | 5 ++ keyboards/ckeys/washington/config.h | 3 - keyboards/ckeys/washington/info.json | 5 ++ keyboards/clickety_split/leeloo/info.json | 14 ++++- keyboards/clickety_split/leeloo/rev1/config.h | 6 -- keyboards/clueboard/2x1800/2019/config.h | 8 --- keyboards/clueboard/2x1800/2019/info.json | 8 +++ keyboards/clueboard/2x1800/2021/config.h | 7 --- keyboards/clueboard/2x1800/2021/info.json | 6 ++ keyboards/crbn/config.h | 7 --- keyboards/crbn/info.json | 5 ++ keyboards/custommk/evo70/config.h | 3 - keyboards/custommk/evo70/info.json | 5 ++ keyboards/custommk/genesis/rev1/config.h | 3 - keyboards/custommk/genesis/rev1/info.json | 6 ++ keyboards/custommk/genesis/rev2/config.h | 3 - keyboards/custommk/genesis/rev2/info.json | 6 ++ keyboards/dailycraft/owl8/config.h | 3 - keyboards/dailycraft/owl8/info.json | 6 ++ keyboards/dailycraft/stickey4/config.h | 3 - keyboards/dailycraft/stickey4/info.json | 6 ++ keyboards/delikeeb/vaguettelite/config.h | 4 -- keyboards/delikeeb/vaguettelite/info.json | 6 ++ keyboards/delikeeb/vanana/rev1/config.h | 3 - keyboards/delikeeb/vanana/rev1/info.json | 6 ++ keyboards/delikeeb/vanana/rev2/config.h | 3 - keyboards/delikeeb/vanana/rev2/info.json | 6 ++ keyboards/delikeeb/waaffle/rev3/config.h | 4 -- keyboards/delikeeb/waaffle/rev3/info.json | 6 ++ keyboards/dmqdesign/spin/config.h | 5 -- keyboards/dmqdesign/spin/info.json | 7 +++ keyboards/doio/kb16/rev1/config.h | 4 -- keyboards/doio/kb16/rev1/info.json | 7 +++ keyboards/doio/kb16/rev2/config.h | 4 -- keyboards/doio/kb16/rev2/info.json | 7 +++ keyboards/doio/kb30/config.h | 6 -- keyboards/doio/kb30/info.json | 7 +++ keyboards/doio/kb38/config.h | 5 -- keyboards/doio/kb38/info.json | 7 +++ keyboards/doodboard/duckboard/config.h | 4 -- keyboards/doodboard/duckboard/info.json | 5 ++ keyboards/doodboard/duckboard_r2/config.h | 4 -- keyboards/doodboard/duckboard_r2/info.json | 5 ++ keyboards/draculad/config.h | 6 -- keyboards/draculad/info.json | 16 ++++- keyboards/draytronics/daisy/config.h | 2 - keyboards/draytronics/daisy/info.json | 6 ++ keyboards/drhigsby/bkf/config.h | 4 -- keyboards/drhigsby/bkf/info.json | 5 ++ keyboards/drhigsby/packrat/config.h | 3 - keyboards/drhigsby/packrat/info.json | 5 ++ keyboards/dumbo/config.h | 5 -- keyboards/dumbo/info.json | 16 ++++- keyboards/dumbpad/v0x/config.h | 4 -- keyboards/dumbpad/v0x/info.json | 5 ++ keyboards/dumbpad/v0x_dualencoder/config.h | 4 -- keyboards/dumbpad/v0x_dualencoder/info.json | 6 ++ keyboards/dumbpad/v0x_right/config.h | 4 -- keyboards/dumbpad/v0x_right/info.json | 5 ++ keyboards/dumbpad/v1x/config.h | 4 -- keyboards/dumbpad/v1x/info.json | 5 ++ keyboards/dumbpad/v1x_dualencoder/config.h | 4 -- keyboards/dumbpad/v1x_dualencoder/info.json | 6 ++ keyboards/dumbpad/v1x_oled/config.h | 4 -- keyboards/dumbpad/v1x_oled/info.json | 6 ++ keyboards/dumbpad/v1x_right/config.h | 4 -- keyboards/dumbpad/v1x_right/info.json | 5 ++ keyboards/dumbpad/v3x/config.h | 4 -- keyboards/dumbpad/v3x/info.json | 5 ++ keyboards/dyz/dyz40/config.h | 2 - keyboards/dyz/dyz40/info.json | 5 ++ keyboards/dyz/dyz60/config.h | 2 - keyboards/dyz/dyz60/info.json | 5 ++ keyboards/dyz/selka40/config.h | 2 - keyboards/dyz/selka40/info.json | 5 ++ keyboards/ealdin/quadrant/config.h | 4 -- keyboards/ealdin/quadrant/info.json | 5 ++ keyboards/ebastler/isometria_75/rev1/config.h | 7 --- .../ebastler/isometria_75/rev1/info.json | 5 ++ keyboards/ein_60/config.h | 6 -- keyboards/ein_60/info.json | 6 ++ keyboards/evolv/config.h | 3 - keyboards/evolv/info.json | 5 ++ keyboards/evyd13/atom47/rev4/config.h | 3 - keyboards/evyd13/atom47/rev4/info.json | 5 ++ keyboards/evyd13/eon40/config.h | 3 - keyboards/evyd13/eon40/info.json | 7 +++ keyboards/evyd13/gh80_3700/config.h | 4 -- keyboards/evyd13/gh80_3700/info.json | 5 ++ keyboards/evyd13/ta65/config.h | 6 -- keyboards/evyd13/ta65/info.json | 5 ++ keyboards/eyeohdesigns/sprh/config.h | 6 -- keyboards/eyeohdesigns/sprh/info.json | 5 ++ keyboards/eyeohdesigns/theboulevard/config.h | 5 -- keyboards/eyeohdesigns/theboulevard/info.json | 5 ++ keyboards/feker/ik75/config.h | 9 --- keyboards/feker/ik75/info.json | 5 ++ keyboards/ffkeebs/puca/config.h | 4 -- keyboards/ffkeebs/puca/info.json | 5 ++ keyboards/ffkeebs/siris/config.h | 3 - keyboards/ffkeebs/siris/info.json | 6 ++ keyboards/flxlb/zplit/config.h | 3 - keyboards/flxlb/zplit/info.json | 5 ++ keyboards/giabalanai/config.h | 13 +---- keyboards/giabalanai/info.json | 12 +++- keyboards/gl516/n51gl/config.h | 4 -- keyboards/gl516/n51gl/info.json | 5 ++ keyboards/gmmk/pro/config.h | 4 -- keyboards/gmmk/pro/rev1/ansi/info.json | 5 ++ keyboards/gmmk/pro/rev1/iso/info.json | 5 ++ keyboards/gmmk/pro/rev2/ansi/info.json | 5 ++ keyboards/gmmk/pro/rev2/iso/info.json | 5 ++ keyboards/gorthage_truck/config.h | 3 - keyboards/gorthage_truck/info.json | 5 ++ keyboards/h0oni/deskpad/config.h | 4 -- keyboards/h0oni/deskpad/info.json | 5 ++ keyboards/hadron/ver3/config.h | 4 -- keyboards/hadron/ver3/info.json | 5 ++ keyboards/halfcliff/config.h | 5 -- keyboards/halfcliff/info.json | 5 ++ keyboards/halokeys/elemental75/config.h | 2 - keyboards/halokeys/elemental75/info.json | 5 ++ keyboards/handwired/amigopunk/config.h | 6 -- keyboards/handwired/amigopunk/info.json | 5 ++ keyboards/handwired/bento/rev1/config.h | 3 - keyboards/handwired/bento/rev1/info.json | 5 ++ keyboards/handwired/d48/config.h | 5 -- keyboards/handwired/d48/info.json | 6 ++ keyboards/handwired/dactylmacropad/config.h | 3 - keyboards/handwired/dactylmacropad/info.json | 5 ++ keyboards/handwired/daishi/config.h | 5 -- keyboards/handwired/daishi/info.json | 5 ++ .../daskeyboard/daskeyboard4/info.json | 3 +- keyboards/handwired/dc/mc/001/config.h | 10 ---- keyboards/handwired/dc/mc/001/info.json | 5 ++ keyboards/handwired/ddg_56/config.h | 3 - keyboards/handwired/ddg_56/info.json | 6 ++ keyboards/handwired/frankie_macropad/config.h | 3 - .../handwired/frankie_macropad/info.json | 6 ++ keyboards/handwired/hnah108/config.h | 3 - keyboards/handwired/hnah108/info.json | 5 ++ keyboards/handwired/mutepad/config.h | 8 --- keyboards/handwired/mutepad/info.json | 5 ++ .../handwired/obuwunkunubi/spaget/config.h | 4 -- .../handwired/obuwunkunubi/spaget/info.json | 6 ++ keyboards/handwired/pill60/config.h | 35 +++++------ keyboards/handwired/pill60/info.json | 5 ++ keyboards/handwired/prkl30/feather/config.h | 3 - keyboards/handwired/prkl30/feather/info.json | 7 +++ keyboards/handwired/prkl30/promicro/config.h | 3 - keyboards/handwired/prkl30/promicro/info.json | 7 +++ keyboards/handwired/snatchpad/config.h | 5 -- keyboards/handwired/snatchpad/info.json | 6 ++ .../handwired/swiftrax/bumblebee/config.h | 4 -- .../handwired/swiftrax/bumblebee/info.json | 5 ++ .../handwired/swiftrax/digicarp65/config.h | 3 - .../handwired/swiftrax/digicarp65/info.json | 5 ++ keyboards/handwired/swiftrax/joypad/config.h | 3 - keyboards/handwired/swiftrax/joypad/info.json | 5 ++ .../handwired/swiftrax/pandamic/config.h | 4 -- .../handwired/swiftrax/pandamic/info.json | 5 ++ keyboards/handwired/swiftrax/walter/config.h | 3 - keyboards/handwired/swiftrax/walter/info.json | 5 ++ .../5x6_right/elite_c/config.h | 5 -- .../5x6_right/elite_c/info.json | 5 ++ .../tractyl_manuform/5x6_right/f303/config.h | 6 -- .../tractyl_manuform/5x6_right/f303/info.json | 5 ++ .../tractyl_manuform/5x6_right/f411/config.h | 6 -- .../tractyl_manuform/5x6_right/f411/info.json | 5 ++ .../5x6_right/teensy2pp/config.h | 5 -- .../5x6_right/teensy2pp/info.json | 5 ++ keyboards/handwired/uthol/rev3/config.h | 8 --- keyboards/handwired/uthol/rev3/info.json | 5 ++ keyboards/helix/rev3_4rows/config.h | 4 -- keyboards/helix/rev3_4rows/info.json | 5 ++ keyboards/helix/rev3_5rows/config.h | 4 -- keyboards/helix/rev3_5rows/info.json | 5 ++ keyboards/hillside/46/0_1/config.h | 6 -- keyboards/hillside/46/0_1/info.json | 14 ++++- keyboards/hillside/48/0_1/config.h | 7 --- keyboards/hillside/48/0_1/info.json | 14 ++++- keyboards/hillside/52/0_1/config.h | 6 -- keyboards/hillside/52/0_1/info.json | 14 ++++- keyboards/hnahkb/vn66/config.h | 4 -- keyboards/hnahkb/vn66/info.json | 5 ++ keyboards/hub16/config.h | 7 --- keyboards/hub16/info.json | 6 ++ keyboards/hub20/config.h | 5 -- keyboards/hub20/info.json | 6 ++ keyboards/io_mini1800/config.h | 3 - keyboards/io_mini1800/info.json | 5 ++ keyboards/jagdpietr/drakon/config.h | 3 - keyboards/jagdpietr/drakon/info.json | 5 ++ keyboards/jkeys_design/gentleman65/config.h | 4 -- keyboards/jkeys_design/gentleman65/info.json | 5 ++ .../jkeys_design/gentleman65_se_s/config.h | 4 -- .../jkeys_design/gentleman65_se_s/info.json | 5 ++ keyboards/jones/v03/config.h | 5 -- keyboards/jones/v03/info.json | 6 ++ keyboards/jones/v03_1/config.h | 5 -- keyboards/jones/v03_1/info.json | 6 ++ keyboards/jones/v1/config.h | 5 -- keyboards/jones/v1/info.json | 6 ++ keyboards/jones/v1/keymaps/via/config.h | 3 - keyboards/jones/v1/keymaps/via/keymap.c | 8 +-- keyboards/kabedon/kabedon98e/config.h | 4 -- keyboards/kabedon/kabedon98e/info.json | 6 ++ keyboards/kabedon/kabedon98e/kabedon98e.c | 8 +-- keyboards/kapcave/arya/config.h | 4 -- keyboards/kapcave/arya/info.json | 7 +++ keyboards/keebio/bamfk1/config.h | 3 - keyboards/keebio/bamfk1/info.json | 6 ++ keyboards/keebio/bdn9/rev1/config.h | 3 - keyboards/keebio/bdn9/rev1/info.json | 7 +++ keyboards/keebio/bdn9/rev2/config.h | 3 - keyboards/keebio/bdn9/rev2/info.json | 7 +++ keyboards/keebio/dsp40/rev1/config.h | 3 +- keyboards/keebio/dsp40/rev1/info.json | 5 ++ keyboards/keebio/encoder_actions.c | 15 ++--- keyboards/keebio/foldkb/rev1/config.h | 2 - keyboards/keebio/foldkb/rev1/info.json | 5 ++ keyboards/keebio/iris/rev3/config.h | 3 - keyboards/keebio/iris/rev3/info.json | 5 ++ keyboards/keebio/iris/rev4/config.h | 5 -- keyboards/keebio/iris/rev4/info.json | 14 ++++- keyboards/keebio/iris/rev5/config.h | 5 -- keyboards/keebio/iris/rev5/info.json | 14 ++++- keyboards/keebio/iris/rev6/config.h | 5 -- keyboards/keebio/iris/rev6/info.json | 5 ++ keyboards/keebio/iris/rev6a/config.h | 5 -- keyboards/keebio/iris/rev6a/info.json | 5 ++ keyboards/keebio/iris/rev6b/config.h | 5 -- keyboards/keebio/iris/rev6b/info.json | 5 ++ keyboards/keebio/iris/rev7/config.h | 5 -- keyboards/keebio/iris/rev7/info.json | 6 ++ keyboards/keebio/kbo5000/rev1/config.h | 4 -- keyboards/keebio/kbo5000/rev1/info.json | 16 ++++- keyboards/keebio/quefrency/rev2/config.h | 4 -- keyboards/keebio/quefrency/rev2/info.json | 14 ++++- keyboards/keebio/quefrency/rev3/config.h | 4 -- keyboards/keebio/quefrency/rev3/info.json | 14 ++++- keyboards/keebio/quefrency/rev4/config.h | 4 -- keyboards/keebio/quefrency/rev4/info.json | 14 ++++- keyboards/keebio/quefrency/rev5/config.h | 4 -- keyboards/keebio/quefrency/rev5/info.json | 14 ++++- keyboards/keebio/stick/config.h | 3 - keyboards/keebio/stick/info.json | 6 ++ keyboards/keebsforall/coarse60/config.h | 4 -- keyboards/keebsforall/coarse60/info.json | 5 ++ keyboards/keebsforall/freebirdnp/pro/config.h | 4 -- .../keebsforall/freebirdnp/pro/info.json | 5 ++ keyboards/keybage/radpad/config.h | 5 -- keyboards/keybage/radpad/info.json | 6 ++ keyboards/keycapsss/kimiko/rev1/config.h | 7 --- keyboards/keycapsss/kimiko/rev1/info.json | 5 ++ keyboards/keycapsss/plaid_pad/config.h | 2 - keyboards/keycapsss/plaid_pad/rev1/config.h | 3 - keyboards/keycapsss/plaid_pad/rev1/info.json | 8 ++- keyboards/keycapsss/plaid_pad/rev2/config.h | 3 - keyboards/keycapsss/plaid_pad/rev2/info.json | 8 +++ keyboards/keycapsss/plaid_pad/rev3/config.h | 20 ------- keyboards/keycapsss/plaid_pad/rev3/info.json | 10 +++- keyboards/keychron/q0/rev_0131/config.h | 3 - keyboards/keychron/q0/rev_0131/info.json | 5 ++ keyboards/keychron/q1/ansi_encoder/config.h | 7 --- keyboards/keychron/q1/ansi_encoder/info.json | 5 ++ keyboards/keychron/q1/iso_encoder/config.h | 4 -- keyboards/keychron/q1/iso_encoder/info.json | 5 ++ keyboards/keychron/q10/ansi_encoder/config.h | 3 - keyboards/keychron/q10/ansi_encoder/info.json | 5 ++ keyboards/keychron/q10/iso_encoder/config.h | 3 - keyboards/keychron/q10/iso_encoder/info.json | 5 ++ keyboards/keychron/q2/ansi_encoder/config.h | 3 - keyboards/keychron/q2/ansi_encoder/info.json | 5 ++ keyboards/keychron/q2/iso_encoder/config.h | 3 - keyboards/keychron/q2/iso_encoder/info.json | 5 ++ keyboards/keychron/q2/jis_encoder/config.h | 3 - keyboards/keychron/q2/jis_encoder/info.json | 5 ++ keyboards/keychron/q3/ansi_encoder/config.h | 3 - keyboards/keychron/q3/ansi_encoder/info.json | 5 ++ keyboards/keychron/q3/iso_encoder/config.h | 3 - keyboards/keychron/q3/iso_encoder/info.json | 5 ++ keyboards/keychron/q3/jis_encoder/config.h | 3 - keyboards/keychron/q3/jis_encoder/info.json | 5 ++ keyboards/keychron/q5/ansi_encoder/config.h | 3 - keyboards/keychron/q5/ansi_encoder/info.json | 5 ++ keyboards/keychron/q5/iso_encoder/config.h | 3 - keyboards/keychron/q5/iso_encoder/info.json | 5 ++ keyboards/keychron/q6/ansi_encoder/config.h | 3 - keyboards/keychron/q6/ansi_encoder/info.json | 5 ++ keyboards/keychron/q6/iso_encoder/config.h | 3 - keyboards/keychron/q6/iso_encoder/info.json | 5 ++ keyboards/keychron/q65/ansi_encoder/config.h | 3 - keyboards/keychron/q65/ansi_encoder/info.json | 5 ++ keyboards/keychron/q8/ansi_encoder/config.h | 3 - keyboards/keychron/q8/ansi_encoder/info.json | 5 ++ keyboards/keychron/q8/iso_encoder/config.h | 3 - keyboards/keychron/q8/iso_encoder/info.json | 5 ++ keyboards/keychron/q9/ansi_encoder/config.h | 3 - keyboards/keychron/q9/ansi_encoder/info.json | 5 ++ keyboards/keychron/q9/iso_encoder/config.h | 3 - keyboards/keychron/q9/iso_encoder/info.json | 5 ++ keyboards/keychron/v1/ansi_encoder/config.h | 3 - keyboards/keychron/v1/ansi_encoder/info.json | 5 ++ keyboards/keychron/v1/iso_encoder/config.h | 3 - keyboards/keychron/v1/iso_encoder/info.json | 5 ++ keyboards/keychron/v1/jis_encoder/config.h | 3 - keyboards/keychron/v1/jis_encoder/info.json | 5 ++ keyboards/keychron/v10/ansi_encoder/config.h | 3 - keyboards/keychron/v10/ansi_encoder/info.json | 5 ++ keyboards/keychron/v10/iso_encoder/config.h | 3 - keyboards/keychron/v10/iso_encoder/info.json | 5 ++ keyboards/keychron/v2/ansi_encoder/config.h | 3 - keyboards/keychron/v2/ansi_encoder/info.json | 5 ++ keyboards/keychron/v2/iso_encoder/config.h | 3 - keyboards/keychron/v2/iso_encoder/info.json | 5 ++ keyboards/keychron/v2/jis_encoder/config.h | 3 - keyboards/keychron/v2/jis_encoder/info.json | 5 ++ keyboards/keychron/v3/ansi_encoder/config.h | 3 - keyboards/keychron/v3/ansi_encoder/info.json | 5 ++ keyboards/keychron/v3/iso_encoder/config.h | 3 - keyboards/keychron/v3/iso_encoder/info.json | 5 ++ keyboards/keychron/v3/jis_encoder/config.h | 3 - keyboards/keychron/v3/jis_encoder/info.json | 5 ++ keyboards/keychron/v5/ansi_encoder/config.h | 3 - keyboards/keychron/v5/ansi_encoder/info.json | 5 ++ keyboards/keychron/v5/iso_encoder/config.h | 3 - keyboards/keychron/v5/iso_encoder/info.json | 5 ++ keyboards/keychron/v6/ansi_encoder/config.h | 3 - keyboards/keychron/v6/ansi_encoder/info.json | 5 ++ keyboards/keychron/v6/iso_encoder/config.h | 3 - keyboards/keychron/v6/iso_encoder/info.json | 5 ++ keyboards/keychron/v8/ansi_encoder/config.h | 3 - keyboards/keychron/v8/ansi_encoder/info.json | 5 ++ keyboards/keychron/v8/iso_encoder/config.h | 3 - keyboards/keychron/v8/iso_encoder/info.json | 5 ++ keyboards/keyhive/absinthe/config.h | 3 - keyboards/keyhive/absinthe/info.json | 5 ++ keyboards/keyhive/uno/rev2/config.h | 4 -- keyboards/keyhive/uno/rev2/info.json | 5 ++ keyboards/keyprez/bison/config.h | 6 -- keyboards/keyprez/bison/info.json | 14 ++++- keyboards/keyprez/corgi/config.h | 4 -- keyboards/keyprez/corgi/info.json | 5 ++ keyboards/keyprez/rhino/config.h | 4 -- keyboards/keyprez/rhino/info.json | 5 ++ keyboards/keyprez/unicorn/config.h | 7 --- keyboards/keyprez/unicorn/info.json | 5 ++ keyboards/keysofkings/twokey/config.h | 5 -- keyboards/keysofkings/twokey/info.json | 5 ++ .../keystonecaps/gameroyadvance/config.h | 5 -- .../keystonecaps/gameroyadvance/info.json | 14 ++++- keyboards/kikoslab/ellora65/config.h | 3 - keyboards/kikoslab/ellora65/info.json | 5 ++ keyboards/kikoslab/kl90/config.h | 3 - keyboards/kikoslab/kl90/info.json | 6 ++ keyboards/kingly_keys/ave/config.h | 4 -- keyboards/kingly_keys/ave/ortho/info.json | 5 ++ keyboards/kingly_keys/ave/staggered/info.json | 5 ++ keyboards/kingly_keys/romac_plus/config.h | 3 - keyboards/kingly_keys/romac_plus/info.json | 5 ++ keyboards/kingly_keys/ropro/config.h | 4 -- keyboards/kingly_keys/ropro/info.json | 5 ++ keyboards/kingly_keys/soap/config.h | 4 -- keyboards/kingly_keys/soap/info.json | 5 ++ keyboards/kiwikeebs/macro/config.h | 3 - keyboards/kiwikeebs/macro/info.json | 5 ++ keyboards/kiwikeebs/macro_v2/config.h | 3 - keyboards/kiwikeebs/macro_v2/info.json | 5 ++ keyboards/kiwikey/borderland/config.h | 3 - keyboards/kiwikey/borderland/info.json | 5 ++ keyboards/knobgoblin/config.h | 3 - keyboards/knobgoblin/info.json | 6 ++ .../kprepublic/bm60hsrgb_ec/rev1/config.h | 5 -- .../kprepublic/bm60hsrgb_ec/rev1/info.json | 5 ++ .../kprepublic/bm60hsrgb_ec/rev2/config.h | 5 -- .../kprepublic/bm60hsrgb_ec/rev2/info.json | 5 ++ keyboards/latincompass/latinpad/config.h | 5 -- keyboards/latincompass/latinpad/info.json | 6 ++ keyboards/latincompass/latinpadble/config.h | 5 -- keyboards/latincompass/latinpadble/info.json | 5 ++ keyboards/leafcutterlabs/bigknob/config.h | 5 -- keyboards/leafcutterlabs/bigknob/info.json | 5 ++ keyboards/lily58/glow_enc/config.h | 5 -- keyboards/lily58/glow_enc/info.json | 14 ++++- keyboards/lily58/light/config.h | 5 -- keyboards/lily58/light/info.json | 14 ++++- keyboards/lime/rev1/config.h | 9 --- keyboards/lime/rev1/info.json | 14 ++++- keyboards/linworks/whale75/config.h | 7 --- keyboards/linworks/whale75/info.json | 5 ++ .../lizard_trick/tenkey_plusplus/config.h | 5 -- .../lizard_trick/tenkey_plusplus/info.json | 7 +++ keyboards/ll3macorn/bongopad/config.h | 4 -- keyboards/ll3macorn/bongopad/info.json | 5 ++ keyboards/lw67/config.h | 5 -- keyboards/lw67/info.json | 5 ++ keyboards/lw75/config.h | 4 -- keyboards/lw75/info.json | 5 ++ keyboards/lyso1/lck75/config.h | 4 -- keyboards/lyso1/lck75/info.json | 5 ++ keyboards/macro1/config.h | 5 -- keyboards/macro1/info.json | 5 ++ keyboards/macro3/config.h | 9 --- keyboards/macro3/info.json | 6 ++ keyboards/macrocat/config.h | 4 -- keyboards/macrocat/info.json | 5 ++ keyboards/makrosu/config.h | 2 - keyboards/makrosu/info.json | 5 ++ keyboards/manyboard/macro/config.h | 4 -- keyboards/manyboard/macro/info.json | 5 ++ keyboards/marksard/leftover30/config.h | 6 -- keyboards/marksard/leftover30/info.json | 5 ++ keyboards/matthewdias/m3n3van/config.h | 2 - keyboards/matthewdias/m3n3van/info.json | 5 ++ keyboards/maxr1998/pulse4k/config.h | 5 -- keyboards/maxr1998/pulse4k/info.json | 6 ++ keyboards/mb44/config.h | 4 -- keyboards/mb44/info.json | 5 ++ keyboards/mechanickeys/undead60m/config.h | 5 -- keyboards/mechanickeys/undead60m/info.json | 5 ++ .../mechlovin/adelais/rgb_led/rev2/config.h | 4 -- .../mechlovin/adelais/rgb_led/rev2/info.json | 5 ++ .../mechlovin/adelais/rgb_led/rev3/config.h | 5 -- .../mechlovin/adelais/rgb_led/rev3/info.json | 5 ++ .../adelais/standard_led/arm/rev3/config.h | 4 -- .../adelais/standard_led/arm/rev3/info.json | 7 +++ .../adelais/standard_led/arm/rev4/config.h | 4 -- .../adelais/standard_led/arm/rev4/info.json | 7 +++ .../adelais/standard_led/avr/rev1/config.h | 4 -- .../adelais/standard_led/avr/rev1/info.json | 7 +++ keyboards/mechlovin/foundation/config.h | 5 -- keyboards/mechlovin/foundation/info.json | 5 ++ keyboards/mechlovin/hex6c/config.h | 4 -- keyboards/mechlovin/hex6c/info.json | 5 ++ .../zed65/no_backlight/retro66/config.h | 7 --- .../zed65/no_backlight/retro66/info.json | 6 ++ keyboards/mechwild/bde/rev2/config.h | 7 --- keyboards/mechwild/bde/rev2/info.json | 5 ++ keyboards/mechwild/clunker/config.h | 4 -- keyboards/mechwild/clunker/info.json | 5 ++ keyboards/mechwild/mercutio/config.h | 6 -- keyboards/mechwild/mercutio/info.json | 5 ++ keyboards/mechwild/mokulua/mirrored/config.h | 6 -- keyboards/mechwild/mokulua/mirrored/info.json | 5 ++ keyboards/mechwild/mokulua/standard/config.h | 6 -- keyboards/mechwild/mokulua/standard/info.json | 5 ++ keyboards/mechwild/murphpad/config.h | 6 -- keyboards/mechwild/murphpad/info.json | 6 ++ keyboards/mechwild/obe/config.h | 6 -- keyboards/mechwild/obe/info.json | 5 ++ keyboards/mechwild/puckbuddy/config.h | 6 -- keyboards/mechwild/puckbuddy/info.json | 6 ++ keyboards/mechwild/waka60/config.h | 6 -- keyboards/mechwild/waka60/info.json | 5 ++ keyboards/meletrix/zoom65/config.h | 8 --- keyboards/meletrix/zoom65/info.json | 5 ++ keyboards/meletrix/zoom65/zoom65.c | 8 +-- keyboards/meletrix/zoom65_lite/config.h | 8 --- keyboards/meletrix/zoom65_lite/info.json | 5 ++ .../meletrix/zoom65_lite/keymaps/via/keymap.c | 12 ++-- keyboards/merge/iso_macro/config.h | 5 -- keyboards/merge/iso_macro/info.json | 6 ++ keyboards/merge/uc1/config.h | 4 -- keyboards/merge/uc1/info.json | 5 ++ keyboards/merge/um70/config.h | 3 - keyboards/merge/um70/info.json | 5 ++ keyboards/merge/um80/config.h | 3 - keyboards/merge/um80/info.json | 5 ++ keyboards/merge/uma/config.h | 3 - keyboards/merge/uma/info.json | 5 ++ keyboards/metamechs/timberwolf/config.h | 10 ---- keyboards/metamechs/timberwolf/info.json | 5 ++ keyboards/mexsistor/ludmila/config.h | 5 -- keyboards/mexsistor/ludmila/info.json | 5 ++ keyboards/millipad/config.h | 6 -- keyboards/millipad/info.json | 5 ++ keyboards/mincedshon/ecila/config.h | 6 -- keyboards/mini_elixivy/config.h | 2 - keyboards/mini_elixivy/info.json | 5 ++ keyboards/mini_ten_key_plus/config.h | 4 -- keyboards/mini_ten_key_plus/info.json | 5 ++ keyboards/minimacro5/config.h | 6 -- keyboards/minimacro5/info.json | 9 +++ keyboards/misonoworks/karina/config.h | 5 -- keyboards/misonoworks/karina/info.json | 6 ++ keyboards/mixi/config.h | 3 - keyboards/mixi/info.json | 6 ++ keyboards/mk65/config.h | 5 -- keyboards/mk65/info.json | 5 ++ keyboards/ml/gas75/config.h | 4 -- keyboards/ml/gas75/info.json | 5 ++ keyboards/ml/gas75/keymaps/via/keymap.c | 10 ++-- keyboards/mlego/m48/rev1/config.h | 8 --- keyboards/mlego/m48/rev1/info.json | 5 ++ keyboards/mlego/m60/rev1/config.h | 8 --- keyboards/mlego/m60/rev1/info.json | 5 ++ keyboards/mlego/m60_split/rev1/config.h | 9 --- keyboards/mlego/m60_split/rev1/info.json | 5 ++ keyboards/mlego/m60_split/rev2/config.h | 11 ---- keyboards/mlego/m60_split/rev2/info.json | 5 ++ keyboards/mlego/m65/rev1/config.h | 7 --- keyboards/mlego/m65/rev1/info.json | 5 ++ keyboards/mlego/m65/rev2/config.h | 7 --- keyboards/mlego/m65/rev2/info.json | 5 ++ keyboards/mlego/m65/rev3/config.h | 8 --- keyboards/mlego/m65/rev3/info.json | 5 ++ keyboards/mlego/m65/rev4/config.h | 8 --- keyboards/mlego/m65/rev4/info.json | 5 ++ keyboards/monarch/config.h | 5 -- keyboards/monarch/info.json | 5 ++ keyboards/montsinger/rebound/rev2/config.h | 3 - keyboards/montsinger/rebound/rev2/info.json | 5 ++ keyboards/montsinger/rebound/rev3/config.h | 3 - keyboards/montsinger/rebound/rev3/info.json | 5 ++ keyboards/montsinger/rebound/rev4/config.h | 3 - keyboards/montsinger/rebound/rev4/info.json | 5 ++ keyboards/murcielago/info.json | 14 ++++- keyboards/murcielago/rev1/config.h | 6 -- keyboards/mwstudio/alicekk/config.h | 3 - keyboards/mwstudio/alicekk/info.json | 5 ++ .../mwstudio/alicekk/keymaps/via/keymap.c | 12 ++-- keyboards/mwstudio/mw65_black/config.h | 3 - keyboards/mwstudio/mw65_black/info.json | 5 ++ keyboards/mwstudio/mw65_rgb/config.h | 4 -- keyboards/mwstudio/mw65_rgb/info.json | 5 ++ keyboards/mwstudio/mw75/config.h | 3 - keyboards/mwstudio/mw75/info.json | 5 ++ keyboards/mwstudio/mw75r2/config.h | 3 - keyboards/mwstudio/mw75r2/info.json | 5 ++ .../mwstudio/mw75r2/keymaps/via/keymap.c | 12 ++-- keyboards/ncc1701kb/config.h | 5 -- keyboards/ncc1701kb/info.json | 19 +++--- keyboards/neito/config.h | 3 - keyboards/neito/info.json | 5 ++ keyboards/neopad/rev1/config.h | 4 -- keyboards/neopad/rev1/info.json | 6 ++ keyboards/nightingale_studios/hailey/config.h | 3 - .../nightingale_studios/hailey/info.json | 5 ++ keyboards/nightly_boards/adellein/config.h | 6 -- .../nightly_boards/adellein/encoder_action.c | 14 ++--- keyboards/nightly_boards/adellein/info.json | 5 ++ keyboards/nightly_boards/n40_o/config.h | 6 -- .../nightly_boards/n40_o/encoder_action.c | 14 ++--- keyboards/nightly_boards/n40_o/info.json | 7 +++ keyboards/nightly_boards/n60_s/config.h | 6 -- .../nightly_boards/n60_s/encoder_action.c | 14 ++--- keyboards/nightly_boards/n60_s/info.json | 5 ++ keyboards/nightly_boards/octopad/config.h | 6 -- .../nightly_boards/octopad/encoder_action.c | 14 ++--- keyboards/nightly_boards/octopad/info.json | 6 ++ keyboards/nightly_boards/octopadplus/config.h | 7 --- .../nightly_boards/octopadplus/info.json | 6 ++ keyboards/nixkeyboards/day_off/config.h | 7 --- keyboards/nixkeyboards/day_off/info.json | 5 ++ .../nopunin10did/kastenwagen1840/config.h | 5 -- .../nopunin10did/kastenwagen1840/info.json | 6 ++ keyboards/nopunin10did/kastenwagen48/config.h | 5 -- .../nopunin10did/kastenwagen48/info.json | 6 ++ keyboards/np12/config.h | 5 -- keyboards/np12/info.json | 5 ++ keyboards/nullbitsco/nibble/config.h | 4 -- keyboards/nullbitsco/nibble/info.json | 5 ++ keyboards/nullbitsco/scramble/v1/config.h | 3 - keyboards/nullbitsco/scramble/v1/info.json | 5 ++ keyboards/nullbitsco/scramble/v2/config.h | 3 - keyboards/nullbitsco/scramble/v2/info.json | 5 ++ keyboards/nullbitsco/tidbit/config.h | 5 -- keyboards/nullbitsco/tidbit/info.json | 8 +++ keyboards/om60/config.h | 3 - keyboards/om60/info.json | 5 ++ keyboards/onekeyco/dango40/config.h | 3 - keyboards/onekeyco/dango40/info.json | 5 ++ keyboards/orthocode/config.h | 3 - keyboards/orthocode/info.json | 5 ++ keyboards/owlab/voice65/hotswap/config.h | 4 -- keyboards/owlab/voice65/hotswap/info.json | 5 ++ keyboards/owlab/voice65/soldered/config.h | 4 -- keyboards/owlab/voice65/soldered/info.json | 5 ++ keyboards/p3d/glitch/config.h | 4 -- keyboards/p3d/glitch/info.json | 5 ++ keyboards/pabile/p18/config.h | 4 -- keyboards/pabile/p18/info.json | 6 ++ keyboards/pabile/p20/ver1/config.h | 3 - keyboards/pabile/p20/ver1/info.json | 6 ++ keyboards/palette1202/config.h | 7 --- keyboards/palette1202/info.json | 6 ++ keyboards/pauperboards/brick/info.json | 2 +- keyboards/pearlboards/atlas/config.h | 6 -- keyboards/pearlboards/atlas/info.json | 5 ++ keyboards/pearlboards/pandora/config.h | 5 -- keyboards/pearlboards/pandora/info.json | 5 ++ keyboards/pearlboards/zeus/config.h | 6 -- keyboards/pearlboards/zeus/info.json | 5 ++ keyboards/pearlboards/zeuspad/config.h | 6 -- keyboards/pearlboards/zeuspad/info.json | 5 ++ keyboards/pegasus/config.h | 5 -- keyboards/pegasus/info.json | 6 ++ keyboards/peranekofactory/tone/rev1/config.h | 3 - keyboards/peranekofactory/tone/rev1/info.json | 5 ++ keyboards/peranekofactory/tone/rev2/config.h | 3 - keyboards/peranekofactory/tone/rev2/info.json | 5 ++ keyboards/percent/canoe_gen2/config.h | 3 - keyboards/pica40/rev2/info.json | 2 +- keyboards/pica40/rev2/rev2.h | 3 - keyboards/planck/ez/config.h | 3 - keyboards/planck/ez/info.json | 5 ++ keyboards/planck/rev6/config.h | 4 -- keyboards/planck/rev6/info.json | 5 ++ keyboards/planck/rev6_drop/config.h | 6 -- keyboards/planck/rev6_drop/info.json | 5 ++ keyboards/planck/thk/config.h | 3 - keyboards/planck/thk/info.json | 6 ++ keyboards/pluckey/config.h | 8 --- keyboards/pluckey/info.json | 14 ++++- keyboards/pohjolaworks/louhi/config.h | 4 -- keyboards/pohjolaworks/louhi/info.json | 5 ++ keyboards/preonic/rev3/config.h | 3 - keyboards/preonic/rev3/info.json | 5 ++ keyboards/preonic/rev3_drop/config.h | 3 - keyboards/preonic/rev3_drop/info.json | 5 ++ keyboards/program_yoink/config.h | 4 -- keyboards/program_yoink/ortho/info.json | 5 ++ keyboards/program_yoink/staggered/info.json | 5 ++ keyboards/projectcain/relic/config.h | 3 - keyboards/projectcain/relic/info.json | 5 ++ keyboards/projectcain/vault35/config.h | 4 -- keyboards/projectcain/vault35/info.json | 5 ++ keyboards/projectcain/vault45/config.h | 4 -- keyboards/projectcain/vault45/info.json | 6 ++ keyboards/protozoa/p01/config.h | 5 -- keyboards/protozoa/p01/info.json | 5 ++ keyboards/psuieee/pluto12/config.h | 5 -- keyboards/psuieee/pluto12/info.json | 5 ++ keyboards/pteron36/config.h | 8 --- keyboards/pteron36/info.json | 14 ++++- keyboards/punk75/config.h | 4 -- keyboards/punk75/info.json | 6 ++ keyboards/qpockets/eggman/config.h | 7 --- keyboards/qpockets/eggman/info.json | 6 ++ keyboards/qpockets/space_space/rev1/config.h | 10 ---- keyboards/qpockets/space_space/rev1/info.json | 6 ++ keyboards/qpockets/space_space/rev2/config.h | 8 --- keyboards/qpockets/space_space/rev2/info.json | 6 ++ keyboards/qpockets/wanten/config.h | 7 --- keyboards/qpockets/wanten/info.json | 6 ++ keyboards/qvex/lynepad/config.h | 4 -- keyboards/qvex/lynepad/info.json | 6 ++ keyboards/qwertlekeys/calice/config.h | 4 -- keyboards/qwertlekeys/calice/info.json | 5 ++ keyboards/rainkeebs/rainkeeb/config.h | 5 -- keyboards/rainkeebs/rainkeeb/info.json | 5 ++ keyboards/rart/rart4x4/config.h | 3 - keyboards/rart/rart4x4/info.json | 6 ++ keyboards/rart/rart75/config.h | 3 - keyboards/rart/rart75/info.json | 5 ++ keyboards/rart/rart75hs/config.h | 4 -- keyboards/rart/rart75hs/info.json | 5 ++ keyboards/rart/rart75m/config.h | 4 -- keyboards/rart/rart75m/info.json | 5 ++ keyboards/rart/rartland/config.h | 4 -- keyboards/rart/rartland/info.json | 5 ++ keyboards/rart/rartpad/config.h | 3 - keyboards/rart/rartpad/info.json | 6 ++ keyboards/rate/pistachio_mp/config.h | 6 -- keyboards/rate/pistachio_mp/info.json | 5 ++ keyboards/rate/pistachio_pro/config.h | 4 -- keyboards/rate/pistachio_pro/info.json | 5 ++ keyboards/redox_media/config.h | 4 -- keyboards/redox_media/info.json | 5 ++ keyboards/reedskeebs/alish40/info.json | 3 +- keyboards/reviung/reviung5/config.h | 6 -- keyboards/reviung/reviung5/info.json | 5 ++ keyboards/rgbkb/mun/config.h | 4 -- keyboards/rgbkb/mun/rev1/info.json | 6 ++ keyboards/rgbkb/pan/config.h | 2 - keyboards/rgbkb/pan/rev1/32a/config.h | 3 +- keyboards/rgbkb/pan/rev1/32a/info.json | 8 ++- keyboards/rgbkb/pan/rev1/proton_c/config.h | 3 +- keyboards/rgbkb/pan/rev1/proton_c/info.json | 8 ++- keyboards/rgbkb/sol/rev1/config.h | 4 -- keyboards/rgbkb/sol/rev1/info.json | 5 ++ keyboards/rgbkb/sol3/config.h | 8 --- keyboards/rgbkb/sol3/rev1/info.json | 18 +++++- keyboards/rgbkb/zen/rev2/config.h | 3 - keyboards/rgbkb/zen/rev2/info.json | 5 ++ keyboards/rgbkb/zygomorph/rev1/config.h | 3 - keyboards/rgbkb/zygomorph/rev1/info.json | 5 ++ keyboards/ristretto/config.h | 4 -- keyboards/ristretto/info.json | 5 ++ keyboards/rmi_kb/chevron/config.h | 6 -- keyboards/rmi_kb/chevron/info.json | 5 ++ keyboards/rmi_kb/herringbone/pro/config.h | 4 -- keyboards/rmi_kb/herringbone/pro/info.json | 5 ++ keyboards/rmi_kb/squishytkl/config.h | 8 --- keyboards/rmi_kb/squishytkl/info.json | 5 ++ keyboards/rmi_kb/wete/v2/config.h | 4 -- keyboards/rmi_kb/wete/v2/info.json | 5 ++ keyboards/rmkeebs/rm_numpad/config.h | 4 -- keyboards/rmkeebs/rm_numpad/info.json | 5 ++ keyboards/rocketboard_16/config.h | 6 -- keyboards/rocketboard_16/info.json | 6 ++ keyboards/rotr/config.h | 8 --- keyboards/rotr/info.json | 5 ++ keyboards/rubi/config.h | 3 - keyboards/rubi/info.json | 5 ++ keyboards/rura66/rev1/config.h | 4 -- .../krush/krush65/hotswap/config.h | 5 -- .../krush/krush65/hotswap/encoder_actions.c | 15 ++--- .../krush/krush65/hotswap/info.json | 5 ++ .../krush/krush65/solder/config.h | 5 -- .../krush/krush65/solder/encoder_actions.c | 58 ------------------- .../krush/krush65/solder/encoder_actions.h | 23 -------- .../krush/krush65/solder/info.json | 5 ++ .../krush/krush65/solder/solder.c | 1 - keyboards/sck/gtm/config.h | 5 -- keyboards/sck/gtm/info.json | 5 ++ keyboards/sendyyeah/pix/config.h | 3 - keyboards/sendyyeah/pix/info.json | 5 ++ keyboards/sergiopoverony/creator_pro/config.h | 7 --- .../sergiopoverony/creator_pro/info.json | 5 ++ keyboards/sidderskb/majbritt/rev2/config.h | 3 - keyboards/sidderskb/majbritt/rev2/info.json | 5 ++ keyboards/sneakbox/aliceclone/config.h | 6 -- keyboards/sneakbox/aliceclone/info.json | 5 ++ keyboards/sneakbox/aliceclonergb/config.h | 6 -- keyboards/sneakbox/aliceclonergb/info.json | 5 ++ keyboards/sneakbox/ava/config.h | 6 -- keyboards/sneakbox/ava/info.json | 5 ++ keyboards/sneakbox/disarray/ortho/config.h | 6 -- keyboards/sneakbox/disarray/ortho/info.json | 5 ++ .../sneakbox/disarray/staggered/config.h | 6 -- .../sneakbox/disarray/staggered/info.json | 5 ++ keyboards/sofle/keyhive/config.h | 8 --- keyboards/sofle/keyhive/info.json | 14 ++++- keyboards/sofle/rev1/config.h | 7 --- keyboards/sofle/rev1/info.json | 14 ++++- keyboards/spacey/config.h | 5 -- keyboards/spacey/info.json | 5 ++ keyboards/splitkb/kyria/rev1/config.h | 9 --- keyboards/splitkb/kyria/rev1/info.json | 14 +++++ keyboards/splitkb/kyria/rev2/config.h | 9 --- keyboards/splitkb/kyria/rev2/info.json | 14 +++++ keyboards/splitkb/zima/config.h | 7 --- keyboards/splitkb/zima/info.json | 5 ++ keyboards/star75/config.h | 6 -- keyboards/star75/info.json | 5 ++ keyboards/stello65/beta/config.h | 7 --- keyboards/stello65/beta/encoder_actions.c | 15 ++--- keyboards/stello65/beta/info.json | 5 ++ keyboards/sthlmkb/lagom/info.json | 4 +- keyboards/sthlmkb/litl/info.json | 2 +- keyboards/swiftrax/retropad/config.h | 3 - keyboards/swiftrax/retropad/info.json | 5 ++ keyboards/synapse/config.h | 8 --- keyboards/synapse/info.json | 6 ++ keyboards/synthlabs/solo/config.h | 5 -- keyboards/synthlabs/solo/info.json | 5 ++ keyboards/synthlabs/solo/keymaps/via/keymap.c | 15 ++--- .../takashicompany/center_enter/config.h | 4 -- .../takashicompany/center_enter/info.json | 5 ++ keyboards/takashicompany/compacx/config.h | 4 -- keyboards/takashicompany/compacx/info.json | 6 ++ keyboards/takashicompany/dogtag/config.h | 4 -- keyboards/takashicompany/dogtag/info.json | 5 ++ keyboards/takashicompany/qoolee/config.h | 4 -- keyboards/takashicompany/qoolee/info.json | 5 ++ .../takashicompany/spreadwriter/config.h | 9 --- .../takashicompany/spreadwriter/info.json | 5 ++ .../spreadwriter/keymaps/via/config.h | 3 - .../spreadwriter/keymaps/via/keymap.c | 8 +-- keyboards/taleguers/taleguers75/config.h | 3 - keyboards/taleguers/taleguers75/info.json | 5 ++ keyboards/terrazzo/config.h | 38 ------------ keyboards/terrazzo/info.json | 7 +++ keyboards/tetris/config.h | 3 - keyboards/tetris/info.json | 6 ++ keyboards/themadnoodle/ncc1701kb/v2/config.h | 4 -- keyboards/themadnoodle/ncc1701kb/v2/info.json | 5 ++ keyboards/themadnoodle/noodlepad/config.h | 4 -- keyboards/themadnoodle/noodlepad/info.json | 5 ++ keyboards/thepanduuh/degenpad/config.h | 3 - keyboards/thepanduuh/degenpad/info.json | 5 ++ keyboards/tkc/portico75/config.h | 9 --- keyboards/tkc/portico75/info.json | 5 ++ keyboards/tkw/grandiceps/config.h | 3 - keyboards/tkw/grandiceps/info.json | 5 ++ keyboards/tkw/stoutgat/v1/config.h | 3 - keyboards/tkw/stoutgat/v1/info.json | 6 ++ keyboards/tkw/stoutgat/v2/config.h | 3 - keyboards/tkw/stoutgat/v2/info.json | 6 ++ keyboards/tominabox1/bigboy/config.h | 4 -- keyboards/tominabox1/bigboy/info.json | 5 ++ keyboards/tominabox1/le_chiffre/he/config.h | 4 -- keyboards/tominabox1/le_chiffre/he/info.json | 5 ++ keyboards/tominabox1/le_chiffre/rev1/config.h | 4 -- .../tominabox1/le_chiffre/rev1/info.json | 5 ++ keyboards/tominabox1/le_chiffre/rev2/config.h | 4 -- .../tominabox1/le_chiffre/rev2/info.json | 5 ++ keyboards/torn/config.h | 5 -- keyboards/torn/info.json | 5 ++ keyboards/tunks/ergo33/config.h | 3 - keyboards/tunks/ergo33/info.json | 5 ++ keyboards/tzarc/djinn/config.h | 14 ----- keyboards/tzarc/djinn/info.json | 14 ++++- keyboards/ungodly/launch_pad/config.h | 7 --- keyboards/ungodly/launch_pad/info.json | 5 ++ keyboards/ungodly/nines/config.h | 6 -- keyboards/ungodly/nines/info.json | 6 ++ keyboards/unison/v04/config.h | 7 --- keyboards/unison/v04/info.json | 9 +++ keyboards/viendi8l/config.h | 4 -- keyboards/viendi8l/info.json | 5 ++ keyboards/viktus/smolka/config.h | 5 -- keyboards/viktus/smolka/info.json | 6 ++ keyboards/viktus/sp_mini/config.h | 9 --- keyboards/viktus/sp_mini/info.json | 5 ++ keyboards/walletburner/cajal/config.h | 3 - keyboards/walletburner/cajal/info.json | 5 ++ keyboards/waterfowl/config.h | 5 -- keyboards/waterfowl/info.json | 6 ++ keyboards/wekey/we27/config.h | 13 +---- keyboards/wekey/we27/encoder_actions.c | 15 ++--- keyboards/wekey/we27/info.json | 5 ++ keyboards/winry/winry315/config.h | 11 ---- keyboards/winry/winry315/info.json | 7 +++ .../winry315/keymaps/via/encoder_actions.c | 16 ++--- keyboards/work_louder/loop/config.h | 3 - keyboards/work_louder/loop/info.json | 7 +++ keyboards/work_louder/micro/config.h | 5 -- keyboards/work_louder/micro/info.json | 6 ++ keyboards/work_louder/nano/config.h | 5 -- keyboards/work_louder/nano/info.json | 5 ++ keyboards/work_louder/work_board/config.h | 5 -- keyboards/work_louder/work_board/info.json | 5 ++ keyboards/wren/config.h | 10 ---- keyboards/wren/info.json | 14 +++++ keyboards/wuque/mammoth20x/config.h | 11 ---- keyboards/wuque/mammoth20x/info.json | 5 ++ keyboards/wuque/mammoth20x/mammoth20x.c | 8 +-- keyboards/wuque/mammoth75x/config.h | 11 ---- keyboards/wuque/mammoth75x/info.json | 5 ++ keyboards/wuque/mammoth75x/mammoth75x.c | 8 +-- keyboards/wuque/serneity65/config.h | 5 -- keyboards/wuque/serneity65/info.json | 5 ++ keyboards/wuque/serneity65/serneity65.c | 8 +-- keyboards/xenon/config.h | 3 - keyboards/xenon/info.json | 5 ++ keyboards/yandrstudio/nz67v2/config.h | 7 --- keyboards/yandrstudio/nz67v2/info.json | 5 ++ keyboards/yanghu/unicorne/config.h | 5 -- keyboards/yanghu/unicorne/info.json | 6 ++ keyboards/yeehaw/config.h | 3 - keyboards/yeehaw/info.json | 5 ++ keyboards/yushakobo/navpad/10/config.h | 4 -- keyboards/yushakobo/navpad/10/info.json | 5 ++ .../yushakobo/navpad/10_helix_r/config.h | 6 -- .../yushakobo/navpad/10_helix_r/info.json | 14 ++++- keyboards/yushakobo/quick17/config.h | 5 -- keyboards/yushakobo/quick17/info.json | 5 ++ keyboards/yushakobo/quick7/config.h | 3 - keyboards/yushakobo/quick7/info.json | 6 ++ keyboards/z12/config.h | 4 -- keyboards/z12/info.json | 6 ++ keyboards/ztboards/after/config.h | 2 - keyboards/ztboards/after/info.json | 5 ++ keyboards/zvecr/zv48/config.h | 3 - keyboards/zvecr/zv48/info.json | 5 ++ 972 files changed, 2898 insertions(+), 2569 deletions(-) delete mode 100644 keyboards/arrayperipherals/1x4p1/config.h create mode 100644 keyboards/handwired/prkl30/feather/info.json create mode 100644 keyboards/handwired/prkl30/promicro/info.json delete mode 100644 keyboards/keycapsss/plaid_pad/rev3/config.h delete mode 100644 keyboards/macro3/config.h delete mode 100644 keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.c delete mode 100644 keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.h delete mode 100644 keyboards/takashicompany/spreadwriter/config.h diff --git a/keyboards/0xcb/1337/config.h b/keyboards/0xcb/1337/config.h index b7cbf3b757e0d16bd7ddb7a1dd06bf907312aceb..a247d1b36782ec32a41a0d52ad6826709cd2235d 100644 --- a/keyboards/0xcb/1337/config.h +++ b/keyboards/0xcb/1337/config.h @@ -19,9 +19,6 @@ along with this program. If not, see . // clang-format off #define TAP_CODE_DELAY 10 -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F5 } #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN diff --git a/keyboards/0xcb/1337/info.json b/keyboards/0xcb/1337/info.json index 95170ee8732fa266a7574110b3932541bcccb6fa..d34d7166bf8ef9a29dd6914653425ed13bfeb6f7 100644 --- a/keyboards/0xcb/1337/info.json +++ b/keyboards/0xcb/1337/info.json @@ -13,6 +13,11 @@ "levels": 7, "breathing": true }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5"} + ] + }, "qmk_lufa_bootloader": { "led": "B0" }, diff --git a/keyboards/0xcb/static/config.h b/keyboards/0xcb/static/config.h index 0f517163e5e73fd686b7d42c229e77e153842d64..f77002e8ab7e1a2625ff5d57cdf61e4c38222340 100644 --- a/keyboards/0xcb/static/config.h +++ b/keyboards/0xcb/static/config.h @@ -35,9 +35,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW #define TAP_CODE_DELAY 10 -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } // clang-format on /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ diff --git a/keyboards/0xcb/static/info.json b/keyboards/0xcb/static/info.json index b6e5f01b2720d9ef734066f612433d829f89bc4a..a18bd7b3136e906e27d93857b383c0bef879e7ef 100644 --- a/keyboards/0xcb/static/info.json +++ b/keyboards/0xcb/static/info.json @@ -8,6 +8,11 @@ "pid": "0xA455", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega328p", "bootloader": "usbasploader", "layout_aliases": { diff --git a/keyboards/10bleoledhub/config.h b/keyboards/10bleoledhub/config.h index 0fcd15894f73c73f12062f19c3148a37d67e9dba..5943564661325b8c387cfa39a57faebfeda62d4b 100644 --- a/keyboards/10bleoledhub/config.h +++ b/keyboards/10bleoledhub/config.h @@ -40,8 +40,3 @@ along with this program. If not, see .*/ #define OLED_FONT_H "./lib/glcdfont.c" - -#define ENCODERS_PAD_A { C7 } -#define ENCODERS_PAD_B { F7 } - -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/10bleoledhub/info.json b/keyboards/10bleoledhub/info.json index 84dea67c3ad44d9de2a8d46a23c60ddc4847a798..dd106a74a50e5aeaf983de45bbad4c80aa4493ec 100644 --- a/keyboards/10bleoledhub/info.json +++ b/keyboards/10bleoledhub/info.json @@ -8,6 +8,11 @@ "pid": "0x7C99", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "F7"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/1upkeyboards/pi40/config.h b/keyboards/1upkeyboards/pi40/config.h index 6d19ace806c490fbdff6c7c9b4cf02d389b895ee..dfed1e4e6f17361ea3dc6310fe4fac49af9d1134 100644 --- a/keyboards/1upkeyboards/pi40/config.h +++ b/keyboards/1upkeyboards/pi40/config.h @@ -20,9 +20,6 @@ #define MATRIX_ROW_PINS { GP21, GP20, GP19, GP18 } #define MATRIX_COL_PINS { GP1, GP2, GP3, GP4, GP5, GP6, GP7, GP8, GP9, GP10, GP11, GP12 } -#define ENCODERS_PAD_A { GP14 } -#define ENCODERS_PAD_B { GP13 } - #define RGB_DI_PIN GP0 #define RGB_MATRIX_LED_COUNT 47 #define RGBLED_NUM 47 diff --git a/keyboards/1upkeyboards/pi40/info.json b/keyboards/1upkeyboards/pi40/info.json index 0f8bee6efe818bb401ddfb81f1522bb09450ba6b..42c0bc7b12947bdccd2c39bca9416057c8e700b8 100644 --- a/keyboards/1upkeyboards/pi40/info.json +++ b/keyboards/1upkeyboards/pi40/info.json @@ -6,6 +6,11 @@ "pid": "0x5600", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "GP14", "pin_b": "GP13"} + ] + }, "processor": "RP2040", "bootloader": "rp2040", "board": "GENERIC_RP_RP2040", diff --git a/keyboards/1upkeyboards/super16v2/config.h b/keyboards/1upkeyboards/super16v2/config.h index f71b6b7942908411eb707733a994972d16ec62f4..04f5fdd9793a08c1c0ffc13a40441aa8bdcfd82e 100644 --- a/keyboards/1upkeyboards/super16v2/config.h +++ b/keyboards/1upkeyboards/super16v2/config.h @@ -34,10 +34,6 @@ #define MATRIX_ROW_PINS { D1, D2, D3, D4 } #define MATRIX_COL_PINS { D5, D6, C2, D0 } -#define ENCODERS_PAD_A { B1, B3 } -#define ENCODERS_PAD_B { B2, B4 } - - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/1upkeyboards/super16v2/info.json b/keyboards/1upkeyboards/super16v2/info.json index 7886ce228e63c735dbde108a9f0a71cd928dc659..13e2c55fa595209f421ab230250dbdabffe0a544 100644 --- a/keyboards/1upkeyboards/super16v2/info.json +++ b/keyboards/1upkeyboards/super16v2/info.json @@ -8,6 +8,12 @@ "pid": "0x5517", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2"}, + {"pin_a": "B3", "pin_b": "B4"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/25keys/aleth42/rev0/config.h b/keyboards/25keys/aleth42/rev0/config.h index b84cc698e445e4c379ab2cbfc1c9f1ce36fe4581..eb8bd97b590f482e1c9edae1fdf3ac5a3059d589 100644 --- a/keyboards/25keys/aleth42/rev0/config.h +++ b/keyboards/25keys/aleth42/rev0/config.h @@ -25,9 +25,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B6, B5 } // located @ upper left -#define ENCODERS_PAD_B { B7, B4 } // located @ bottom left - #define RGB_DI_PIN C7 #ifdef RGB_DI_PIN #define RGBLED_NUM 6 diff --git a/keyboards/25keys/aleth42/rev0/info.json b/keyboards/25keys/aleth42/rev0/info.json index acb5cc58550487855c1dc3a2941fb145fb36bd6f..18023c847efe20415e01704b72b0a40fd8ffcd7e 100644 --- a/keyboards/25keys/aleth42/rev0/info.json +++ b/keyboards/25keys/aleth42/rev0/info.json @@ -2,6 +2,12 @@ "usb": { "device_version": "0.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B7"}, + {"pin_a": "B5", "pin_b": "B4"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu" } diff --git a/keyboards/25keys/aleth42/rev1/config.h b/keyboards/25keys/aleth42/rev1/config.h index afce07dbc9b2a889186b921b1c775f5bd02800ad..e0799e65a120a9ae4ba1efe6759cf02755a13dd6 100644 --- a/keyboards/25keys/aleth42/rev1/config.h +++ b/keyboards/25keys/aleth42/rev1/config.h @@ -25,9 +25,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B5, F5 } -#define ENCODERS_PAD_B { B6, F6 } - #define RGB_DI_PIN B3 #ifdef RGB_DI_PIN #define RGBLED_NUM 8 diff --git a/keyboards/25keys/aleth42/rev1/info.json b/keyboards/25keys/aleth42/rev1/info.json index 7d3baad862d239cbf1812fa8c7ecddf6c0419b38..9d70daf01ff0f1020b122bc519afcce64a671f5a 100644 --- a/keyboards/25keys/aleth42/rev1/info.json +++ b/keyboards/25keys/aleth42/rev1/info.json @@ -2,6 +2,12 @@ "usb": { "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B6"}, + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "backlight": { "pin": "C6", "levels": 8, diff --git a/keyboards/25keys/cassette42/config.h b/keyboards/25keys/cassette42/config.h index c57f66da5d5569bc2f79dfb833938168cb2b6559..686eea8fc759e6aa65af735ffb1ed3cd56ced747 100644 --- a/keyboards/25keys/cassette42/config.h +++ b/keyboards/25keys/cassette42/config.h @@ -17,10 +17,6 @@ along with this program. If not, see . #pragma once -#define ENCODERS_PAD_A { B6, B3 } -#define ENCODERS_PAD_B { B2, B1 } -#define ENCODER_RESOLUTION 4 - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN # define RGBLED_NUM 5 diff --git a/keyboards/25keys/cassette42/info.json b/keyboards/25keys/cassette42/info.json index 280733feb92cc58ebda550ab2507960ad95206bc..f791a83e4817a1a02d71475652bf4861db5a06a3 100644 --- a/keyboards/25keys/cassette42/info.json +++ b/keyboards/25keys/cassette42/info.json @@ -8,6 +8,12 @@ "pid": "0xCA42", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B2"}, + {"pin_a": "B3", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/2key2crawl/config.h b/keyboards/2key2crawl/config.h index 6025ba1d013096118064703ddf0f8d6753801d99..67a1b481577afd2bd7b51c33c580c698c4cb2cfd 100644 --- a/keyboards/2key2crawl/config.h +++ b/keyboards/2key2crawl/config.h @@ -5,11 +5,6 @@ #define MATRIX_ROW_PINS { C4, C5 } #define MATRIX_COL_PINS { B3, B4, B5, B6, B7, C7, B2 } - -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } -#define ENCODER_RESOLUTION 1 - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/2key2crawl/info.json b/keyboards/2key2crawl/info.json index a50d646244c2cfd761ecd9adbfed387092a193e3..e4ab7f79a954cd25e2989d46e944b7f24c5e17fc 100644 --- a/keyboards/2key2crawl/info.json +++ b/keyboards/2key2crawl/info.json @@ -8,6 +8,11 @@ "pid": "0x6090", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1", "resolution": 1} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/45_ats/config.h b/keyboards/45_ats/config.h index 734bc8d737c7c7a63ee4aee19e153881a66aafbf..fcf2f8ea44f2ba8b20e6025792c160e4d895eeaf 100644 --- a/keyboards/45_ats/config.h +++ b/keyboards/45_ats/config.h @@ -18,10 +18,6 @@ #pragma once - -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } - /* key matrix pins */ #define MATRIX_ROW_PINS { D3, D5, D7, D6 } #define MATRIX_COL_PINS { E6, B0, B1, B2, B3, B7, F6, F5, F4, C7, F7, C6, B6, D4 } diff --git a/keyboards/45_ats/info.json b/keyboards/45_ats/info.json index 530c2f3031a120fedbf6ba77378ea22db0613ea8..0bf42f9a75e092fca9eb95dacb68473758a576b1 100644 --- a/keyboards/45_ats/info.json +++ b/keyboards/45_ats/info.json @@ -8,6 +8,11 @@ "pid": "0x4511", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/7c8/framework/config.h b/keyboards/7c8/framework/config.h index 3cc7d44f1b373b6f6e0f2347c2b8a00339f1e94f..ba7016ab340e2da24e421260080bdf1206bdf63d 100644 --- a/keyboards/7c8/framework/config.h +++ b/keyboards/7c8/framework/config.h @@ -18,10 +18,7 @@ #define MATRIX_ROW_PINS { B0, B1, D7, B2, D6, B3, D5, B4, D4, B5 } #define MATRIX_COL_PINS { C0, C1, C2, C3, C4, C5 } -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 16 #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/7c8/framework/info.json b/keyboards/7c8/framework/info.json index a9871f77455611c58955c5922c70be97ad1d83bf..ca440e9a76ede5ba5bc8f60b139ab46dc31a7043 100644 --- a/keyboards/7c8/framework/info.json +++ b/keyboards/7c8/framework/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega328p", "bootloader": "usbasploader", "layouts": { diff --git a/keyboards/abacus/config.h b/keyboards/abacus/config.h index 0fff005257207b6edebdf97ce831de5c94d3d3f9..2e28b792a1d780541f151329db7f5d1acac48f9d 100644 --- a/keyboards/abacus/config.h +++ b/keyboards/abacus/config.h @@ -33,10 +33,6 @@ along with this program. If not, see . #define DIP_SWITCH_PINS { D0 } -#define ENCODERS_PAD_A { F1 } -#define ENCODERS_PAD_B { F0 } -#define ENCODER_RESOLUTION 4 - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW #define RGB_DI_PIN D1 diff --git a/keyboards/abacus/info.json b/keyboards/abacus/info.json index 17cd35aba8b53cfaef5e186e05050aea94340b34..132187db265d0021992eb99119007b8e2e27a2da 100644 --- a/keyboards/abacus/info.json +++ b/keyboards/abacus/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F1", "pin_b": "F0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/abstract/ellipse/rev1/config.h b/keyboards/abstract/ellipse/rev1/config.h index 46e0cacce49a80d9715fec67c9bcab2358b0089f..f7932863e9a251cd4f46038bfd4c4b550e404bbb 100644 --- a/keyboards/abstract/ellipse/rev1/config.h +++ b/keyboards/abstract/ellipse/rev1/config.h @@ -64,7 +64,3 @@ along with this program. If not, see . //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -#define ENCODERS_PAD_A { B2, B3, D5 } -#define ENCODERS_PAD_B { B1, B7, B4 } -#define ENCODER_RESOLUTION 2 diff --git a/keyboards/abstract/ellipse/rev1/info.json b/keyboards/abstract/ellipse/rev1/info.json index fe1939d2b6164b81f22697d876c179a201b5bbca..230e286c5da24ad2f3358354405b499ec36d32eb 100644 --- a/keyboards/abstract/ellipse/rev1/info.json +++ b/keyboards/abstract/ellipse/rev1/info.json @@ -1,13 +1,20 @@ { - "keyboard_name": "Ellipse", + "keyboard_name": "Ellipse", "manufacturer": "AbstractKB", - "url": "https://abstractkb.tk/product/ellipse-rev1", - "maintainer": "AbstractKB", + "url": "https://abstractkb.tk/product/ellipse-rev1", + "maintainer": "AbstractKB", "usb": { "vid": "0xFEED", "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1", "resolution": 2}, + {"pin_a": "B3", "pin_b": "B7", "resolution": 2}, + {"pin_a": "D5", "pin_b": "B4", "resolution": 2} + ] + }, "backlight": { "pin": "C6", "levels": 15 diff --git a/keyboards/acheron/shark/alpha/config.h b/keyboards/acheron/shark/alpha/config.h index dba9b3f41d201e12b243913f435b572006f1f5c5..9c36ac3a1f6179c714aec1a9e75e4babd6456672 100644 --- a/keyboards/acheron/shark/alpha/config.h +++ b/keyboards/acheron/shark/alpha/config.h @@ -17,11 +17,6 @@ along with this program. If not, see . #pragma once - -/* encoder pads */ -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B7 } - /* * Keyboard Matrix Assignments * diff --git a/keyboards/acheron/shark/alpha/info.json b/keyboards/acheron/shark/alpha/info.json index 5b235cc387c40d54b7b0f92d7ca821f3b3cdc007..d6b5dfcd0f60bd1d145f629a7004aba78797d345 100644 --- a/keyboards/acheron/shark/alpha/info.json +++ b/keyboards/acheron/shark/alpha/info.json @@ -6,6 +6,11 @@ "pid": "0x5368", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B7"} + ] + }, "backlight": { "pin": "B0" }, diff --git a/keyboards/acheron/shark/beta/config.h b/keyboards/acheron/shark/beta/config.h index 161b9b155824faa31f493c0fe80277b2ca26a0a9..8cfc57b9d587b7927659882b7f84b10c61f8527c 100644 --- a/keyboards/acheron/shark/beta/config.h +++ b/keyboards/acheron/shark/beta/config.h @@ -49,7 +49,4 @@ along with this program. If not, see . #define WS2812_DMA_STREAM STM32_DMA2_STREAM5 #define WS2812_DMA_CHANNEL 6 -#define ENCODERS_PAD_A { C15 } -#define ENCODERS_PAD_B { C14 } - #define EEPROM_I2C_24LC256 diff --git a/keyboards/acheron/shark/beta/info.json b/keyboards/acheron/shark/beta/info.json index 0dcb286e9785ee3843c69c7f0f8aa0314a083949..73025df6c4b041d9637789874793190059b3ffb8 100644 --- a/keyboards/acheron/shark/beta/info.json +++ b/keyboards/acheron/shark/beta/info.json @@ -4,6 +4,11 @@ "pid": "0x5369", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14"} + ] + }, "backlight": { "pin": "A6", "levels": 20, diff --git a/keyboards/adafruit/macropad/config.h b/keyboards/adafruit/macropad/config.h index 6f2c08c5e8e8bcf98175c635f3da8cfb5c4cd277..c493c487e3857d455d5fa73269ae15ca7ff1ec58 100644 --- a/keyboards/adafruit/macropad/config.h +++ b/keyboards/adafruit/macropad/config.h @@ -37,10 +37,6 @@ #define SPI_MOSI_PIN GP27 #define SPI_MISO_PIN GP28 -/* Encoders */ -#define ENCODERS_PAD_A { GP18 } -#define ENCODERS_PAD_B { GP17 } - /* Double tap the side button to enter bootloader */ #define RP2040_BOOTLOADER_DOUBLE_TAP_RESET #define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP13 diff --git a/keyboards/adafruit/macropad/info.json b/keyboards/adafruit/macropad/info.json index 4986a5974f216ef4722b2990893e3420aa01ebad..75c859adb12d084d3183e171a0a3389b6ea8689c 100644 --- a/keyboards/adafruit/macropad/info.json +++ b/keyboards/adafruit/macropad/info.json @@ -8,6 +8,11 @@ "pid": "0x0108", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "GP18", "pin_b": "GP17"} + ] + }, "bootmagic": { "matrix": [1, 2] }, diff --git a/keyboards/adpenrose/akemipad/config.h b/keyboards/adpenrose/akemipad/config.h index 41156ecf3d334e6b509efe24de4f63f21a925a26..47fcf429ac8797e3f973fb24a6fccad5aedfc950 100644 --- a/keyboards/adpenrose/akemipad/config.h +++ b/keyboards/adpenrose/akemipad/config.h @@ -20,12 +20,6 @@ /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/*Rotary encoder - set the resolution fitting your encoder. -Most will need a value of 4. If 1 encoder click results in 2 keycodes sent -increase the value. If you need 2 clicks for 1 keycode, decrease*/ -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B3 } #define TAP_CODE_DELAY 10 /* Audio functionality */ diff --git a/keyboards/adpenrose/akemipad/info.json b/keyboards/adpenrose/akemipad/info.json index 2e3f7851643e00d9b55f040f7ca93b6936a4767f..9b5a8d6ef6ad52d6b907cf52ea4a1fdcece7523b 100644 --- a/keyboards/adpenrose/akemipad/info.json +++ b/keyboards/adpenrose/akemipad/info.json @@ -7,6 +7,11 @@ "pid": "0x0004", "vid": "0x4450" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B3"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/adpenrose/kintsugi/config.h b/keyboards/adpenrose/kintsugi/config.h index c4007613e980df86fab039904da848a81ce5c4d3..5ffeb868374c9bd3634f1b87991c9b9350c18f07 100644 --- a/keyboards/adpenrose/kintsugi/config.h +++ b/keyboards/adpenrose/kintsugi/config.h @@ -34,12 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/*Rotary encoder - set the resolution fitting your encoder. -Most will need a value of 4. If 1 encoder click results in 2 keycodes sent -increase the value. If you need 2 clicks for 1 keycode, decrease*/ -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { B7 } -#define ENCODERS_PAD_B { D5 } #define TAP_CODE_DELAY 10 /* Underglow options: */ diff --git a/keyboards/adpenrose/kintsugi/info.json b/keyboards/adpenrose/kintsugi/info.json index 8c6258f020ab68eb25a0678c18984f41cc4508b4..a26c65b42a869769bcc11e8c9dceffdcd39de5c7 100644 --- a/keyboards/adpenrose/kintsugi/info.json +++ b/keyboards/adpenrose/kintsugi/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "D5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/adpenrose/obi/config.h b/keyboards/adpenrose/obi/config.h index c577a4a727d841fd930f60c899e6d149cafce794..c9f606999e19a1a12f148f839e50b7feb06e803a 100644 --- a/keyboards/adpenrose/obi/config.h +++ b/keyboards/adpenrose/obi/config.h @@ -20,12 +20,6 @@ /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/*Rotary encoder - set the resolution fitting your encoder. -Most will need a value of 4. If 1 encoder click results in 2 keycodes sent -increase the value. If you need 2 clicks for 1 keycode, decrease*/ -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { F1 } -#define ENCODERS_PAD_B { F0 } #define TAP_CODE_DELAY 10 /* Underglow options: */ diff --git a/keyboards/adpenrose/obi/info.json b/keyboards/adpenrose/obi/info.json index 544b4fc5d4adb84569a677ee567dc548413e838d..c0c1b73c64484b44b0c3ba83efd9a18c0006cb31 100644 --- a/keyboards/adpenrose/obi/info.json +++ b/keyboards/adpenrose/obi/info.json @@ -7,6 +7,11 @@ "pid": "0x0002", "vid": "0x4450" }, + "encoder": { + "rotary": [ + {"pin_a": "F1", "pin_b": "F0"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/aidansmithdotdev/fine40/config.h b/keyboards/aidansmithdotdev/fine40/config.h index e7799e2b0be64166bc4b47d983caa3680bd87ad4..a39d7fef7d723179a2f095a492ac263966cc4364 100644 --- a/keyboards/aidansmithdotdev/fine40/config.h +++ b/keyboards/aidansmithdotdev/fine40/config.h @@ -3,9 +3,4 @@ #pragma once - -#define ENCODER_RESOLUTION 2 -#define ENCODERS_PAD_A { D5 } -#define ENCODERS_PAD_B { B7 } - #define OLED_DISPLAY_128X64 //Comment this out to change the screen size diff --git a/keyboards/aidansmithdotdev/fine40/info.json b/keyboards/aidansmithdotdev/fine40/info.json index c2e1afd84cab41facfafdc870d582a687769ac26..c41557a9204a0b991efe256cfc264eb5e2a85cec 100644 --- a/keyboards/aidansmithdotdev/fine40/info.json +++ b/keyboards/aidansmithdotdev/fine40/info.json @@ -25,6 +25,11 @@ "pid": "0x4564", "vid": "0xA059" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "B7", "resolution": 2} + ] + }, "layouts": { "LAYOUT_2u_single_space": { "layout": [ diff --git a/keyboards/aleblazer/zodiark/config.h b/keyboards/aleblazer/zodiark/config.h index 2028f9bda3e692242b002edf7501e88519543725..148e9a767200294ebe5bf0bb10d4f2df3c9bac9b 100644 --- a/keyboards/aleblazer/zodiark/config.h +++ b/keyboards/aleblazer/zodiark/config.h @@ -20,12 +20,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D4 } -#define ENCODERS_PAD_A_RIGHT { D4 } -#define ENCODERS_PAD_B_RIGHT { D2 } -#define ENCODER_RESOLUTION 3 - /* key matrix pins */ #define MATRIX_ROW_PINS { C6, D7, E6, B4, F4 } #define MATRIX_COL_PINS { F5, F6, F7, B1, B3, B2, B6 } diff --git a/keyboards/aleblazer/zodiark/info.json b/keyboards/aleblazer/zodiark/info.json index f8d2300fd9447f5ce5b457f5709160b78a93a454..8211117625744312d470b4c3f918134595b06f38 100644 --- a/keyboards/aleblazer/zodiark/info.json +++ b/keyboards/aleblazer/zodiark/info.json @@ -8,8 +8,20 @@ "pid": "0xF902", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D4", "resolution": 3} + ] + }, "split": { - "soft_serial_pin": "D3" + "soft_serial_pin": "D3", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "D4", "pin_b": "D2", "resolution": 3} + ] + } + }, }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/ano/config.h b/keyboards/ano/config.h index be3a49fe33783225755c467b84c9aa85a72b1b08..df6d076d5c0458770bc1b991371a298d09a8c36c 100644 --- a/keyboards/ano/config.h +++ b/keyboards/ano/config.h @@ -19,11 +19,6 @@ #define MATRIX_ROW_PINS { A4, B14, B15, B9, B10, B11 } #define MATRIX_COL_PINS { B0, B1, B2, B3, B4, B5, B6, B7, A5, A6, A7, A8, A15, A2, A1, A0, B8, B13 } - -#define ENCODERS_PAD_A { B12 } -#define ENCODERS_PAD_B { A14 } -#define ENCODER_RESOLUTION 2 - #define DIODE_DIRECTION COL2ROW #define TAP_CODE_DELAY 10 diff --git a/keyboards/ano/info.json b/keyboards/ano/info.json index 94e1f828cc46ef2c04c3f90fa5d408bfb814e6b1..19d53a9ce10a28197f245b851fe7ee2508b26983 100644 --- a/keyboards/ano/info.json +++ b/keyboards/ano/info.json @@ -8,6 +8,11 @@ "pid": "0x0651", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "A14", "resolution": 2} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/aplyard/aplx6/rev2/config.h b/keyboards/aplyard/aplx6/rev2/config.h index 1e109c700169603ea17512976da59cdd3492f3df..f2793935cbcb2ccf5002c5bbe0708f94f249c5e4 100644 --- a/keyboards/aplyard/aplx6/rev2/config.h +++ b/keyboards/aplyard/aplx6/rev2/config.h @@ -27,9 +27,4 @@ along with this program. If not, see . #define TAPPING_TERM 200 -/* Encoder */ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODER_RESOLUTION 4 - #define TAP_CODE_DELAY 50 diff --git a/keyboards/aplyard/aplx6/rev2/info.json b/keyboards/aplyard/aplx6/rev2/info.json index 314d52dc8dea984fa095f911244ad0a3d196ad0e..114894a71449b3f949e65fdc116fa9ecbf73f56b 100644 --- a/keyboards/aplyard/aplx6/rev2/info.json +++ b/keyboards/aplyard/aplx6/rev2/info.json @@ -3,6 +3,11 @@ "pid": "0x0040", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina" } diff --git a/keyboards/arrayperipherals/1x4p1/config.h b/keyboards/arrayperipherals/1x4p1/config.h deleted file mode 100644 index b70680e4f53d74e35d4091346953dc84045879c5..0000000000000000000000000000000000000000 --- a/keyboards/arrayperipherals/1x4p1/config.h +++ /dev/null @@ -1,22 +0,0 @@ -/* -Copyright 2020 David Doan - -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation, either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program. If not, see . -*/ - -#pragma once - -/* rotary encoder*/ -#define ENCODERS_PAD_A {F0} -#define ENCODERS_PAD_B {F1} diff --git a/keyboards/arrayperipherals/1x4p1/info.json b/keyboards/arrayperipherals/1x4p1/info.json index b124b203349b6bbe2519304c7166da9233a1412c..2cc838bc929bbd54fccc713d7a7eadc6a1af8c45 100644 --- a/keyboards/arrayperipherals/1x4p1/info.json +++ b/keyboards/arrayperipherals/1x4p1/info.json @@ -8,6 +8,11 @@ "pid": "0x4F46", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/atlantis/ak81_ve/config.h b/keyboards/atlantis/ak81_ve/config.h index 4a7898350df1d2a1719615c5f57f59ff72c5560c..7379856a4f82e618bf54c6fe999e42957226dfcb 100644 --- a/keyboards/atlantis/ak81_ve/config.h +++ b/keyboards/atlantis/ak81_ve/config.h @@ -21,11 +21,6 @@ #define MATRIX_ROW_PINS { F1, F7, F6, F5, F4, D5 } #define MATRIX_COL_PINS { F0, C7, C6, B6, B5, B4, D7, D6, B2, B7, D3, D2, D1, D0, B3 } -/* Encoder pins */ -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { B0 } -#define ENCODER_RESOLUTION 4 -#define ENCODERS 1 #define ENCODERS_CCW_KEY { { 4, 5 } } // Note: array is { col, row ) #define ENCODERS_CW_KEY { { 3, 5 } } // Note: array is { col, row ) diff --git a/keyboards/atlantis/ak81_ve/info.json b/keyboards/atlantis/ak81_ve/info.json index 052492b7ce1bc88a5977b81b43542cb261535cb4..0269bd1e279dabd4b026e7fd8115944fbaa9d4ee 100644 --- a/keyboards/atlantis/ak81_ve/info.json +++ b/keyboards/atlantis/ak81_ve/info.json @@ -7,6 +7,11 @@ "pid": "0x0081", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B0"} + ] + }, "indicators": { "caps_lock": "D4", "on_state": 0 diff --git a/keyboards/atlantis/encoder_actions.c b/keyboards/atlantis/encoder_actions.c index b41a248a83f0ff9d870ab635580f1deed35ebe23..5bfba6d99f8e3dfaf785341e39047f2a35938ae6 100644 --- a/keyboards/atlantis/encoder_actions.c +++ b/keyboards/atlantis/encoder_actions.c @@ -18,16 +18,12 @@ #include "encoder_actions.h" #if defined(VIA_ENABLE) && defined(ENCODER_ENABLE) - -# ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -# endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -# ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -38,11 +34,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -# endif } void encoder_action_register(uint8_t index, bool clockwise) { -# ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -50,7 +44,6 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -# endif } void matrix_scan_kb(void) { diff --git a/keyboards/atreyu/rev1/config.h b/keyboards/atreyu/rev1/config.h index 67a4d1d05da635b6dea58789c0043eb83f40208d..99eb2c21e60c6987c7f7c065f1ac05d185e0628c 100644 --- a/keyboards/atreyu/rev1/config.h +++ b/keyboards/atreyu/rev1/config.h @@ -30,13 +30,6 @@ #define MATRIX_ROW_PINS { D7, E6, B4, B5, F6, F7, B1, B3, B6, B2 } #define MATRIX_COL_PINS { C6, D4, D0, D1, D2, D3 } -/* encoder support */ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } -#define ENCODER_RESOLUTION 4 - /* COL2ROW, ROW2COL, or CUSTOM_MATRIX */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/atreyu/rev1/info.json b/keyboards/atreyu/rev1/info.json index a9522acd5dc7c6e76c40469d8aba80c84c728f12..6d191d0635627de9333b0d3f6c21c6e8fad198d0 100644 --- a/keyboards/atreyu/rev1/info.json +++ b/keyboards/atreyu/rev1/info.json @@ -8,6 +8,20 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, + "split": { + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + } + } + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/atreyu/rev2/config.h b/keyboards/atreyu/rev2/config.h index baaef0800c97b49232d00ba5611b80c06b18e95c..de63cf3bd1b5e661f54411a636e8e27cb1330e39 100644 --- a/keyboards/atreyu/rev2/config.h +++ b/keyboards/atreyu/rev2/config.h @@ -30,11 +30,6 @@ #define MATRIX_ROW_PINS { D7, E6, B4, B5, F6, F7, B1, B3, B6, B2 } #define MATRIX_COL_PINS { F4, F5, C6, D4, D2, D3 } -/* encoder support */ -#define ENCODERS_PAD_A { D5, D5 } -#define ENCODERS_PAD_B { B7, C7 } -#define ENCODER_RESOLUTION 4 - /* COL2ROW, ROW2COL, or CUSTOM_MATRIX */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/atreyu/rev2/info.json b/keyboards/atreyu/rev2/info.json index 5c74a40c92cfe63c869f110cb0369746a3d21865..a890b8d271645575a6e73d2757522538e06c82c1 100644 --- a/keyboards/atreyu/rev2/info.json +++ b/keyboards/atreyu/rev2/info.json @@ -8,6 +8,12 @@ "pid": "0x0001", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "B7"}, + {"pin_a": "D5", "pin_b": "C7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/avalanche/v2/config.h b/keyboards/avalanche/v2/config.h index 5aee77c04d669cc4339a2952f6bcb7fd39f6063f..3978f581e1c7a0235d9b30022ea737f6cfff96be 100644 --- a/keyboards/avalanche/v2/config.h +++ b/keyboards/avalanche/v2/config.h @@ -13,7 +13,3 @@ #define RGBLED_NUM 12 #define RGBLED_SPLIT { 6, 6 } #define RGBLIGHT_SPLIT - -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODER_RESOLUTION 2 diff --git a/keyboards/avalanche/v2/info.json b/keyboards/avalanche/v2/info.json index d6b770ee48954f474d202b2b2c1017f29385c640..7105fc17874a409537e0e2171cfd7566b18ac62e 100644 --- a/keyboards/avalanche/v2/info.json +++ b/keyboards/avalanche/v2/info.json @@ -8,6 +8,11 @@ "pid": "0x0002", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "F4", "resolution": 2} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/avalanche/v3/config.h b/keyboards/avalanche/v3/config.h index a0e5af4531f25c612c777fd6a97e88de60f1da93..efe0c2793240d58cd3a5a3aaee53e098e697efe0 100644 --- a/keyboards/avalanche/v3/config.h +++ b/keyboards/avalanche/v3/config.h @@ -13,7 +13,3 @@ #define RGBLED_NUM 12 #define RGBLED_SPLIT { 7, 7 } #define RGBLIGHT_SPLIT - -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODER_RESOLUTION 2 diff --git a/keyboards/avalanche/v3/info.json b/keyboards/avalanche/v3/info.json index 3a0b43fb7123f197b8f2170052fbdc58eecdc538..70ffcc9efc32e43d9f92c39de90171003c97c44f 100644 --- a/keyboards/avalanche/v3/info.json +++ b/keyboards/avalanche/v3/info.json @@ -8,6 +8,11 @@ "pid": "0x0003", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "F4", "resolution": 2} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/avalanche/v4/config.h b/keyboards/avalanche/v4/config.h index 1009ab6e33144ac39f9337472a9c6b42f6595d66..86dff022e06ff183a58be1a5c64afe054bffa397 100644 --- a/keyboards/avalanche/v4/config.h +++ b/keyboards/avalanche/v4/config.h @@ -8,10 +8,6 @@ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODER_RESOLUTION 2 - #ifdef RGBLIGHT_ENABLE # define RGB_DI_PIN D3 # define RGBLED_NUM 64 diff --git a/keyboards/avalanche/v4/info.json b/keyboards/avalanche/v4/info.json index fdb71ce0e89828c4303658595f85deb873c0e029..5b31b5ca111d6c630dceb98e27ebf5a1a4979fd4 100644 --- a/keyboards/avalanche/v4/info.json +++ b/keyboards/avalanche/v4/info.json @@ -8,6 +8,11 @@ "pid": "0x0004", "device_version": "0.0.4" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "F4", "resolution": 2} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/bandominedoni/config.h b/keyboards/bandominedoni/config.h index 947f60b0f639326625584a6ec6363614fe20c43a..7a25216afdd961257d7c494160ddae1813f8a003 100644 --- a/keyboards/bandominedoni/config.h +++ b/keyboards/bandominedoni/config.h @@ -157,15 +157,4 @@ # define MIDI_INITIAL_VELOCITY 117 #endif // MIDI_ENABLE -/* - * Encoder options - */ -#ifdef ENCODER_ENABLE -# define ENCODERS_PAD_A { } -# define ENCODERS_PAD_B { } -# define ENCODER_RESOLUTIONS { } -# define ENCODERS_PAD_A_RIGHT { F5 } -# define ENCODERS_PAD_B_RIGHT { F4 } -# define ENCODER_RESOLUTIONS_RIGHT { 4 } -# define TAP_CODE_DELAY 10 -#endif // ENCODER_ENABLE +#define TAP_CODE_DELAY 10 diff --git a/keyboards/bandominedoni/info.json b/keyboards/bandominedoni/info.json index 79961fa770df244e2d983b62a608b29d0e083f54..d0d470a4e47f152cad811f22eaa238d32aeac9f1 100644 --- a/keyboards/bandominedoni/info.json +++ b/keyboards/bandominedoni/info.json @@ -9,7 +9,14 @@ "device_version": "0.0.1" }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/basekeys/trifecta/config.h b/keyboards/basekeys/trifecta/config.h index e21dcdd3fe73f96baf8094becb3b42a8ea8a4193..c06395545d51dc554538abd69644cf12b67b4f70 100644 --- a/keyboards/basekeys/trifecta/config.h +++ b/keyboards/basekeys/trifecta/config.h @@ -22,10 +22,6 @@ #define MATRIX_ROW_PINS { B0, B7, F7, B1, B6, C6, C7, B5, F6, D2 } #define MATRIX_COL_PINS { F0, F1, F4, F5, D1, B2, D0, B3 } - -#define ENCODERS_PAD_A { D4, D6, D7 } -#define ENCODERS_PAD_B { B4, D3, D5 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/basekeys/trifecta/info.json b/keyboards/basekeys/trifecta/info.json index 6d7cf723a828c554207651834dedf32e2e796b81..8743e3aad1fe152facc9e7acde23f71328a177c8 100644 --- a/keyboards/basekeys/trifecta/info.json +++ b/keyboards/basekeys/trifecta/info.json @@ -8,6 +8,13 @@ "pid": "0xEAF3", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "B4"}, + {"pin_a": "D6", "pin_b": "D3"}, + {"pin_a": "D7", "pin_b": "D5"} + ] + }, "bootmagic": { "matrix": [1, 0] }, diff --git a/keyboards/basketweave/config.h b/keyboards/basketweave/config.h index dca609a1703d1a72bc5e74d0bd32b55be153baa1..2c3f6f97f247a1c64966988cf2a63d9af1a72488 100644 --- a/keyboards/basketweave/config.h +++ b/keyboards/basketweave/config.h @@ -30,7 +30,4 @@ /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { D7 } -#define ENCODERS_PAD_B { C0 } -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 diff --git a/keyboards/basketweave/info.json b/keyboards/basketweave/info.json index d976a2811cd9dd4e1a703df6ca44056e103699e4..3ef505854e88ebe56c49d7d44796a0d0fffe6344 100644 --- a/keyboards/basketweave/info.json +++ b/keyboards/basketweave/info.json @@ -8,6 +8,11 @@ "pid": "0x8989", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "C0"} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "layouts": { diff --git a/keyboards/bbrfkr/dynamis/config.h b/keyboards/bbrfkr/dynamis/config.h index 516f749ff6b0056a9121817050c3cdd21a5bcb2d..28c21cb9f551c87136578ee5f2f3b5a247a53791 100644 --- a/keyboards/bbrfkr/dynamis/config.h +++ b/keyboards/bbrfkr/dynamis/config.h @@ -37,9 +37,5 @@ /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* rotary encoder */ -#define ENCODERS_PAD_A { B7 } -#define ENCODERS_PAD_B { E6 } - #define PMW33XX_CS_PIN SPI_SS_PIN #define POINTING_DEVICE_INVERT_Y diff --git a/keyboards/bbrfkr/dynamis/info.json b/keyboards/bbrfkr/dynamis/info.json index 5574bf6da4fcf5910839303c83dfed2cbdff9c52..4f256e8ac574d78d10f78754cdad9b2debd20ea3 100644 --- a/keyboards/bbrfkr/dynamis/info.json +++ b/keyboards/bbrfkr/dynamis/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "E6"} + ] + }, "processor": "atmega32u4", "bootloader": "qmk-dfu", "layouts": { diff --git a/keyboards/bluebell/swoop/config.h b/keyboards/bluebell/swoop/config.h index ece3ed5928f86893f11084c6a28ef8e1b7640631..de47d3a071d95269d87a934645fe4ecc8490ffb8 100644 --- a/keyboards/bluebell/swoop/config.h +++ b/keyboards/bluebell/swoop/config.h @@ -22,12 +22,6 @@ #define EE_HANDS -// encoders -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } -#define ENCODERS_PAD_A_RIGHT { B5 } -#define ENCODERS_PAD_B_RIGHT { B4 } - // OLED driver #ifdef OLED_DRIVER_ENABLE #define OLED_DISPLAY_128X32 diff --git a/keyboards/bluebell/swoop/info.json b/keyboards/bluebell/swoop/info.json index 320590894bef2d0c0b4aceb43b596e1e7069ac4b..49dcc857e9399ba0ec7b1765c9a4e62cb801f1d0 100644 --- a/keyboards/bluebell/swoop/info.json +++ b/keyboards/bluebell/swoop/info.json @@ -8,8 +8,20 @@ "pid": "0x3046", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B4"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/bobpad/config.h b/keyboards/bobpad/config.h index 587a0a0d5ded5d9316f105071393c94431b7a735..1b4ca326d9f4c4a74eeba72cc8ebba3d5c48ea1c 100644 --- a/keyboards/bobpad/config.h +++ b/keyboards/bobpad/config.h @@ -31,6 +31,3 @@ #define MATRIX_COL_PINS { F6, F5, F4 } #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } \ No newline at end of file diff --git a/keyboards/bobpad/info.json b/keyboards/bobpad/info.json index 58f724fbbef6edd3012ab61e141be4d708ba0ee6..43e614dbad5da831546dcff35e692119693ecc61 100644 --- a/keyboards/bobpad/info.json +++ b/keyboards/bobpad/info.json @@ -8,6 +8,11 @@ "pid": "0x0002", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "indicators": { "caps_lock": "D0", "num_lock": "D4", diff --git a/keyboards/bolsa/damapad/config.h b/keyboards/bolsa/damapad/config.h index 444f0de0e7d679a28b60b826c8eb8dcbc83a8ef2..9342bd028398f5df16f4cdafd08301082d5a59f7 100644 --- a/keyboards/bolsa/damapad/config.h +++ b/keyboards/bolsa/damapad/config.h @@ -26,10 +26,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } -#define ENCODER_RESOLUTION 2 - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/bolsa/damapad/info.json b/keyboards/bolsa/damapad/info.json index 3db2ab2e111a1cd659c70e5427f1dfbcd4b651f2..72e432c871726d3e1e24e2d0da2cb85ace38a6da 100644 --- a/keyboards/bolsa/damapad/info.json +++ b/keyboards/bolsa/damapad/info.json @@ -8,6 +8,11 @@ "pid": "0x6470", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/boston/config.h b/keyboards/boston/config.h index 6dddf137f725fc05991eca02065f6e44788c40c4..1c175166eebe8b6ec1588240eda951456f04a8bc 100644 --- a/keyboards/boston/config.h +++ b/keyboards/boston/config.h @@ -49,12 +49,6 @@ //The 3D-printed version of Boston uses APA106 LEDs, which are reversed #define WS2812_BYTE_ORDER WS2812_BYTE_ORDER_RGB -/* Define encoder */ -#define ENCODERS_PAD_A \ - { C13 } -#define ENCODERS_PAD_B \ - { F1 } -#define ENCODER_RESOLUTION 2 #define TAP_CODE_DELAY 15 /* diff --git a/keyboards/boston/info.json b/keyboards/boston/info.json index 40cc21008c76953b9d3d338b517d619141ff41ea..1d8e39f29df967b65849f0a072591229c1e72434 100644 --- a/keyboards/boston/info.json +++ b/keyboards/boston/info.json @@ -8,6 +8,11 @@ "pid": "0x4176", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C13", "pin_b": "F1", "resolution": 2} + ] + }, "backlight": { "pin": "A6", "levels": 6, diff --git a/keyboards/boston_meetup/2019/config.h b/keyboards/boston_meetup/2019/config.h index 624d8fd1d057936ed2eb90cef9358a62f7e31a9d..00e8648df869f4b687435c9e416bc0dcea1cc64f 100644 --- a/keyboards/boston_meetup/2019/config.h +++ b/keyboards/boston_meetup/2019/config.h @@ -17,9 +17,6 @@ #define MATRIX_ROW_PINS { A3, B8, B9, B1 } #define MATRIX_COL_PINS { A7, A8, B2, B10 } -#define ENCODERS_PAD_A { B13 } -#define ENCODERS_PAD_B { B14 } - //Audio #undef AUDIO_VOICES #undef AUDIO_PIN diff --git a/keyboards/boston_meetup/2019/info.json b/keyboards/boston_meetup/2019/info.json index 5ce237506258f133646a0214c390ec7d92c99302..22f54c3472ee1ca571043824d5b6136cef32ac17 100644 --- a/keyboards/boston_meetup/2019/info.json +++ b/keyboards/boston_meetup/2019/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "20.1.9" }, + "encoder": { + "rotary": [ + {"pin_a": "B13", "pin_b": "B14"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C", diff --git a/keyboards/cannonkeys/balance/config.h b/keyboards/cannonkeys/balance/config.h index 5ba99322ff4021be928bbd98cea750710383d3a5..5d93b09a273a529ff67daeafdad71a73c68e94e4 100644 --- a/keyboards/cannonkeys/balance/config.h +++ b/keyboards/cannonkeys/balance/config.h @@ -26,10 +26,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B6 } - -#define ENCODER_RESOLUTION 2 #define TAP_CODE_DELAY 25 #define DYNAMIC_KEYMAP_LAYER_COUNT 3 diff --git a/keyboards/cannonkeys/balance/info.json b/keyboards/cannonkeys/balance/info.json index 13eb96a62fbe7b8ecc2e486aecc163e5dca6a284..b9844e52950f41d50e04973aeb58b840be667460 100644 --- a/keyboards/cannonkeys/balance/info.json +++ b/keyboards/cannonkeys/balance/info.json @@ -8,6 +8,11 @@ "pid": "0xBA77", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B6", "resolution": 2} + ] + }, "indicators": { "caps_lock": "B12", "num_lock": "B14", diff --git a/keyboards/cannonkeys/ortho75/config.h b/keyboards/cannonkeys/ortho75/config.h index 021c4f38b6522c486ebc735317e8f46a7e76ea88..5246778d1309ff3319c34b1dc0c7c8d3baebd39a 100644 --- a/keyboards/cannonkeys/ortho75/config.h +++ b/keyboards/cannonkeys/ortho75/config.h @@ -24,9 +24,6 @@ along with this program. If not, see . #define BACKLIGHT_PWM_DRIVER PWMD1 #define BACKLIGHT_PWM_CHANNEL 1 -#define ENCODERS_PAD_A { B9 } -#define ENCODERS_PAD_B { B8 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/cannonkeys/ortho75/info.json b/keyboards/cannonkeys/ortho75/info.json index 31465c47c0409aa26cd5c5bcc59052138e6813a2..751eeb5297df1015d0247cbcfede023814927e6f 100644 --- a/keyboards/cannonkeys/ortho75/info.json +++ b/keyboards/cannonkeys/ortho75/info.json @@ -8,6 +8,11 @@ "pid": "0x6464", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B9", "pin_b": "B8"} + ] + }, "backlight": { "pin": "A8", "levels": 6, diff --git a/keyboards/cannonkeys/satisfaction75/config.h b/keyboards/cannonkeys/satisfaction75/config.h index c2c20e177169f3b9c8ce949844908dd09dea985a..ac9548dd272d092bddbeb94f559e84555813c90f 100644 --- a/keyboards/cannonkeys/satisfaction75/config.h +++ b/keyboards/cannonkeys/satisfaction75/config.h @@ -27,11 +27,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B3, B4, A0, A2, A4, A3 } #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B9 } -#define ENCODERS_PAD_B { B8 } - -#define ENCODER_RESOLUTION 2 - // I2C config #define I2C_DRIVER I2CD1 #define I2C1_SCL_PIN B6 diff --git a/keyboards/cannonkeys/satisfaction75/info.json b/keyboards/cannonkeys/satisfaction75/info.json index dd157defba2e466f11b6334b3e4702271c0d2072..9bf8459b1ae242ecfa752a1331725d9b92f7847c 100644 --- a/keyboards/cannonkeys/satisfaction75/info.json +++ b/keyboards/cannonkeys/satisfaction75/info.json @@ -8,6 +8,11 @@ "pid": "0x57F5", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B9", "pin_b": "B8", "resolution": 2} + ] + }, "backlight": { "levels": 24, "breathing": true diff --git a/keyboards/capsunlocked/cu7/config.h b/keyboards/capsunlocked/cu7/config.h index 93db7814f256591dec15fef4a1a2100539e766b8..cdc031b93b09b6cc252e260fe60f1fc5d8e7539d 100644 --- a/keyboards/capsunlocked/cu7/config.h +++ b/keyboards/capsunlocked/cu7/config.h @@ -27,12 +27,6 @@ along with this program. If not, see . * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) * */ - -#define ENCODER_RESOLUTION 2 - -#define ENCODERS_PAD_A { D6 } -#define ENCODERS_PAD_B { D4 } - #define MATRIX_ROW_PINS { D7, F0, F6 } #define MATRIX_COL_PINS { F5, F7, F4 } diff --git a/keyboards/capsunlocked/cu7/info.json b/keyboards/capsunlocked/cu7/info.json index 64416b026469c0016a44d5d72e2fc9fe00ecedbd..ebd7b6d491daa48ffa81e4df1677399a2528778c 100644 --- a/keyboards/capsunlocked/cu7/info.json +++ b/keyboards/capsunlocked/cu7/info.json @@ -8,6 +8,11 @@ "pid": "0x0007", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D4", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/checkerboards/phoenix45_ortho/config.h b/keyboards/checkerboards/phoenix45_ortho/config.h index 3f1b16129a99651db73ca413ff398bd07921019e..8c11a3ccf7417f3aad094a4fc03c174484838c9a 100644 --- a/keyboards/checkerboards/phoenix45_ortho/config.h +++ b/keyboards/checkerboards/phoenix45_ortho/config.h @@ -29,8 +29,3 @@ /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -/* encoder pads */ -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B2 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/checkerboards/phoenix45_ortho/info.json b/keyboards/checkerboards/phoenix45_ortho/info.json index ed976903e8d7fa1b10ced91e727a41364e06f6c9..23f6b024fa0b3123f9c9bea030ddfec1a672729f 100644 --- a/keyboards/checkerboards/phoenix45_ortho/info.json +++ b/keyboards/checkerboards/phoenix45_ortho/info.json @@ -8,6 +8,11 @@ "pid": "0x1849", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/checkerboards/quark/config.h b/keyboards/checkerboards/quark/config.h index c064c8569a91595f020cefe6eb12a86b82ad4883..42ccb06300179ce954d31963bfd9e77fa7259aa6 100644 --- a/keyboards/checkerboards/quark/config.h +++ b/keyboards/checkerboards/quark/config.h @@ -46,8 +46,3 @@ #define RGBLIGHT_HUE_STEP 12 // units to step when in/decreasing hue #define RGBLIGHT_SAT_STEP 12 // units to step when in/decresing saturation #define RGBLIGHT_VAL_STEP 12 // units to step when in/decreasing value (brightness) - -// rotary encoder parameters -#define ENCODERS_PAD_A { B0 } -#define ENCODERS_PAD_B { D1 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/checkerboards/quark/info.json b/keyboards/checkerboards/quark/info.json index f7016ac048bb0b410e3944666cb122986988af17..0f7f3b0f4403367dc9c0a07894a08c666ec6d76b 100644 --- a/keyboards/checkerboards/quark/info.json +++ b/keyboards/checkerboards/quark/info.json @@ -8,6 +8,11 @@ "pid": "0x5340", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "D1"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "community_layouts": ["ortho_4x12", "planck_mit"], diff --git a/keyboards/checkerboards/quark_plus/config.h b/keyboards/checkerboards/quark_plus/config.h index b44a42406b61a2f99976f0e8db9079b8b487be83..69781c0fa2ee96aa5c989b4e3db12016fc7fb631 100644 --- a/keyboards/checkerboards/quark_plus/config.h +++ b/keyboards/checkerboards/quark_plus/config.h @@ -46,7 +46,3 @@ #define RGBLIGHT_HUE_STEP 12 // units to step when in/decreasing hue #define RGBLIGHT_SAT_STEP 12 // units to step when in/decresing saturation #define RGBLIGHT_VAL_STEP 12 // units to step when in/decreasing value (brightness) - -#define ENCODERS_PAD_A { C7, B7, B3, B2} -#define ENCODERS_PAD_B { B7, C7, B2, B3} -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/checkerboards/quark_plus/info.json b/keyboards/checkerboards/quark_plus/info.json index 6c40827e74ffee5dbaa41bb8eb1dd6dbeb0be9d5..49ab42adcb0d0ee3499b48c1e2d2d266b148488c 100644 --- a/keyboards/checkerboards/quark_plus/info.json +++ b/keyboards/checkerboards/quark_plus/info.json @@ -8,6 +8,14 @@ "pid": "0x5344", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "B7"}, + {"pin_a": "B7", "pin_b": "C7"}, + {"pin_a": "B3", "pin_b": "B2"}, + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "backlight": { "pin": "C4", "levels": 6, diff --git a/keyboards/checkerboards/quark_squared/config.h b/keyboards/checkerboards/quark_squared/config.h index 1715a1101b72427ee5db59ccd1e5af68569cc4c0..85bed28b4596255a2c93578ed40a64fc50faf613 100644 --- a/keyboards/checkerboards/quark_squared/config.h +++ b/keyboards/checkerboards/quark_squared/config.h @@ -46,7 +46,3 @@ #define RGBLIGHT_HUE_STEP 12 // units to step when in/decreasing hue #define RGBLIGHT_SAT_STEP 12 // units to step when in/decresing saturation #define RGBLIGHT_VAL_STEP 12 // units to step when in/decreasing value (brightness) - -/* define rotary encoder pins */ -#define ENCODERS_PAD_A {B0} -#define ENCODERS_PAD_B {D1} diff --git a/keyboards/checkerboards/quark_squared/info.json b/keyboards/checkerboards/quark_squared/info.json index 699300a3a6ebdeff3b6b1121da95905dcd85cd94..de8496a7981a9ef050cb95a73c689bdd35899882 100644 --- a/keyboards/checkerboards/quark_squared/info.json +++ b/keyboards/checkerboards/quark_squared/info.json @@ -8,6 +8,11 @@ "pid": "0x5342", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "D1"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/checkerboards/snop60/config.h b/keyboards/checkerboards/snop60/config.h index 92f1cd72e85d746bc31e05d9a75cebe58619c7fe..5015355170dbcf0c8e7447a09f3adabebaa8699c 100644 --- a/keyboards/checkerboards/snop60/config.h +++ b/keyboards/checkerboards/snop60/config.h @@ -47,6 +47,3 @@ Copyright 2022 Nathan Spears /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -#define ENCODERS_PAD_A {D2} -#define ENCODERS_PAD_B {D3} diff --git a/keyboards/checkerboards/snop60/info.json b/keyboards/checkerboards/snop60/info.json index b3e964546516bd298c5280fdb8fb6287c1dbb17c..0c543a7c85dff37384bd3ad6a3b7adcfb934f9c5 100644 --- a/keyboards/checkerboards/snop60/info.json +++ b/keyboards/checkerboards/snop60/info.json @@ -8,6 +8,11 @@ "pid": "0x2416", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "backlight": { "pin": "D1", "levels": 6, diff --git a/keyboards/cherrybstudio/cb65/config.h b/keyboards/cherrybstudio/cb65/config.h index 6bf9dba1e5aa53a7baeecf7d193aa790af63b94f..b298fec8dc5547b6901d5a82c519be7f435ec757 100644 --- a/keyboards/cherrybstudio/cb65/config.h +++ b/keyboards/cherrybstudio/cb65/config.h @@ -28,11 +28,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B0, B1, B2, B3, B7, D0, D1, D2, D3 } #define MATRIX_COL_PINS { D5, D4, D6, D7, F7, B5, B6, C6 } -/* Encoder configuration */ -//#define ENCODERS_PAD_A { F5 } -//#define ENCODERS_PAD_B { F6 } -//#define ENCODER_RESOLUTION 4 - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/chocofly/v1/config.h b/keyboards/chocofly/v1/config.h index aa7e280ce4ff308ade39cdcc495485a7f944c6a5..a1886ffafad7564c79b512c5b38036cda237a757 100644 --- a/keyboards/chocofly/v1/config.h +++ b/keyboards/chocofly/v1/config.h @@ -7,7 +7,3 @@ #define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, B2, B6 } #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } -#define ENCODER_RESOLUTION 2 diff --git a/keyboards/chocofly/v1/info.json b/keyboards/chocofly/v1/info.json index f0b5f7b21dc0926f2f1d9b0bfb6755526c850e37..ab4fde45e6ca089d2a6d90e613155a4f4d3a0f75 100644 --- a/keyboards/chocofly/v1/info.json +++ b/keyboards/chocofly/v1/info.json @@ -8,6 +8,11 @@ "pid": "0x1001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/chromatonemini/info.json b/keyboards/chromatonemini/info.json index 506347a4d5821aa98b6e9746d6e36f1df450da82..c4307fe98878c81b538296cb1e6838e60e787a42 100644 --- a/keyboards/chromatonemini/info.json +++ b/keyboards/chromatonemini/info.json @@ -77,7 +77,7 @@ }, "encoder": { "rotary": [ - { "pin_a": "B5", "pin_b": "B4", "resolution": 4 } + { "pin_a": "B5", "pin_b": "B4" } ] } } diff --git a/keyboards/ck60i/config.h b/keyboards/ck60i/config.h index b847eb42d7b279391fc850680c27ba2d1e1a0513..908eb0d188be46b82b451a310cd6476837177b9e 100644 --- a/keyboards/ck60i/config.h +++ b/keyboards/ck60i/config.h @@ -45,9 +45,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -#define ENCODERS_PAD_A { A5 } -#define ENCODERS_PAD_B { A4 } - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/ck60i/info.json b/keyboards/ck60i/info.json index 5ebf94953edaf6e65559f099ae418ce277271979..22e8f265f6444de09b2c9412ea484583659d2a15 100644 --- a/keyboards/ck60i/info.json +++ b/keyboards/ck60i/info.json @@ -8,6 +8,11 @@ "pid": "0x6049", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A5", "pin_b": "A4"} + ] + }, "backlight": { "pin": "A6", "levels": 6, diff --git a/keyboards/ckeys/thedora/config.h b/keyboards/ckeys/thedora/config.h index 787b4dcc19b1df6acd5f4977213c6d54bb791f70..5bcb91e82253a72c6d5a9bd380175bf2c5359c49 100755 --- a/keyboards/ckeys/thedora/config.h +++ b/keyboards/ckeys/thedora/config.h @@ -16,11 +16,6 @@ #pragma once - -#define ENCODERS_PAD_A { B13 } -#define ENCODERS_PAD_B { B15 } -#define ENCODER_RESOLUTION 4 - #define MATRIX_ROW_PINS { A2, A1, A0, B8 } #define MATRIX_COL_PINS { B5, B4, B3, B2, B1, B0 } diff --git a/keyboards/ckeys/thedora/info.json b/keyboards/ckeys/thedora/info.json index 66b2e3784532610a883be165d198037390c4fc73..b72287fc2e6d57243cb6499895554213de8f04aa 100644 --- a/keyboards/ckeys/thedora/info.json +++ b/keyboards/ckeys/thedora/info.json @@ -8,6 +8,11 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B13", "pin_b": "B15"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C", diff --git a/keyboards/ckeys/washington/config.h b/keyboards/ckeys/washington/config.h index 0461020f0912816d71520400f16b6a42ff7b8242..b57e29acdef5cf300b826ef26b1e48b983bf64d1 100644 --- a/keyboards/ckeys/washington/config.h +++ b/keyboards/ckeys/washington/config.h @@ -32,9 +32,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { C6 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/ckeys/washington/info.json b/keyboards/ckeys/washington/info.json index 59e427a0b0acdd9592c5c2f46b233196e1452124..b9bb2fce7b2f4f4b04667e7f9d4b261021948195 100644 --- a/keyboards/ckeys/washington/info.json +++ b/keyboards/ckeys/washington/info.json @@ -8,6 +8,11 @@ "pid": "0x002A", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "C6"} + ] + }, "backlight": { "pin": "B6", "breathing": true diff --git a/keyboards/clickety_split/leeloo/info.json b/keyboards/clickety_split/leeloo/info.json index fbed9fefa54646c527ad2018eb9d4f21e91c445f..cdd9d713a6d2ee62a59acfc66167989f7fddfd17 100644 --- a/keyboards/clickety_split/leeloo/info.json +++ b/keyboards/clickety_split/leeloo/info.json @@ -8,8 +8,20 @@ "pid": "0x2022", "device_version": "0.1.3" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/clickety_split/leeloo/rev1/config.h b/keyboards/clickety_split/leeloo/rev1/config.h index 70ba6154ddf28c9185c71b68fee97a1c561b7c50..b309fa210b1f8b99470dd6a34eb1de3021db5647 100644 --- a/keyboards/clickety_split/leeloo/rev1/config.h +++ b/keyboards/clickety_split/leeloo/rev1/config.h @@ -26,12 +26,6 @@ /* define tapping term */ #define TAPPING_TERM 100 -/* encoder support */ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } - /* disable action features */ //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING diff --git a/keyboards/clueboard/2x1800/2019/config.h b/keyboards/clueboard/2x1800/2019/config.h index b73b5bb9ff9fe5f9b2a2cb1517e969ac821ebced..031952a0b39cf0374fd52d371d96f8cbd76ff2be 100644 --- a/keyboards/clueboard/2x1800/2019/config.h +++ b/keyboards/clueboard/2x1800/2019/config.h @@ -17,14 +17,6 @@ along with this program. If not, see . #pragma once - -/* - * Encoder Assignments - */ -#define ENCODERS_PAD_A { A5, A4, A2, A1 } -#define ENCODERS_PAD_B { A6, A7, A3, A0 } -#define ENCODER_RESOLUTION 4 - /* audio support */ #define AUDIO_PIN_ALT B7 #define AUDIO_PIN C4 diff --git a/keyboards/clueboard/2x1800/2019/info.json b/keyboards/clueboard/2x1800/2019/info.json index 37a3146ee34aafbc6babb247e7b5b3208b60b8aa..0eebbabb6d60ca0cc8d3cae8293c61ec524df8c4 100644 --- a/keyboards/clueboard/2x1800/2019/info.json +++ b/keyboards/clueboard/2x1800/2019/info.json @@ -27,6 +27,14 @@ "pid": "0x23A0", "vid": "0xC1ED" }, + "encoder": { + "rotary": [ + {"pin_a": "A5", "pin_b": "A6"}, + {"pin_a": "A4", "pin_b": "A7"}, + {"pin_a": "A2", "pin_b": "A3"}, + {"pin_a": "A1", "pin_b": "A0"} + ] + }, "layout_aliases": { "LAYOUT": "LAYOUT_all" }, diff --git a/keyboards/clueboard/2x1800/2021/config.h b/keyboards/clueboard/2x1800/2021/config.h index 8e514629837450cce3897c540e7763ccd6142769..eb4fd4bbf689fb751570418f0faae90722e33941 100644 --- a/keyboards/clueboard/2x1800/2021/config.h +++ b/keyboards/clueboard/2x1800/2021/config.h @@ -23,13 +23,6 @@ along with this program. If not, see . #define AUDIO_PIN C4 #define AUDIO_CLICKY -/* - * Encoder Assignments - */ -#define ENCODERS_PAD_A { D0, C5 } -#define ENCODERS_PAD_B { D1, C6 } -#define ENCODER_RESOLUTION 4 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/clueboard/2x1800/2021/info.json b/keyboards/clueboard/2x1800/2021/info.json index 10b681f60ccc2df6bea14b73f8dacfb285a9fc37..44842c0e168a9ac9477885fe358991b0ebd98e5d 100644 --- a/keyboards/clueboard/2x1800/2021/info.json +++ b/keyboards/clueboard/2x1800/2021/info.json @@ -26,6 +26,12 @@ "usb": { "pid": "0x23A0" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "C5", "pin_b": "C6"} + ] + }, "layout_aliases": { "LAYOUT": "LAYOUT_all" }, diff --git a/keyboards/crbn/config.h b/keyboards/crbn/config.h index d33e3e1f788fbbac90e662ead4e643863158aae0..840d8e7ca5856c358465720f530fd303aa976898 100644 --- a/keyboards/crbn/config.h +++ b/keyboards/crbn/config.h @@ -24,13 +24,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/*Rotary Encoder Pins*/ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } - -/*Sets the number of pulses per increment*/ -#define ENCODER_RESOLUTION 2 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/crbn/info.json b/keyboards/crbn/info.json index eae6ee7415b0c6abfab3d0576d510948b0cf593b..20d5ad2ff40c1e5d6586102b401cff0c91b2c36c 100644 --- a/keyboards/crbn/info.json +++ b/keyboards/crbn/info.json @@ -8,6 +8,11 @@ "pid": "0x0002", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "community_layouts": [ "ortho_4x12", "planck_mit" ], diff --git a/keyboards/custommk/evo70/config.h b/keyboards/custommk/evo70/config.h index d73f5b18232e029afdb779bf0fcc6770b9c9ea0a..633cbec1554ca1c4febf236e6de71e6cd93c8738 100644 --- a/keyboards/custommk/evo70/config.h +++ b/keyboards/custommk/evo70/config.h @@ -21,9 +21,6 @@ #define OLED_DISABLE_TIMEOUT -#define ENCODERS_PAD_A { C7 } -#define ENCODERS_PAD_B { D5 } -#define ENCODER_RESOLUTION 2 #define TAP_CODE_DELAY 10 #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/custommk/evo70/info.json b/keyboards/custommk/evo70/info.json index 824edd427733337ea8084dd93025f9b182b4eb08..1ea89ad92ad4979a052ca25f7cbd059d461b0bb2 100644 --- a/keyboards/custommk/evo70/info.json +++ b/keyboards/custommk/evo70/info.json @@ -9,6 +9,11 @@ "pid": "0xFAB5", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "D5", "resolution": 2} + ] + }, "backlight": { "pin": "B5", "levels": 17, diff --git a/keyboards/custommk/genesis/rev1/config.h b/keyboards/custommk/genesis/rev1/config.h index 5f6113bc68d0767153c7f5b77c3fc4037a3458b0..c5e7661c65bc877ba9af8db038243871ed445987 100644 --- a/keyboards/custommk/genesis/rev1/config.h +++ b/keyboards/custommk/genesis/rev1/config.h @@ -24,9 +24,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { F6, D2 } -#define ENCODERS_PAD_B { F7, D1 } -#define ENCODER_RESOLUTION 2 #define TAP_CODE_DELAY 10 #define RGB_DI_PIN E6 diff --git a/keyboards/custommk/genesis/rev1/info.json b/keyboards/custommk/genesis/rev1/info.json index 3ff1d77904f3395384e3d7401edafbf25b978d34..aaab705432edc419cf4a32f3a998d5c2fe322c29 100644 --- a/keyboards/custommk/genesis/rev1/info.json +++ b/keyboards/custommk/genesis/rev1/info.json @@ -8,6 +8,12 @@ "pid": "0xFAB0", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F7", "resolution": 2}, + {"pin_a": "D2", "pin_b": "D1", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "qmk-dfu", "layouts": { diff --git a/keyboards/custommk/genesis/rev2/config.h b/keyboards/custommk/genesis/rev2/config.h index f034eab5790dc92bda34452ce84bec33b93a2033..f152f723febe3ed3fd87f60dcef337d16473e103 100644 --- a/keyboards/custommk/genesis/rev2/config.h +++ b/keyboards/custommk/genesis/rev2/config.h @@ -24,9 +24,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { F6, D2 } -#define ENCODERS_PAD_B { F7, D1 } -#define ENCODER_RESOLUTION 2 #define TAP_CODE_DELAY 10 #define RGB_DI_PIN E6 diff --git a/keyboards/custommk/genesis/rev2/info.json b/keyboards/custommk/genesis/rev2/info.json index 6ba57648cb18260f9280a7d3902ebf1c9e6cac88..45b83c512ab76b5df5e5f05bf2929f70c08c7067 100644 --- a/keyboards/custommk/genesis/rev2/info.json +++ b/keyboards/custommk/genesis/rev2/info.json @@ -8,6 +8,12 @@ "pid": "0xFAB1", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F7", "resolution": 2}, + {"pin_a": "D2", "pin_b": "D1", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "qmk-dfu", "layouts": { diff --git a/keyboards/dailycraft/owl8/config.h b/keyboards/dailycraft/owl8/config.h index 41efbbb6b51af350d846a29b1083ed31337cc415..7da6e3f1bf27024749e7ccea2e9314caa00e319e 100644 --- a/keyboards/dailycraft/owl8/config.h +++ b/keyboards/dailycraft/owl8/config.h @@ -37,6 +37,3 @@ along with this program. If not, see . //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -#define ENCODERS_PAD_A { D4, D7 } -#define ENCODERS_PAD_B { C6, E6 } diff --git a/keyboards/dailycraft/owl8/info.json b/keyboards/dailycraft/owl8/info.json index 1aed397e381aff299a2e93001ac25dd46a6b456c..ee1d19e7d669718b5ea51ddbc0dcfc98b7b3f3c9 100644 --- a/keyboards/dailycraft/owl8/info.json +++ b/keyboards/dailycraft/owl8/info.json @@ -8,6 +8,12 @@ "pid": "0x0008", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "C6"}, + {"pin_a": "D7", "pin_b": "E6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/dailycraft/stickey4/config.h b/keyboards/dailycraft/stickey4/config.h index 41efbbb6b51af350d846a29b1083ed31337cc415..7da6e3f1bf27024749e7ccea2e9314caa00e319e 100644 --- a/keyboards/dailycraft/stickey4/config.h +++ b/keyboards/dailycraft/stickey4/config.h @@ -37,6 +37,3 @@ along with this program. If not, see . //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -#define ENCODERS_PAD_A { D4, D7 } -#define ENCODERS_PAD_B { C6, E6 } diff --git a/keyboards/dailycraft/stickey4/info.json b/keyboards/dailycraft/stickey4/info.json index 69dc1479a4ad79067464496e6bcdeedbb366aea3..c8d580371885c92b81969bf28e404e7b2e8ec103 100644 --- a/keyboards/dailycraft/stickey4/info.json +++ b/keyboards/dailycraft/stickey4/info.json @@ -8,6 +8,12 @@ "pid": "0x0010", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "C6"}, + {"pin_a": "D7", "pin_b": "E6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/delikeeb/vaguettelite/config.h b/keyboards/delikeeb/vaguettelite/config.h index b430a301d7bc3e451f9fd5be7fa141ad1b86c7b9..3708284700ba551feea9fcbcf71742a301fec275 100644 --- a/keyboards/delikeeb/vaguettelite/config.h +++ b/keyboards/delikeeb/vaguettelite/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/*rotary encoder setting*/ -#define ENCODERS_PAD_A { D5, F1 } -#define ENCODERS_PAD_B { B7, F0 } - #define RGB_DI_PIN C7 #ifdef RGB_DI_PIN # define RGBLED_NUM 9 diff --git a/keyboards/delikeeb/vaguettelite/info.json b/keyboards/delikeeb/vaguettelite/info.json index 5558cac96fdd6f8092586fe6dda7c6af7eccd5f1..e976a6a1554053e6f98dff58fa8fa24dc1e53f21 100644 --- a/keyboards/delikeeb/vaguettelite/info.json +++ b/keyboards/delikeeb/vaguettelite/info.json @@ -8,6 +8,12 @@ "pid": "0x0011", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "B7"}, + {"pin_a": "F1", "pin_b": "F0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/delikeeb/vanana/rev1/config.h b/keyboards/delikeeb/vanana/rev1/config.h index bf501e83abb7aaee4aef43a21e3fa2bf64e36860..d8a6d95c9b3db1ca3357a780e4d29df4ce8d5a66 100644 --- a/keyboards/delikeeb/vanana/rev1/config.h +++ b/keyboards/delikeeb/vanana/rev1/config.h @@ -33,9 +33,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Rotary Encoder and Buzzer */ -#define ENCODERS_PAD_A { C7, F1 } -#define ENCODERS_PAD_B { D5, F0 } #define B7_AUDIO #define RGB_DI_PIN F0 diff --git a/keyboards/delikeeb/vanana/rev1/info.json b/keyboards/delikeeb/vanana/rev1/info.json index 992960c5a2eeda542833097a9d36180d29da94a6..4434ba95d749c1fbcffb7bf769564fb85ea3e55e 100644 --- a/keyboards/delikeeb/vanana/rev1/info.json +++ b/keyboards/delikeeb/vanana/rev1/info.json @@ -2,5 +2,11 @@ "keyboard_name": "Vanana rev1", "usb": { "device_version": "0.0.1" + }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "D5"}, + {"pin_a": "F1", "pin_b": "F0"} + ] } } diff --git a/keyboards/delikeeb/vanana/rev2/config.h b/keyboards/delikeeb/vanana/rev2/config.h index 687bb7a2942e0f953a937374b70978e0006543fd..e28d974b78f397fa9328e8a031ae6cec07de6fa7 100644 --- a/keyboards/delikeeb/vanana/rev2/config.h +++ b/keyboards/delikeeb/vanana/rev2/config.h @@ -33,9 +33,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Rotary Encoder and Buzzer */ -#define ENCODERS_PAD_A { B6, F0 } -#define ENCODERS_PAD_B { B2, F1 } #define B7_AUDIO #define RGB_DI_PIN C7 diff --git a/keyboards/delikeeb/vanana/rev2/info.json b/keyboards/delikeeb/vanana/rev2/info.json index c7206e9d97164884cd6bd8961ea0d9f284472728..589c8c5089f1f4b27a32ec265124cd5d7e619610 100644 --- a/keyboards/delikeeb/vanana/rev2/info.json +++ b/keyboards/delikeeb/vanana/rev2/info.json @@ -2,5 +2,11 @@ "keyboard_name": "Vanana rev2", "usb": { "device_version": "0.0.2" + }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B2"}, + {"pin_a": "F0", "pin_b": "F1"} + ] } } diff --git a/keyboards/delikeeb/waaffle/rev3/config.h b/keyboards/delikeeb/waaffle/rev3/config.h index 48326e7f226bc55af19660cc1e84e1935b57c610..4d5aa33be973e7c4cc4908aa60eac0db7dbd7f24 100644 --- a/keyboards/delikeeb/waaffle/rev3/config.h +++ b/keyboards/delikeeb/waaffle/rev3/config.h @@ -33,10 +33,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/*rotary encoder setting*/ -#define ENCODERS_PAD_A { B7, F1 } -#define ENCODERS_PAD_B { D5, F0 } - #define RGB_DI_PIN C7 #ifdef RGB_DI_PIN # define RGBLED_NUM 10 diff --git a/keyboards/delikeeb/waaffle/rev3/info.json b/keyboards/delikeeb/waaffle/rev3/info.json index 735a5cf16af92064bbfff72910821a78fee67642..8301a03813ed31933fdc4835565a3a0ce8bf3057 100644 --- a/keyboards/delikeeb/waaffle/rev3/info.json +++ b/keyboards/delikeeb/waaffle/rev3/info.json @@ -8,6 +8,12 @@ "pid": "0x0012", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "D5"}, + {"pin_a": "F1", "pin_b": "F0"} + ] + }, "bootmagic": { "matrix": [6, 0] }, diff --git a/keyboards/dmqdesign/spin/config.h b/keyboards/dmqdesign/spin/config.h index 47255ed3aeaa620e41a8bc9d499276d377b4a773..1e908ea0291c76944f1e43ce8405a0df0dfc575e 100644 --- a/keyboards/dmqdesign/spin/config.h +++ b/keyboards/dmqdesign/spin/config.h @@ -26,11 +26,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -//rotary encoder setup -#define ENCODERS_PAD_A { B6, B4, D6 } -#define ENCODERS_PAD_B { B5, D7, D4 } -#define ENCODER_RESOLUTION 4 - //Data pin for the 3 RGB LEDs #define RGB_DI_PIN D3 //Number of RGB LEDs diff --git a/keyboards/dmqdesign/spin/info.json b/keyboards/dmqdesign/spin/info.json index 2e5148236e2dd8d31bcb292c218c1a2fa74f3d78..ff5101f8ea8f9edafa78be4e2ed6c48feecde637 100644 --- a/keyboards/dmqdesign/spin/info.json +++ b/keyboards/dmqdesign/spin/info.json @@ -8,6 +8,13 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"}, + {"pin_a": "B4", "pin_b": "D7"}, + {"pin_a": "D6", "pin_b": "D4"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/doio/kb16/rev1/config.h b/keyboards/doio/kb16/rev1/config.h index 5f30b978121973905fdba97a15f310f1ed6a32ca..aa066fe3933e1a4f6a1892653fe884f1f3d11de9 100644 --- a/keyboards/doio/kb16/rev1/config.h +++ b/keyboards/doio/kb16/rev1/config.h @@ -31,10 +31,6 @@ /* Use the custom font */ #define OLED_FONT_H "./lib/glcdfont.c" -/* Encoder pins */ -#define ENCODERS_PAD_A { F7, C7, D7 } -#define ENCODERS_PAD_B { E6, C6, D6 } - #ifdef RGB_MATRIX_ENABLE /* RGB Matrix config */ #define RGB_DI_PIN F6 diff --git a/keyboards/doio/kb16/rev1/info.json b/keyboards/doio/kb16/rev1/info.json index d8bf6e8b7391cbab67652b68349d375596afed94..d0acdedfb9b5fe16fc115659c491180ad2d78c3c 100644 --- a/keyboards/doio/kb16/rev1/info.json +++ b/keyboards/doio/kb16/rev1/info.json @@ -8,6 +8,13 @@ "pid": "0x1601", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F7", "pin_b": "E6"}, + {"pin_a": "C7", "pin_b": "C6"}, + {"pin_a": "D7", "pin_b": "D6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/doio/kb16/rev2/config.h b/keyboards/doio/kb16/rev2/config.h index 29367f26e84b0d5d362b7952d216ba564b96a2a7..e7e2791ac8d258564321db8f5034f5c17fc6a8ec 100644 --- a/keyboards/doio/kb16/rev2/config.h +++ b/keyboards/doio/kb16/rev2/config.h @@ -38,10 +38,6 @@ #define OLED_FONT_H "./lib/glcdfont.c" #endif -/* Encoder pins */ -#define ENCODERS_PAD_A { B5, A1, A3 } -#define ENCODERS_PAD_B { B6, A2, A4 } - #ifdef RGB_MATRIX_ENABLE /* RGB Matrix config */ #define RGB_DI_PIN A10 diff --git a/keyboards/doio/kb16/rev2/info.json b/keyboards/doio/kb16/rev2/info.json index 28aa77b127ccb52cc06746b701cd8566a8dbb1c7..8b5eeb45c2925d9cc355e64a22502a1f4a6106a8 100644 --- a/keyboards/doio/kb16/rev2/info.json +++ b/keyboards/doio/kb16/rev2/info.json @@ -8,6 +8,13 @@ "pid": "0x1601", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B6"}, + {"pin_a": "A1", "pin_b": "A2"}, + {"pin_a": "A3", "pin_b": "A4"} + ] + }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/doio/kb30/config.h b/keyboards/doio/kb30/config.h index 42e521c18d113a38332cf9404c7566a62e9aeb7c..866bd3e1d92ebba92c64b12fb5cc378abdbd74d1 100644 --- a/keyboards/doio/kb30/config.h +++ b/keyboards/doio/kb30/config.h @@ -27,12 +27,6 @@ /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -/* key encoders pins*/ -#define ENCODERS_PAD_A { B5 , A1 , A3 } -#define ENCODERS_PAD_B { B6 , A2 , A4 } -#define ENCODER_RESOLUTIONS \ - { 4, 4, 2 } - // #define QMK_KEYS_PER_SCAN 12 /* OLED */ diff --git a/keyboards/doio/kb30/info.json b/keyboards/doio/kb30/info.json index 47ed0c3f42969632f1178f7390e5a6aceb5ea7a2..9fe8e831859fa65a3004a39ca7a354eb43d0a906 100644 --- a/keyboards/doio/kb30/info.json +++ b/keyboards/doio/kb30/info.json @@ -8,6 +8,13 @@ "pid": "0x3001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B6"}, + {"pin_a": "A1", "pin_b": "A2"}, + {"pin_a": "A3", "pin_b": "A4", "resolution": 2} + ] + }, "processor": "STM32F103", "bootloader": "stm32duino", "layouts": { diff --git a/keyboards/doio/kb38/config.h b/keyboards/doio/kb38/config.h index 416219d5c74b4aabac9bfba9744117b19883cc6c..740f1baea76bec19cc4e97d59699e8f520090095 100644 --- a/keyboards/doio/kb38/config.h +++ b/keyboards/doio/kb38/config.h @@ -16,11 +16,6 @@ #define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON #define RGB_MATRIX_DEFAULT_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS -#define ENCODERS_PAD_A { C7, F7, D6 } -#define ENCODERS_PAD_B { C6, E6, D7 } -#define ENCODER_RESOLUTIONS { 4, 4, 2 } - - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/doio/kb38/info.json b/keyboards/doio/kb38/info.json index 9d75ada43ebbb77794e31d3e4996baf11522c2bf..227511295cb0bfc355d1f1a4c744f785f0d00324 100644 --- a/keyboards/doio/kb38/info.json +++ b/keyboards/doio/kb38/info.json @@ -25,6 +25,13 @@ "pid": "0x0000", "vid": "0xFEED" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "C6"}, + {"pin_a": "F7", "pin_b": "E6"}, + {"pin_a": "D6", "pin_b": "D7", "resolution": 2} + ] + }, "rgb_matrix": { "driver": "WS2812", "layout": [ diff --git a/keyboards/doodboard/duckboard/config.h b/keyboards/doodboard/duckboard/config.h index bce35cc22e5061f5fb3413f984bda47560db3a8d..d4617a87861501fb83e798babda990819cd2944b 100644 --- a/keyboards/doodboard/duckboard/config.h +++ b/keyboards/doodboard/duckboard/config.h @@ -21,10 +21,6 @@ #define MATRIX_ROW_PINS { C6, D7, E6, B4, B5 } #define MATRIX_COL_PINS { F7, B1, B3, B2, B6 } -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } -#define ENCODER_RESOLUTION 2 - /* media key slowdown for windows */ #define TAP_CODE_DELAY 20 diff --git a/keyboards/doodboard/duckboard/info.json b/keyboards/doodboard/duckboard/info.json index 52915ac222427ed0026cc8fbb180285f329a8e8e..f2ee7bb80a3526111ee7fd470b3c8551f93864e1 100644 --- a/keyboards/doodboard/duckboard/info.json +++ b/keyboards/doodboard/duckboard/info.json @@ -8,6 +8,11 @@ "pid": "0xFF44", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/doodboard/duckboard_r2/config.h b/keyboards/doodboard/duckboard_r2/config.h index dae2e086522b932791d2a9e27068f44169a82adb..d4617a87861501fb83e798babda990819cd2944b 100644 --- a/keyboards/doodboard/duckboard_r2/config.h +++ b/keyboards/doodboard/duckboard_r2/config.h @@ -21,10 +21,6 @@ #define MATRIX_ROW_PINS { C6, D7, E6, B4, B5 } #define MATRIX_COL_PINS { F7, B1, B3, B2, B6 } -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F5 } -#define ENCODER_RESOLUTION 2 - /* media key slowdown for windows */ #define TAP_CODE_DELAY 20 diff --git a/keyboards/doodboard/duckboard_r2/info.json b/keyboards/doodboard/duckboard_r2/info.json index 6483a4b1293e589155fee6d90510921b30a50eb7..b2de93f477c7fbafa7b1ac79df7b011028ff93e2 100644 --- a/keyboards/doodboard/duckboard_r2/info.json +++ b/keyboards/doodboard/duckboard_r2/info.json @@ -8,6 +8,11 @@ "pid": "0x6462", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5", "resolution": 2} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/draculad/config.h b/keyboards/draculad/config.h index 8ea9dd48d5d932603821c06d7a43e16c25e9ea66..63c16c1c710e22db189050bcb34dc883c71eb298 100644 --- a/keyboards/draculad/config.h +++ b/keyboards/draculad/config.h @@ -42,12 +42,6 @@ along with this program. If not, see . #define RGBLIGHT_SLEEP #endif -#define ENCODERS_PAD_A {B2 , B4} -#define ENCODERS_PAD_B {B6 , B5} - -#define ENCODER_RESOLUTIONS { 4, 4 } -#define ENCODER_RESOLUTIONS_RIGHT { 4, 1 } - #define EE_HANDS #define LAYER_STATE_8BIT diff --git a/keyboards/draculad/info.json b/keyboards/draculad/info.json index 310fa976593b9dbb26705af423726e1f23f32750..83b071e98bc0da0347b033959bb61e75abac5696 100644 --- a/keyboards/draculad/info.json +++ b/keyboards/draculad/info.json @@ -8,8 +8,22 @@ "pid": "0x1B1E", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B6"}, + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B6", "resolution": 4}, + {"pin_a": "B4", "pin_b": "B5", "resolution": 1} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/draytronics/daisy/config.h b/keyboards/draytronics/daisy/config.h index f941fa5d058f665d544e5ce7e3c943898349a337..e701420bee72467b84e49b5bfd1673416205d374 100644 --- a/keyboards/draytronics/daisy/config.h +++ b/keyboards/draytronics/daisy/config.h @@ -33,8 +33,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B0, C0, C1} #define MATRIX_COL_PINS { C2, C3, C4, C5 } -#define ENCODERS_PAD_A { B1, D0 } -#define ENCODERS_PAD_B { B2, D1 } /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW #define TAP_CODE_DELAY 10 diff --git a/keyboards/draytronics/daisy/info.json b/keyboards/draytronics/daisy/info.json index 8b39ae5ba1ec7b67b2b42ac8eea3fbb4e8404650..c847a456501fe26c96b27fde3b074286c46364af 100644 --- a/keyboards/draytronics/daisy/info.json +++ b/keyboards/draytronics/daisy/info.json @@ -8,6 +8,12 @@ "pid": "0x4441", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2"}, + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega328p", "bootloader": "usbasploader", "layout_aliases": { diff --git a/keyboards/drhigsby/bkf/config.h b/keyboards/drhigsby/bkf/config.h index 6e384d11623354e2308fe8f904825dc584c2024e..e13ed8af9db5a910cb137ef7c5a4bfe552a36c47 100644 --- a/keyboards/drhigsby/bkf/config.h +++ b/keyboards/drhigsby/bkf/config.h @@ -31,10 +31,6 @@ #define MATRIX_ROW_PINS { F6, F7, B1, B3 } #define MATRIX_COL_PINS { B6, B2, D3, D2, D1, D0, D4, C6, D7, E6, B4, B5 } -/* Define encoder pads */ -#define ENCODERS_PAD_A { F4 } -#define ENCODERS_PAD_B { F5 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/drhigsby/bkf/info.json b/keyboards/drhigsby/bkf/info.json index 20f2edd54f99629752b26da3ade1c741b26ba4f2..49a56a278620bf6e3e3ceb5a3dd4634f420d8354 100644 --- a/keyboards/drhigsby/bkf/info.json +++ b/keyboards/drhigsby/bkf/info.json @@ -8,6 +8,11 @@ "pid": "0x0003", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/drhigsby/packrat/config.h b/keyboards/drhigsby/packrat/config.h index d063077004d65c48322e545e6b1a2f3f5c0982f2..5700fad7d231bb205533ffcfe8f66ba5a15f73fe 100644 --- a/keyboards/drhigsby/packrat/config.h +++ b/keyboards/drhigsby/packrat/config.h @@ -38,6 +38,3 @@ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } diff --git a/keyboards/drhigsby/packrat/info.json b/keyboards/drhigsby/packrat/info.json index 02d1e1e4c3c47bfacd8059299db507101b9e880c..b9f924670125451176808aed22c89b42da25ca77 100644 --- a/keyboards/drhigsby/packrat/info.json +++ b/keyboards/drhigsby/packrat/info.json @@ -8,6 +8,11 @@ "pid": "0x0004", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/dumbo/config.h b/keyboards/dumbo/config.h index fe1f5e44aadbd26839df339793133578d6ffe678..da4fb5b410889bf2f00015f0221b33248c55f92b 100644 --- a/keyboards/dumbo/config.h +++ b/keyboards/dumbo/config.h @@ -19,11 +19,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D4, D7, E6, B4 } #define MATRIX_COL_PINS { B6, B2, B3, B1, F7, F6} -#define ENCODERS_PAD_A { F4, C6 } -#define ENCODERS_PAD_B { F5, B5 } -#define ENCODERS_PAD_A_RIGHT { F5, B5 } -#define ENCODERS_PAD_B_RIGHT { F4, C6 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/dumbo/info.json b/keyboards/dumbo/info.json index 1b96eab73f0c9fd8a524fe443534b5b5eba9d90c..3fe1a8b4f83817e4b3cb6905e1ad61813a118eda 100644 --- a/keyboards/dumbo/info.json +++ b/keyboards/dumbo/info.json @@ -8,8 +8,22 @@ "pid": "0x25E3", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"}, + {"pin_a": "C6", "pin_b": "B5"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"}, + {"pin_a": "B5", "pin_b": "C6"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/dumbpad/v0x/config.h b/keyboards/dumbpad/v0x/config.h index d302a078d5be0c444be5bf9b182547ce3effd376..2e605318d12bd4d9a0b1b2b3a03317da37797eb2 100644 --- a/keyboards/dumbpad/v0x/config.h +++ b/keyboards/dumbpad/v0x/config.h @@ -21,10 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { C6, D7, E6, B4, B5 } -/* Single rotary encoder */ -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D4 } - /* Onboard LEDs */ #define LED_00 B3 #define LED_01 B1 diff --git a/keyboards/dumbpad/v0x/info.json b/keyboards/dumbpad/v0x/info.json index 160b696fe249fa1dbe46231c1429d4a73f0ae3cc..cf6adb380161a1c638b12cec3f5b3a46b53ee1fc 100644 --- a/keyboards/dumbpad/v0x/info.json +++ b/keyboards/dumbpad/v0x/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.0.7" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D4"} + ] + }, "bootmagic": { "matrix": [3, 0] }, diff --git a/keyboards/dumbpad/v0x_dualencoder/config.h b/keyboards/dumbpad/v0x_dualencoder/config.h index 10e50bbb9962eb5901f58ef1cfa10fc263b74a18..92dd62ea17a6142d825a2b584e731c0b33068768 100644 --- a/keyboards/dumbpad/v0x_dualencoder/config.h +++ b/keyboards/dumbpad/v0x_dualencoder/config.h @@ -21,10 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { D7, E6, B4, B5 } -/* Dual rotary encoders */ -#define ENCODERS_PAD_A { C6, D0 } -#define ENCODERS_PAD_B { D4, D1 } - /* Onboard LEDs */ #define LED_00 B3 #define LED_01 B1 diff --git a/keyboards/dumbpad/v0x_dualencoder/info.json b/keyboards/dumbpad/v0x_dualencoder/info.json index a12eecb8dc352c68daf7967bfe28c6e7b13dd66a..8b6294af5f988b99f50b445c4dae8878afffb7e2 100644 --- a/keyboards/dumbpad/v0x_dualencoder/info.json +++ b/keyboards/dumbpad/v0x_dualencoder/info.json @@ -2,6 +2,12 @@ "usb": { "device_version": "0.0.6" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "D4"}, + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "bootmagic": { "matrix": [3, 0] }, diff --git a/keyboards/dumbpad/v0x_right/config.h b/keyboards/dumbpad/v0x_right/config.h index 5eb5ae961c9894328563084266ddd46cbb9b649e..cdc8d665dcfe86a191a5ad2c059454ee74b526a9 100644 --- a/keyboards/dumbpad/v0x_right/config.h +++ b/keyboards/dumbpad/v0x_right/config.h @@ -20,10 +20,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { B5, B4, E6, D7, C6 } -/* Single rotary encoder */ -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { D0 } - /* Onboard LEDs */ #define LED_00 B1 #define LED_01 B3 diff --git a/keyboards/dumbpad/v0x_right/info.json b/keyboards/dumbpad/v0x_right/info.json index dc01df1c323c64af182e0e7ac12005a6a47e2dbb..437d009dc8637d1064f0f342b4b00732164bb6f2 100644 --- a/keyboards/dumbpad/v0x_right/info.json +++ b/keyboards/dumbpad/v0x_right/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.0.7" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "D0"} + ] + }, "bootmagic": { "matrix": [3, 4] }, diff --git a/keyboards/dumbpad/v1x/config.h b/keyboards/dumbpad/v1x/config.h index 421d1f7a1d004d41e15ec764d1596b2170e43ea1..09adca69e5c0e3f8c3d2e60e032e0b6705d9a252 100644 --- a/keyboards/dumbpad/v1x/config.h +++ b/keyboards/dumbpad/v1x/config.h @@ -21,10 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { C6, D7, E6, B4, B5 } -/* Single rotary encoder */ -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { D4 } - /* Onboard LEDs */ #define LED_00 B6 #define LED_01 B1 diff --git a/keyboards/dumbpad/v1x/info.json b/keyboards/dumbpad/v1x/info.json index f7da467561a5e6430c94638b43a4d269b94f47da..8a3d273415195f4336c16ae4a8e8fe4c062e4306 100644 --- a/keyboards/dumbpad/v1x/info.json +++ b/keyboards/dumbpad/v1x/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "D4"} + ] + }, "bootmagic": { "matrix": [3, 0] }, diff --git a/keyboards/dumbpad/v1x_dualencoder/config.h b/keyboards/dumbpad/v1x_dualencoder/config.h index 9a7be81260a4d5789a6eac4567c2c6b1c68c3088..dce94fd8d4c47686845d0f9baccc44f89d694e9b 100644 --- a/keyboards/dumbpad/v1x_dualencoder/config.h +++ b/keyboards/dumbpad/v1x_dualencoder/config.h @@ -21,10 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { C6, D7, E6, B4, B5 } -/* Dual rotary encoders */ -#define ENCODERS_PAD_A { B2, D0 } -#define ENCODERS_PAD_B { D4, D1 } - /* Onboard LEDs */ #define LED_00 B6 #define LED_01 B1 diff --git a/keyboards/dumbpad/v1x_dualencoder/info.json b/keyboards/dumbpad/v1x_dualencoder/info.json index f7da467561a5e6430c94638b43a4d269b94f47da..e51452897ac17f256fbe34ab579899848ce34396 100644 --- a/keyboards/dumbpad/v1x_dualencoder/info.json +++ b/keyboards/dumbpad/v1x_dualencoder/info.json @@ -2,6 +2,12 @@ "usb": { "device_version": "0.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "D4"}, + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "bootmagic": { "matrix": [3, 0] }, diff --git a/keyboards/dumbpad/v1x_oled/config.h b/keyboards/dumbpad/v1x_oled/config.h index 4300694b822e6db06533238b8b40cf53ff241f96..57fac8225fadbfb353b3c7cab39b580258ed252f 100644 --- a/keyboards/dumbpad/v1x_oled/config.h +++ b/keyboards/dumbpad/v1x_oled/config.h @@ -18,10 +18,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { C6, B1, B3, B2, B6 } -/* Dual rotary encoders */ -#define ENCODERS_PAD_A { B4, E6 } -#define ENCODERS_PAD_B { B5, D7 } - /* Column/Row IO definitions */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/dumbpad/v1x_oled/info.json b/keyboards/dumbpad/v1x_oled/info.json index a20f41682ebc960c51d963583fa4e1c25f244933..7576fe2aa506e9ab93c7ebcc0d5912094cb27de4 100644 --- a/keyboards/dumbpad/v1x_oled/info.json +++ b/keyboards/dumbpad/v1x_oled/info.json @@ -2,6 +2,12 @@ "usb": { "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"}, + {"pin_a": "E6", "pin_b": "D7"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/dumbpad/v1x_right/config.h b/keyboards/dumbpad/v1x_right/config.h index 9f6a109f847808fbf989f7f270484cfaef0a4918..82f308f6513594a8ff3f48f7913da03b4107adc0 100644 --- a/keyboards/dumbpad/v1x_right/config.h +++ b/keyboards/dumbpad/v1x_right/config.h @@ -21,10 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { B5, B4, E6, D7, C6 } -/* Single rotary encoder */ -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { B2 } - /* Onboard LEDs - reversed */ #define LED_00 B3 #define LED_01 B1 diff --git a/keyboards/dumbpad/v1x_right/info.json b/keyboards/dumbpad/v1x_right/info.json index db02b1aead70ca442eed81bd21185766570677de..6cef09807bf5ff0d9b85c6943b56e2f07851d08e 100644 --- a/keyboards/dumbpad/v1x_right/info.json +++ b/keyboards/dumbpad/v1x_right/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "B2"} + ] + }, "bootmagic": { "matrix": [3, 4] }, diff --git a/keyboards/dumbpad/v3x/config.h b/keyboards/dumbpad/v3x/config.h index a989bf9bafb88ec9a65c6e48709001c01a088c2e..2c00ba8eef24b19555286c78a26cc972f500d5fe 100644 --- a/keyboards/dumbpad/v3x/config.h +++ b/keyboards/dumbpad/v3x/config.h @@ -20,10 +20,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5, F6, F7 } #define MATRIX_COL_PINS { C6, D7, E6, B4, B5 } -/* Single rotary encoder */ -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { D4 } - /* Onboard LEDs */ #define LED_00 B1 #define LED_01 B3 diff --git a/keyboards/dumbpad/v3x/info.json b/keyboards/dumbpad/v3x/info.json index 31f44f74fed7ba04fce83588c4b46b8c61e2d26c..acdbe2c590bd1157ad3ae21e396af219eefe9578 100644 --- a/keyboards/dumbpad/v3x/info.json +++ b/keyboards/dumbpad/v3x/info.json @@ -5,6 +5,11 @@ "usb": { "device_version": "0.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "D4"} + ] + }, "bootmagic": { "matrix": [3, 0] }, diff --git a/keyboards/dyz/dyz40/config.h b/keyboards/dyz/dyz40/config.h index 4a907fc8ece8d2339ecd59b2030f1d8ab995ca1d..87e057133dcbd6c69b6abf24d9acbe754dea1040 100644 --- a/keyboards/dyz/dyz40/config.h +++ b/keyboards/dyz/dyz40/config.h @@ -18,7 +18,5 @@ along with this program. If not, see . #pragma once #define TAP_CODE_DELAY 10 // Need this delay for some keys like VOLD/VOLU to work -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } #define DYNAMIC_KEYMAP_LAYER_COUNT 3 diff --git a/keyboards/dyz/dyz40/info.json b/keyboards/dyz/dyz40/info.json index 7043ccc98d49f24b5da88f93275dad241fa0c02c..f1a4bc3f161bc858fda818ba8f4cbf317cd0ff44 100644 --- a/keyboards/dyz/dyz40/info.json +++ b/keyboards/dyz/dyz40/info.json @@ -8,6 +8,11 @@ "cols": ["E6", "F0", "F1", "F4", "F5", "F6", "F7", "C7", "C6", "B6", "B5", "B4", "D7"], "rows": ["B0", "B1", "B3", "B2"] }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "rgblight": { "led_count": 13, "pin": "B7", diff --git a/keyboards/dyz/dyz60/config.h b/keyboards/dyz/dyz60/config.h index bd80723d92940904a40a045303f7af9d9d2dffe7..87e057133dcbd6c69b6abf24d9acbe754dea1040 100644 --- a/keyboards/dyz/dyz60/config.h +++ b/keyboards/dyz/dyz60/config.h @@ -18,7 +18,5 @@ along with this program. If not, see . #pragma once #define TAP_CODE_DELAY 10 // Need this delay for some keys like VOLD/VOLU to work -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } #define DYNAMIC_KEYMAP_LAYER_COUNT 3 diff --git a/keyboards/dyz/dyz60/info.json b/keyboards/dyz/dyz60/info.json index 1f54c23d8e6bf80e331db177d85b4fdb6b38ac3e..413e0ac37950404559ad413926692b4c41033b2b 100644 --- a/keyboards/dyz/dyz60/info.json +++ b/keyboards/dyz/dyz60/info.json @@ -32,6 +32,11 @@ "pid": "0x000A", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "indicators": { "caps_lock": "F1" }, diff --git a/keyboards/dyz/selka40/config.h b/keyboards/dyz/selka40/config.h index d93f882fb088507bffdd18554766d56a2bae81c6..87e057133dcbd6c69b6abf24d9acbe754dea1040 100644 --- a/keyboards/dyz/selka40/config.h +++ b/keyboards/dyz/selka40/config.h @@ -18,7 +18,5 @@ along with this program. If not, see . #pragma once #define TAP_CODE_DELAY 10 // Need this delay for some keys like VOLD/VOLU to work -#define ENCODERS_PAD_A { D6 } -#define ENCODERS_PAD_B { D7 } #define DYNAMIC_KEYMAP_LAYER_COUNT 3 diff --git a/keyboards/dyz/selka40/info.json b/keyboards/dyz/selka40/info.json index 246473ec3d5722913a85a43850a954b56ec730e3..7f3d04417c17f65ad0590f84d70f8622f9997358 100644 --- a/keyboards/dyz/selka40/info.json +++ b/keyboards/dyz/selka40/info.json @@ -32,6 +32,11 @@ "pid": "0x0012", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D7"} + ] + }, "indicators": { "caps_lock": "B1", "num_lock": "B3", diff --git a/keyboards/ealdin/quadrant/config.h b/keyboards/ealdin/quadrant/config.h index e4f37ae1c9a5b18e379528c4eb1b3c0f54298943..f4954fcd1198f4a219eaf07509f6652723e9229d 100644 --- a/keyboards/ealdin/quadrant/config.h +++ b/keyboards/ealdin/quadrant/config.h @@ -24,10 +24,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D5 } -#define ENCODERS_PAD_B { F1 } -#define ENCODER_RESOLUTION 4 - #define RGB_DI_PIN C7 #ifdef RGB_DI_PIN #define RGBLED_NUM 7 diff --git a/keyboards/ealdin/quadrant/info.json b/keyboards/ealdin/quadrant/info.json index e62de3f54f09a27b40b5cd03b424e99f1c00322c..d8b388c331497406fd77a9ef8ff8656e01c5af40 100644 --- a/keyboards/ealdin/quadrant/info.json +++ b/keyboards/ealdin/quadrant/info.json @@ -8,6 +8,11 @@ "pid": "0x5154", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "F1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "community_layouts": ["ortho_5x14"], diff --git a/keyboards/ebastler/isometria_75/rev1/config.h b/keyboards/ebastler/isometria_75/rev1/config.h index 4aa733a06a962e974cc947d1f2a4502b31538e56..979424c64a331ed14cf1c99305dc1a09e92b4b56 100644 --- a/keyboards/ebastler/isometria_75/rev1/config.h +++ b/keyboards/ebastler/isometria_75/rev1/config.h @@ -43,13 +43,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_RAINBOW_MOOD #define RGBLIGHT_EFFECT_RAINBOW_SWIRL - -/* Rotary encoder - set the resolution fitting your encoder. -Most will need a value of 4. If 1 encoder click results in 2 keycodes sent -increase the value. If you need 2 clicks for 1 keycode, decrease*/ -#define ENCODER_RESOLUTION 2 -#define ENCODERS_PAD_A { C15 } -#define ENCODERS_PAD_B { C14 } #define TAP_CODE_DELAY 10 /* ADC - will be used for battery monitoring once BT support is added */ diff --git a/keyboards/ebastler/isometria_75/rev1/info.json b/keyboards/ebastler/isometria_75/rev1/info.json index a2a8c4e1d54bdcd91af29a65d953becfd84788dd..83061d92df31276128cc42b3c1f7fe071041694f 100644 --- a/keyboards/ebastler/isometria_75/rev1/info.json +++ b/keyboards/ebastler/isometria_75/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0x1337", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14", "resolution": 2} + ] + }, "backlight": { "pin": "A9", "levels": 5, diff --git a/keyboards/ein_60/config.h b/keyboards/ein_60/config.h index 3297437ae8cc4f58851eeac9ddd4f7a308924a4e..457f0a5013edbe14f90c61281544c9b86128ccd3 100644 --- a/keyboards/ein_60/config.h +++ b/keyboards/ein_60/config.h @@ -23,12 +23,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW -#ifdef ENCODER_ENABLE -# define ENCODERS_PAD_A { B0, C5 } -# define ENCODERS_PAD_B { E3, C4 } -# define ENCODER_RESOLUTIONS { 4, 4 } -#endif - #ifdef OLED_ENABLE # define OLED_DISPLAY_128X64 # define OLED_TIMEOUT 450000 diff --git a/keyboards/ein_60/info.json b/keyboards/ein_60/info.json index 676915d9e638212f5f1e04f2a8fc660a2c8df3dd..3eaa251d7809f7b0a888a6fac8f41205014d533b 100644 --- a/keyboards/ein_60/info.json +++ b/keyboards/ein_60/info.json @@ -8,6 +8,12 @@ "pid": "0x0003", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "E3"}, + {"pin_a": "C5", "pin_b": "C4"} + ] + }, "processor": "at90usb1286", "bootloader": "qmk-dfu", "layouts": { diff --git a/keyboards/evolv/config.h b/keyboards/evolv/config.h index 2a7804e1a16bbb72e6d5c74b68c221a74ba8460d..c76fc98986d8713dcb9da1ffa9a4b087ce484898 100644 --- a/keyboards/evolv/config.h +++ b/keyboards/evolv/config.h @@ -41,9 +41,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { A15 } -#define ENCODER_RESOLUTION 2 #define TAPPING_TERM 200 /* diff --git a/keyboards/evolv/info.json b/keyboards/evolv/info.json index b3b8a77a02794f87fd8ed2cec985e98427a89ea2..76b428b1cd50d2ebcdb6b4fc662cec1a85e9e62f 100644 --- a/keyboards/evolv/info.json +++ b/keyboards/evolv/info.json @@ -8,6 +8,11 @@ "pid": "0x0E75", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "A15", "resolution": 2} + ] + }, "processor": "STM32F072", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/evyd13/atom47/rev4/config.h b/keyboards/evyd13/atom47/rev4/config.h index 3cd6d65e1a3987dfb8822869ae9bf0bb3c0b2f8c..52a4bf2ff9b5705466a9f2caba1811d1f204630c 100644 --- a/keyboards/evyd13/atom47/rev4/config.h +++ b/keyboards/evyd13/atom47/rev4/config.h @@ -23,8 +23,5 @@ along with this program. If not, see . #define MATRIX_ROW_PINS {D0,C2,C5,C6} #define MATRIX_COL_PINS {C4,C7,B7,B6,B5,B2,B1,B0,D6,D5,D4,D3,D2} -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B4 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/evyd13/atom47/rev4/info.json b/keyboards/evyd13/atom47/rev4/info.json index b89255f90ab7a0ae4fb85204469167bed2c072f4..42b8abda541211dbc2bc8a93537d6af32e313aab 100644 --- a/keyboards/evyd13/atom47/rev4/info.json +++ b/keyboards/evyd13/atom47/rev4/info.json @@ -8,6 +8,11 @@ "pid": "0x8446", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B4"} + ] + }, "qmk_lufa_bootloader": { "esc_input": "C6", "esc_output": "C4", diff --git a/keyboards/evyd13/eon40/config.h b/keyboards/evyd13/eon40/config.h index ca86bd78bcb618212934a77c585b481f8b228732..2f1708d532b18a6d3b166bc2c5d801ea875e3df8 100644 --- a/keyboards/evyd13/eon40/config.h +++ b/keyboards/evyd13/eon40/config.h @@ -30,9 +30,6 @@ #define MATRIX_ROW_PINS {B7,D5,F5,F6} #define MATRIX_COL_PINS {F0,F1,F4,D3,D4,D6,D7,B4,B5,B6,C6,C7} -#define ENCODERS_PAD_A { E6, B0, D1 } -#define ENCODERS_PAD_B { F7, D0, D2 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/evyd13/eon40/info.json b/keyboards/evyd13/eon40/info.json index 66bcb280ce8c0f8139ad4d15dacb70471286c894..cda0c495a4bfc61afdae2924d13c9d3be2ddd3de 100644 --- a/keyboards/evyd13/eon40/info.json +++ b/keyboards/evyd13/eon40/info.json @@ -8,6 +8,13 @@ "pid": "0x0140", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "F7"}, + {"pin_a": "B0", "pin_b": "D0"}, + {"pin_a": "D1", "pin_b": "D2"} + ] + }, "qmk_lufa_bootloader": { "esc_input": "B7", "esc_output": "F0" diff --git a/keyboards/evyd13/gh80_3700/config.h b/keyboards/evyd13/gh80_3700/config.h index 7e3a59e6316c7a58dee4f80597fa6e5a49a99d35..003131ceaeb27beeb9547e1e66163eb3c6e37b2d 100644 --- a/keyboards/evyd13/gh80_3700/config.h +++ b/keyboards/evyd13/gh80_3700/config.h @@ -53,7 +53,3 @@ //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -// Define rotary encoder -#define ENCODERS_PAD_A { F1 } -#define ENCODERS_PAD_B { F4 } diff --git a/keyboards/evyd13/gh80_3700/info.json b/keyboards/evyd13/gh80_3700/info.json index 9a92b02d6efb95971c13b9baa54dbee7273a0bba..7ab1267ed9bae55df2d6838ded39af1f22a1b8c8 100644 --- a/keyboards/evyd13/gh80_3700/info.json +++ b/keyboards/evyd13/gh80_3700/info.json @@ -8,6 +8,11 @@ "pid": "0x633A", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F1", "pin_b": "F4"} + ] + }, "processor": "atmega32u4", "bootloader": "qmk-dfu", "community_layouts": ["numpad_6x4", "ortho_6x4"], diff --git a/keyboards/evyd13/ta65/config.h b/keyboards/evyd13/ta65/config.h index 6bea2c459c144a3d140ad182c5def5e8f42731e3..ef8948786b316b321166fdc984900243199b7ea6 100644 --- a/keyboards/evyd13/ta65/config.h +++ b/keyboards/evyd13/ta65/config.h @@ -23,12 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS {B4,D7,D6,D4,B3} #define MATRIX_COL_PINS {D2,D1,D0,D3,D5,C7,C6,B6,B5,F0,F1,F4,F5,F6,F7,B0} -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B1 } - -/* Uncomment if your encoder doesn't react to every turn or skips */ -//#define ENCODER_RESOLUTION 2 - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/evyd13/ta65/info.json b/keyboards/evyd13/ta65/info.json index 4c52181f6790190ece920da5dd23c50d2e11c75f..da501c67567b01701f1a5b6d32372c2ffb990f8b 100644 --- a/keyboards/evyd13/ta65/info.json +++ b/keyboards/evyd13/ta65/info.json @@ -8,6 +8,11 @@ "pid": "0x7465", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1"} + ] + }, "qmk_lufa_bootloader": { "esc_input": "B4", "esc_output": "D2", diff --git a/keyboards/eyeohdesigns/sprh/config.h b/keyboards/eyeohdesigns/sprh/config.h index f386c4033cac049f0e4939bcac0994b74edb5b91..31b6d017ce60cbd553a22850a756113e11847a2c 100644 --- a/keyboards/eyeohdesigns/sprh/config.h +++ b/keyboards/eyeohdesigns/sprh/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once - -#define ENCODERS_PAD_A {D0} -#define ENCODERS_PAD_B {D1} -#define ENCODER_RESOLUTION 2 - - #define MATRIX_ROW_PINS { B3, B7, D2, D5, D3 } #define MATRIX_COL_PINS { E6, F0, F1, F4, F5, F6, C6, B6, B5, B4, D7, D6, F7, D4 } diff --git a/keyboards/eyeohdesigns/sprh/info.json b/keyboards/eyeohdesigns/sprh/info.json index b61d4c95d5bc9e7a4530ae3400b26139f14b93b6..bcef81b3106d89b9e365b12fe1cc1c1188af089c 100644 --- a/keyboards/eyeohdesigns/sprh/info.json +++ b/keyboards/eyeohdesigns/sprh/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/eyeohdesigns/theboulevard/config.h b/keyboards/eyeohdesigns/theboulevard/config.h index 22143042a85b32871bfcd3b5486f71d0b9a51622..081ab50216958cc60ccac9bdfa99c42b02bb0bd6 100644 --- a/keyboards/eyeohdesigns/theboulevard/config.h +++ b/keyboards/eyeohdesigns/theboulevard/config.h @@ -17,11 +17,6 @@ along with this program. If not, see . #pragma once - -#define ENCODERS_PAD_A {F5} -#define ENCODERS_PAD_B {F4} -#define ENCODER_RESOLUTION 2 - #define MATRIX_ROW_PINS { F7, B1, E6, F0, F1 } #define MATRIX_COL_PINS { B0, C6, B6, B5, B4, D7, D6, D4, D5, D3, D2, D1, D0 } diff --git a/keyboards/eyeohdesigns/theboulevard/info.json b/keyboards/eyeohdesigns/theboulevard/info.json index 3fc238b3b9057d137cd9e0f0a26afc559c4cec9d..0a1274290307810d121fbf9acb0726a7d53493c3 100644 --- a/keyboards/eyeohdesigns/theboulevard/info.json +++ b/keyboards/eyeohdesigns/theboulevard/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/feker/ik75/config.h b/keyboards/feker/ik75/config.h index faddc42ce8c4e10bd0d1219c6aaf1bef8a8a8fc5..d05ae4f3fedd5c616a0dcc8810a7e8278193990e 100644 --- a/keyboards/feker/ik75/config.h +++ b/keyboards/feker/ik75/config.h @@ -25,15 +25,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION ROW2COL -#ifdef ENCODER_ENABLE - /* Encoder pins */ - #define ENCODERS_PAD_A { C6 } - #define ENCODERS_PAD_B { C7 } - - /* Encoder config */ - #define ENCODER_RESOLUTION 2 -#endif - #ifdef RGB_MATRIX_ENABLE #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 diff --git a/keyboards/feker/ik75/info.json b/keyboards/feker/ik75/info.json index 0fec2c9d4c076a8ba1f19472c3d19c2123827162..2107909b3e62b34bf548425008ccda7363b6e002 100644 --- a/keyboards/feker/ik75/info.json +++ b/keyboards/feker/ik75/info.json @@ -8,6 +8,11 @@ "pid": "0x1226", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "C7", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/ffkeebs/puca/config.h b/keyboards/ffkeebs/puca/config.h index 81212585a9339784da6c1e4a91478117c7e1d7d8..6f88b36fe7611d8fd70aa99f0c839c800375f72d 100644 --- a/keyboards/ffkeebs/puca/config.h +++ b/keyboards/ffkeebs/puca/config.h @@ -41,10 +41,6 @@ along with this program. If not, see . #define RGBLED_NUM 8 #endif - -#define ENCODERS_PAD_A { F4 } -#define ENCODERS_PAD_B { F5 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/ffkeebs/puca/info.json b/keyboards/ffkeebs/puca/info.json index 764daf8788213c117e690b7cdcf943d5dcd23d85..1cf9fd94ebd2ed990ac0273e150b290acc9a88ba 100644 --- a/keyboards/ffkeebs/puca/info.json +++ b/keyboards/ffkeebs/puca/info.json @@ -8,6 +8,11 @@ "pid": "0x0002", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layout_aliases": { diff --git a/keyboards/ffkeebs/siris/config.h b/keyboards/ffkeebs/siris/config.h index 831bb7a0e629e11ecd4ada14cebab8c0325b4772..3e03a4020ea92447c6a1b4aeeb4db1977e19d7dc 100644 --- a/keyboards/ffkeebs/siris/config.h +++ b/keyboards/ffkeebs/siris/config.h @@ -25,6 +25,3 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { D3, C6 } -#define ENCODERS_PAD_B { D5, B6 } diff --git a/keyboards/ffkeebs/siris/info.json b/keyboards/ffkeebs/siris/info.json index 335f80f65cc463bf43ae946917cd16050477e775..5da5369b7c4670f5694117c6ede581bcc898c26c 100644 --- a/keyboards/ffkeebs/siris/info.json +++ b/keyboards/ffkeebs/siris/info.json @@ -8,6 +8,12 @@ "pid": "0xE96C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D5"}, + {"pin_a": "C6", "pin_b": "B6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/flxlb/zplit/config.h b/keyboards/flxlb/zplit/config.h index ffd05b6e7db85a65de7496949997c9ccc88a65e7..83dcb4fe421fa3275766078fd161cb1dab6a609b 100644 --- a/keyboards/flxlb/zplit/config.h +++ b/keyboards/flxlb/zplit/config.h @@ -31,9 +31,6 @@ along with this program. If not, see . #define SPLIT_USB_DETECT #define SPLIT_USB_TIMEOUT 500 -#define ENCODERS_PAD_A { B0 } -#define ENCODERS_PAD_B { D2 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/flxlb/zplit/info.json b/keyboards/flxlb/zplit/info.json index 3d1619776f88721d8d0347e311f98f05d32e42e4..2cfb64b79345fe928cbd2901776e970fc2ed5867 100644 --- a/keyboards/flxlb/zplit/info.json +++ b/keyboards/flxlb/zplit/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "D2"} + ] + }, "split": { "soft_serial_pin": "D0" }, diff --git a/keyboards/giabalanai/config.h b/keyboards/giabalanai/config.h index a24f802ff045e704f88719505a9aae7de523ba2f..01e84b4cdd82fd9b1f2a9d966be42bd0cc801716 100644 --- a/keyboards/giabalanai/config.h +++ b/keyboards/giabalanai/config.h @@ -220,18 +220,7 @@ along with this program. If not, see . # define MIDI_INITIAL_VELOCITY 117 #endif // MIDI_ENABLE -/* - * Encoder options - */ -#ifdef ENCODER_ENABLE -# define ENCODERS_PAD_A { } -# define ENCODERS_PAD_B { } -# define ENCODER_RESOLUTIONS { } -# define ENCODERS_PAD_A_RIGHT { B4 } -# define ENCODERS_PAD_B_RIGHT { B6 } -# define ENCODER_RESOLUTIONS_RIGHT { 4 } -# define TAP_CODE_DELAY 10 -#endif // ENCODER_ENABLE +#define TAP_CODE_DELAY 10 /* 2021/01/22 added to shrink firmware size */ // NO_ACTION_TAPPING -1964 bytes, however, this disables Layer mods... diff --git a/keyboards/giabalanai/info.json b/keyboards/giabalanai/info.json index 05c0e67fdfd3c58aed9171bd1e661561b6409163..30bd26159f9621e25c2bde2f93ec4b60a1d54bb9 100644 --- a/keyboards/giabalanai/info.json +++ b/keyboards/giabalanai/info.json @@ -8,8 +8,18 @@ "pid": "0xF4B0", "device_version": "0.0.1" }, + "encoder": { + "rotary": [] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B6"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/gl516/n51gl/config.h b/keyboards/gl516/n51gl/config.h index ee71cdbca74e2849135ea1543a1a7287b00624d7..276e6f6c6d8bef39e10d2cd2750e79cc8012c450 100644 --- a/keyboards/gl516/n51gl/config.h +++ b/keyboards/gl516/n51gl/config.h @@ -26,10 +26,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D1, D0, D4, C6 } #define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, B2 } -#define ENCODERS_PAD_A { D7 } -#define ENCODERS_PAD_B { E6 } -#define ENCODER_RESOLUTION 3 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/gl516/n51gl/info.json b/keyboards/gl516/n51gl/info.json index 50607c3f8f16eb4099f4c0fc9fb59883a7050858..eaaf6e69dd964f16f085a3f8d88e9bddd301626d 100644 --- a/keyboards/gl516/n51gl/info.json +++ b/keyboards/gl516/n51gl/info.json @@ -8,6 +8,11 @@ "pid": "0xE8CF", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "E6", "resolution": 3} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/gmmk/pro/config.h b/keyboards/gmmk/pro/config.h index 73e8e75bdf9e84646c95111f23ed99d084c774c2..c633d722a09c8cd3e64b00eebef185fdf94f8f43 100644 --- a/keyboards/gmmk/pro/config.h +++ b/keyboards/gmmk/pro/config.h @@ -26,10 +26,6 @@ #define DIODE_DIRECTION COL2ROW #define TAP_CODE_DELAY 10 -#define ENCODERS_PAD_A \ - { C15 } -#define ENCODERS_PAD_B \ - { C14 } /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/gmmk/pro/rev1/ansi/info.json b/keyboards/gmmk/pro/rev1/ansi/info.json index 58636b462b88bc0f31f3bbf9dee8bf6042fc9b35..b8a7e94a82f328af59acb1ca45ca49e0af33483a 100644 --- a/keyboards/gmmk/pro/rev1/ansi/info.json +++ b/keyboards/gmmk/pro/rev1/ansi/info.json @@ -8,6 +8,11 @@ "pid": "0x5044", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14"} + ] + }, "bootmagic": { "matrix": [1, 3] }, diff --git a/keyboards/gmmk/pro/rev1/iso/info.json b/keyboards/gmmk/pro/rev1/iso/info.json index dce316167a07b0e438caecfe60737b903dc0439f..48181ec488a45bf0828b610f2b45d145cea7bdad 100644 --- a/keyboards/gmmk/pro/rev1/iso/info.json +++ b/keyboards/gmmk/pro/rev1/iso/info.json @@ -8,6 +8,11 @@ "pid": "0x5044", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14"} + ] + }, "bootmagic": { "matrix": [1, 3] }, diff --git a/keyboards/gmmk/pro/rev2/ansi/info.json b/keyboards/gmmk/pro/rev2/ansi/info.json index 37b2e4b1cc6fb8fb7caf0dc6aed980d418d26948..a8a25f85470734132dd62397054d5fc078b08eda 100644 --- a/keyboards/gmmk/pro/rev2/ansi/info.json +++ b/keyboards/gmmk/pro/rev2/ansi/info.json @@ -8,6 +8,11 @@ "pid": "0x5044", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14"} + ] + }, "bootmagic": { "matrix": [1, 3] }, diff --git a/keyboards/gmmk/pro/rev2/iso/info.json b/keyboards/gmmk/pro/rev2/iso/info.json index 10eaa5474bea12b0a02715226ab973232ac84363..c37ccd53df8c5c09322c60ae683e29b3632c4851 100644 --- a/keyboards/gmmk/pro/rev2/iso/info.json +++ b/keyboards/gmmk/pro/rev2/iso/info.json @@ -8,6 +8,11 @@ "pid": "0x5044", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14"} + ] + }, "bootmagic": { "matrix": [1, 3] }, diff --git a/keyboards/gorthage_truck/config.h b/keyboards/gorthage_truck/config.h index 9fc348cc73143e38c2f4284569a6dfaf4d825c26..56b84cb4271b556693cad0224ee6149008a6a496 100644 --- a/keyboards/gorthage_truck/config.h +++ b/keyboards/gorthage_truck/config.h @@ -33,6 +33,3 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } diff --git a/keyboards/gorthage_truck/info.json b/keyboards/gorthage_truck/info.json index 34ba7b23a0d57215254d0398c1514f9ca44bc611..fe5b37c6b855e5bb42c406f7cff9f83dc73eb941 100644 --- a/keyboards/gorthage_truck/info.json +++ b/keyboards/gorthage_truck/info.json @@ -8,6 +8,11 @@ "pid": "0x58E4", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "indicators": { "caps_lock": "D3", "num_lock": "D5", diff --git a/keyboards/h0oni/deskpad/config.h b/keyboards/h0oni/deskpad/config.h index a9b932daf4a9b5558e60ca941076b610b6885cbe..ec6c3b733dddc6bce989517a45a50be38123b86d 100644 --- a/keyboards/h0oni/deskpad/config.h +++ b/keyboards/h0oni/deskpad/config.h @@ -33,10 +33,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Defining encoder pads */ -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D3 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/h0oni/deskpad/info.json b/keyboards/h0oni/deskpad/info.json index 30d3e3d32ea79a372e19308e04e97bdb3e48a4b9..2c553313c8af8a4a8521244a135fca064ce72e1c 100644 --- a/keyboards/h0oni/deskpad/info.json +++ b/keyboards/h0oni/deskpad/info.json @@ -8,6 +8,11 @@ "pid": "0x4450", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 3, diff --git a/keyboards/hadron/ver3/config.h b/keyboards/hadron/ver3/config.h index 97ab4c6a439f79835b35eda89894ceeda8822832..64d1d41b0fbbc9b8e00ac9a514a159ba15bff132 100644 --- a/keyboards/hadron/ver3/config.h +++ b/keyboards/hadron/ver3/config.h @@ -33,10 +33,6 @@ #define MATRIX_ROW_PINS { C15, C14, A10, A9, A8 } #define MATRIX_COL_PINS { B8, B2, B10, A0, A1, A2, B0, A3, B1, A6, A7, B12, C13, B11, B9 } -#define ENCODERS_PAD_A { B13 } -#define ENCODERS_PAD_B { B14 } - - //Audio #undef AUDIO_VOICES #undef AUDIO_PIN diff --git a/keyboards/hadron/ver3/info.json b/keyboards/hadron/ver3/info.json index ec89f32253666d55b9f61e7f0b630edb636fae19..2fd5bda88101c4e53163d9eafca710966fe62652 100644 --- a/keyboards/hadron/ver3/info.json +++ b/keyboards/hadron/ver3/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "B13", "pin_b": "B14"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C" diff --git a/keyboards/halfcliff/config.h b/keyboards/halfcliff/config.h index 1185bee5e776ad470222ef3c0adf1abd99f34945..07d53e4e49974fd320ae00a59c6a027742958d1b 100644 --- a/keyboards/halfcliff/config.h +++ b/keyboards/halfcliff/config.h @@ -25,11 +25,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F5, F6, F7, D7, B5, F5, F6, F7, D7, B5 } #define MATRIX_COL_PINS { B4, E6, C6, B6, B2 } -//#define NUMBER_OF_ENCODERS 1 -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { F4 } -#define ENCODER_RESOLUTION 2 - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN #define RGBLED_NUM 10 diff --git a/keyboards/halfcliff/info.json b/keyboards/halfcliff/info.json index 1282ab2ffe69809fef60cfda060fbb0f68380f5f..aa97f81a7334fa6267758217b5a83f57fe120602 100644 --- a/keyboards/halfcliff/info.json +++ b/keyboards/halfcliff/info.json @@ -8,6 +8,11 @@ "pid": "0x0021", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "F4", "resolution": 2} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/halokeys/elemental75/config.h b/keyboards/halokeys/elemental75/config.h index 61eeea4e017b4a71d3884587ae32c7c3cc58fd6b..0ecdf933b0b23f1cee0e6b9935551efe7e8fd7b7 100644 --- a/keyboards/halokeys/elemental75/config.h +++ b/keyboards/halokeys/elemental75/config.h @@ -19,8 +19,6 @@ #define MATRIX_COL_PINS { B2, B1, B0, B10, B11, B13, B14, B15, A8, A9, A14, A15, B3, B4, B7 } #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B5 } #define TAP_CODE_DELAY 10 // tap_code function delay for register and unregister #define RGB_DI_PIN A10 diff --git a/keyboards/halokeys/elemental75/info.json b/keyboards/halokeys/elemental75/info.json index 50ae0900fbe6698ec806983aceb0e53ffd265169..191b105542079c9629debd57dbaa495c2d587a80 100644 --- a/keyboards/halokeys/elemental75/info.json +++ b/keyboards/halokeys/elemental75/info.json @@ -8,6 +8,11 @@ "pid": "0xEA75", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C", diff --git a/keyboards/handwired/amigopunk/config.h b/keyboards/handwired/amigopunk/config.h index 78f8271f840989b04860b1fe59c68a8a1283ec7b..2cbbb3152a5c01da72d60430e64c18d904cfdbe3 100644 --- a/keyboards/handwired/amigopunk/config.h +++ b/keyboards/handwired/amigopunk/config.h @@ -24,12 +24,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Encoder setup */ -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A { E0 } -#define ENCODERS_PAD_B { E1 } -#endif - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/handwired/amigopunk/info.json b/keyboards/handwired/amigopunk/info.json index 2f98f2c7557dc71358d8e7ed14409254a457eb49..e79911a676323ad4740da9ce99f4c70467aa9e95 100644 --- a/keyboards/handwired/amigopunk/info.json +++ b/keyboards/handwired/amigopunk/info.json @@ -8,6 +8,11 @@ "pid": "0x1805", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E0", "pin_b": "E1"} + ] + }, "processor": "at90usb1286", "bootloader": "halfkay", "layouts": { diff --git a/keyboards/handwired/bento/rev1/config.h b/keyboards/handwired/bento/rev1/config.h index 497a2deb16c3a4fade40a633b3b932cbaf9364c1..62c3144cc554d4523a02912fcdb1081f54c30e84 100644 --- a/keyboards/handwired/bento/rev1/config.h +++ b/keyboards/handwired/bento/rev1/config.h @@ -16,9 +16,6 @@ #pragma once -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN #define RGBLED_NUM 4 diff --git a/keyboards/handwired/bento/rev1/info.json b/keyboards/handwired/bento/rev1/info.json index 057931bb4e54cd5f746b4ea5ba43395cfcc4f7b6..5f7e6733062492400c5f06e057203853ca2f3e27 100644 --- a/keyboards/handwired/bento/rev1/info.json +++ b/keyboards/handwired/bento/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0xDAD3", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/handwired/d48/config.h b/keyboards/handwired/d48/config.h index 21f78e0645cafe183aa0f76b0302d9410b80a57e..23dbfa831cd7ae4543c1a10080b7728990e5aecc 100644 --- a/keyboards/handwired/d48/config.h +++ b/keyboards/handwired/d48/config.h @@ -40,11 +40,6 @@ ) #endif -/* Encoders */ -#define ENCODERS_PAD_A { B3, A0 } -#define ENCODERS_PAD_B { A6, A1 } -/* #define ENCODER_RESOLUTION 4 */ - /* OLED */ #define OLED_FONT_H "glcdfont_d48.c" #define OLED_TIMEOUT 0 diff --git a/keyboards/handwired/d48/info.json b/keyboards/handwired/d48/info.json index 9da51d59593a7dcc44833e526325c95c39a8d6ce..c607f21937f325684301ae94bf001d49fe5f6eed 100644 --- a/keyboards/handwired/d48/info.json +++ b/keyboards/handwired/d48/info.json @@ -8,6 +8,12 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "A6"}, + {"pin_a": "A0", "pin_b": "A1"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C", diff --git a/keyboards/handwired/dactylmacropad/config.h b/keyboards/handwired/dactylmacropad/config.h index e69ceac331737724fe368c47bdeb623a2b8931af..a2a5455ab1485b9a9023c7a35a9093bc5cedd332 100644 --- a/keyboards/handwired/dactylmacropad/config.h +++ b/keyboards/handwired/dactylmacropad/config.h @@ -19,7 +19,4 @@ //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 100 diff --git a/keyboards/handwired/dactylmacropad/info.json b/keyboards/handwired/dactylmacropad/info.json index b56174caa2f000a8e0c2b6bc2757bcb8c5ce0cf5..1f56982b6dde521212c7fe519d3a46165e08f495 100644 --- a/keyboards/handwired/dactylmacropad/info.json +++ b/keyboards/handwired/dactylmacropad/info.json @@ -23,6 +23,11 @@ "pid": "0x0000", "vid": "0xFEED" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/handwired/daishi/config.h b/keyboards/handwired/daishi/config.h index 6a5d485d7fe48c526439275a39351c7035ae1029..1fefa56fc60b9e031131e19c725c7db909949836 100644 --- a/keyboards/handwired/daishi/config.h +++ b/keyboards/handwired/daishi/config.h @@ -34,10 +34,5 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Set up rotary encoder */ -#define ENCODERS_PAD_A { F1 } -#define ENCODERS_PAD_B { F0 } -#define ENCODER_RESOLUTION 2 - /* Set delay for tap_code on rotary encoder */ #define TAP_CODE_DELAY 10 diff --git a/keyboards/handwired/daishi/info.json b/keyboards/handwired/daishi/info.json index a28c8855373e95ba40f60edebd443fa618a0c01f..27671cc28a7a5f162e3402938e783a51225f3cec 100644 --- a/keyboards/handwired/daishi/info.json +++ b/keyboards/handwired/daishi/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F1", "pin_b": "F0", "resolution": 2} + ] + }, "processor": "at90usb1286", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/handwired/daskeyboard/daskeyboard4/info.json b/keyboards/handwired/daskeyboard/daskeyboard4/info.json index 067450ae0bb0c8502e82f0a0daef63ebd1df2385..900a66bb8b95dd61d7c38b32849c10c608f3c94a 100644 --- a/keyboards/handwired/daskeyboard/daskeyboard4/info.json +++ b/keyboards/handwired/daskeyboard/daskeyboard4/info.json @@ -39,8 +39,7 @@ "rotary": [ { "pin_a": "B13", - "pin_b": "B12", - "resolution": 4 + "pin_b": "B12" } ] }, diff --git a/keyboards/handwired/dc/mc/001/config.h b/keyboards/handwired/dc/mc/001/config.h index 7be4ba0aa9bcc5c86a94b910e93038e53a17c8c4..4e9dfdea8cc9d551243301415a1beabbdcbfda5b 100644 --- a/keyboards/handwired/dc/mc/001/config.h +++ b/keyboards/handwired/dc/mc/001/config.h @@ -17,16 +17,6 @@ along with this program. If not, see . #pragma once -/* - RE_CHANNEL_A = _BV(6), - RE_CHANNEL_B = _BV(5), -*/ -#define ENCODERS_PAD_A \ - { B6 } -#define ENCODERS_PAD_B \ - { B5 } -#define ENCODER_RESOLUTION 4 - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/handwired/dc/mc/001/info.json b/keyboards/handwired/dc/mc/001/info.json index 78c75f37133c17f72ddc7653805af62679baebf2..852915569ed8cf6c292f33409dbe9730718becd8 100644 --- a/keyboards/handwired/dc/mc/001/info.json +++ b/keyboards/handwired/dc/mc/001/info.json @@ -8,6 +8,11 @@ "pid": "0x4D43", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/handwired/ddg_56/config.h b/keyboards/handwired/ddg_56/config.h index a9b3c12ef2360ee4c3e100645a485284d68e1574..e46edef395e96c1ce3948b8a27bd22aa7703e9dd 100644 --- a/keyboards/handwired/ddg_56/config.h +++ b/keyboards/handwired/ddg_56/config.h @@ -19,6 +19,3 @@ #define MATRIX_ROW_PINS { B5, B15, B9, B10, A14 } #define MATRIX_COL_PINS { A2, B8, B13, B14, B4, B11, B12, A13, A15, A8, A7, A6, B0, B1 } - -#define ENCODERS_PAD_A { A1, B3 } -#define ENCODERS_PAD_B { A0, B2 } diff --git a/keyboards/handwired/ddg_56/info.json b/keyboards/handwired/ddg_56/info.json index 2b7a8cfc438734d1ef6cc774709e18991059708d..f7253711e4f2cd47a85b8b20377cdc324f3fd40a 100644 --- a/keyboards/handwired/ddg_56/info.json +++ b/keyboards/handwired/ddg_56/info.json @@ -8,6 +8,12 @@ "pid": "0xB195", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A1", "pin_b": "A0"}, + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C", diff --git a/keyboards/handwired/frankie_macropad/config.h b/keyboards/handwired/frankie_macropad/config.h index 8045d59c670f99806fa1dd60b43898b5337cee60..577b27b37201f89552a56f300c6f154b9409e560 100644 --- a/keyboards/handwired/frankie_macropad/config.h +++ b/keyboards/handwired/frankie_macropad/config.h @@ -49,6 +49,3 @@ along with this program. If not, see . //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING #define NO_ACTION_ONESHOT - -#define ENCODERS_PAD_A { D0, D2 } -#define ENCODERS_PAD_B { D1, D3 } diff --git a/keyboards/handwired/frankie_macropad/info.json b/keyboards/handwired/frankie_macropad/info.json index 3ddf4075495e37d637cb06cc1be08f6844b1b6ef..24fb55f5daf7838980a871aed94b6fccdfeba606 100644 --- a/keyboards/handwired/frankie_macropad/info.json +++ b/keyboards/handwired/frankie_macropad/info.json @@ -8,6 +8,12 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "bootmagic": { "matrix": [2, 0] }, diff --git a/keyboards/handwired/hnah108/config.h b/keyboards/handwired/hnah108/config.h index a942bd253d4f7169b535e0aaa08ab5fe44edd105..2face5fbed712890b614aea85e2ce6cadfe2eaa1 100644 --- a/keyboards/handwired/hnah108/config.h +++ b/keyboards/handwired/hnah108/config.h @@ -34,9 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } - #define RGB_DI_PIN E2 #define RGB_MATRIX_LED_COUNT 30 // RGB Matrix Animation modes. Explicitly enabled diff --git a/keyboards/handwired/hnah108/info.json b/keyboards/handwired/hnah108/info.json index c9dcc020cc5f84f2e11442b1e214edd1551c71ae..116591fddff16473a25e05c3ef0c6a09d234ff9a 100644 --- a/keyboards/handwired/hnah108/info.json +++ b/keyboards/handwired/hnah108/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "backlight": { "pin": "B7", "levels": 4, diff --git a/keyboards/handwired/mutepad/config.h b/keyboards/handwired/mutepad/config.h index 97ba13cd6a643470a69c4067d726726b9366d1c4..9ebec0ffef68764766711db35b152ffe158a9a4c 100644 --- a/keyboards/handwired/mutepad/config.h +++ b/keyboards/handwired/mutepad/config.h @@ -19,14 +19,6 @@ #define MATRIX_COL_PINS \ { B1, B3, B2, B6 } -/* encoder support */ -#define ENCODERS_PAD_A \ - { F4 } -#define ENCODERS_PAD_B \ - { F5 } - -#define ENCODER_RESOLUTION 2 - #define TAP_CODE_DELAY 10 /* COL2ROW, ROW2COL */ diff --git a/keyboards/handwired/mutepad/info.json b/keyboards/handwired/mutepad/info.json index 408ecffc51e0a7b0aade07571be6cf56bda88009..6068f33b9dcca1960b78c20485c7bcf5135d7dbb 100644 --- a/keyboards/handwired/mutepad/info.json +++ b/keyboards/handwired/mutepad/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/handwired/obuwunkunubi/spaget/config.h b/keyboards/handwired/obuwunkunubi/spaget/config.h index 7743cd6cd60ddefa52feb1daf37176d688adaeb3..6a7baeba3380b917f94cf2f2c32a39ee4e363bb5 100644 --- a/keyboards/handwired/obuwunkunubi/spaget/config.h +++ b/keyboards/handwired/obuwunkunubi/spaget/config.h @@ -32,10 +32,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -/* Define encoder pins */ -#define ENCODERS_PAD_A { F5, F7 } // 1a, 2a -#define ENCODERS_PAD_B { F4, F6 } // 1b, 2b - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/handwired/obuwunkunubi/spaget/info.json b/keyboards/handwired/obuwunkunubi/spaget/info.json index ed635d02089a084adcd07d92c0831bbf2295e295..8a205c67945bd22758e66d775110b0c4aad3fb54 100644 --- a/keyboards/handwired/obuwunkunubi/spaget/info.json +++ b/keyboards/handwired/obuwunkunubi/spaget/info.json @@ -8,6 +8,12 @@ "pid": "0x6969", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"}, + {"pin_a": "F7", "pin_b": "F6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/handwired/pill60/config.h b/keyboards/handwired/pill60/config.h index d374143192da209b8bb9f9699ea431b449582687..e96fba1db88d1adc1acae325c5c2f4fee60c4f34 100644 --- a/keyboards/handwired/pill60/config.h +++ b/keyboards/handwired/pill60/config.h @@ -1,17 +1,17 @@ - /* Copyright 2020 Imam Rafii - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . + /* Copyright 2020 Imam Rafii + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . */ #pragma once @@ -20,10 +20,3 @@ #define BACKLIGHT_PWM_DRIVER PWMD5 #define BACKLIGHT_PWM_CHANNEL 1 - -/* Encoder */ -#define ENCODERS_PAD_A \ - { B9 } -#define ENCODERS_PAD_B \ - { B8 } -#define ENCODER_RESOLUTION 2 diff --git a/keyboards/handwired/pill60/info.json b/keyboards/handwired/pill60/info.json index 891196f87bb3a076d5f4b052ad5da48f57197247..5ab526ce67d999bee2830e89b6b8e96149b5fc92 100644 --- a/keyboards/handwired/pill60/info.json +++ b/keyboards/handwired/pill60/info.json @@ -8,6 +8,11 @@ "pid": "0x5444", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B9", "pin_b": "B8", "resolution": 2} + ] + }, "backlight": { "driver": "software", "pin": "B14", diff --git a/keyboards/handwired/prkl30/feather/config.h b/keyboards/handwired/prkl30/feather/config.h index 5e94752e1b59616e307d4465789e6805a9f27b5c..a1b7295e324fc1f9e089137a12a3a14514b4b507 100644 --- a/keyboards/handwired/prkl30/feather/config.h +++ b/keyboards/handwired/prkl30/feather/config.h @@ -20,9 +20,6 @@ #define MATRIX_COL_PINS { D3, D1, B7, D6, C7, B6, B5, D7, C6, D0} /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { F7 } -#define ENCODERS_PAD_B { F6 } -#define ENCODER_RESOLUTION 4 /* RGB Light Configuration */ diff --git a/keyboards/handwired/prkl30/feather/info.json b/keyboards/handwired/prkl30/feather/info.json new file mode 100644 index 0000000000000000000000000000000000000000..8078ee048147401a3b4527437f2c595ee019c27c --- /dev/null +++ b/keyboards/handwired/prkl30/feather/info.json @@ -0,0 +1,7 @@ +{ + "encoder": { + "rotary": [ + {"pin_a": "F7", "pin_b": "F6"} + ] + } +} diff --git a/keyboards/handwired/prkl30/promicro/config.h b/keyboards/handwired/prkl30/promicro/config.h index 6edad3bc5cd0e37b94def3781ffc879bc56bbd72..c3767088c7937b24c783fbb042b8dfd916aa366a 100644 --- a/keyboards/handwired/prkl30/promicro/config.h +++ b/keyboards/handwired/prkl30/promicro/config.h @@ -20,9 +20,6 @@ #define MATRIX_COL_PINS { B4, B5, F6, F5, F4, F7, B1, B3, B2, B6} /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } -#define ENCODER_RESOLUTION 4 /* RGB Light Configuration */ diff --git a/keyboards/handwired/prkl30/promicro/info.json b/keyboards/handwired/prkl30/promicro/info.json new file mode 100644 index 0000000000000000000000000000000000000000..a7ca847765bec4c544c50f4ee638c09dc3e20944 --- /dev/null +++ b/keyboards/handwired/prkl30/promicro/info.json @@ -0,0 +1,7 @@ +{ + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"} + ] + } +} \ No newline at end of file diff --git a/keyboards/handwired/snatchpad/config.h b/keyboards/handwired/snatchpad/config.h index 97de836d049b7deeba6cdd53eb01098abc69414c..57d303a983ff38ccbc75d3b3dccc5c6c4d3bd13e 100644 --- a/keyboards/handwired/snatchpad/config.h +++ b/keyboards/handwired/snatchpad/config.h @@ -20,11 +20,6 @@ /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Rotary encoder options */ -#define ENCODER_RESOLUTIONS { 4, 4 } -#define ENCODERS_PAD_A { D3, D0 } -#define ENCODERS_PAD_B { D2, D1 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/handwired/snatchpad/info.json b/keyboards/handwired/snatchpad/info.json index da0221f4741c6d3333eef53e35b14088dbbb3a05..a86091abfdb4670bb87a7ba35512bf083db0d168 100644 --- a/keyboards/handwired/snatchpad/info.json +++ b/keyboards/handwired/snatchpad/info.json @@ -8,6 +8,12 @@ "pid": "0x7370", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"}, + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/handwired/swiftrax/bumblebee/config.h b/keyboards/handwired/swiftrax/bumblebee/config.h index f18b0fab89cf26624efde12e18417179a24466e5..c10291a82af8ab634cdcc1fb22c72edf6a59b2f1 100644 --- a/keyboards/handwired/swiftrax/bumblebee/config.h +++ b/keyboards/handwired/swiftrax/bumblebee/config.h @@ -25,10 +25,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION ROW2COL -/* Encoder */ -#define ENCODERS_PAD_A { C6 } -#define ENCODERS_PAD_B { B6 } - /* RGB Indicators */ #define RGB_DI_PIN E6 #define RGBLED_NUM 3 diff --git a/keyboards/handwired/swiftrax/bumblebee/info.json b/keyboards/handwired/swiftrax/bumblebee/info.json index 887fc697af6860e1f21d74558a960e4d6e1c4212..2147a556c2d7b35c0c8c0b7f8a711cad317b9786 100644 --- a/keyboards/handwired/swiftrax/bumblebee/info.json +++ b/keyboards/handwired/swiftrax/bumblebee/info.json @@ -8,6 +8,11 @@ "pid": "0xE881", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "B6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/handwired/swiftrax/digicarp65/config.h b/keyboards/handwired/swiftrax/digicarp65/config.h index 6618b9fa8396b0ede8876d6060f9524ce0fe9f39..80b735d0d8afa616f5ee90bfaf09e8876c9afd96 100644 --- a/keyboards/handwired/swiftrax/digicarp65/config.h +++ b/keyboards/handwired/swiftrax/digicarp65/config.h @@ -25,6 +25,3 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B7 } diff --git a/keyboards/handwired/swiftrax/digicarp65/info.json b/keyboards/handwired/swiftrax/digicarp65/info.json index aba6fbd54d660af95ac65139f53901368714b898..2eef105756357bcb5cd54084957b65c6a018491a 100644 --- a/keyboards/handwired/swiftrax/digicarp65/info.json +++ b/keyboards/handwired/swiftrax/digicarp65/info.json @@ -8,6 +8,11 @@ "pid": "0xE7F1", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "community_layouts": ["65_ansi", "65_ansi_split_bs", "65_iso", "65_iso_split_bs"], diff --git a/keyboards/handwired/swiftrax/joypad/config.h b/keyboards/handwired/swiftrax/joypad/config.h index 45d0d0bb700c80316dee3bd1ca7849b8f9e20b06..2f54bc0c4e51344aef90506d0cf673427d05df66 100644 --- a/keyboards/handwired/swiftrax/joypad/config.h +++ b/keyboards/handwired/swiftrax/joypad/config.h @@ -23,9 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { C6, B3, B0, B1, D6, D5 } #define MATRIX_COL_PINS { C7, B4, D0, C2 } -#define ENCODERS_PAD_A { C5 } -#define ENCODERS_PAD_B { C4 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/handwired/swiftrax/joypad/info.json b/keyboards/handwired/swiftrax/joypad/info.json index 9b3f094e85ca12d6eb8b3dcb62b1f4a4fe790b10..bef5225bcd0492f53ba659c4d3b189ac8f6f77c0 100644 --- a/keyboards/handwired/swiftrax/joypad/info.json +++ b/keyboards/handwired/swiftrax/joypad/info.json @@ -8,6 +8,11 @@ "pid": "0xEA68", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C5", "pin_b": "C4"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/handwired/swiftrax/pandamic/config.h b/keyboards/handwired/swiftrax/pandamic/config.h index b802e4782a8fa7c67188abae7628295659d916d8..77daa76c24ab1df3ee847be0477be1eadeebe9ce 100644 --- a/keyboards/handwired/swiftrax/pandamic/config.h +++ b/keyboards/handwired/swiftrax/pandamic/config.h @@ -23,10 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D1, D2, B5, B7, D3, D5, D6, D4, D7, B4 } #define MATRIX_COL_PINS { B6, C6, C7, F7, F6, F5, F4, F1, F0, D0 } -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { B0 } - - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/handwired/swiftrax/pandamic/info.json b/keyboards/handwired/swiftrax/pandamic/info.json index b5d0ebd1ba5dad5ee90e31d8dbc37f482c7ad018..60fe2886f5fe3e8a3e4f33aa9be4e103e85eb331 100644 --- a/keyboards/handwired/swiftrax/pandamic/info.json +++ b/keyboards/handwired/swiftrax/pandamic/info.json @@ -8,6 +8,11 @@ "pid": "0xEB0E", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/handwired/swiftrax/walter/config.h b/keyboards/handwired/swiftrax/walter/config.h index d58a3cbfb426a5627110428cc6ea74728047b4eb..7bfee265ab68cba681df5b83fc51b3633a28e25c 100644 --- a/keyboards/handwired/swiftrax/walter/config.h +++ b/keyboards/handwired/swiftrax/walter/config.h @@ -26,9 +26,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B7 } - #define RGB_DI_PIN E6 #define RGBLED_NUM 24 #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/handwired/swiftrax/walter/info.json b/keyboards/handwired/swiftrax/walter/info.json index 675da09c9ca7b83f72c341ca0e4e53caaf21834c..88da47f36b8e1a3bc18aaa51f5d4047cdc1ca777 100644 --- a/keyboards/handwired/swiftrax/walter/info.json +++ b/keyboards/handwired/swiftrax/walter/info.json @@ -8,6 +8,11 @@ "pid": "0xE964", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/config.h b/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/config.h index e4856c4eecb0c01b82c35575472a6d08dd7ff5f9..c52610e9d3d1333b517bcaf2b31019a45f9b4d47 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/config.h +++ b/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/config.h @@ -38,10 +38,5 @@ along with this program. If not, see . #define EE_HANDS -#define ENCODERS_PAD_A \ - { D5 } -#define ENCODERS_PAD_B \ - { C7 } - /* PMW33XX Settings */ #define PMW33XX_CS_PIN B6 diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/info.json b/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/info.json index 4fcfeed92188479d333661f4ec69de8ade8b1f57..dabab602ddb94453c1ae7bdb2903e27469a69df1 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/info.json +++ b/keyboards/handwired/tractyl_manuform/5x6_right/elite_c/info.json @@ -1,5 +1,10 @@ { "keyboard_name": "Tractyl Manuform (5x6) Elite-C", + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "C7"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/f303/config.h b/keyboards/handwired/tractyl_manuform/5x6_right/f303/config.h index f3f3fb7e22fc7a1f0d8afedf89a96c06d8b1d34b..d10cb0bd8bbe430bc4d16f7da729081f3f6b43db 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/f303/config.h +++ b/keyboards/handwired/tractyl_manuform/5x6_right/f303/config.h @@ -70,12 +70,6 @@ along with this program. If not, see . #define I2C1_SDA_PAL_MODE 4 #define I2C1_CLOCK_SPEED 400000 -/* encoder config */ -#define ENCODERS_PAD_A \ - { A7 } -#define ENCODERS_PAD_B \ - { A8 } - /* spi config for eeprom and pmw3360 sensor */ #define SPI_DRIVER SPID2 #define SPI_SCK_PIN B13 diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/f303/info.json b/keyboards/handwired/tractyl_manuform/5x6_right/f303/info.json index 3ad29d36b8f12a578b55fc40f044c74316ec45ac..bed70941bfa0decf02453790933b1ea6c0971e06 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/f303/info.json +++ b/keyboards/handwired/tractyl_manuform/5x6_right/f303/info.json @@ -1,5 +1,10 @@ { "keyboard_name": "Tractyl Manuform (5x6) Proton-C", + "encoder": { + "rotary": [ + {"pin_a": "A7", "pin_b": "A8"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu" } diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/f411/config.h b/keyboards/handwired/tractyl_manuform/5x6_right/f411/config.h index e93e70f569bca036ffaef00ecbb67426b168853c..227863aaa5be089e43a46c3174508cae86b624f0 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/f411/config.h +++ b/keyboards/handwired/tractyl_manuform/5x6_right/f411/config.h @@ -76,12 +76,6 @@ along with this program. If not, see . #define I2C1_CLOCK_SPEED 400000 #define I2C1_DUTY_CYCLE FAST_DUTY_CYCLE_16_9 -/* encoder config */ -#define ENCODERS_PAD_A \ - { A13 } -#define ENCODERS_PAD_B \ - { A14 } - /* spi config for eeprom and pmw3360 sensor */ #define SPI_DRIVER SPID1 #define SPI_SCK_PIN A5 diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/f411/info.json b/keyboards/handwired/tractyl_manuform/5x6_right/f411/info.json index 9b81dc18ebb45f46e58ac9cc932ccbce7f1fa71a..0791e50ebf89cbce974a71b565d765e7c3344963 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/f411/info.json +++ b/keyboards/handwired/tractyl_manuform/5x6_right/f411/info.json @@ -1,5 +1,10 @@ { "keyboard_name": "Tractyl Manuform (5x6) BlackPill", + "encoder": { + "rotary": [ + {"pin_a": "A13", "pin_b": "A14"} + ] + }, "processor": "STM32F411", "bootloader": "stm32-dfu", "board": "BLACKPILL_STM32_F411" diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/config.h b/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/config.h index cae5b7fc14d7585b3980409bfd4dcde7463debb5..51ff0d31239f45fc592d3a78c73c5b383290f82b 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/config.h +++ b/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/config.h @@ -42,10 +42,5 @@ along with this program. If not, see . #define EE_HANDS -#define ENCODERS_PAD_A \ - { D5 } -#define ENCODERS_PAD_B \ - { D4 } - /* PMW33XX Settings */ #define PMW33XX_CS_PIN B0 diff --git a/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/info.json b/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/info.json index a7fb36c71e6033d633db22970370f39315af8b93..7f60ae0edc52b510f1992f9847daed04af3003c3 100644 --- a/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/info.json +++ b/keyboards/handwired/tractyl_manuform/5x6_right/teensy2pp/info.json @@ -1,5 +1,10 @@ { "keyboard_name": "Tractyl Manuform (5x6) Teensy 2.0++", + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "D4"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/handwired/uthol/rev3/config.h b/keyboards/handwired/uthol/rev3/config.h index dff88fb7c6d4316cd4940ecd7e6299b672bc3dfd..1e6b532e2af453e0a549a985b717b09f40d4e05e 100644 --- a/keyboards/handwired/uthol/rev3/config.h +++ b/keyboards/handwired/uthol/rev3/config.h @@ -25,14 +25,6 @@ #define MATRIX_ROW_PINS \ { A4, A3, A2, A1, A0 } - -// Encoder config -#define ENCODERS_PAD_A \ - { C15 } -#define ENCODERS_PAD_B \ - { C14 } -#define ENCODER_RESOLUTION 2 - // OLED config #define OLED_DISPLAY_128X64 #define OLED_DISPLAY_WIDTH 128 diff --git a/keyboards/handwired/uthol/rev3/info.json b/keyboards/handwired/uthol/rev3/info.json index d95bbc9bca29e6cb571c99055475cda65dab6586..b5d099b27a09094d6d5342b04ae764ec30e8e7ec 100644 --- a/keyboards/handwired/uthol/rev3/info.json +++ b/keyboards/handwired/uthol/rev3/info.json @@ -3,6 +3,11 @@ "usb": { "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14", "resolution": 2} + ] + }, "processor": "STM32F401", "bootloader": "stm32-dfu", "board": "BLACKPILL_STM32_F401" diff --git a/keyboards/helix/rev3_4rows/config.h b/keyboards/helix/rev3_4rows/config.h index 083b95c8adede92ea5e771621f44d2c57f902416..97b4ed3f486f572af7a283ae38fc13d9997a3fe0 100644 --- a/keyboards/helix/rev3_4rows/config.h +++ b/keyboards/helix/rev3_4rows/config.h @@ -86,10 +86,6 @@ along with this program. If not, see . /* Custom font */ #define OLED_FONT_H "keyboards/helix/common/glcdfont.c" -/* Encorder */ -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B5 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/helix/rev3_4rows/info.json b/keyboards/helix/rev3_4rows/info.json index d37df4d4c50119316a3c4e5a38c9b45297131dc0..45945f88719e694d70c92fc0c28d0775cf8fb4dd 100644 --- a/keyboards/helix/rev3_4rows/info.json +++ b/keyboards/helix/rev3_4rows/info.json @@ -8,6 +8,11 @@ "pid": "0x0004", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/helix/rev3_5rows/config.h b/keyboards/helix/rev3_5rows/config.h index 2f6ea61bb6aca81c4c4e8d01ed4bac008241c776..a047bd7d878c5912fd449a6923c7a4be78b2bb14 100644 --- a/keyboards/helix/rev3_5rows/config.h +++ b/keyboards/helix/rev3_5rows/config.h @@ -86,10 +86,6 @@ along with this program. If not, see . /* Custom font */ #define OLED_FONT_H "keyboards/helix/common/glcdfont.c" -/* Encorder */ -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B5 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/helix/rev3_5rows/info.json b/keyboards/helix/rev3_5rows/info.json index 6d7786d213c0adc9399e1bacfa083d56923d6ee6..9709708d68e5580d4f5969a2a1ee19b93998e0d6 100644 --- a/keyboards/helix/rev3_5rows/info.json +++ b/keyboards/helix/rev3_5rows/info.json @@ -8,6 +8,11 @@ "pid": "0x0003", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/hillside/46/0_1/config.h b/keyboards/hillside/46/0_1/config.h index e1464871bad02abece2a80eaf54aaae12e234522..81736ff17598c3f931993f9997602121207403f3 100644 --- a/keyboards/hillside/46/0_1/config.h +++ b/keyboards/hillside/46/0_1/config.h @@ -8,12 +8,6 @@ #define SPLIT_HAND_MATRIX_GRID B5, F6 #define MATRIX_MASKED -/* Encoder */ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } - #define RGBLIGHT_SLEEP /* Haptic hardware */ diff --git a/keyboards/hillside/46/0_1/info.json b/keyboards/hillside/46/0_1/info.json index 29a23aad809ff0231b2b18bb5aaf2a0743684303..f18bd158cca756a70d8750e4719d430ef13071c6 100644 --- a/keyboards/hillside/46/0_1/info.json +++ b/keyboards/hillside/46/0_1/info.json @@ -13,6 +13,11 @@ "pid": "0x4846", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "features": { "encoder": true, @@ -20,7 +25,14 @@ "rgblight": true }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + } + } }, "rgblight": { diff --git a/keyboards/hillside/48/0_1/config.h b/keyboards/hillside/48/0_1/config.h index 5e2ba6018ae984ffb14898fff6ac2343a1b13ee1..72f1a842c775b26670aedf27c0a70c909785748f 100644 --- a/keyboards/hillside/48/0_1/config.h +++ b/keyboards/hillside/48/0_1/config.h @@ -3,13 +3,6 @@ #pragma once - -/* Encoder */ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } - #define RGBLIGHT_SLEEP /* Haptic hardware */ diff --git a/keyboards/hillside/48/0_1/info.json b/keyboards/hillside/48/0_1/info.json index 943982d65e70082de6a1cc9ecc5cb8b8b416b9dd..aa03a7a4f926308d41e17ed46adbe7da011925af 100644 --- a/keyboards/hillside/48/0_1/info.json +++ b/keyboards/hillside/48/0_1/info.json @@ -13,6 +13,11 @@ "pid": "0x67C0", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "features": { "encoder": true, @@ -21,7 +26,14 @@ }, "split": { "soft_serial_pin": "D2", - "main": "left" + "main": "left", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + } + } }, "rgblight": { diff --git a/keyboards/hillside/52/0_1/config.h b/keyboards/hillside/52/0_1/config.h index e1464871bad02abece2a80eaf54aaae12e234522..81736ff17598c3f931993f9997602121207403f3 100644 --- a/keyboards/hillside/52/0_1/config.h +++ b/keyboards/hillside/52/0_1/config.h @@ -8,12 +8,6 @@ #define SPLIT_HAND_MATRIX_GRID B5, F6 #define MATRIX_MASKED -/* Encoder */ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } - #define RGBLIGHT_SLEEP /* Haptic hardware */ diff --git a/keyboards/hillside/52/0_1/info.json b/keyboards/hillside/52/0_1/info.json index f5cf4486d5ae97bb2da604e652d335eef0f686b3..e803ed52beb5fcaffe36bd6c23a50ba12defb1af 100644 --- a/keyboards/hillside/52/0_1/info.json +++ b/keyboards/hillside/52/0_1/info.json @@ -13,6 +13,11 @@ "pid": "0x4852", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "features": { "encoder": true, @@ -20,7 +25,14 @@ "rgblight": true }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + } + } }, "rgblight": { diff --git a/keyboards/hnahkb/vn66/config.h b/keyboards/hnahkb/vn66/config.h index 6388d793208f94d9b10f57d48ed2affd4d67d5c9..8436f5df2515f15ea2b4c6353d707b2e13454597 100644 --- a/keyboards/hnahkb/vn66/config.h +++ b/keyboards/hnahkb/vn66/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B0 } -#define ENCODERS_PAD_B { B7 } -#define ENCODER_RESOLUTION 2 - #define RGB_DI_PIN E2 #ifdef RGB_DI_PIN # define RGBLED_NUM 20 diff --git a/keyboards/hnahkb/vn66/info.json b/keyboards/hnahkb/vn66/info.json index 6a3f12e65ec27f9426e7eb2df9dadf6e71959094..b35cabd1a10e4fb8829930e567282ac3695fb83f 100644 --- a/keyboards/hnahkb/vn66/info.json +++ b/keyboards/hnahkb/vn66/info.json @@ -8,6 +8,11 @@ "pid": "0xCA2C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B7", "resolution": 2} + ] + }, "backlight": { "pin": "B6", "levels": 4, diff --git a/keyboards/hub16/config.h b/keyboards/hub16/config.h index 83f0ac5b239936db0ec2aa75505bddab6c9feabd..8eb865e9b33744ee360edefd1583e3084d723b62 100755 --- a/keyboards/hub16/config.h +++ b/keyboards/hub16/config.h @@ -44,13 +44,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -/* ENCODER THINGS */ -// #define ENCODER_DIRECTION_FLIP -#define ENCODERS_PAD_A \ - { F5, B5 } -#define ENCODERS_PAD_B \ - { F6, B4 } - /* Tap Dance timing */ #define TAPPING_TERM 200 diff --git a/keyboards/hub16/info.json b/keyboards/hub16/info.json index ec1f3fc2cd5d271bacb3f223ae942e2c33bc78ae..0da7c129eb6a8443e96b43c9ba37c05d626b6b74 100644 --- a/keyboards/hub16/info.json +++ b/keyboards/hub16/info.json @@ -8,6 +8,12 @@ "pid": "0x4810", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"}, + {"pin_a": "B5", "pin_b": "B4"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "debounce": 20, diff --git a/keyboards/hub20/config.h b/keyboards/hub20/config.h index ad95e4f38c22979106732bd0f08648b0ca5add7e..41a98ac9834cb0a1d3cc45c45ee599f5702d4ad9 100644 --- a/keyboards/hub20/config.h +++ b/keyboards/hub20/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* Rotary Encoder Things */ -// #define ENCODER_DIRECTION_FLIP -#define ENCODERS_PAD_A { B12, A8 } -#define ENCODERS_PAD_B { B13, A9 } - #define RGB_DI_PIN B15 #define RGBLED_NUM 27 diff --git a/keyboards/hub20/info.json b/keyboards/hub20/info.json index a8f678cb243a52597ae3a06a173590bf914aa421..10ec779fdf462a816d700ed4b75f65d086248719 100644 --- a/keyboards/hub20/info.json +++ b/keyboards/hub20/info.json @@ -8,6 +8,12 @@ "pid": "0x4414", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13"}, + {"pin_a": "A8", "pin_b": "A9"} + ] + }, "processor": "STM32F072", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/io_mini1800/config.h b/keyboards/io_mini1800/config.h index 32f4e0e49bede3fb8efdec41a2634a424f69568f..95251ca8f87e181385927cff1c9940dba16e229a 100644 --- a/keyboards/io_mini1800/config.h +++ b/keyboards/io_mini1800/config.h @@ -19,6 +19,3 @@ /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { B0 } -#define ENCODERS_PAD_B { B1 } diff --git a/keyboards/io_mini1800/info.json b/keyboards/io_mini1800/info.json index bdc04f17166ebab1117010b6f41e13aae9008649..05b346d793f67f2557f21683a1c2a1d53d791a59 100644 --- a/keyboards/io_mini1800/info.json +++ b/keyboards/io_mini1800/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/jagdpietr/drakon/config.h b/keyboards/jagdpietr/drakon/config.h index dc4f83bc321465e4acf711606744abf2b237819e..163236c90c2102c3780abe37758a7be7820f0867 100644 --- a/keyboards/jagdpietr/drakon/config.h +++ b/keyboards/jagdpietr/drakon/config.h @@ -34,9 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { F0 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/jagdpietr/drakon/info.json b/keyboards/jagdpietr/drakon/info.json index d29849d0c6417a2abf5a5f89db68b44c68fc7fc5..3aab78919901dd809ea20a88cb864b560e23eb7b 100644 --- a/keyboards/jagdpietr/drakon/info.json +++ b/keyboards/jagdpietr/drakon/info.json @@ -8,6 +8,11 @@ "pid": "0x7776", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "F0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/jkeys_design/gentleman65/config.h b/keyboards/jkeys_design/gentleman65/config.h index 91259c5f2cf3ef077863d87999f2cb621db8af88..f8280340e8259d0eaffac79890bb8006f3784e3f 100644 --- a/keyboards/jkeys_design/gentleman65/config.h +++ b/keyboards/jkeys_design/gentleman65/config.h @@ -39,8 +39,4 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F5 } -#define ENCODER_RESOLUTION 4 - #define RGB_MATRIX_LED_COUNT 14 diff --git a/keyboards/jkeys_design/gentleman65/info.json b/keyboards/jkeys_design/gentleman65/info.json index 51a34f460e429e3697bb4f0d389f135603fbd002..fff5b9b75299fea94c9781a42cfb0701b38e487d 100644 --- a/keyboards/jkeys_design/gentleman65/info.json +++ b/keyboards/jkeys_design/gentleman65/info.json @@ -8,6 +8,11 @@ "pid": "0x2020", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/jkeys_design/gentleman65_se_s/config.h b/keyboards/jkeys_design/gentleman65_se_s/config.h index 662d0b78c29198f5d7f821bc373dca8ee5c7e4bd..c80b64ef10de8aa50508fc20b1bcf9ad579b87ea 100644 --- a/keyboards/jkeys_design/gentleman65_se_s/config.h +++ b/keyboards/jkeys_design/gentleman65_se_s/config.h @@ -39,8 +39,4 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -#define ENCODERS_PAD_A { B0 } -#define ENCODERS_PAD_B { B1 } -#define ENCODER_RESOLUTION 4 - #define RGB_MATRIX_LED_COUNT 14 diff --git a/keyboards/jkeys_design/gentleman65_se_s/info.json b/keyboards/jkeys_design/gentleman65_se_s/info.json index b4acdb13929c5d57b2cdddde9d94221a136bdad6..2415eb5c1804721a540bc866c483609c6f168991 100644 --- a/keyboards/jkeys_design/gentleman65_se_s/info.json +++ b/keyboards/jkeys_design/gentleman65_se_s/info.json @@ -8,6 +8,11 @@ "pid": "0x2322", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/jones/v03/config.h b/keyboards/jones/v03/config.h index f04b9cc78e36cd0d28c87144818588afa9de260c..fc1ae1ff7743b3644b3c46f9cd1c3eef25edb65c 100644 --- a/keyboards/jones/v03/config.h +++ b/keyboards/jones/v03/config.h @@ -41,11 +41,6 @@ along with this program. If not, see . // No need to define DIODE_DIRECTION for Jones' custom Round-Robin matrix. //#define DIODE_DIRECTION COL2ROW -/* Rotary Encoder */ -#define ENCODERS_PAD_A { F6, B3 } -#define ENCODERS_PAD_B { F7, B2 } -#define ENCODER_RESOLUTION 4 //the default & suggested is 4 - /* Audio */ #ifdef AUDIO_ENABLE #define AUDIO_PIN C6 diff --git a/keyboards/jones/v03/info.json b/keyboards/jones/v03/info.json index 996509d504760c4795ed72992d89035dc12c60ee..388c0fb9efd5ffe4184bace8e8b852b8f42a537b 100644 --- a/keyboards/jones/v03/info.json +++ b/keyboards/jones/v03/info.json @@ -8,6 +8,12 @@ "pid": "0x175A", "device_version": "0.3.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F7"}, + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/jones/v03_1/config.h b/keyboards/jones/v03_1/config.h index b0d12c81558a4c0bf2ce648789a8ca86ee090114..548b98e67574aebfd80fe58bd70345752cee4986 100644 --- a/keyboards/jones/v03_1/config.h +++ b/keyboards/jones/v03_1/config.h @@ -41,11 +41,6 @@ along with this program. If not, see . // No need to define DIODE_DIRECTION for Jones' custom Round-Robin matrix. //#define DIODE_DIRECTION COL2ROW -/* Rotary Encoder */ -#define ENCODERS_PAD_A { F6, B3 } -#define ENCODERS_PAD_B { F7, B2 } -#define ENCODER_RESOLUTION 4 //the default & suggested is 4 - /* Audio */ #ifdef AUDIO_ENABLE #define AUDIO_PIN C6 diff --git a/keyboards/jones/v03_1/info.json b/keyboards/jones/v03_1/info.json index 0bde4d3b5b2ad9d5f30dba4a00465178ed8d75f4..45e7b8022f2d7f7910686c1df3986b5f132be1c7 100644 --- a/keyboards/jones/v03_1/info.json +++ b/keyboards/jones/v03_1/info.json @@ -8,6 +8,12 @@ "pid": "0x175A", "device_version": "0.3.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F7"}, + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/jones/v1/config.h b/keyboards/jones/v1/config.h index aa0ceee74b1ce674228b7415258ffc35f29dcc2c..1936d5d2567eedffd4910723160eef74d9587e1f 100644 --- a/keyboards/jones/v1/config.h +++ b/keyboards/jones/v1/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW -/* Rotary Encoder */ -#define ENCODERS_PAD_A { F5, D2 } -#define ENCODERS_PAD_B { F4, D3 } -#define ENCODER_RESOLUTION 4 //the default & suggested is 4 - /* Audio */ #ifdef AUDIO_ENABLE #define AUDIO_PIN C6 diff --git a/keyboards/jones/v1/info.json b/keyboards/jones/v1/info.json index 8e03e57950e44ce427da731e410a4fb72b8cc48b..37f0b70087f02c475a90367800c1b8f159582b99 100644 --- a/keyboards/jones/v1/info.json +++ b/keyboards/jones/v1/info.json @@ -8,6 +8,12 @@ "pid": "0x175A", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"}, + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "bootmagic": { "matrix": [0, 9] }, diff --git a/keyboards/jones/v1/keymaps/via/config.h b/keyboards/jones/v1/keymaps/via/config.h index 5d24e1f91a3881c068d6d2b486fd180f16d2b0a9..a66ab809048c502e29d08e13f45e9b5f9f7a8653 100644 --- a/keyboards/jones/v1/keymaps/via/config.h +++ b/keyboards/jones/v1/keymaps/via/config.h @@ -24,9 +24,6 @@ along with this program. If not, see . // when turn knob clockwise or counterclockwise. // This is handy to assign key codes by VIA. -// Number of endoder -#define ENCODERS 2 - // Mappings of encoder rotation to key position in key matrix. // First encoder, Left side : k85, k86 // Second encoder, Right side : k95, k96 diff --git a/keyboards/jones/v1/keymaps/via/keymap.c b/keyboards/jones/v1/keymaps/via/keymap.c index 651f7d12ee0751716b78617183ad68aa6ea27a26..31a182733a3084026c3c0296a57a6297f8834e6e 100644 --- a/keyboards/jones/v1/keymaps/via/keymap.c +++ b/keyboards/jones/v1/keymaps/via/keymap.c @@ -168,12 +168,12 @@ bool led_update_user(led_t led_state) { //------------------------------------------------------------------------------ // Rotary Encoder //------------------------------------------------------------------------------ -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], diff --git a/keyboards/kabedon/kabedon98e/config.h b/keyboards/kabedon/kabedon98e/config.h index 7edabd4292d2d237c2c0202853b7b241e22af004..b2156c4ada9505226e2c3edb85489fff0eca74f3 100644 --- a/keyboards/kabedon/kabedon98e/config.h +++ b/keyboards/kabedon/kabedon98e/config.h @@ -45,10 +45,6 @@ /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS 2 -#define ENCODERS_PAD_A { B3,A14 } -#define ENCODERS_PAD_B { B5,A15 } - #define ENCODERS_CW_KEY { { 0, 0 },{ 2, 0 } } #define ENCODERS_CCW_KEY { { 6, 0 },{ 8, 0 } } diff --git a/keyboards/kabedon/kabedon98e/info.json b/keyboards/kabedon/kabedon98e/info.json index 1ec2ed9ac5fe63ab7a0bdd03132ec01510321965..def8f7261252e447a83e314315593e5273f2aad7 100644 --- a/keyboards/kabedon/kabedon98e/info.json +++ b/keyboards/kabedon/kabedon98e/info.json @@ -8,6 +8,12 @@ "pid": "0x3935", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B5"}, + {"pin_a": "A14", "pin_b": "A15"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/kabedon/kabedon98e/kabedon98e.c b/keyboards/kabedon/kabedon98e/kabedon98e.c index 09af36de42e045fa0abc0e9eb5d3bbd4959b9524..7ca156eab9160ac422a39142adf6047774ac408a 100644 --- a/keyboards/kabedon/kabedon98e/kabedon98e.c +++ b/keyboards/kabedon/kabedon98e/kabedon98e.c @@ -15,12 +15,12 @@ */ #include "kabedon98e.h" -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], diff --git a/keyboards/kapcave/arya/config.h b/keyboards/kapcave/arya/config.h index 5f60e8fec5ed4d991491286f83b52bb7524f30ad..dd197f23385337bcba0e85a712dda87f7e9b889a 100644 --- a/keyboards/kapcave/arya/config.h +++ b/keyboards/kapcave/arya/config.h @@ -26,10 +26,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { B12, B14, C15 } -#define ENCODERS_PAD_B { B13, B15, C14 } - -#define ENCODER_RESOLUTION 2 #define TAP_CODE_DELAY 25 #define DYNAMIC_KEYMAP_LAYER_COUNT 3 diff --git a/keyboards/kapcave/arya/info.json b/keyboards/kapcave/arya/info.json index 9ded56205af6264453492aed410453cb9ff0e800..54a1513f90d29a7b2ffeff4f54cff149ccb7e33a 100644 --- a/keyboards/kapcave/arya/info.json +++ b/keyboards/kapcave/arya/info.json @@ -8,6 +8,13 @@ "pid": "0x4152", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13", "resolution": 2}, + {"pin_a": "B14", "pin_b": "B15", "resolution": 2}, + {"pin_a": "C15", "pin_b": "C14", "resolution": 2} + ] + }, "processor": "STM32F072", "bootloader": "stm32-dfu", "community_layouts": ["alice_split_bs"], diff --git a/keyboards/keebio/bamfk1/config.h b/keyboards/keebio/bamfk1/config.h index de8b594cec1682cf9b73145fb8e45ac5eff34f97..590cce19c5c85c87ac2960497540d220334c9955 100644 --- a/keyboards/keebio/bamfk1/config.h +++ b/keyboards/keebio/bamfk1/config.h @@ -8,9 +8,6 @@ # define STARTUP_SONG SONG(STARTUP_SOUND) #endif -#define ENCODERS_PAD_A { C7, D7 } -#define ENCODERS_PAD_B { B5, D4 } -#define ENCODERS 2 #define ENCODERS_CW_KEY { { 1, 1 }, { 3, 1 } } #define ENCODERS_CCW_KEY { { 0, 1 }, { 2, 1 } } diff --git a/keyboards/keebio/bamfk1/info.json b/keyboards/keebio/bamfk1/info.json index c39cbd3ce0a611710b88f88095d5c0f395915287..c647eec5144a14be6b3f70866ce1d63015501ca6 100644 --- a/keyboards/keebio/bamfk1/info.json +++ b/keyboards/keebio/bamfk1/info.json @@ -8,6 +8,12 @@ "pid": "0x1111", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "B5"}, + {"pin_a": "D7", "pin_b": "D4"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/keebio/bdn9/rev1/config.h b/keyboards/keebio/bdn9/rev1/config.h index c9e0a63896c6229dca9b60d9792899bc7c248711..fbd33490d622728bafd630cef825b4a018b094b2 100644 --- a/keyboards/keebio/bdn9/rev1/config.h +++ b/keyboards/keebio/bdn9/rev1/config.h @@ -17,9 +17,6 @@ along with this program. If not, see . #pragma once -#define ENCODERS_PAD_A { D0, F6, B6 } -#define ENCODERS_PAD_B { D1, F5, F7 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN #define RGBLED_NUM 4 diff --git a/keyboards/keebio/bdn9/rev1/info.json b/keyboards/keebio/bdn9/rev1/info.json index ec52e8ef6b5da573a0fd01ca8b7d46a3a631de88..8e7b01b794996d0b683496ee8eaf418b4ab7db2c 100644 --- a/keyboards/keebio/bdn9/rev1/info.json +++ b/keyboards/keebio/bdn9/rev1/info.json @@ -4,6 +4,13 @@ "pid": "0x1133", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "F6", "pin_b": "F5"}, + {"pin_a": "B6", "pin_b": "F7"} + ] + }, "backlight": { "pin": "B5", "levels": 7 diff --git a/keyboards/keebio/bdn9/rev2/config.h b/keyboards/keebio/bdn9/rev2/config.h index f30de7e1978bda0ee24853b46fad3b524420ddcf..ee2065f176ecb24dcf11bbdd8bce80b3e696391b 100644 --- a/keyboards/keebio/bdn9/rev2/config.h +++ b/keyboards/keebio/bdn9/rev2/config.h @@ -17,9 +17,6 @@ along with this program. If not, see . #pragma once -// Left, Right, Middle -#define ENCODERS_PAD_A { A8, B3, A10 } -#define ENCODERS_PAD_B { A4, A15, A9 } #define TAP_CODE_DELAY 10 #define RGB_DI_PIN B15 diff --git a/keyboards/keebio/bdn9/rev2/info.json b/keyboards/keebio/bdn9/rev2/info.json index 24eebef1a8f48167539a47a95cbfbe4cba4e98d3..c23acbc27fabb573f1b602a67770bb2ce9d3e0cb 100644 --- a/keyboards/keebio/bdn9/rev2/info.json +++ b/keyboards/keebio/bdn9/rev2/info.json @@ -4,6 +4,13 @@ "pid": "0x2133", "device_version": "2.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A8", "pin_b": "A4"}, + {"pin_a": "B3", "pin_b": "A15"}, + {"pin_a": "A10", "pin_b": "A9"} + ] + }, "processor": "STM32F072", "bootloader": "stm32-dfu", "matrix_pins": { diff --git a/keyboards/keebio/dsp40/rev1/config.h b/keyboards/keebio/dsp40/rev1/config.h index 9aa38cbe070ac37a94b84566268dfae319e38c02..0f69303ca809ecf74337fe263c405f3972494137 100644 --- a/keyboards/keebio/dsp40/rev1/config.h +++ b/keyboards/keebio/dsp40/rev1/config.h @@ -20,8 +20,7 @@ along with this program. If not, see . /* Keyboard Matrix Assignments */ #define MATRIX_ROW_PINS { B9, A9, A8, B15 } #define MATRIX_COL_PINS { B10, B2, A3, A4, B7, B6, A10, C13, C14, C15, F0, F1 } -#define ENCODERS_PAD_A { A1 } -#define ENCODERS_PAD_B { A2 } + #define TAP_CODE_DELAY 10 #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/dsp40/rev1/info.json b/keyboards/keebio/dsp40/rev1/info.json index 5421218a6b6134063fff7871cb6a3042d6313bef..c5ce2f5a175acbc05e71d5a5fa057985937b0943 100644 --- a/keyboards/keebio/dsp40/rev1/info.json +++ b/keyboards/keebio/dsp40/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0x144C", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A1", "pin_b": "A2"} + ] + }, "backlight": { "pin": "A6", "levels": 7 diff --git a/keyboards/keebio/encoder_actions.c b/keyboards/keebio/encoder_actions.c index c4e49813f44bacd4f2fad8f3f798021be9c265da..ead941469ab7633d30ef40c0d33a36ef0aa00035 100644 --- a/keyboards/keebio/encoder_actions.c +++ b/keyboards/keebio/encoder_actions.c @@ -18,16 +18,12 @@ #include "encoder_actions.h" #if defined(ENCODER_ENABLE) - -# ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -# endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -# ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -38,11 +34,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -# endif } void encoder_action_register(uint8_t index, bool clockwise) { -# ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -50,7 +44,6 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -# endif } void matrix_scan_kb(void) { diff --git a/keyboards/keebio/foldkb/rev1/config.h b/keyboards/keebio/foldkb/rev1/config.h index 002bf3b9a8a8444f1972a5d79a5a55a96021e8a9..3b10809fb647ea09ee7db8b076ad5cd646fb8d9c 100644 --- a/keyboards/keebio/foldkb/rev1/config.h +++ b/keyboards/keebio/foldkb/rev1/config.h @@ -21,8 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B1, B2, C7, B4, D7 } #define MATRIX_COL_PINS { F4, F1, F0, B7, B3, D2, D3, D5 } #define SPLIT_HAND_PIN F7 -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/keebio/foldkb/rev1/info.json b/keyboards/keebio/foldkb/rev1/info.json index 46617db128ced197e76cb1efd9bfcb306e4a26d3..00dffdc401d86bca286b77bc49d1a8e04eb9c70d 100644 --- a/keyboards/keebio/foldkb/rev1/info.json +++ b/keyboards/keebio/foldkb/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0x1258", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "backlight": { "pin": "B5" }, diff --git a/keyboards/keebio/iris/rev3/config.h b/keyboards/keebio/iris/rev3/config.h index 1834b0573dc304091fedcf468ef5cc99ae58c846..932daf439684b3deadd4d9679b19e851036ed0c2 100644 --- a/keyboards/keebio/iris/rev3/config.h +++ b/keyboards/keebio/iris/rev3/config.h @@ -22,9 +22,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS { F1, F4, F5, F6, D4, B4 } #define SPLIT_HAND_PIN F0 -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B7 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/iris/rev3/info.json b/keyboards/keebio/iris/rev3/info.json index a90be8a1b6bad01a0aaa3fc00e867196724deb6a..0fc9aa4832eca5e5dfcbb9ea79c7ff288d0b787a 100644 --- a/keyboards/keebio/iris/rev3/info.json +++ b/keyboards/keebio/iris/rev3/info.json @@ -4,6 +4,11 @@ "pid": "0x3256", "device_version": "3.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B7"} + ] + }, "backlight": { "pin": "B6", "levels": 5 diff --git a/keyboards/keebio/iris/rev4/config.h b/keyboards/keebio/iris/rev4/config.h index afac7c80ee7ce1b3ac142b22c68b99033cfa93b8..d1e542d7748d3541f0f193e6f97b4ad891a2a8a7 100644 --- a/keyboards/keebio/iris/rev4/config.h +++ b/keyboards/keebio/iris/rev4/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS_RIGHT { D4, D7, D3, B7, F0, B3 } #define SPLIT_HAND_PIN D5 -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } -#define ENCODERS_PAD_A_RIGHT { F7 } -#define ENCODERS_PAD_B_RIGHT { F6 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/iris/rev4/info.json b/keyboards/keebio/iris/rev4/info.json index 6915619b0f01bd615a3c6d7af3b04a70ee735600..a0689c0ed410552d17f1f5b0f14a16087f004b04 100644 --- a/keyboards/keebio/iris/rev4/info.json +++ b/keyboards/keebio/iris/rev4/info.json @@ -4,6 +4,11 @@ "pid": "0x4256", "device_version": "4.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "backlight": { "pin": "B5", "levels": 5 @@ -15,7 +20,14 @@ "speaker": "C6" }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F7", "pin_b": "F6"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "qmk-dfu" diff --git a/keyboards/keebio/iris/rev5/config.h b/keyboards/keebio/iris/rev5/config.h index 086bddd8ced2d6137a13cebf7b711141028ccd7f..2444970342440ec1a7bb70e75df5517b55657790 100644 --- a/keyboards/keebio/iris/rev5/config.h +++ b/keyboards/keebio/iris/rev5/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS_RIGHT { D4, D7, D3, B7, F0, B3 } #define SPLIT_HAND_PIN D5 -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } -#define ENCODERS_PAD_A_RIGHT { F7 } -#define ENCODERS_PAD_B_RIGHT { F6 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/iris/rev5/info.json b/keyboards/keebio/iris/rev5/info.json index c45d09a8df23fa81d1377825ff94eb0f2cf2520b..8279cdcc2b62cf3f4abddbe4dd42413525705665 100644 --- a/keyboards/keebio/iris/rev5/info.json +++ b/keyboards/keebio/iris/rev5/info.json @@ -4,6 +4,11 @@ "pid": "0x5256", "device_version": "5.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "backlight": { "pin": "B5", "levels": 5 @@ -15,7 +20,14 @@ "speaker": "C6" }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F7", "pin_b": "F6"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "qmk-dfu" diff --git a/keyboards/keebio/iris/rev6/config.h b/keyboards/keebio/iris/rev6/config.h index a07aee024d15d54a7dec992074b782ecbc4febab..0c6b1e38f8e0bbb8c9396ffb2b852522e68a559a 100644 --- a/keyboards/keebio/iris/rev6/config.h +++ b/keyboards/keebio/iris/rev6/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS_RIGHT { D4, D6, D7, C7, F1, F4 } #define SPLIT_HAND_PIN D5 -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } -#define ENCODERS_PAD_A_RIGHT { B3 } -#define ENCODERS_PAD_B_RIGHT { B2 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/iris/rev6/info.json b/keyboards/keebio/iris/rev6/info.json index 930cc7a34da24b0ed4166be975cf8d3d7612e838..8470624a310fa5789766c6be6ebed0dc14562abb 100644 --- a/keyboards/keebio/iris/rev6/info.json +++ b/keyboards/keebio/iris/rev6/info.json @@ -4,6 +4,11 @@ "pid": "0x6256", "device_version": "6.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "split": { "soft_serial_pin": "D0" }, diff --git a/keyboards/keebio/iris/rev6a/config.h b/keyboards/keebio/iris/rev6a/config.h index b78a757344cb026605fae888c2d43c05783a3d43..dd05a6ec3be2fc4d2fce6e928cd64b67896efcbd 100644 --- a/keyboards/keebio/iris/rev6a/config.h +++ b/keyboards/keebio/iris/rev6a/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS_RIGHT { D4, D6, D7, C7, F1, F4 } #define SPLIT_HAND_PIN D5 -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } -#define ENCODERS_PAD_A_RIGHT { B3 } -#define ENCODERS_PAD_B_RIGHT { B2 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/iris/rev6a/info.json b/keyboards/keebio/iris/rev6a/info.json index f03043a0e76a146c82b0aa10539fa2a5bb50f047..027a79f512fc6c963909cd1f10010c7795f9a6d9 100644 --- a/keyboards/keebio/iris/rev6a/info.json +++ b/keyboards/keebio/iris/rev6a/info.json @@ -4,6 +4,11 @@ "pid": "0x6356", "device_version": "6.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "split": { "soft_serial_pin": "D0" }, diff --git a/keyboards/keebio/iris/rev6b/config.h b/keyboards/keebio/iris/rev6b/config.h index b78a757344cb026605fae888c2d43c05783a3d43..dd05a6ec3be2fc4d2fce6e928cd64b67896efcbd 100644 --- a/keyboards/keebio/iris/rev6b/config.h +++ b/keyboards/keebio/iris/rev6b/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS_RIGHT { D4, D6, D7, C7, F1, F4 } #define SPLIT_HAND_PIN D5 -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } -#define ENCODERS_PAD_A_RIGHT { B3 } -#define ENCODERS_PAD_B_RIGHT { B2 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/iris/rev6b/info.json b/keyboards/keebio/iris/rev6b/info.json index 2fef279eb3a579c5bf8372854c301768dd4ca51a..b8d1f076a411cfd9f4a33a9beae91ad170e9922e 100644 --- a/keyboards/keebio/iris/rev6b/info.json +++ b/keyboards/keebio/iris/rev6b/info.json @@ -4,6 +4,11 @@ "pid": "0x6456", "device_version": "6.2.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "split": { "soft_serial_pin": "D0" }, diff --git a/keyboards/keebio/iris/rev7/config.h b/keyboards/keebio/iris/rev7/config.h index 112edec592944745e6744a578adf5986c84d66d2..906b65b0b2e876dce6f08b4e6384a33ddf4f7559 100644 --- a/keyboards/keebio/iris/rev7/config.h +++ b/keyboards/keebio/iris/rev7/config.h @@ -24,11 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS_RIGHT { D4, D6, D7, C7, F1, F4 } #define SPLIT_HAND_PIN D5 -#define ENCODERS_PAD_A { B3, F6 } -#define ENCODERS_PAD_B { B2, F7 } -#define ENCODERS_PAD_A_RIGHT { B3, F6 } -#define ENCODERS_PAD_B_RIGHT { B2, F7 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keebio/iris/rev7/info.json b/keyboards/keebio/iris/rev7/info.json index b44059ee2404ad81109b2b078764c31ccd9db49b..086f8907a955711e308041c2a0caead2f1e34d45 100644 --- a/keyboards/keebio/iris/rev7/info.json +++ b/keyboards/keebio/iris/rev7/info.json @@ -4,6 +4,12 @@ "pid": "0x7256", "device_version": "7.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2"}, + {"pin_a": "F6", "pin_b": "F7"} + ] + }, "split": { "soft_serial_pin": "D0" }, diff --git a/keyboards/keebio/kbo5000/rev1/config.h b/keyboards/keebio/kbo5000/rev1/config.h index df4180f9c23c49b177155114dc8deea8d943e4d2..4e6f11cd389abfcc98b4441ff223eb9a728d902e 100644 --- a/keyboards/keebio/kbo5000/rev1/config.h +++ b/keyboards/keebio/kbo5000/rev1/config.h @@ -25,10 +25,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS_RIGHT { B3, B2, B6, B4, D7, B0 } #define MATRIX_COL_PINS_RIGHT { F1, F0, F4, F5, F6, D5, D2, D3, B7, B1 } #define SPLIT_HAND_PIN F7 -#define ENCODERS_PAD_A { F5, NO_PIN } -#define ENCODERS_PAD_B { F6, NO_PIN } -#define ENCODERS_PAD_A_RIGHT { D6, C7 } -#define ENCODERS_PAD_B_RIGHT { D4, C6 } #define CAPS_LOCK_LED_PIN B6 diff --git a/keyboards/keebio/kbo5000/rev1/info.json b/keyboards/keebio/kbo5000/rev1/info.json index 8d0b9877a110dca0add72984390dbed3cfd58ec4..d65c9b38e2b4ae6563e0a2335e8cb797c1244dab 100644 --- a/keyboards/keebio/kbo5000/rev1/info.json +++ b/keyboards/keebio/kbo5000/rev1/info.json @@ -8,11 +8,25 @@ "pid": "0x126A", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"}, + {"pin_a": "NO_PIN", "pin_b": "NO_PIN"} + ] + }, "backlight": { "pin": "B5" }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "D6", "pin_b": "C7"}, + {"pin_a": "D4", "pin_b": "C6"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/keebio/quefrency/rev2/config.h b/keyboards/keebio/quefrency/rev2/config.h index 3ccae644215a1c79a750b41015f9ad2624b30887..63f1408cda9c8bd0beb3d7ff4343570528892f77 100644 --- a/keyboards/keebio/quefrency/rev2/config.h +++ b/keyboards/keebio/quefrency/rev2/config.h @@ -25,10 +25,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS_RIGHT { B3, B2, B6, B4, D7 } #define MATRIX_COL_PINS_RIGHT { F1, F0, F4, F5, F6, D5, C7, D3, B7 } #define SPLIT_HAND_PIN F7 -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } -#define ENCODERS_PAD_A_RIGHT { D6 } -#define ENCODERS_PAD_B_RIGHT { D4 } #define CAPS_LOCK_LED_PIN B6 diff --git a/keyboards/keebio/quefrency/rev2/info.json b/keyboards/keebio/quefrency/rev2/info.json index c5e75b37819de6e1dc197a0c709e90e5e58872f2..508e2431b9c23ac3a6c3cca0b19b9c5ca96351fd 100644 --- a/keyboards/keebio/quefrency/rev2/info.json +++ b/keyboards/keebio/quefrency/rev2/info.json @@ -8,11 +8,23 @@ "pid": "0x2257", "device_version": "2.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "backlight": { "pin": "B5" }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D4"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/keebio/quefrency/rev3/config.h b/keyboards/keebio/quefrency/rev3/config.h index 3ccae644215a1c79a750b41015f9ad2624b30887..63f1408cda9c8bd0beb3d7ff4343570528892f77 100644 --- a/keyboards/keebio/quefrency/rev3/config.h +++ b/keyboards/keebio/quefrency/rev3/config.h @@ -25,10 +25,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS_RIGHT { B3, B2, B6, B4, D7 } #define MATRIX_COL_PINS_RIGHT { F1, F0, F4, F5, F6, D5, C7, D3, B7 } #define SPLIT_HAND_PIN F7 -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } -#define ENCODERS_PAD_A_RIGHT { D6 } -#define ENCODERS_PAD_B_RIGHT { D4 } #define CAPS_LOCK_LED_PIN B6 diff --git a/keyboards/keebio/quefrency/rev3/info.json b/keyboards/keebio/quefrency/rev3/info.json index 0fcb867a882b5b0a01ab18283894f02924fc8edb..cd335a1d277f442908288fe65e9709036edeb6bf 100644 --- a/keyboards/keebio/quefrency/rev3/info.json +++ b/keyboards/keebio/quefrency/rev3/info.json @@ -8,11 +8,23 @@ "pid": "0x3357", "device_version": "3.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "backlight": { "pin": "B5" }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D4"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/keebio/quefrency/rev4/config.h b/keyboards/keebio/quefrency/rev4/config.h index ed29b07d323d8cb8f9dc45848482f523d4d71882..3292fbf302153d32f847693294cd55eb75a94e43 100644 --- a/keyboards/keebio/quefrency/rev4/config.h +++ b/keyboards/keebio/quefrency/rev4/config.h @@ -23,10 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS_RIGHT { B3, B2, B6, B4, D7 } #define MATRIX_COL_PINS_RIGHT { F1, F0, F4, F5, F6, D5, C7, D3, B7 } #define SPLIT_HAND_PIN F7 -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } -#define ENCODERS_PAD_A_RIGHT { D6 } -#define ENCODERS_PAD_B_RIGHT { D4 } /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/keebio/quefrency/rev4/info.json b/keyboards/keebio/quefrency/rev4/info.json index 374335f2b4ec79769f6ba12e8ad613f54974e91a..de9a383d4fddb840a125af522a80a5257db1241b 100644 --- a/keyboards/keebio/quefrency/rev4/info.json +++ b/keyboards/keebio/quefrency/rev4/info.json @@ -8,8 +8,20 @@ "pid": "0x4357", "device_version": "4.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D4"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/keebio/quefrency/rev5/config.h b/keyboards/keebio/quefrency/rev5/config.h index ed29b07d323d8cb8f9dc45848482f523d4d71882..3292fbf302153d32f847693294cd55eb75a94e43 100644 --- a/keyboards/keebio/quefrency/rev5/config.h +++ b/keyboards/keebio/quefrency/rev5/config.h @@ -23,10 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS_RIGHT { B3, B2, B6, B4, D7 } #define MATRIX_COL_PINS_RIGHT { F1, F0, F4, F5, F6, D5, C7, D3, B7 } #define SPLIT_HAND_PIN F7 -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } -#define ENCODERS_PAD_A_RIGHT { D6 } -#define ENCODERS_PAD_B_RIGHT { D4 } /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/keebio/quefrency/rev5/info.json b/keyboards/keebio/quefrency/rev5/info.json index c2fdc5c149dcacce5daf00ae8d8743c17d80ec70..422d9872585c9e7d52127f620a86a7ceae3a4332 100644 --- a/keyboards/keebio/quefrency/rev5/info.json +++ b/keyboards/keebio/quefrency/rev5/info.json @@ -8,8 +8,20 @@ "pid": "0x5357", "device_version": "5.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D4"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/keebio/stick/config.h b/keyboards/keebio/stick/config.h index 807383befc830114c97d08733d6ad732bff5d0db..c4b27e4324a7bf8a34e0610db105c30436cb3184 100644 --- a/keyboards/keebio/stick/config.h +++ b/keyboards/keebio/stick/config.h @@ -17,9 +17,6 @@ along with this program. If not, see . #pragma once -#define ENCODERS_PAD_A { D1, D4 } -#define ENCODERS_PAD_B { D0, C6 } - /* WS2812 RGB LED */ #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN diff --git a/keyboards/keebio/stick/info.json b/keyboards/keebio/stick/info.json index 268e56032da51e6d24c675a3e5939e1d6abe0a4e..028332b5f4fbc0276b0618267a9f07e0dfaf2e37 100644 --- a/keyboards/keebio/stick/info.json +++ b/keyboards/keebio/stick/info.json @@ -8,6 +8,12 @@ "pid": "0x111C", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"}, + {"pin_a": "D4", "pin_b": "C6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/keebsforall/coarse60/config.h b/keyboards/keebsforall/coarse60/config.h index 0ec73b78743eaf93426dc8f9cce710dc2e8b8e54..e30cb58610183783a2b56b5b2dd3e845f36030bf 100644 --- a/keyboards/keebsforall/coarse60/config.h +++ b/keyboards/keebsforall/coarse60/config.h @@ -47,10 +47,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -#define ENCODERS_PAD_A { A8 } -#define ENCODERS_PAD_B { A1 } -#define ENCODER_RESOLUTION 2 - // 2 bits for 4 layout options #define VIA_EEPROM_LAYOUT_OPTIONS_SIZE 2 diff --git a/keyboards/keebsforall/coarse60/info.json b/keyboards/keebsforall/coarse60/info.json index 63fa7d5fe821ea722f93df8645ec6b5cc0afc69e..d769b4e7d0360f0cb02d800a786fd337dac980b3 100644 --- a/keyboards/keebsforall/coarse60/info.json +++ b/keyboards/keebsforall/coarse60/info.json @@ -8,6 +8,11 @@ "pid": "0x5341", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A8", "pin_b": "A1", "resolution": 2} + ] + }, "backlight": { "pin": "A6", "levels": 6, diff --git a/keyboards/keebsforall/freebirdnp/pro/config.h b/keyboards/keebsforall/freebirdnp/pro/config.h index 943d87d730fabb4208345b08082a7f35f706a021..85bcc17f0e08e30ba913e31a4ce61efc3de6ca2a 100644 --- a/keyboards/keebsforall/freebirdnp/pro/config.h +++ b/keyboards/keebsforall/freebirdnp/pro/config.h @@ -17,10 +17,6 @@ along with this program. If not, see . #pragma once - -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { D5 } - /* * Keyboard Matrix Assignments * diff --git a/keyboards/keebsforall/freebirdnp/pro/info.json b/keyboards/keebsforall/freebirdnp/pro/info.json index 40723c36996e4bc261538cc907dfdea50fcce6a3..d4eda0ad0b8a27f0ca9161be01e0e1971f9d02ba 100644 --- a/keyboards/keebsforall/freebirdnp/pro/info.json +++ b/keyboards/keebsforall/freebirdnp/pro/info.json @@ -8,6 +8,11 @@ "pid": "0x1014", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "D5"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "community_layouts": ["numpad_6x4", "ortho_6x4"], diff --git a/keyboards/keybage/radpad/config.h b/keyboards/keybage/radpad/config.h index 240f334ccf7658ec67c07df41beaf01e5e861fcb..f2988c8ede08b4fa37c4cf0db799f55d34dfd6d1 100644 --- a/keyboards/keybage/radpad/config.h +++ b/keyboards/keybage/radpad/config.h @@ -23,11 +23,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D4, F6 } -#define ENCODERS_PAD_B { C6, F7 } - -#define ENCODER_RESOLUTION 2 - #define RGB_DI_PIN F4 #ifdef RGB_DI_PIN #define RGBLED_NUM 16 diff --git a/keyboards/keybage/radpad/info.json b/keyboards/keybage/radpad/info.json index c2d77fca50128ad7934083f32a5a9b5796196e20..f0c0dcd63fa76efeae2238c83c506a26d04d116c 100644 --- a/keyboards/keybage/radpad/info.json +++ b/keyboards/keybage/radpad/info.json @@ -8,6 +8,12 @@ "pid": "0x5250", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "C6", "resolution": 2}, + {"pin_a": "F6", "pin_b": "F7", "resolution": 2} + ] + }, "bootmagic": { "matrix": [1, 3] }, diff --git a/keyboards/keycapsss/kimiko/rev1/config.h b/keyboards/keycapsss/kimiko/rev1/config.h index fbcf482c355f8e059d8f75709ed56fb91e1bf02e..592fefe5d471d9a299fa9d23b07f92b8ecca7e4d 100644 --- a/keyboards/keycapsss/kimiko/rev1/config.h +++ b/keyboards/keycapsss/kimiko/rev1/config.h @@ -38,13 +38,6 @@ #define RGBLIGHT_LIMIT_VAL 80 #endif -#ifdef ENCODER_ENABLE -# define ENCODERS_PAD_A { F4 } -# define ENCODERS_PAD_B { F5 } -# define ENCODERS_PAD_A_RIGHT { F4 } -# define ENCODERS_PAD_B_RIGHT { F5 } -#endif - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/keycapsss/kimiko/rev1/info.json b/keyboards/keycapsss/kimiko/rev1/info.json index 09f5867a4c915cfd4cf577a6395b9ea5273e65c6..0bfeffe39ac536c77b9d6b83ec838b87d1957cce 100644 --- a/keyboards/keycapsss/kimiko/rev1/info.json +++ b/keyboards/keycapsss/kimiko/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0x4B69", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/keycapsss/plaid_pad/config.h b/keyboards/keycapsss/plaid_pad/config.h index 1bdd1187364a7a8581734895a91eec081b5ca8ec..5825367ac1e0926b8cd64208ecceb2ef521f4391 100644 --- a/keyboards/keycapsss/plaid_pad/config.h +++ b/keyboards/keycapsss/plaid_pad/config.h @@ -20,8 +20,6 @@ #define MATRIX_ROW_PINS { C0, C1, C2, C3 } #define MATRIX_COL_PINS { B0, D7, D6, D5 } -#define ENCODER_RESOLUTION 4 - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keycapsss/plaid_pad/rev1/config.h b/keyboards/keycapsss/plaid_pad/rev1/config.h index 5956835a0b22f0f32b634e566742edd1dbd0a87c..ef2037c5684f06b186a11e5437bc77772e0d9251 100644 --- a/keyboards/keycapsss/plaid_pad/rev1/config.h +++ b/keyboards/keycapsss/plaid_pad/rev1/config.h @@ -16,8 +16,5 @@ #pragma once -#define ENCODERS_PAD_A { D1, B2 } -#define ENCODERS_PAD_B { D0, B1 } - #define LED_RED C5 // LED1 #define LED_GREEN C4 // LED2 diff --git a/keyboards/keycapsss/plaid_pad/rev1/info.json b/keyboards/keycapsss/plaid_pad/rev1/info.json index 3d98c4cb575a8eb0feaf8348775eaf32b4e6196a..b9fe9e977a2011f5870f52aff3ed4ce8b7029b25 100644 --- a/keyboards/keycapsss/plaid_pad/rev1/info.json +++ b/keyboards/keycapsss/plaid_pad/rev1/info.json @@ -2,5 +2,11 @@ "keyboard_name": "Plaid-Pad Rev1", "usb": { "device_version": "0.0.1" - } + }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"}, + {"pin_a": "B2", "pin_b": "B1"} + ] + }, } diff --git a/keyboards/keycapsss/plaid_pad/rev2/config.h b/keyboards/keycapsss/plaid_pad/rev2/config.h index efb2609eddf88f93a306cc03094affbf9106ff25..ef2037c5684f06b186a11e5437bc77772e0d9251 100644 --- a/keyboards/keycapsss/plaid_pad/rev2/config.h +++ b/keyboards/keycapsss/plaid_pad/rev2/config.h @@ -16,8 +16,5 @@ #pragma once -#define ENCODERS_PAD_A { D1, B2, B4, D4 } -#define ENCODERS_PAD_B { D0, B1, B3, B5 } - #define LED_RED C5 // LED1 #define LED_GREEN C4 // LED2 diff --git a/keyboards/keycapsss/plaid_pad/rev2/info.json b/keyboards/keycapsss/plaid_pad/rev2/info.json index 0a1da66f73f13b25973f5da9cb1e111542ac4a8f..637139c5a4468ecda7bd11c65bf14e464073a6a1 100644 --- a/keyboards/keycapsss/plaid_pad/rev2/info.json +++ b/keyboards/keycapsss/plaid_pad/rev2/info.json @@ -2,5 +2,13 @@ "keyboard_name": "Plaid-Pad Rev2", "usb": { "device_version": "0.0.2" + }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"}, + {"pin_a": "B2", "pin_b": "B1"}, + {"pin_a": "B4", "pin_b": "B3"}, + {"pin_a": "D4", "pin_b": "B5"} + ] } } diff --git a/keyboards/keycapsss/plaid_pad/rev3/config.h b/keyboards/keycapsss/plaid_pad/rev3/config.h deleted file mode 100644 index 7e4786c5bca928088c6e07d59e263052a8a13d2e..0000000000000000000000000000000000000000 --- a/keyboards/keycapsss/plaid_pad/rev3/config.h +++ /dev/null @@ -1,20 +0,0 @@ -/* Copyright 2020 Ben Roesner (keycapsss.com) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#pragma once - -#define ENCODERS_PAD_A { D1, B2, B4, D4 } -#define ENCODERS_PAD_B { D0, B1, B3, B5 } diff --git a/keyboards/keycapsss/plaid_pad/rev3/info.json b/keyboards/keycapsss/plaid_pad/rev3/info.json index 2f5b474c4d83e1fcb07c1524b7bb79b7aa84cd16..93b5e3bdc9778eb6fb844d8ec62da84a383bdeee 100644 --- a/keyboards/keycapsss/plaid_pad/rev3/info.json +++ b/keyboards/keycapsss/plaid_pad/rev3/info.json @@ -2,5 +2,13 @@ "keyboard_name": "Plaid-Pad Rev3", "usb": { "device_version": "0.0.3" - } + }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"}, + {"pin_a": "B2", "pin_b": "B1"}, + {"pin_a": "B4", "pin_b": "B3"}, + {"pin_a": "D4", "pin_b": "B5"} + ] + }, } diff --git a/keyboards/keychron/q0/rev_0131/config.h b/keyboards/keychron/q0/rev_0131/config.h index 5a31fc4e770ea4e7a58df4ffc1a1a9d2246c8b24..f94517ebb40ecb13e87d4624d8d00ddd67235083 100644 --- a/keyboards/keychron/q0/rev_0131/config.h +++ b/keyboards/keychron/q0/rev_0131/config.h @@ -35,7 +35,4 @@ #define NUM_LOCK_LED_INDEX 5 /* Encoder Configuration */ -#define ENCODERS_PAD_A { A3 } -#define ENCODERS_PAD_B { A4 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 diff --git a/keyboards/keychron/q0/rev_0131/info.json b/keyboards/keychron/q0/rev_0131/info.json index ad555630f91e33b61e37e1138e8df0d0f2cf1661..94808bd9c4dc85920ce876b653b3a0f771d493c6 100644 --- a/keyboards/keychron/q0/rev_0131/info.json +++ b/keyboards/keychron/q0/rev_0131/info.json @@ -8,6 +8,11 @@ "pid": "0x0131", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A3", "pin_b": "A4"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/keychron/q1/ansi_encoder/config.h b/keyboards/keychron/q1/ansi_encoder/config.h index b38261abf6b24bb77cb52b521188dabcac9e87eb..a41976d560bd273ccd73b1cdf2e81d1b2324c2d0 100644 --- a/keyboards/keychron/q1/ansi_encoder/config.h +++ b/keyboards/keychron/q1/ansi_encoder/config.h @@ -24,10 +24,3 @@ #define DRIVER_1_LED_TOTAL 59 #define DRIVER_2_LED_TOTAL 23 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) - -/* Encoder used pins */ -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { B7 } - -/* Specifies the number of pulses the encoder registers between each detent */ -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/keychron/q1/ansi_encoder/info.json b/keyboards/keychron/q1/ansi_encoder/info.json index 8fdd64ed7a46d2d2c6f835080125d584a34070ab..2391e674ad0dd811c837a5d60d52b1dc07e7f86d 100644 --- a/keyboards/keychron/q1/ansi_encoder/info.json +++ b/keyboards/keychron/q1/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0101", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/keychron/q1/iso_encoder/config.h b/keyboards/keychron/q1/iso_encoder/config.h index 984b3c77d02c98d52e01dbf3dd476de6b53c8fd7..b52fb88383c31466d9da8bca972d57df1146dfff 100644 --- a/keyboards/keychron/q1/iso_encoder/config.h +++ b/keyboards/keychron/q1/iso_encoder/config.h @@ -33,9 +33,5 @@ #define DRIVER_2_LED_TOTAL 24 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) -/* Encoder Configuration */ -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { B7 } - /* Enable caps-lock LED */ #define CAPS_LOCK_LED_INDEX 44 diff --git a/keyboards/keychron/q1/iso_encoder/info.json b/keyboards/keychron/q1/iso_encoder/info.json index 573c43696facbde437d208ba93dc09281f4669bc..e4dce374c85b2b69fc8993a16b3a8df6fc79ed63 100644 --- a/keyboards/keychron/q1/iso_encoder/info.json +++ b/keyboards/keychron/q1/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0103", "device_version": "1.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/keychron/q10/ansi_encoder/config.h b/keyboards/keychron/q10/ansi_encoder/config.h index d02436c01d853a8b2f32e7225868f713685ef05a..9012abd4f75c4c9dc7053e79522ade947bb83947 100644 --- a/keyboards/keychron/q10/ansi_encoder/config.h +++ b/keyboards/keychron/q10/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q10/ansi_encoder/info.json b/keyboards/keychron/q10/ansi_encoder/info.json index 70de4d95be674c28d9813096c24f727d9ad89522..9814da0c264c9ac7b8102d4c99efde461feed442 100644 --- a/keyboards/keychron/q10/ansi_encoder/info.json +++ b/keyboards/keychron/q10/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x01A1", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/keychron/q10/iso_encoder/config.h b/keyboards/keychron/q10/iso_encoder/config.h index 7f4a57543272cbb864d2e2e4ee7d90674549c7ea..7a5646c56e2f1bbeb7d4c84f047167539f317323 100644 --- a/keyboards/keychron/q10/iso_encoder/config.h +++ b/keyboards/keychron/q10/iso_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q10/iso_encoder/info.json b/keyboards/keychron/q10/iso_encoder/info.json index f0b5b2704e233ab488b5530fbf44eff556a5f8e7..96311fac066ebbdd34f7e13fc6b4fed2f9c09889 100644 --- a/keyboards/keychron/q10/iso_encoder/info.json +++ b/keyboards/keychron/q10/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x01A3", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/keychron/q2/ansi_encoder/config.h b/keyboards/keychron/q2/ansi_encoder/config.h index 25e444933ceaf848ca9fc2c086bfa96d98d0a017..b7e4b1e7f871d91bc1065d2bd2bdf9ec5bc583f7 100644 --- a/keyboards/keychron/q2/ansi_encoder/config.h +++ b/keyboards/keychron/q2/ansi_encoder/config.h @@ -22,7 +22,4 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder used pins */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 diff --git a/keyboards/keychron/q2/ansi_encoder/info.json b/keyboards/keychron/q2/ansi_encoder/info.json index f3eddd9ecbd27663b820a3be3437719a106cda8a..a2a12dc39cef3b881512cf52f1c2951a7f18d918 100644 --- a/keyboards/keychron/q2/ansi_encoder/info.json +++ b/keyboards/keychron/q2/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0111", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q2/iso_encoder/config.h b/keyboards/keychron/q2/iso_encoder/config.h index aa779918af28fbccadcc1b960fa9a9652f2c10e8..376b92b6fa1187499ae82849394cb5372cf63b40 100644 --- a/keyboards/keychron/q2/iso_encoder/config.h +++ b/keyboards/keychron/q2/iso_encoder/config.h @@ -22,7 +22,4 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder used pins */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 diff --git a/keyboards/keychron/q2/iso_encoder/info.json b/keyboards/keychron/q2/iso_encoder/info.json index 36184a880779c52202c83a71c3ac31082473774d..028522c259866dcc342f6f62669d1305622c79ac 100644 --- a/keyboards/keychron/q2/iso_encoder/info.json +++ b/keyboards/keychron/q2/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0113", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q2/jis_encoder/config.h b/keyboards/keychron/q2/jis_encoder/config.h index e0ca950bc3e4cbc688178cc5d6b25f29f0b0f591..5e7ab551437f361e8a0817b171408f390bcb880d 100644 --- a/keyboards/keychron/q2/jis_encoder/config.h +++ b/keyboards/keychron/q2/jis_encoder/config.h @@ -24,9 +24,6 @@ #define CKLED2001_CURRENT_TUNE { 0xC0, 0xC0, 0x5D, 0xC0, 0xC0, 0x5D, 0xC0, 0xC0, 0x5D, 0xC0, 0xC0, 0x5D } /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q2/jis_encoder/info.json b/keyboards/keychron/q2/jis_encoder/info.json index a0b5852b15c1cd7704d7605ba9f4d428fa7ae0d8..18e800703b9a998a1bc519bc20fcba4279ab9e3e 100644 --- a/keyboards/keychron/q2/jis_encoder/info.json +++ b/keyboards/keychron/q2/jis_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0115", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q3/ansi_encoder/config.h b/keyboards/keychron/q3/ansi_encoder/config.h index 505a45b79cf61ebaab21ffe3a96a08340bc28e6c..201288841a6b60af907516986f5269678c291922 100644 --- a/keyboards/keychron/q3/ansi_encoder/config.h +++ b/keyboards/keychron/q3/ansi_encoder/config.h @@ -26,9 +26,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 #define CKLED2001_CURRENT_TUNE \ diff --git a/keyboards/keychron/q3/ansi_encoder/info.json b/keyboards/keychron/q3/ansi_encoder/info.json index 491a2831c87e635b0efc45d84d2b2b0bdea5acab..3bd5a9d59a1c0abffd83db567d17090d69d637d3 100644 --- a/keyboards/keychron/q3/ansi_encoder/info.json +++ b/keyboards/keychron/q3/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0121", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q3/iso_encoder/config.h b/keyboards/keychron/q3/iso_encoder/config.h index 0cc5fbf1d9725299ba96a8d43e30b42c6849061d..2ee93a4faeac9972c9b32cb8213f938adc33503c 100644 --- a/keyboards/keychron/q3/iso_encoder/config.h +++ b/keyboards/keychron/q3/iso_encoder/config.h @@ -26,9 +26,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 #define CKLED2001_CURRENT_TUNE \ diff --git a/keyboards/keychron/q3/iso_encoder/info.json b/keyboards/keychron/q3/iso_encoder/info.json index 06fb0338256ad1652b043fe4a4bb3067a5663b8b..6f1a24b372355bc24cbaf550bfdf8263080f0058 100644 --- a/keyboards/keychron/q3/iso_encoder/info.json +++ b/keyboards/keychron/q3/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0123", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q3/jis_encoder/config.h b/keyboards/keychron/q3/jis_encoder/config.h index 322f04cb0fc2b96bbf9a5d4c86fd83012c10e5d1..9fca0cfc73ce656b251a6aabbe29528cce34e5f4 100644 --- a/keyboards/keychron/q3/jis_encoder/config.h +++ b/keyboards/keychron/q3/jis_encoder/config.h @@ -31,9 +31,6 @@ { 0x94, 0x94, 0x44, 0x94, 0x94, 0x44, 0x94, 0x94, 0x44, 0x94, 0x94, 0x44 } /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable CapsLcok LED */ diff --git a/keyboards/keychron/q3/jis_encoder/info.json b/keyboards/keychron/q3/jis_encoder/info.json index 7e203cb9c98139e3c0692ad9dbb35ab10a652179..ed12472732595e8ad9643c0407c8311c04afed29 100644 --- a/keyboards/keychron/q3/jis_encoder/info.json +++ b/keyboards/keychron/q3/jis_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0125", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q5/ansi_encoder/config.h b/keyboards/keychron/q5/ansi_encoder/config.h index 6aecac619e07320d491cb65f0eebc7e0f914ef34..3986c11a027efe49171c93d69f047f02d95dac3f 100644 --- a/keyboards/keychron/q5/ansi_encoder/config.h +++ b/keyboards/keychron/q5/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q5/ansi_encoder/info.json b/keyboards/keychron/q5/ansi_encoder/info.json index ab5d25320a67cb2c5f54981f4b2b8bbe2df879e8..7bd6f179c6ae478ac972ab259de1866497523a58 100644 --- a/keyboards/keychron/q5/ansi_encoder/info.json +++ b/keyboards/keychron/q5/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0151", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q5/iso_encoder/config.h b/keyboards/keychron/q5/iso_encoder/config.h index 3c9eee8d494aa12e0777c51ce8fe6fdbf639752d..3a786cbb39be1320a6abfc71060ff99a5ed694ad 100644 --- a/keyboards/keychron/q5/iso_encoder/config.h +++ b/keyboards/keychron/q5/iso_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q5/iso_encoder/info.json b/keyboards/keychron/q5/iso_encoder/info.json index 59a4ad32334cdfa74839ba6e66b1844d90b838c7..81cd72036f456e9a39395c1cb2a20f8af4b8524c 100644 --- a/keyboards/keychron/q5/iso_encoder/info.json +++ b/keyboards/keychron/q5/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0153", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q6/ansi_encoder/config.h b/keyboards/keychron/q6/ansi_encoder/config.h index 1949be399b072d5a0cd5f662c20abd3a737d0a30..573fa614a3211f992f7c58587fc726f54c80b08d 100644 --- a/keyboards/keychron/q6/ansi_encoder/config.h +++ b/keyboards/keychron/q6/ansi_encoder/config.h @@ -31,9 +31,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED*/ diff --git a/keyboards/keychron/q6/ansi_encoder/info.json b/keyboards/keychron/q6/ansi_encoder/info.json index 86d2cda5d16fa700e1bae9e110b76eda3410917b..60b983b12e7b9ea6b472e4576e789a4beb367e33 100644 --- a/keyboards/keychron/q6/ansi_encoder/info.json +++ b/keyboards/keychron/q6/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0161", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q6/iso_encoder/config.h b/keyboards/keychron/q6/iso_encoder/config.h index 63fe3a83c14e2a9908bc7aaf21d7303836b97d77..512a33bafdecf404b3aeb73117c36e61dfc04f12 100644 --- a/keyboards/keychron/q6/iso_encoder/config.h +++ b/keyboards/keychron/q6/iso_encoder/config.h @@ -31,9 +31,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED*/ diff --git a/keyboards/keychron/q6/iso_encoder/info.json b/keyboards/keychron/q6/iso_encoder/info.json index 2996e0022a7a1ffc5204d3615ade4173044ee201..598a715c3f06173bd36fa0653c2874ee0581b1d6 100644 --- a/keyboards/keychron/q6/iso_encoder/info.json +++ b/keyboards/keychron/q6/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0163", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q65/ansi_encoder/config.h b/keyboards/keychron/q65/ansi_encoder/config.h index 1d04a4649ea1b5c8a4fd989b2bb5d48fb1ee7e81..f57797677e9d46875f5e6e6e271654a611eb3c33 100644 --- a/keyboards/keychron/q65/ansi_encoder/config.h +++ b/keyboards/keychron/q65/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q65/ansi_encoder/info.json b/keyboards/keychron/q65/ansi_encoder/info.json index a7ec2d56b33a0948a6f9b8e61822ac72056b5055..b91892a55bc3d2559df9581af34d05b9ae12b32c 100644 --- a/keyboards/keychron/q65/ansi_encoder/info.json +++ b/keyboards/keychron/q65/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x01B1", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/keychron/q8/ansi_encoder/config.h b/keyboards/keychron/q8/ansi_encoder/config.h index 1d825e97701801bd500680778d4f3cb13a309f91..63d16c21af2341662ab302551e2b6c9f9e8e30b4 100644 --- a/keyboards/keychron/q8/ansi_encoder/config.h +++ b/keyboards/keychron/q8/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { A10 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q8/ansi_encoder/info.json b/keyboards/keychron/q8/ansi_encoder/info.json index 3859c19dee7cb6088766897b7e2dd2bf12ac34d5..b75a87819864aa8ed4751c6e7ac3504adf011d15 100644 --- a/keyboards/keychron/q8/ansi_encoder/info.json +++ b/keyboards/keychron/q8/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0181", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "A10"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q8/iso_encoder/config.h b/keyboards/keychron/q8/iso_encoder/config.h index 1325738f8f5fcee65585213afbfa8b473f483a90..cdda41df5d09d7b4b6274eb9f478cbcedfb29896 100644 --- a/keyboards/keychron/q8/iso_encoder/config.h +++ b/keyboards/keychron/q8/iso_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { A10 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q8/iso_encoder/info.json b/keyboards/keychron/q8/iso_encoder/info.json index 48a32c915cf42dea39a0f9292f68324d0faac871..45181452bea54c9f58b05f2e09432c2f821b4944 100644 --- a/keyboards/keychron/q8/iso_encoder/info.json +++ b/keyboards/keychron/q8/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0183", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "A10"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q9/ansi_encoder/config.h b/keyboards/keychron/q9/ansi_encoder/config.h index 56f4966388f073625ba8296a42e6a7cfbce8db7c..6850e5c2d67d6a029023864f71384b46ac8d0c36 100644 --- a/keyboards/keychron/q9/ansi_encoder/config.h +++ b/keyboards/keychron/q9/ansi_encoder/config.h @@ -21,9 +21,6 @@ #define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL /* Encoder Configuration */ -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q9/ansi_encoder/info.json b/keyboards/keychron/q9/ansi_encoder/info.json index 54719d574966cd544519027955fc11c84c9c6802..5100c189450b62275128165a0428bfb3547d722f 100644 --- a/keyboards/keychron/q9/ansi_encoder/info.json +++ b/keyboards/keychron/q9/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0191", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/q9/iso_encoder/config.h b/keyboards/keychron/q9/iso_encoder/config.h index 0d7e2c5a501275fe7d9300ece905f6503d5ae123..65d7ad770824f3ccaaba3f909c3e3c049dc229cf 100644 --- a/keyboards/keychron/q9/iso_encoder/config.h +++ b/keyboards/keychron/q9/iso_encoder/config.h @@ -21,9 +21,6 @@ #define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL /* Encoder Configuration */ -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/q9/iso_encoder/info.json b/keyboards/keychron/q9/iso_encoder/info.json index 4e4819519d3d0a011632515b067c299965d5becb..dee0a8953aabb5a8cfd9b06cc10bad85a076ec2d 100644 --- a/keyboards/keychron/q9/iso_encoder/info.json +++ b/keyboards/keychron/q9/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0193", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v1/ansi_encoder/config.h b/keyboards/keychron/v1/ansi_encoder/config.h index c7af3db8fa4d939cc735b12f1e5780058afd1ed1..c32e4d104a37f001756fd6527453328ab5c81dde 100644 --- a/keyboards/keychron/v1/ansi_encoder/config.h +++ b/keyboards/keychron/v1/ansi_encoder/config.h @@ -25,9 +25,6 @@ { 0xA6, 0xA6, 0x50, 0xA6, 0xA6, 0x50, 0xA6, 0xA6, 0x50, 0xA6, 0xA6, 0x50 } /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v1/ansi_encoder/info.json b/keyboards/keychron/v1/ansi_encoder/info.json index 19322f1fc988f03c7ddb7f3d0fa3205431a10149..af396f6bb608570052077205c53d97b483a15b22 100644 --- a/keyboards/keychron/v1/ansi_encoder/info.json +++ b/keyboards/keychron/v1/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0311", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v1/iso_encoder/config.h b/keyboards/keychron/v1/iso_encoder/config.h index 18273b3b36fbb08f14dc736c81885b8bc6d82111..fd231aa98a18b61d10842b08ab6419361af31dcc 100644 --- a/keyboards/keychron/v1/iso_encoder/config.h +++ b/keyboards/keychron/v1/iso_encoder/config.h @@ -25,9 +25,6 @@ { 0xA6, 0xA6, 0x50, 0xA6, 0xA6, 0x50, 0xA6, 0xA6, 0x50, 0xA6, 0xA6, 0x50 } /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v1/iso_encoder/info.json b/keyboards/keychron/v1/iso_encoder/info.json index 9febe465db7a4410c2c5af4ac1bdaa6490d76043..c08e7d4539b59f60164bd0f552e8b363750b608d 100644 --- a/keyboards/keychron/v1/iso_encoder/info.json +++ b/keyboards/keychron/v1/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0313", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v1/jis_encoder/config.h b/keyboards/keychron/v1/jis_encoder/config.h index 5a68e5dd50fdcaa2df1165d476347f036d1b4d13..93d2a72d98a6ebac4c3f3d27c987bdeaa9db929b 100644 --- a/keyboards/keychron/v1/jis_encoder/config.h +++ b/keyboards/keychron/v1/jis_encoder/config.h @@ -25,9 +25,6 @@ { 0xA0, 0xA0, 0x4D, 0xA0, 0xA0, 0x4D, 0xA0, 0xA0, 0x4D, 0xA0, 0xA0, 0x4D } /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v1/jis_encoder/info.json b/keyboards/keychron/v1/jis_encoder/info.json index abbe941427e92a443c8619febeabc4f062ea4d1e..755449848175b8f83dc331201d5aab3c5c3683fb 100644 --- a/keyboards/keychron/v1/jis_encoder/info.json +++ b/keyboards/keychron/v1/jis_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0315", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v10/ansi_encoder/config.h b/keyboards/keychron/v10/ansi_encoder/config.h index 4f689125412914111ef89d2762c70be7e4927c09..8b5595e4d6c6159be10c49d2799b244fe1a121d3 100644 --- a/keyboards/keychron/v10/ansi_encoder/config.h +++ b/keyboards/keychron/v10/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v10/ansi_encoder/info.json b/keyboards/keychron/v10/ansi_encoder/info.json index c3b78316d5224c392a9ea4980caedf9c58fb3339..cf8ae78b99e3d134102fcc4fadb956fa57d67176 100644 --- a/keyboards/keychron/v10/ansi_encoder/info.json +++ b/keyboards/keychron/v10/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x03A1", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/keychron/v10/iso_encoder/config.h b/keyboards/keychron/v10/iso_encoder/config.h index b064f10a604e5b7de401229eee3450e75b381e22..75706949d619374e2f366bc3675d5bd575ebbc62 100644 --- a/keyboards/keychron/v10/iso_encoder/config.h +++ b/keyboards/keychron/v10/iso_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v10/iso_encoder/info.json b/keyboards/keychron/v10/iso_encoder/info.json index ed48f6270a4ac1c67492029a21adb70b1173909e..554e0b907e73ddbf556889c352cd497fd921654c 100644 --- a/keyboards/keychron/v10/iso_encoder/info.json +++ b/keyboards/keychron/v10/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x03A3", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/keychron/v2/ansi_encoder/config.h b/keyboards/keychron/v2/ansi_encoder/config.h index 51b5cf8c66a05090d604817a0b6fc6c610114218..6ee6d1e7c66e5a7ba3ffee0530ffb5d78e8355ae 100644 --- a/keyboards/keychron/v2/ansi_encoder/config.h +++ b/keyboards/keychron/v2/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v2/ansi_encoder/info.json b/keyboards/keychron/v2/ansi_encoder/info.json index 257bd6b5fc74dcc39f559bee5fa047afc11a7f55..1e729eb6368c110ccb0e2cc5951aac8d79f11549 100644 --- a/keyboards/keychron/v2/ansi_encoder/info.json +++ b/keyboards/keychron/v2/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0321", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v2/iso_encoder/config.h b/keyboards/keychron/v2/iso_encoder/config.h index 60d3f554fa8a38a2667655f37d737e9f158335e6..f69d6834538d137df9f841369463ab283e023530 100644 --- a/keyboards/keychron/v2/iso_encoder/config.h +++ b/keyboards/keychron/v2/iso_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v2/iso_encoder/info.json b/keyboards/keychron/v2/iso_encoder/info.json index 212129eeb473d2b6dc8744ce929170e7614a84b9..a784b33ec5757598af22ee63a5f7d30fceb44045 100644 --- a/keyboards/keychron/v2/iso_encoder/info.json +++ b/keyboards/keychron/v2/iso_encoder/info.json @@ -7,6 +7,11 @@ "pid": "0x0323", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v2/jis_encoder/config.h b/keyboards/keychron/v2/jis_encoder/config.h index 3c4b5ddd011bf52855124bede52a995846112b39..a9a3438ab759881eab0694c0d2b47d6908bd4906 100644 --- a/keyboards/keychron/v2/jis_encoder/config.h +++ b/keyboards/keychron/v2/jis_encoder/config.h @@ -25,9 +25,6 @@ { 0xBD, 0xBD, 0x5D, 0xBD, 0xBD, 0x5D, 0xBD, 0xBD, 0x5D, 0xBD, 0xBD, 0x5D } /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v2/jis_encoder/info.json b/keyboards/keychron/v2/jis_encoder/info.json index d284dd5a2492de9e1cfe8cca618078ef8ddf23f5..abb76636f73e99ae7dfca73937661bb6871a8a5c 100644 --- a/keyboards/keychron/v2/jis_encoder/info.json +++ b/keyboards/keychron/v2/jis_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0325", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v3/ansi_encoder/config.h b/keyboards/keychron/v3/ansi_encoder/config.h index 6b6d2b9a1cd18432c43faa667d197c5f9df53574..6310f181a08c196b1080410b73b72b74756d58d3 100644 --- a/keyboards/keychron/v3/ansi_encoder/config.h +++ b/keyboards/keychron/v3/ansi_encoder/config.h @@ -28,9 +28,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable CapsLcok LED */ diff --git a/keyboards/keychron/v3/ansi_encoder/info.json b/keyboards/keychron/v3/ansi_encoder/info.json index fb9a1a669e7826f3a6e6fc35d43a83b3b02a0f94..5fdf765356da0fd94225166dc9e5a1927c8139e3 100644 --- a/keyboards/keychron/v3/ansi_encoder/info.json +++ b/keyboards/keychron/v3/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0331", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v3/iso_encoder/config.h b/keyboards/keychron/v3/iso_encoder/config.h index 8972acfe02da54ee6e651d2e8d0c0e1962bd61ab..7033a2093aa4aaee71875ee0b4be5e22b1392ffa 100644 --- a/keyboards/keychron/v3/iso_encoder/config.h +++ b/keyboards/keychron/v3/iso_encoder/config.h @@ -28,9 +28,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v3/iso_encoder/info.json b/keyboards/keychron/v3/iso_encoder/info.json index 34ff04a9d06a19c87800c205c4e3200acb81e418..b38ad45930b17f472e8c5173dc87d0d4d7cd73de 100644 --- a/keyboards/keychron/v3/iso_encoder/info.json +++ b/keyboards/keychron/v3/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0333", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v3/jis_encoder/config.h b/keyboards/keychron/v3/jis_encoder/config.h index 3c63cd306ee09e6c38dbc8ce6759047c02c106db..5f67d6a870d8fae0dbbd0fa4089eea9b8347ab10 100644 --- a/keyboards/keychron/v3/jis_encoder/config.h +++ b/keyboards/keychron/v3/jis_encoder/config.h @@ -31,9 +31,6 @@ { 0x94, 0x94, 0x44, 0x94, 0x94, 0x44, 0x94, 0x94, 0x44, 0x94, 0x94, 0x44 } /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { A8 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable CapsLcok LED */ diff --git a/keyboards/keychron/v3/jis_encoder/info.json b/keyboards/keychron/v3/jis_encoder/info.json index 86374520f7cb011a534e4d72a18b716769573e56..1f2d2b425b47f58d1bbe2435c240e4a3d3be85a4 100644 --- a/keyboards/keychron/v3/jis_encoder/info.json +++ b/keyboards/keychron/v3/jis_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0335", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "A8"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v5/ansi_encoder/config.h b/keyboards/keychron/v5/ansi_encoder/config.h index 659a3ea88e6c93f80c6d36e880552341ff93271c..6ce87e63ab84fbed87609f6ca0e7f8f2b0ef4c22 100644 --- a/keyboards/keychron/v5/ansi_encoder/config.h +++ b/keyboards/keychron/v5/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v5/ansi_encoder/info.json b/keyboards/keychron/v5/ansi_encoder/info.json index b9da185e56deb9a587686667989d7b27ebed491d..9461379d1ab0f0f33243cd0fdcc0a91a0b732cea 100644 --- a/keyboards/keychron/v5/ansi_encoder/info.json +++ b/keyboards/keychron/v5/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0351", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v5/iso_encoder/config.h b/keyboards/keychron/v5/iso_encoder/config.h index 49711b5d3b3f4bb725aae932375485dfbfd905d6..dab565612eb364aec837bd45ad26789cbe2dbd49 100644 --- a/keyboards/keychron/v5/iso_encoder/config.h +++ b/keyboards/keychron/v5/iso_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v5/iso_encoder/info.json b/keyboards/keychron/v5/iso_encoder/info.json index edde8d4b21d1a94017204bca0c643f27d8a440ff..21c1891069fa254f05710430a4a9f91e4aac1aea 100644 --- a/keyboards/keychron/v5/iso_encoder/info.json +++ b/keyboards/keychron/v5/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0353", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v6/ansi_encoder/config.h b/keyboards/keychron/v6/ansi_encoder/config.h index c87df6a9bfd52666ed89acbbdb665d93e97b1f41..0d8d843d2f34e589d5a190c8abc7ededff7262dc 100644 --- a/keyboards/keychron/v6/ansi_encoder/config.h +++ b/keyboards/keychron/v6/ansi_encoder/config.h @@ -37,9 +37,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED*/ diff --git a/keyboards/keychron/v6/ansi_encoder/info.json b/keyboards/keychron/v6/ansi_encoder/info.json index 1ac88337f32bb29fd1f41a1959757ef576ffade2..d6f46506ecaeebf6a8e07fb6b5f2ce1f4f90ba17 100644 --- a/keyboards/keychron/v6/ansi_encoder/info.json +++ b/keyboards/keychron/v6/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0361", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v6/iso_encoder/config.h b/keyboards/keychron/v6/iso_encoder/config.h index 567db0d7b57b33a4c7827f28a44ef20eeb5c8ec3..6e8069f7ece31d5b035123e7e04a4f653e510dcd 100644 --- a/keyboards/keychron/v6/iso_encoder/config.h +++ b/keyboards/keychron/v6/iso_encoder/config.h @@ -37,9 +37,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { C14 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED*/ diff --git a/keyboards/keychron/v6/iso_encoder/info.json b/keyboards/keychron/v6/iso_encoder/info.json index f0e4a3d4f2d16d51f8007cfe3fbafc9ce6d613aa..d8f86e5aa0b85e6268867e2d4899ea1095a9d76f 100644 --- a/keyboards/keychron/v6/iso_encoder/info.json +++ b/keyboards/keychron/v6/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0363", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "A2"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v8/ansi_encoder/config.h b/keyboards/keychron/v8/ansi_encoder/config.h index 6d749eed3757b87de7384c72771e79b8b5127cc7..57b9bd02707255057bba07dd0f8126464c8ac03d 100644 --- a/keyboards/keychron/v8/ansi_encoder/config.h +++ b/keyboards/keychron/v8/ansi_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v8/ansi_encoder/info.json b/keyboards/keychron/v8/ansi_encoder/info.json index c33b8955e852948c247cb26b5c3e39f5775547f3..f6a9de655b499002b376ebfca239bdbf39623254 100644 --- a/keyboards/keychron/v8/ansi_encoder/info.json +++ b/keyboards/keychron/v8/ansi_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0381", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keychron/v8/iso_encoder/config.h b/keyboards/keychron/v8/iso_encoder/config.h index b460669c2453de6c90ea693b2352795526c60bda..0bb4fbf8217e95f396466a6656b0a1f1e500e1d5 100644 --- a/keyboards/keychron/v8/iso_encoder/config.h +++ b/keyboards/keychron/v8/iso_encoder/config.h @@ -22,9 +22,6 @@ #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) /* Encoder Configuration */ -#define ENCODERS_PAD_A { A10 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define ENCODER_DEFAULT_POS 0x3 /* Enable caps-lock LED */ diff --git a/keyboards/keychron/v8/iso_encoder/info.json b/keyboards/keychron/v8/iso_encoder/info.json index ad546d0e3303e267c60478eb3f8e81d0d59cd957..2abaeda111f2a03642c7246f2463719bc94637d1 100644 --- a/keyboards/keychron/v8/iso_encoder/info.json +++ b/keyboards/keychron/v8/iso_encoder/info.json @@ -8,6 +8,11 @@ "pid": "0x0383", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A10", "pin_b": "B5"} + ] + }, "processor": "STM32L432", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/keyhive/absinthe/config.h b/keyboards/keyhive/absinthe/config.h index e8e33187d9fc8e38535b8aeaf42eef8f9574250e..0c7fe33f6bae4adb2e17ecd37715a70f6e40d9e0 100644 --- a/keyboards/keyhive/absinthe/config.h +++ b/keyboards/keyhive/absinthe/config.h @@ -31,9 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D2, D1, B6, D4, C6, D7, E6, B4, B5 } #define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, B2, D3, D0 } -#define ENCODERS_PAD_A { B7 } -#define ENCODERS_PAD_B { D5 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keyhive/absinthe/info.json b/keyboards/keyhive/absinthe/info.json index 7739f4f17157432f2cfc8e0a66f7259af9814c08..336707f23920504a200bbe120c787599ad68de04 100644 --- a/keyboards/keyhive/absinthe/info.json +++ b/keyboards/keyhive/absinthe/info.json @@ -8,6 +8,11 @@ "pid": "0xFEED", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "D5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/keyhive/uno/rev2/config.h b/keyboards/keyhive/uno/rev2/config.h index b9e3a702861d2ebfeb2019bea0308a62fcfcc4bb..e940f5fa057bef95c21a6263cb8384dbf95c5f3f 100644 --- a/keyboards/keyhive/uno/rev2/config.h +++ b/keyboards/keyhive/uno/rev2/config.h @@ -18,10 +18,6 @@ #define RGBLIGHT_EFFECT_RAINBOW_MOOD -/* ENCODER */ -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } - #ifdef RGBLIGHT_ENABLE #define RGB_DI_PIN D1 #define RGBLED_NUM 1 diff --git a/keyboards/keyhive/uno/rev2/info.json b/keyboards/keyhive/uno/rev2/info.json index 2ea14e8aeb7c49cc49c2fa483c6b03d44121c8f4..66e0ca20e04d86f59de5b9eab56fe8f33fb6f54f 100644 --- a/keyboards/keyhive/uno/rev2/info.json +++ b/keyboards/keyhive/uno/rev2/info.json @@ -3,6 +3,11 @@ "usb": { "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/keyprez/bison/config.h b/keyboards/keyprez/bison/config.h index 28e823f11f1c61ab09ff3956d68286b543f9ef9b..ba68e0d9761a16da26ece7e4d9edb50c401b98d0 100644 --- a/keyboards/keyprez/bison/config.h +++ b/keyboards/keyprez/bison/config.h @@ -34,12 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B5 } -#define ENCODERS_PAD_A_RIGHT { B5 } -#define ENCODERS_PAD_B_RIGHT { B6 } -#define ENCODER_RESOLUTION 4 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/keyprez/bison/info.json b/keyboards/keyprez/bison/info.json index 5c33dc5fa67d009ad1ec5a167c2b470bad355610..a18beb8305c3fcfce97b98fe49df3539ad1d92af 100644 --- a/keyboards/keyprez/bison/info.json +++ b/keyboards/keyprez/bison/info.json @@ -8,8 +8,20 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "split": { - "soft_serial_pin": "D0" + "soft_serial_pin": "D0", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B6"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/keyprez/corgi/config.h b/keyboards/keyprez/corgi/config.h index ac78581c42ec8eb1f6ededd29df20d51a7d42d2e..081e14372dbf85bbc7586eeb77499dbdae248169 100644 --- a/keyboards/keyprez/corgi/config.h +++ b/keyboards/keyprez/corgi/config.h @@ -28,10 +28,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D4 } -#define ENCODER_RESOLUTION 4 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/keyprez/corgi/info.json b/keyboards/keyprez/corgi/info.json index daaacae394e698b2280553dd143c30cf3bca1851..f130ae59193df7f696c53cf188418f591bd6dd65 100644 --- a/keyboards/keyprez/corgi/info.json +++ b/keyboards/keyprez/corgi/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D4"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 0, diff --git a/keyboards/keyprez/rhino/config.h b/keyboards/keyprez/rhino/config.h index 1b972e7b602e1c0a38c9fd166c65f4f4f5ab6ddc..3ea5c1384d6f1b6689647278d230a6d316860e0f 100644 --- a/keyboards/keyprez/rhino/config.h +++ b/keyboards/keyprez/rhino/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } -#define ENCODER_RESOLUTION 4 - #define AUDIO_PIN C6 #define MUSIC_MAP diff --git a/keyboards/keyprez/rhino/info.json b/keyboards/keyprez/rhino/info.json index b203dc23d704ec5f9e8bbbb3704126455975e5d2..f92ce7b0b2266513d3fa71eed9b41cd226487d99 100644 --- a/keyboards/keyprez/rhino/info.json +++ b/keyboards/keyprez/rhino/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 2, diff --git a/keyboards/keyprez/unicorn/config.h b/keyboards/keyprez/unicorn/config.h index d5badd4ae15c73cfdf3756844018ccf3eb7e20d2..80747b54be3bb4127dcd33edb8e7890fca2be13b 100644 --- a/keyboards/keyprez/unicorn/config.h +++ b/keyboards/keyprez/unicorn/config.h @@ -43,10 +43,3 @@ //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D4 } -#define ENCODER_RESOLUTIONS { 4 } -#define ENCODERS_PAD_A_RIGHT { D2 } -#define ENCODERS_PAD_B_RIGHT { D4 } -#define ENCODER_RESOLUTIONS_RIGHT {4} diff --git a/keyboards/keyprez/unicorn/info.json b/keyboards/keyprez/unicorn/info.json index 03de7b5c8c652a27ab07ef0b4763b829ced653fb..e3afebbc0f69dcd41274d9268166b96511b39bf2 100644 --- a/keyboards/keyprez/unicorn/info.json +++ b/keyboards/keyprez/unicorn/info.json @@ -8,6 +8,11 @@ "pid": "0x7563", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D4"} + ] + }, "split": { "soft_serial_pin": "D0" }, diff --git a/keyboards/keysofkings/twokey/config.h b/keyboards/keysofkings/twokey/config.h index 3fba4f8efa6e07bda1e7c91992fdd7f78e4025d3..21661d533d36537c4d9cac5d6bfa33c7107af66a 100755 --- a/keyboards/keysofkings/twokey/config.h +++ b/keyboards/keysofkings/twokey/config.h @@ -21,11 +21,6 @@ #define MATRIX_ROW_PINS { B4, B5 } #define MATRIX_COL_PINS { B3, B2 } - -#define ENCODERS_PAD_A { D7 } -#define ENCODERS_PAD_B { E6 } -#define ENCODER_RESOLUTION 1 - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/keysofkings/twokey/info.json b/keyboards/keysofkings/twokey/info.json index 86e3a070e90914ade257e23703ed493c45962959..910d8cc0eff0380486f222aa11ea87c69c279ce9 100644 --- a/keyboards/keysofkings/twokey/info.json +++ b/keyboards/keysofkings/twokey/info.json @@ -8,6 +8,11 @@ "pid": "0xAE12", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "E6", "resolution": 1} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/keystonecaps/gameroyadvance/config.h b/keyboards/keystonecaps/gameroyadvance/config.h index 1aa7ff33ff4c64a416e860ea96ed113dd31d2766..75b25e02c374537818109509d8ea52c2a039de20 100644 --- a/keyboards/keystonecaps/gameroyadvance/config.h +++ b/keyboards/keystonecaps/gameroyadvance/config.h @@ -23,10 +23,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS { D4, D0, D1, C6, D7, E6, F4, B2, B6 } #define MATRIX_ROW_PINS_RIGHT { D7, E6, B4, B5, B6 } #define MATRIX_COL_PINS_RIGHT { C6, D4, D0, D1, B1, F7, F4, F5, F6 } -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B4 } -#define ENCODERS_PAD_A_RIGHT { B3 } -#define ENCODERS_PAD_B_RIGHT { B2 } /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW @@ -53,5 +49,4 @@ along with this program. If not, see . #define RGBLIGHT_HUE_STEP 8 #define RGBLIGHT_SAT_STEP 8 #define RGBLIGHT_VAL_STEP 8 -#define ENCODER_RESOLUTION 4 #endif diff --git a/keyboards/keystonecaps/gameroyadvance/info.json b/keyboards/keystonecaps/gameroyadvance/info.json index 703c6a864a6640f6f1d97a19ba91892f491dd3cb..7a968deded9d783f833201ec253c8b3002149074 100644 --- a/keyboards/keystonecaps/gameroyadvance/info.json +++ b/keyboards/keystonecaps/gameroyadvance/info.json @@ -8,8 +8,20 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B4"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/kikoslab/ellora65/config.h b/keyboards/kikoslab/ellora65/config.h index cc87fc39f7992e5a2481175404348be1439aeaef..1243e775d310b235925927da71262c0c04a56f65 100644 --- a/keyboards/kikoslab/ellora65/config.h +++ b/keyboards/kikoslab/ellora65/config.h @@ -26,9 +26,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B0 } -#define ENCODERS_PAD_B { B1 } - /*RGB TINGS*/ #define RGB_DI_PIN E6 #define RGBLED_NUM 12 diff --git a/keyboards/kikoslab/ellora65/info.json b/keyboards/kikoslab/ellora65/info.json index e143889119a33d13a73edd768b27546eea9f99d1..2fae7509853429cde4e1a09d6af5f1724347c56a 100644 --- a/keyboards/kikoslab/ellora65/info.json +++ b/keyboards/kikoslab/ellora65/info.json @@ -8,6 +8,11 @@ "pid": "0xE88F", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "bootmagic": { "matrix": [1, 0] }, diff --git a/keyboards/kikoslab/kl90/config.h b/keyboards/kikoslab/kl90/config.h index ffae7d10fcfd961c6bdfc340a3041cfb2314eff3..f5f54eee2c3290c42faabb8f12969ab578bf59dc 100644 --- a/keyboards/kikoslab/kl90/config.h +++ b/keyboards/kikoslab/kl90/config.h @@ -26,9 +26,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { A3, C3 } -#define ENCODERS_PAD_B { A4, C4 } - #define EMCODER_DIRECTION_FLIP /*EEPROM for via*/ diff --git a/keyboards/kikoslab/kl90/info.json b/keyboards/kikoslab/kl90/info.json index 7caa9824b05d6f3d439341edf20c4bb71b4585e7..f063fd2323f283ad06c5e841fff646fdff0a55f8 100644 --- a/keyboards/kikoslab/kl90/info.json +++ b/keyboards/kikoslab/kl90/info.json @@ -8,6 +8,12 @@ "pid": "0xEA53", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A3", "pin_b": "A4"}, + {"pin_a": "C3", "pin_b": "C4"} + ] + }, "processor": "at90usb1286", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/kingly_keys/ave/config.h b/keyboards/kingly_keys/ave/config.h index adee0a4d10abb248e83e723db95bce9de06c6378..fadfdae7150f15c3858e32bc6cb85f2ecb1c7017 100644 --- a/keyboards/kingly_keys/ave/config.h +++ b/keyboards/kingly_keys/ave/config.h @@ -17,10 +17,6 @@ #pragma once - -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B1 } - #define MATRIX_ROW_PINS { B3, F4, F7, F6, F5 } #define MATRIX_COL_PINS { C7, C6, B6, B5, B4, D7, D6, D4, D5, D3, D2, D1, D0} diff --git a/keyboards/kingly_keys/ave/ortho/info.json b/keyboards/kingly_keys/ave/ortho/info.json index f9344727c11e3666ba36dd513e174e5868b02563..cdd3f418354042da21f0570e11eedba62724f7ae 100644 --- a/keyboards/kingly_keys/ave/ortho/info.json +++ b/keyboards/kingly_keys/ave/ortho/info.json @@ -8,6 +8,11 @@ "pid": "0x1225", "device_version": "0.1.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/kingly_keys/ave/staggered/info.json b/keyboards/kingly_keys/ave/staggered/info.json index 9b0d9cf0c1c855c5b2d248ed473694702dd1f26d..2e9c83df4cbcffbfde9b93b7637ca355f04dd41e 100644 --- a/keyboards/kingly_keys/ave/staggered/info.json +++ b/keyboards/kingly_keys/ave/staggered/info.json @@ -8,6 +8,11 @@ "pid": "0x1225", "device_version": "0.1.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/kingly_keys/romac_plus/config.h b/keyboards/kingly_keys/romac_plus/config.h index 04e5cf4f5a6f7083af300f60c8c0d40d7127ece7..8392caa689041c5cd35b1877ef714ad669d597fa 100644 --- a/keyboards/kingly_keys/romac_plus/config.h +++ b/keyboards/kingly_keys/romac_plus/config.h @@ -5,9 +5,6 @@ #define MATRIX_ROW_PINS { C6, D4, D2, D3 } #define MATRIX_COL_PINS { F6, F5, F4 } -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/kingly_keys/romac_plus/info.json b/keyboards/kingly_keys/romac_plus/info.json index b9ffc07076694520afe56dbdd6cdad31f5eeccbd..a93fa6496ba319cc4031e33461e36bcaef059fe5 100644 --- a/keyboards/kingly_keys/romac_plus/info.json +++ b/keyboards/kingly_keys/romac_plus/info.json @@ -8,6 +8,11 @@ "pid": "0x0002", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/kingly_keys/ropro/config.h b/keyboards/kingly_keys/ropro/config.h index 51a108cd7ed2312cc49cd3062cad4e3ea75ff539..d1e5d913403e51747830e6802f294f589d65e0e2 100644 --- a/keyboards/kingly_keys/ropro/config.h +++ b/keyboards/kingly_keys/ropro/config.h @@ -16,10 +16,6 @@ * along with this program. If not, see .#pragma once */ - -#define ENCODERS_PAD_A { B7 } -#define ENCODERS_PAD_B { D5 } - /* key matrix pins */ #define MATRIX_ROW_PINS { F4, F5, F6, F7, B1, F1, NO_PIN } #define MATRIX_COL_PINS { F0, D1, D0, D4, C6, D7, E6, B4, B5, B3, B2, B6, D2, C7 } diff --git a/keyboards/kingly_keys/ropro/info.json b/keyboards/kingly_keys/ropro/info.json index b9150cbcfa1498988545940a169587caa0972616..b2d3cf21e5bde92a857edb0ff8c961fd27d7e030 100644 --- a/keyboards/kingly_keys/ropro/info.json +++ b/keyboards/kingly_keys/ropro/info.json @@ -8,6 +8,11 @@ "pid": "0x0002", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "D5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/kingly_keys/soap/config.h b/keyboards/kingly_keys/soap/config.h index 012c6a923937c2695debee0384ab1d79936be62f..3127ee94112eecb4db4878836c5e06f705ae9066 100644 --- a/keyboards/kingly_keys/soap/config.h +++ b/keyboards/kingly_keys/soap/config.h @@ -14,10 +14,6 @@ * along with this program. If not, see .#pragma once */ - -#define ENCODERS_PAD_A { D6 } -#define ENCODERS_PAD_B { D7 } - /* key matrix pins */ #define MATRIX_ROW_PINS { C7, C6 } #define MATRIX_COL_PINS { F4, F1, F0, D5 } diff --git a/keyboards/kingly_keys/soap/info.json b/keyboards/kingly_keys/soap/info.json index 2caa2c27b63ab9d091416528242a5bdff6b39525..b910faac329a04d912a7dc33fcbcfbc7aab67fc5 100644 --- a/keyboards/kingly_keys/soap/info.json +++ b/keyboards/kingly_keys/soap/info.json @@ -8,6 +8,11 @@ "pid": "0x0003", "device_version": "0.0.4" }, + "encoder": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/kiwikeebs/macro/config.h b/keyboards/kiwikeebs/macro/config.h index 2e49fafd4d84762a020c6e06f7b0b20cdcc62ea5..3d06b6bc041462984fcfc6a61052fa81e27a16b8 100644 --- a/keyboards/kiwikeebs/macro/config.h +++ b/keyboards/kiwikeebs/macro/config.h @@ -34,9 +34,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/kiwikeebs/macro/info.json b/keyboards/kiwikeebs/macro/info.json index 223bd710352c7d3ab53c7dc01325400a1575f9f8..ae6ed513a2794b01b6a9864dcfb3cba452c3c48a 100644 --- a/keyboards/kiwikeebs/macro/info.json +++ b/keyboards/kiwikeebs/macro/info.json @@ -8,6 +8,11 @@ "pid": "0x4712", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/kiwikeebs/macro_v2/config.h b/keyboards/kiwikeebs/macro_v2/config.h index f1dc869ab07b417d228418ec19a7a239d64250b0..d5fe49330f1f7742714096d5b7c51d2ee95f2bcf 100644 --- a/keyboards/kiwikeebs/macro_v2/config.h +++ b/keyboards/kiwikeebs/macro_v2/config.h @@ -34,9 +34,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D7 } -#define ENCODERS_PAD_B { D6 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/kiwikeebs/macro_v2/info.json b/keyboards/kiwikeebs/macro_v2/info.json index c83e861c72fb5e4f06026cdb70f2035e9dc4233e..168b3ba447f8bb7a1cf0a215e755cf78f9af1194 100644 --- a/keyboards/kiwikeebs/macro_v2/info.json +++ b/keyboards/kiwikeebs/macro_v2/info.json @@ -8,6 +8,11 @@ "pid": "0x4712", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "D6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/kiwikey/borderland/config.h b/keyboards/kiwikey/borderland/config.h index 70c80d42f6f6f97d27944ab6bee4a6e7ca0bbf4f..a698476a5f5839b2f5d3cf05ba60ccb061fe5000 100644 --- a/keyboards/kiwikey/borderland/config.h +++ b/keyboards/kiwikey/borderland/config.h @@ -20,9 +20,6 @@ /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 #define RGB_DI_PIN B2 diff --git a/keyboards/kiwikey/borderland/info.json b/keyboards/kiwikey/borderland/info.json index d88a8b20bfb0a52961f35c3aa2957b787110aac0..84b17c438504e02b44f75d851031d3ae831e230b 100644 --- a/keyboards/kiwikey/borderland/info.json +++ b/keyboards/kiwikey/borderland/info.json @@ -8,6 +8,11 @@ "pid": "0x424C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/knobgoblin/config.h b/keyboards/knobgoblin/config.h index 5ace53258ee7f6bbb6d2a0599f69c56a7e73e376..435c727db5d8e09d6934ed983ae60d1755850dfd 100644 --- a/keyboards/knobgoblin/config.h +++ b/keyboards/knobgoblin/config.h @@ -21,9 +21,6 @@ #define MATRIX_ROW_PINS { D4, B6, B2, B3, B1 } #define MATRIX_COL_PINS { B5, B4, E6, D7, C6 } -#define ENCODERS_PAD_A { F7, F5 } -#define ENCODERS_PAD_B { F6, F4 } - #define OLED_TIMEOUT 180000 /* COL2ROW or ROW2COL */ diff --git a/keyboards/knobgoblin/info.json b/keyboards/knobgoblin/info.json index d80aef23131374b67c64ab9d995e229b6b8014d3..c0d8de34e9cbfcd1abc0592ea1e695369be3e5dd 100644 --- a/keyboards/knobgoblin/info.json +++ b/keyboards/knobgoblin/info.json @@ -8,6 +8,12 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F7", "pin_b": "F6"}, + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/kprepublic/bm60hsrgb_ec/rev1/config.h b/keyboards/kprepublic/bm60hsrgb_ec/rev1/config.h index 375e54504c02632b95e83ccc05ea6a967162f7ef..8a5d4a50bc528f64c0d873cd300554ba2dba23e0 100644 --- a/keyboards/kprepublic/bm60hsrgb_ec/rev1/config.h +++ b/keyboards/kprepublic/bm60hsrgb_ec/rev1/config.h @@ -16,11 +16,6 @@ #pragma once - -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F5 } -#define ENCODER_RESOLUTION 2 - /* * Keyboard Matrix Assignments * diff --git a/keyboards/kprepublic/bm60hsrgb_ec/rev1/info.json b/keyboards/kprepublic/bm60hsrgb_ec/rev1/info.json index 3e0084c1a7d956bd5927b4a5e4a56a792a2cb626..a255a480b3e0c7f9813006fee8947af2de7aa905 100644 --- a/keyboards/kprepublic/bm60hsrgb_ec/rev1/info.json +++ b/keyboards/kprepublic/bm60hsrgb_ec/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0xEF9C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h b/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h index b180e24853833cc83c58a1e2c0b7b5c8efa8a9e2..b70904fae3ea60b24b3f4f9b7d35b4d1ace2d08b 100644 --- a/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h +++ b/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h @@ -15,11 +15,6 @@ */ #pragma once - -#define ENCODERS_PAD_A { F1 } -#define ENCODERS_PAD_B { F4 } -#define ENCODER_RESOLUTION 2 - /* * Keyboard Matrix Assignments * diff --git a/keyboards/kprepublic/bm60hsrgb_ec/rev2/info.json b/keyboards/kprepublic/bm60hsrgb_ec/rev2/info.json index cb75c22dd60ee54344afdf1cc159e1850a796def..83efb7b5e771d0a79717b76f4e20de5afa89d67c 100644 --- a/keyboards/kprepublic/bm60hsrgb_ec/rev2/info.json +++ b/keyboards/kprepublic/bm60hsrgb_ec/rev2/info.json @@ -8,6 +8,11 @@ "pid": "0x1124", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "F1", "pin_b": "F4", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 3, diff --git a/keyboards/latincompass/latinpad/config.h b/keyboards/latincompass/latinpad/config.h index 1b0881a0d5d00c2f45af5525d0af886a57c1d13b..bfbdf01cd743844aa01e18f661284884b1ab570a 100644 --- a/keyboards/latincompass/latinpad/config.h +++ b/keyboards/latincompass/latinpad/config.h @@ -77,8 +77,3 @@ along with this program. If not, see .*/ #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH #define OLED_FONT_H "./lib/glcdfont.c" - -#define ENCODERS_PAD_A { B4, B5 } -#define ENCODERS_PAD_B { B2, B6 } - -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/latincompass/latinpad/info.json b/keyboards/latincompass/latinpad/info.json index 4ab11d8cfbaecf463b41f686b50c8df2465eca08..b2f4199dfd0c4e3b6d1d7aab7abeb50a12e7eec2 100644 --- a/keyboards/latincompass/latinpad/info.json +++ b/keyboards/latincompass/latinpad/info.json @@ -8,6 +8,12 @@ "pid": "0x6C70", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B2"}, + {"pin_a": "B5", "pin_b": "B6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/latincompass/latinpadble/config.h b/keyboards/latincompass/latinpadble/config.h index 7b6ac20389227de95cef08c4bd23d2cd440341f4..fe0ab9999b7b6cb067361b65251ef5934b36d46b 100644 --- a/keyboards/latincompass/latinpadble/config.h +++ b/keyboards/latincompass/latinpadble/config.h @@ -84,9 +84,4 @@ along with this program. If not, see .*/ #define OLED_FONT_H "./lib/glcdfont.c" -#define ENCODERS_PAD_A { C7 } -#define ENCODERS_PAD_B { F7 } - -#define ENCODER_RESOLUTION 4 - #define VIA_HAS_BROKEN_KEYCODES diff --git a/keyboards/latincompass/latinpadble/info.json b/keyboards/latincompass/latinpadble/info.json index ed82794f821b763a79f57b9f1000576b04d2f57d..266f09d8a06b96aa64d0fe787ecf4ec0a5559416 100644 --- a/keyboards/latincompass/latinpadble/info.json +++ b/keyboards/latincompass/latinpadble/info.json @@ -8,6 +8,11 @@ "pid": "0x7C98", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "F7"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/leafcutterlabs/bigknob/config.h b/keyboards/leafcutterlabs/bigknob/config.h index 8a2391095653b35a28f6180d94317d6de1a527ec..3c6bf4e8a99b6c6a63eb262fe096cbfa495c8c88 100644 --- a/keyboards/leafcutterlabs/bigknob/config.h +++ b/keyboards/leafcutterlabs/bigknob/config.h @@ -17,11 +17,6 @@ along with this program. If not, see . #pragma once -/* rotary encoder 1,2,3 closest to usb port is 0*/ -#define ENCODERS_PAD_A { D0} -#define ENCODERS_PAD_B { D2} -#define ENCODER_RESOLUTION 4 //default/suggested - /* ws2812 RGB LED */ #define RGB_DI_PIN C7 //D3 - underglow C7 - backlight #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/leafcutterlabs/bigknob/info.json b/keyboards/leafcutterlabs/bigknob/info.json index 2a8830c308ccc53823adcb1ba46a2e87f204a299..55d5fe13ee9337e129b30880e25fa94a80b52711 100644 --- a/keyboards/leafcutterlabs/bigknob/info.json +++ b/keyboards/leafcutterlabs/bigknob/info.json @@ -8,6 +8,11 @@ "pid": "0x0007", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D2"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/lily58/glow_enc/config.h b/keyboards/lily58/glow_enc/config.h index 443139c82465320c12b0d4743313f9ed7116139b..d89148dbbf50d523100b2b26c5da0174e5d03c5c 100644 --- a/keyboards/lily58/glow_enc/config.h +++ b/keyboards/lily58/glow_enc/config.h @@ -31,8 +31,3 @@ along with this program. If not, see . #define RGBLED_SPLIT { 36, 36 } #define RGBLIGHT_SPLIT #define RGBLIGHT_LIMIT_VAL 120 - -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { D4 } -#define ENCODERS_PAD_A_RIGHT { D4 } -#define ENCODERS_PAD_B_RIGHT { F5 } diff --git a/keyboards/lily58/glow_enc/info.json b/keyboards/lily58/glow_enc/info.json index ef53c7f2d5bd8bea24684cf41d3876c6f349340d..bc2eae23da86ceacd4ce806f10790f6441e2122e 100644 --- a/keyboards/lily58/glow_enc/info.json +++ b/keyboards/lily58/glow_enc/info.json @@ -8,8 +8,20 @@ "pid": "0x0059", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "D4"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "D4", "pin_b": "F5"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/lily58/light/config.h b/keyboards/lily58/light/config.h index 0b11be778a6dc09914c34956ffd43c3633d697b0..3a0780e0a6620a2d473a755ae37e0819e50101aa 100644 --- a/keyboards/lily58/light/config.h +++ b/keyboards/lily58/light/config.h @@ -29,8 +29,3 @@ along with this program. If not, see . #define RGBLED_NUM 70 #define RGBLIGHT_SPLIT #define RGBLIGHT_LIMIT_VAL 120 - -#define ENCODERS_PAD_A { F4 } -#define ENCODERS_PAD_B { F5 } -#define ENCODERS_PAD_A_RIGHT { F5 } -#define ENCODERS_PAD_B_RIGHT { F4 } diff --git a/keyboards/lily58/light/info.json b/keyboards/lily58/light/info.json index 18e16cd469388009ddecf5f4581f72808ff045a1..82e9affbd04347a2c09aec90c2e81b7c8f50f60f 100644 --- a/keyboards/lily58/light/info.json +++ b/keyboards/lily58/light/info.json @@ -8,8 +8,20 @@ "pid": "0x4C4C", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/lime/rev1/config.h b/keyboards/lime/rev1/config.h index 8ca3fd28b96706497668c9f9b124fd7cb308e023..841a7bb7646123a90ed07a869efe2b7c78dbdd9c 100644 --- a/keyboards/lime/rev1/config.h +++ b/keyboards/lime/rev1/config.h @@ -23,15 +23,6 @@ #define TAPPING_TERM 100 -/* encoder support */ -#ifdef ENCODER_ENABLE -# define ENCODERS_PAD_A { F5 } -# define ENCODERS_PAD_B { F4 } -# define ENCODERS_PAD_A_RIGHT { F4 } -# define ENCODERS_PAD_B_RIGHT { F5 } -# define ENCODER_RESOLUTION 2 -#endif - /* joystick support */ #ifdef JOYSTICK_ENABLE # define JOYSTICK_AXIS_COUNT 2 diff --git a/keyboards/lime/rev1/info.json b/keyboards/lime/rev1/info.json index 4daceb8e61f4c7103dd39120b7645bd0a51c71cb..fb05828f6d5fbf971c98285a7f920989ccee858e 100644 --- a/keyboards/lime/rev1/info.json +++ b/keyboards/lime/rev1/info.json @@ -8,8 +8,20 @@ "pid": "0x2784", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4", "resolution": 2} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5", "resolution": 2} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/linworks/whale75/config.h b/keyboards/linworks/whale75/config.h index 9508aeed575ce680ffee779474deac63537fb68f..19580b94640f3ec02826a75dd344f80f4e18e58f 100644 --- a/keyboards/linworks/whale75/config.h +++ b/keyboards/linworks/whale75/config.h @@ -44,11 +44,4 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_RAINBOW_MOOD #define RGBLIGHT_EFFECT_RAINBOW_SWIRL - -/* Rotary encoder - set the resolution fitting your encoder. -Most will need a value of 4. If 1 encoder click results in 2 keycodes sent -double the value. If you need 2 clicks for 1 keycode, half it */ -#define ENCODER_RESOLUTION 2 -#define ENCODERS_PAD_A { A15 } -#define ENCODERS_PAD_B { A14 } #define TAP_CODE_DELAY 10 diff --git a/keyboards/linworks/whale75/info.json b/keyboards/linworks/whale75/info.json index 24cb27f9291313ce8a51ed3671a69372ec080f0b..b84425f6f6999414dca693e5c5e4fc9a7548520d 100644 --- a/keyboards/linworks/whale75/info.json +++ b/keyboards/linworks/whale75/info.json @@ -7,6 +7,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A15", "pin_b": "A14", "resolution": 2} + ] + }, "backlight": { "pin": "A10", "levels": 5, diff --git a/keyboards/lizard_trick/tenkey_plusplus/config.h b/keyboards/lizard_trick/tenkey_plusplus/config.h index ec3b2e6c6dabafa52663eef0c359e245a0789372..c2d33c6ae7d39173fcea6fb7b734638b87e6279c 100644 --- a/keyboards/lizard_trick/tenkey_plusplus/config.h +++ b/keyboards/lizard_trick/tenkey_plusplus/config.h @@ -32,11 +32,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B7, D4, B5, B6, C6, C7 } #define MATRIX_COL_PINS { D5, D3, D2, F7 } -#define ENCODERS_PAD_A \ - { B4, F0, F4 } -#define ENCODERS_PAD_B \ - { D7, E6, F1 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/lizard_trick/tenkey_plusplus/info.json b/keyboards/lizard_trick/tenkey_plusplus/info.json index 376f2dcf60fea37672fab5fcc3c1144043678129..eb8ef5e48d836b59f3d2a1ac2360236021dacbc5 100644 --- a/keyboards/lizard_trick/tenkey_plusplus/info.json +++ b/keyboards/lizard_trick/tenkey_plusplus/info.json @@ -8,6 +8,13 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "D7"}, + {"pin_a": "F0", "pin_b": "E6"}, + {"pin_a": "F4", "pin_b": "F1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/ll3macorn/bongopad/config.h b/keyboards/ll3macorn/bongopad/config.h index a165b3cb9d7559833f6e4733ae2dbaa2d846be87..1ea347bfd61b642b0372abcdde2e3a453f5fc5f1 100644 --- a/keyboards/ll3macorn/bongopad/config.h +++ b/keyboards/ll3macorn/bongopad/config.h @@ -13,10 +13,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* encoders */ -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B3 } - /* misc */ #define LAYER_STATE_8BIT #define NO_ACTION_TAPPING diff --git a/keyboards/ll3macorn/bongopad/info.json b/keyboards/ll3macorn/bongopad/info.json index faed6f473caff0ffe1bbf1d4ed2b3fe19e6c1819..f24e1a3f6f0f039aa38c46bc76086e8a171d97f3 100644 --- a/keyboards/ll3macorn/bongopad/info.json +++ b/keyboards/ll3macorn/bongopad/info.json @@ -8,6 +8,11 @@ "pid": "0x2949", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B3"} + ] + }, "bootmagic": { "matrix": [1, 0] }, diff --git a/keyboards/lw67/config.h b/keyboards/lw67/config.h index c3aa00f56e2c859beea118151aba20bae64543f3..4ca1261982394a07e63f12d324a682430783c505 100644 --- a/keyboards/lw67/config.h +++ b/keyboards/lw67/config.h @@ -21,11 +21,6 @@ #define MATRIX_ROW_PINS { E6, B7, D0, D1, D2 } #define MATRIX_COL_PINS { D3, D5, D4, D6, D7, B4, B5, B6, C6, C7, F7, F6, F5, F4, B0, B1 } -/*ENCODER*/ -#define ENCODERS_PAD_A { F0 } -#define ENCODERS_PAD_B { F1 } -#define ENCODER_RESOLUTION 4 - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/lw67/info.json b/keyboards/lw67/info.json index 29579215dbb39a72e6340f13d4cb2d8c4cd14c45..f443702d69d66ca5b14ebab72ddfda3862852ae3 100644 --- a/keyboards/lw67/info.json +++ b/keyboards/lw67/info.json @@ -8,6 +8,11 @@ "pid": "0x9998", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts":{ diff --git a/keyboards/lw75/config.h b/keyboards/lw75/config.h index 02e5be2413c73f669421f19d3f817a9bc068222f..77a51635b4500cc6e0912871c49fbdda338bcdbf 100644 --- a/keyboards/lw75/config.h +++ b/keyboards/lw75/config.h @@ -7,10 +7,6 @@ #define MATRIX_ROW_PINS { E6, B7, D0, D1, D2, B1 } #define MATRIX_COL_PINS { D3, D5, D4, D6, D7, B4, B5, B6, C6, C7, F7, F6, F5, F4, B0, B2 } -/*ENCODER*/ -#define ENCODERS_PAD_A { F0 } -#define ENCODERS_PAD_B { F1 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/lw75/info.json b/keyboards/lw75/info.json index ef55732d233f3928d998c00b185aed6042dd6a04..de5f70ca146a691975fe16656d91a9f9a1838c41 100644 --- a/keyboards/lw75/info.json +++ b/keyboards/lw75/info.json @@ -8,6 +8,11 @@ "pid": "0x1111", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts":{ diff --git a/keyboards/lyso1/lck75/config.h b/keyboards/lyso1/lck75/config.h index cad5a9321072cf46a10f29e3b327a8cecb9abb31..110d7ecfe9d47c87547a9eb27af3c07a421980aa 100644 --- a/keyboards/lyso1/lck75/config.h +++ b/keyboards/lyso1/lck75/config.h @@ -31,10 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { C2, C3, C7, C4, C6, C5 } #define MATRIX_COL_PINS { A0, B0, A1, B1, A2, B2, A3, B3, A4, B4, A5, A6, A7, D7, D6, D5 } -#define ENCODERS_PAD_B { D1 } -#define ENCODERS_PAD_A { D0 } -#define ENCODER_RESOLUTION 2 //default/suggested - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/lyso1/lck75/info.json b/keyboards/lyso1/lck75/info.json index 025f1fe168d51bd3acd96cf903f328431c0a3513..f3102475d92091c411ac86647cb01e0bd886c4d1 100644 --- a/keyboards/lyso1/lck75/info.json +++ b/keyboards/lyso1/lck75/info.json @@ -8,6 +8,11 @@ "pid": "0x6163", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0", "resolution": 2} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "layouts": { diff --git a/keyboards/macro1/config.h b/keyboards/macro1/config.h index e707daef079f6bf2458e936c3d0494d2ce76fc00..a03f212f374c86dfc29a3f7fb201e9d5fba8972f 100644 --- a/keyboards/macro1/config.h +++ b/keyboards/macro1/config.h @@ -21,11 +21,6 @@ #define MATRIX_ROW_PINS { E6, B7, D0, D1, D2, B3 } #define MATRIX_COL_PINS { D3, D4, D6, D7 } -/*ENCODER*/ -#define ENCODERS_PAD_A { F0 } -#define ENCODERS_PAD_B { F1 } -#define ENCODER_RESOLUTION 4 - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/macro1/info.json b/keyboards/macro1/info.json index c79e7bd4389577e1f4dd35a39e9bb1a57fb52f19..ae4de403109b20dec4e81095cf3078e7c095403f 100644 --- a/keyboards/macro1/info.json +++ b/keyboards/macro1/info.json @@ -8,6 +8,11 @@ "pid": "0x9999", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts":{ diff --git a/keyboards/macro3/config.h b/keyboards/macro3/config.h deleted file mode 100644 index 714f796f48fed11a3dd82646be51bc7008d6333b..0000000000000000000000000000000000000000 --- a/keyboards/macro3/config.h +++ /dev/null @@ -1,9 +0,0 @@ -/* Copyright 2020 David Philip Barr <@davidphilipbarr> - * Copyright 2021 @filterpaper - * SPDX-License-Identifier: GPL-2.0+ - */ - -#pragma once - -#define ENCODERS_PAD_A { D2, F7 } -#define ENCODERS_PAD_B { D3, F6 } diff --git a/keyboards/macro3/info.json b/keyboards/macro3/info.json index 89720d9b70d5301badf67bfafe106450f8b182ef..780dfca3036fd6e67c37d940adcff0238e7fd7ae 100644 --- a/keyboards/macro3/info.json +++ b/keyboards/macro3/info.json @@ -8,6 +8,12 @@ "pid": "0x3388", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"}, + {"pin_a": "F7", "pin_b": "F6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/macrocat/config.h b/keyboards/macrocat/config.h index f74f3d90552bf64c3ddfd879c4fda5ec95c78ced..0d14bca0ea4278dec6fbbceb28fab196cfa40ac1 100644 --- a/keyboards/macrocat/config.h +++ b/keyboards/macrocat/config.h @@ -3,8 +3,4 @@ #pragma once - -/* rotary encoder */ -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } #define ENCODER_SWITCH B7 diff --git a/keyboards/macrocat/info.json b/keyboards/macrocat/info.json index 421f1283e13d614bc2df52dc4b3f702c053a833d..47dbbc6d9a0627dbd0c83fd9df3b7d582f3f0a5d 100644 --- a/keyboards/macrocat/info.json +++ b/keyboards/macrocat/info.json @@ -24,6 +24,11 @@ "pid": "0x8086", "vid": "0x2022" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "layout_aliases": { "LAYOUT_numpad_4x4": "LAYOUT_ortho_4x4" }, diff --git a/keyboards/makrosu/config.h b/keyboards/makrosu/config.h index b07d3842a6b87d4441534279821324acf628b14c..c00353db8901d40f9239184ea60c49b41e5a5182 100644 --- a/keyboards/makrosu/config.h +++ b/keyboards/makrosu/config.h @@ -21,8 +21,6 @@ #define MATRIX_ROW_PINS { B6 } #define MATRIX_COL_PINS { B2, B3, B1, F7, F6, F5} -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { D1 } #define TAP_CODE_DELAY 10 /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/makrosu/info.json b/keyboards/makrosu/info.json index 9474d6c8041e83a50106fd2234d7691e146ea358..77974305e571bd556d13db99721571379c39978b 100644 --- a/keyboards/makrosu/info.json +++ b/keyboards/makrosu/info.json @@ -8,6 +8,11 @@ "pid": "0x8585", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "D1"} + ] + }, "bootmagic": { "matrix": [0, 5] }, diff --git a/keyboards/manyboard/macro/config.h b/keyboards/manyboard/macro/config.h index c21ce974cbce8c32046127f04d4bf783a63985d2..1839a1091d1b4844a94106d48cf70fab65b62107 100644 --- a/keyboards/manyboard/macro/config.h +++ b/keyboards/manyboard/macro/config.h @@ -21,10 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D0, D1, D2, D3 } #define MATRIX_COL_PINS { D4, D5, D6, D7 } -/*Encoder Pins*/ -#define ENCODERS_PAD_A { C6 } -#define ENCODERS_PAD_B { C7 } - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/manyboard/macro/info.json b/keyboards/manyboard/macro/info.json index f781e92265b6fe2d404fe545f75db6f877734ba3..cdf40f68015674e82b522d5385381a7c74f7d85e 100644 --- a/keyboards/manyboard/macro/info.json +++ b/keyboards/manyboard/macro/info.json @@ -8,6 +8,11 @@ "pid": "0x0015", "device_version": "1.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "C7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/marksard/leftover30/config.h b/keyboards/marksard/leftover30/config.h index ed8192061695cc34f9165e4e8840230b335572e4..bf7aa7f198df6a4c1c557cd6558273b379f90723 100644 --- a/keyboards/marksard/leftover30/config.h +++ b/keyboards/marksard/leftover30/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once - -/* Encoder */ -#define ENCODERS_PAD_A { F4 } -#define ENCODERS_PAD_B { F5 } -// #define ENCODER_DIRECTION_FLIP - /* * Keyboard Matrix Assignments * diff --git a/keyboards/marksard/leftover30/info.json b/keyboards/marksard/leftover30/info.json index 7c4a6b4345005b92ce7c5004b0c249b82326f87b..39de1d6bda0d25a9e26fdce7c883e38f2365a40a 100644 --- a/keyboards/marksard/leftover30/info.json +++ b/keyboards/marksard/leftover30/info.json @@ -8,6 +8,11 @@ "pid": "0xDFA8", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/matthewdias/m3n3van/config.h b/keyboards/matthewdias/m3n3van/config.h index 13d647105a6d8b0be41e8e0dc5e954aa9fef6e8c..81acfef553658ad5142931fdfa4a2f9ebbd3ca47 100644 --- a/keyboards/matthewdias/m3n3van/config.h +++ b/keyboards/matthewdias/m3n3van/config.h @@ -21,8 +21,6 @@ along with this program. If not, see . /* m3n3van PCB default pin-out */ #define MATRIX_ROW_PINS { B5, B6, C6, C7 } #define MATRIX_COL_PINS { F4, F5, F6, F1, F7, F0, E6, D3, D0, D1, D2, D4, D6 } -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { D7 } /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/matthewdias/m3n3van/info.json b/keyboards/matthewdias/m3n3van/info.json index bef63b4de0327c366bd21aedc95ccce94f40d424..ffe44159a0fe72fd5e8ffff23e7c0b07a89f29c2 100644 --- a/keyboards/matthewdias/m3n3van/info.json +++ b/keyboards/matthewdias/m3n3van/info.json @@ -8,6 +8,11 @@ "pid": "0x2323", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "D7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/maxr1998/pulse4k/config.h b/keyboards/maxr1998/pulse4k/config.h index dd2e02f98e98ee4ace6da1fbbe42286a7bbea52c..3756899498e2baf07c5cba4c2613a49f608c9cb2 100644 --- a/keyboards/maxr1998/pulse4k/config.h +++ b/keyboards/maxr1998/pulse4k/config.h @@ -25,11 +25,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Rotary encoders */ -#define ENCODERS_PAD_A { D2, F6 } -#define ENCODERS_PAD_B { D3, F5 } -#define ENCODER_RESOLUTION 4 - /* Combo setup */ #define COMBO_COUNT 1 #define COMBO_TERM 150 diff --git a/keyboards/maxr1998/pulse4k/info.json b/keyboards/maxr1998/pulse4k/info.json index 449a3fc0a52264425759d92bc14fb956a3a737b1..9db0307940a16ac4b53e8d56c71a63c5123d1fb3 100644 --- a/keyboards/maxr1998/pulse4k/info.json +++ b/keyboards/maxr1998/pulse4k/info.json @@ -8,6 +8,12 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"}, + {"pin_a": "F6", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mb44/config.h b/keyboards/mb44/config.h index 776c1311db3c8b2fad46390e3aebb96288cf022b..365fed73401f287d02dafe29f074af3ddc2ef962 100644 --- a/keyboards/mb44/config.h +++ b/keyboards/mb44/config.h @@ -33,7 +33,3 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW - -/*Encoder Definition*/ -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } diff --git a/keyboards/mb44/info.json b/keyboards/mb44/info.json index dce66f746a178598ce6f0731e77bee85f66b5443..865f05674f803a282143eec4b86089b6ee21cda4 100644 --- a/keyboards/mb44/info.json +++ b/keyboards/mb44/info.json @@ -8,6 +8,11 @@ "pid": "0x6D62", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mechanickeys/undead60m/config.h b/keyboards/mechanickeys/undead60m/config.h index 2f06367ab839bbcbbc06704cf129e6642bb8de06..c86a3af0f123013cd817c020c03db79e83c6cb78 100644 --- a/keyboards/mechanickeys/undead60m/config.h +++ b/keyboards/mechanickeys/undead60m/config.h @@ -49,8 +49,3 @@ #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE #endif - -/* Rotary encoder */ -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F5 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/mechanickeys/undead60m/info.json b/keyboards/mechanickeys/undead60m/info.json index c525db64202851f91a18b8c68c90b6bcbf5726e6..9bee50289c54732e15b30210260133f3cf8f71a3 100644 --- a/keyboards/mechanickeys/undead60m/info.json +++ b/keyboards/mechanickeys/undead60m/info.json @@ -8,6 +8,11 @@ "pid": "0x3C4D", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mechlovin/adelais/rgb_led/rev2/config.h b/keyboards/mechlovin/adelais/rgb_led/rev2/config.h index 9611ed6744fe41b87c2b0d5706265bd2dafdef94..d9d75a4b9e24a7b6c16699b367ca786991aefc76 100644 --- a/keyboards/mechlovin/adelais/rgb_led/rev2/config.h +++ b/keyboards/mechlovin/adelais/rgb_led/rev2/config.h @@ -91,8 +91,4 @@ #define RGB_MATRIX_DISABLE_KEYCODES -#define ENCODERS_PAD_A { A4 } -#define ENCODERS_PAD_B { A3 } -#define ENCODER_RESOLUTION 4 - #define TAP_CODE_DELAY 10 diff --git a/keyboards/mechlovin/adelais/rgb_led/rev2/info.json b/keyboards/mechlovin/adelais/rgb_led/rev2/info.json index b83a4828e3e12b119849c7203fa130ac7001f3d7..7dcd0f1765fa54faac502e524e83b3a3c80c19de 100644 --- a/keyboards/mechlovin/adelais/rgb_led/rev2/info.json +++ b/keyboards/mechlovin/adelais/rgb_led/rev2/info.json @@ -3,6 +3,11 @@ "usb": { "pid": "0xAEC2" }, + "encoder": { + "rotary": [ + {"pin_a": "A4", "pin_b": "A3"} + ] + }, "processor": "STM32F303", "board": "QMK_PROTON_C", "bootloader": "stm32-dfu", diff --git a/keyboards/mechlovin/adelais/rgb_led/rev3/config.h b/keyboards/mechlovin/adelais/rgb_led/rev3/config.h index faf032647fba9a9783688b1e5bf3c24ca634a81e..7457fd50a763adfa12301dbbecb7659d8a5857d0 100644 --- a/keyboards/mechlovin/adelais/rgb_led/rev3/config.h +++ b/keyboards/mechlovin/adelais/rgb_led/rev3/config.h @@ -113,9 +113,4 @@ along with this program. If not, see . #endif -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A { B12 } -#define ENCODERS_PAD_B { B13 } -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 -#endif diff --git a/keyboards/mechlovin/adelais/rgb_led/rev3/info.json b/keyboards/mechlovin/adelais/rgb_led/rev3/info.json index 89bf9abe9bb98b96e3dde02546964611af5afbbe..3f83750e3a85a67107848553038b8f21e3548c76 100644 --- a/keyboards/mechlovin/adelais/rgb_led/rev3/info.json +++ b/keyboards/mechlovin/adelais/rgb_led/rev3/info.json @@ -3,6 +3,11 @@ "usb": { "pid": "0xAEC3" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13"} + ] + }, "processor": "STM32F103", "bootloader": "stm32duino", "indicators": { diff --git a/keyboards/mechlovin/adelais/standard_led/arm/rev3/config.h b/keyboards/mechlovin/adelais/standard_led/arm/rev3/config.h index 69af2941a64515fb9364f4ecd449a6c1f6bd9788..254d20403810f355e7f439da3add2badc5cd1ae1 100644 --- a/keyboards/mechlovin/adelais/standard_led/arm/rev3/config.h +++ b/keyboards/mechlovin/adelais/standard_led/arm/rev3/config.h @@ -1,7 +1,3 @@ #pragma once -#define ENCODERS_PAD_A { A6, A4, B7 } -#define ENCODERS_PAD_B { A5, A3, B6 } -#define ENCODER_RESOLUTION 4 - #define TAP_CODE_DELAY 10 \ No newline at end of file diff --git a/keyboards/mechlovin/adelais/standard_led/arm/rev3/info.json b/keyboards/mechlovin/adelais/standard_led/arm/rev3/info.json index a8d21313a22eb35fb9aa48965f1d4d43ac38e8f9..60d20c4a29f9443abdac0bf6dab41234b6f2e6b3 100644 --- a/keyboards/mechlovin/adelais/standard_led/arm/rev3/info.json +++ b/keyboards/mechlovin/adelais/standard_led/arm/rev3/info.json @@ -2,6 +2,13 @@ "usb": { "pid": "0xAD02" }, + "encoder": { + "rotary": [ + {"pin_a": "A6", "pin_b": "A5"}, + {"pin_a": "A4", "pin_b": "A3"}, + {"pin_a": "B7", "pin_b": "B6"} + ] + }, "processor": "STM32F303", "board": "QMK_PROTON_C", "bootloader": "stm32-dfu" diff --git a/keyboards/mechlovin/adelais/standard_led/arm/rev4/config.h b/keyboards/mechlovin/adelais/standard_led/arm/rev4/config.h index 70fa00220b7f9dd6e87aeb76c5dd5f358511e7a2..7905be189159cc1d8e00ad561187710770291c78 100644 --- a/keyboards/mechlovin/adelais/standard_led/arm/rev4/config.h +++ b/keyboards/mechlovin/adelais/standard_led/arm/rev4/config.h @@ -16,8 +16,4 @@ along with this program. If not, see . */ #pragma once -#define ENCODERS_PAD_A { A6, A4, B7 } -#define ENCODERS_PAD_B { A5, A3, B6 } -#define ENCODER_RESOLUTION 4 - #define TAP_CODE_DELAY 10 \ No newline at end of file diff --git a/keyboards/mechlovin/adelais/standard_led/arm/rev4/info.json b/keyboards/mechlovin/adelais/standard_led/arm/rev4/info.json index f4c096143b448715342528bd936c4e09cfd540eb..925b7cd213eee180e5f72c43e0bfd3e7ad97f1c1 100644 --- a/keyboards/mechlovin/adelais/standard_led/arm/rev4/info.json +++ b/keyboards/mechlovin/adelais/standard_led/arm/rev4/info.json @@ -1,5 +1,12 @@ { "usb": { "pid": "0xAD03" + }, + "encoder": { + "rotary": [ + {"pin_a": "A6", "pin_b": "A5"}, + {"pin_a": "A4", "pin_b": "A3"}, + {"pin_a": "B7", "pin_b": "B6"} + ] } } diff --git a/keyboards/mechlovin/adelais/standard_led/avr/rev1/config.h b/keyboards/mechlovin/adelais/standard_led/avr/rev1/config.h index aac4aae40df8e7327c4fbbe8e024c6daee820870..831642126b2851fe6ae1d6155e502234b713908a 100644 --- a/keyboards/mechlovin/adelais/standard_led/avr/rev1/config.h +++ b/keyboards/mechlovin/adelais/standard_led/avr/rev1/config.h @@ -45,8 +45,4 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -#define ENCODERS_PAD_A { D3, D5, C7 } -#define ENCODERS_PAD_B { D2, B6, C6 } -#define ENCODER_RESOLUTION 4 - #define TAP_CODE_DELAY 10 diff --git a/keyboards/mechlovin/adelais/standard_led/avr/rev1/info.json b/keyboards/mechlovin/adelais/standard_led/avr/rev1/info.json index 73ea66a9971eb763722678b1207cc0437445f216..e385d5ef1a9c89d333cdeb55d3963f05f06e5acd 100644 --- a/keyboards/mechlovin/adelais/standard_led/avr/rev1/info.json +++ b/keyboards/mechlovin/adelais/standard_led/avr/rev1/info.json @@ -3,6 +3,13 @@ "usb": { "pid": "0xAD04" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"}, + {"pin_a": "D5", "pin_b": "B6"}, + {"pin_a": "C7", "pin_b": "C6"} + ] + }, "backlight": { "pin": "B5", "breathing": true diff --git a/keyboards/mechlovin/foundation/config.h b/keyboards/mechlovin/foundation/config.h index 73d42d4a496a8619ec95150b0a83b1b3ce8a0207..951eab595b5bf636920c59332661f76ebcae2eb0 100644 --- a/keyboards/mechlovin/foundation/config.h +++ b/keyboards/mechlovin/foundation/config.h @@ -55,9 +55,4 @@ along with this program. If not, see . # define RGBLIGHT_EFFECT_TWINKLE #endif -// Encoder pins -#define ENCODERS_PAD_A { C13 } -#define ENCODERS_PAD_B { C14 } - -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 \ No newline at end of file diff --git a/keyboards/mechlovin/foundation/info.json b/keyboards/mechlovin/foundation/info.json index 38f9cace081724175328b543e14c8e51a19fb0ca..bb7491ff191e535263a70305a809d7adb46045a7 100644 --- a/keyboards/mechlovin/foundation/info.json +++ b/keyboards/mechlovin/foundation/info.json @@ -8,6 +8,11 @@ "pid": "0x0180", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "C13", "pin_b": "C14"} + ] + }, "indicators": { "caps_lock": "A1", "on_state": 0 diff --git a/keyboards/mechlovin/hex6c/config.h b/keyboards/mechlovin/hex6c/config.h index a2b1b0311bd47ce9431af499ef8a135a4bcd758c..b0791490a29d37d00e1ffbfbd3817447d05266cf 100644 --- a/keyboards/mechlovin/hex6c/config.h +++ b/keyboards/mechlovin/hex6c/config.h @@ -37,10 +37,6 @@ along with this program. If not, see . #define BACKLIGHT_PWM_DRIVER PWMD3 #define BACKLIGHT_PWM_CHANNEL 3 -#define ENCODERS_PAD_A { A15 } -#define ENCODERS_PAD_B { A2 } -#define ENCODER_RESOLUTION 4 - #define TAP_CODE_DELAY 10 #define WEAR_LEVELING_BACKING_SIZE 4096 diff --git a/keyboards/mechlovin/hex6c/info.json b/keyboards/mechlovin/hex6c/info.json index e03f75c2b8b5058e156967c0b8fe763ab4da76a7..387043bde663ae30cce2414b97212fa8552275d8 100644 --- a/keyboards/mechlovin/hex6c/info.json +++ b/keyboards/mechlovin/hex6c/info.json @@ -8,6 +8,11 @@ "pid": "0x6C01", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A15", "pin_b": "A2"} + ] + }, "backlight": { "pin": "B0", "breathing": true diff --git a/keyboards/mechlovin/zed65/no_backlight/retro66/config.h b/keyboards/mechlovin/zed65/no_backlight/retro66/config.h index cbc575ab938e2e4995167d7680712c144067e45c..4739a7c2b14f0ed2fc9a082b2ec64df757791fdc 100644 --- a/keyboards/mechlovin/zed65/no_backlight/retro66/config.h +++ b/keyboards/mechlovin/zed65/no_backlight/retro66/config.h @@ -21,11 +21,4 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B13, B14, A8, A1, A0 } #define MATRIX_COL_PINS { B11, B12, B10, B2, B1, B0, A7, A6, A5, A4, A3, A2, B3, A15, B5 } -// Number of encoders - -#define ENCODERS_PAD_A { B4, B6 } -#define ENCODERS_PAD_B { B8, B9 } - - -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 \ No newline at end of file diff --git a/keyboards/mechlovin/zed65/no_backlight/retro66/info.json b/keyboards/mechlovin/zed65/no_backlight/retro66/info.json index d2e9604146a49c9003f775668ddc9907218beb19..f14d88910bf22a578c1ca90d8ccd8bb5d2477042 100644 --- a/keyboards/mechlovin/zed65/no_backlight/retro66/info.json +++ b/keyboards/mechlovin/zed65/no_backlight/retro66/info.json @@ -8,6 +8,12 @@ "pid": "0x6601", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B8"}, + {"pin_a": "B6", "pin_b": "B9"} + ] + }, "indicators": { "caps_lock": "C14" }, diff --git a/keyboards/mechwild/bde/rev2/config.h b/keyboards/mechwild/bde/rev2/config.h index 3d045762ca73cf0b5fe1d035fa7bc1e6f2554930..0d43d53bcd6100451b66f9fc906b2c93bacc99ba 100644 --- a/keyboards/mechwild/bde/rev2/config.h +++ b/keyboards/mechwild/bde/rev2/config.h @@ -17,11 +17,4 @@ along with this program. If not, see . #pragma once -/* Encoder pins */ -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D3 } - -/* Encoder resolution */ -#define ENCODER_RESOLUTION 4 - #define OLED_FONT_H "keyboards/mechwild/bde/lib/rev2.c" diff --git a/keyboards/mechwild/bde/rev2/info.json b/keyboards/mechwild/bde/rev2/info.json index 29ddb0e01767aa43613a5e19d66f55aae2b85cce..4d27c538951d5d0d23eae18113d6d9f70ad630b2 100644 --- a/keyboards/mechwild/bde/rev2/info.json +++ b/keyboards/mechwild/bde/rev2/info.json @@ -4,6 +4,11 @@ "pid": "0x170A", "device_version": "1.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "matrix_pins": { "rows":[ "C6", "D7", "B4", "D4", "E6", "B2" ], "cols": ["B3", "B1", "F7", "F6", "F5", "F4", "B5" ] diff --git a/keyboards/mechwild/clunker/config.h b/keyboards/mechwild/clunker/config.h index 19dab9b25d20cf4f10d79cbf1ced63626d92056c..62caa25bb36bb6dfc15a084353041818f2dc1694 100644 --- a/keyboards/mechwild/clunker/config.h +++ b/keyboards/mechwild/clunker/config.h @@ -19,8 +19,4 @@ //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D3 } -#define ENCODER_RESOLUTION 4 - #define SOLENOID_PIN F4 diff --git a/keyboards/mechwild/clunker/info.json b/keyboards/mechwild/clunker/info.json index cc9b8a1c5949966d56d98f099264b2e2e474fabb..89083afeb22aa4013fe1bd99e2b202e1be64c904 100644 --- a/keyboards/mechwild/clunker/info.json +++ b/keyboards/mechwild/clunker/info.json @@ -25,6 +25,11 @@ "pid": "0x1711", "vid": "0x6D77" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/mechwild/mercutio/config.h b/keyboards/mechwild/mercutio/config.h index 98bfeb56254b624683aa8c86fa534ba4f15c71d7..070fe36eb7a23eb9fc0db74b46652baad3494421 100755 --- a/keyboards/mechwild/mercutio/config.h +++ b/keyboards/mechwild/mercutio/config.h @@ -22,12 +22,6 @@ #define MATRIX_ROW_PINS { D0, D1, D4, C3, C0, C1, C2} #define MATRIX_COL_PINS { B0, D7, D6, D5, B1, B2, B3} -/* encoder pins */ -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } - -/* encoder resolution */ -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 /* COL2ROW or ROW2COL */ diff --git a/keyboards/mechwild/mercutio/info.json b/keyboards/mechwild/mercutio/info.json index b0596e76e5b0aca660e4c5ee6f6564a06ffbc3b3..98c815c6a8045ff1f0072c62875109d5cf123412 100644 --- a/keyboards/mechwild/mercutio/info.json +++ b/keyboards/mechwild/mercutio/info.json @@ -8,6 +8,11 @@ "pid": "0x1703", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "atmega328p", "bootloader": "usbasploader", "layouts": { diff --git a/keyboards/mechwild/mokulua/mirrored/config.h b/keyboards/mechwild/mokulua/mirrored/config.h index 0638945b90243a4540563e8aabbeb4cb67f29ff9..92a8dfa3234ac7aa9dc4ddea4f0dc0eaa5b09cde 100644 --- a/keyboards/mechwild/mokulua/mirrored/config.h +++ b/keyboards/mechwild/mokulua/mirrored/config.h @@ -8,12 +8,6 @@ #define MATRIX_ROW_PINS { F4, F5, F6, F7, B1, B3 } #define MATRIX_COL_PINS { D4, C6, D7, E6, B4, B5 } -/* Encoder pins */ -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { B2 } - -/* Encoder resolution */ -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 /* COL2ROW, ROW2COL */ diff --git a/keyboards/mechwild/mokulua/mirrored/info.json b/keyboards/mechwild/mokulua/mirrored/info.json index ea140fca0ee2ed1019a42700981827d9f5177474..29d2497cc1162044631debd06d5f1a6d513ed2fd 100644 --- a/keyboards/mechwild/mokulua/mirrored/info.json +++ b/keyboards/mechwild/mokulua/mirrored/info.json @@ -8,6 +8,11 @@ "pid": "0x170C", "device_version": "1.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "B2"} + ] + }, "split": { "soft_serial_pin": "D3" }, diff --git a/keyboards/mechwild/mokulua/standard/config.h b/keyboards/mechwild/mokulua/standard/config.h index db224094db834928c9096cb8832fdd04036c090b..b720c271b2a0ffbf27b5996fed093c5fc4ea5679 100644 --- a/keyboards/mechwild/mokulua/standard/config.h +++ b/keyboards/mechwild/mokulua/standard/config.h @@ -8,12 +8,6 @@ #define MATRIX_ROW_PINS { F4, F5, F6, F7, B1, B3 } #define MATRIX_COL_PINS { D4, C6, D7, E6, B4, B5 } -/* Encoder pins */ -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { B2 } - -/* Encoder resolution */ -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 /* COL2ROW, ROW2COL */ diff --git a/keyboards/mechwild/mokulua/standard/info.json b/keyboards/mechwild/mokulua/standard/info.json index 0fd80e4c888d6de89b3351cbe8cc00934d571092..d3451698f6cbcb5e2d3a660895578951349847ff 100644 --- a/keyboards/mechwild/mokulua/standard/info.json +++ b/keyboards/mechwild/mokulua/standard/info.json @@ -8,6 +8,11 @@ "pid": "0x170B", "device_version": "1.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "B2"} + ] + }, "split": { "soft_serial_pin": "D3" }, diff --git a/keyboards/mechwild/murphpad/config.h b/keyboards/mechwild/murphpad/config.h index b190f9af869fed000d2aa59a87dbcad0857261a3..d3158c3306610f3c2eec6e461810749f74780cad 100644 --- a/keyboards/mechwild/murphpad/config.h +++ b/keyboards/mechwild/murphpad/config.h @@ -22,12 +22,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F5, B2, B3, B1, F7, F6 } #define MATRIX_COL_PINS { B5, D7, C6, D4, B6 } -/* Encoder pins */ -#define ENCODERS_PAD_A { E6, D2 } -#define ENCODERS_PAD_B { B4, D3 } - -/* Encoder resolution */ -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 /* COL2ROW, ROW2COL */ diff --git a/keyboards/mechwild/murphpad/info.json b/keyboards/mechwild/murphpad/info.json index 57a3c8fa8d3b21e4d7ef37b676b6473e154ab346..92af56f0ddbe0285a6bea9b745d08fed21c84ebd 100644 --- a/keyboards/mechwild/murphpad/info.json +++ b/keyboards/mechwild/murphpad/info.json @@ -8,6 +8,12 @@ "pid": "0x1705", "device_version": "3.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B4"}, + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/mechwild/obe/config.h b/keyboards/mechwild/obe/config.h index 25f9b62394d0824c1e9aa1f7776a447261445ab7..72efdae1e2b1ec9109499f1d7a0dd860eb3b752d 100644 --- a/keyboards/mechwild/obe/config.h +++ b/keyboards/mechwild/obe/config.h @@ -31,12 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { A8, B15, B14, B13, B12, A15, B3 } #define MATRIX_COL_PINS { B10, B1, B0, A7, A6, A5, A4, A3, A2, A1 } -/* encoder pins */ -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B4 } - -/* encoder resolution */ -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 /* COL2ROW, ROW2COL */ diff --git a/keyboards/mechwild/obe/info.json b/keyboards/mechwild/obe/info.json index 806333a0fa123ad1fd49cec062ed8d73a4ce354c..cbe9f7cfa8064013986a389bd3f414812e2e2b13 100644 --- a/keyboards/mechwild/obe/info.json +++ b/keyboards/mechwild/obe/info.json @@ -8,6 +8,11 @@ "pid": "0x1707", "device_version": "2.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B4"} + ] + }, "indicators": { "caps_lock": "B9", "num_lock": "B8" diff --git a/keyboards/mechwild/puckbuddy/config.h b/keyboards/mechwild/puckbuddy/config.h index 0487c5322acc2b8ef64d86a22cedf07ad51a01f6..bf2e1a0b58db225ac7cd2a1bfb04b774d26748cd 100644 --- a/keyboards/mechwild/puckbuddy/config.h +++ b/keyboards/mechwild/puckbuddy/config.h @@ -42,12 +42,6 @@ #define CIRQUE_PINNACLE_SPI_DIVISOR 8 #define CIRQUE_PINNACLE_SPI_CS_PIN A4 -/* encoder pins */ -#define ENCODERS_PAD_A { B1, B3 } -#define ENCODERS_PAD_B { B0, A15 } - -/* encoder resolution */ -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 /* COL2ROW, ROW2COL */ diff --git a/keyboards/mechwild/puckbuddy/info.json b/keyboards/mechwild/puckbuddy/info.json index d0af030ff3464cdd81487873bac5d01031a82a28..825def96a22d02197a8259e0a334a20e6d980fb3 100644 --- a/keyboards/mechwild/puckbuddy/info.json +++ b/keyboards/mechwild/puckbuddy/info.json @@ -8,6 +8,12 @@ "pid": "0x170F", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B0"}, + {"pin_a": "B3", "pin_b": "A15"} + ] + }, "indicators": { "caps_lock": "C13", "on_state": 0 diff --git a/keyboards/mechwild/waka60/config.h b/keyboards/mechwild/waka60/config.h index 5403cd0ddcb2f6d2ddb91b43d1db3321c56dd4d1..88b160a98068a56d8bed9eee9ae44023adaca999 100644 --- a/keyboards/mechwild/waka60/config.h +++ b/keyboards/mechwild/waka60/config.h @@ -31,12 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B8, B4, B3, B9, A15, B12, B13, B14, B15, A8 } #define MATRIX_COL_PINS { B10, B1, B0, A7, A6, A5, A4 } -/* encoder pins */ -#define ENCODERS_PAD_A { A3 } -#define ENCODERS_PAD_B { A2 } - -/* encoder resolution */ -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 /* COL2ROW, ROW2COL */ diff --git a/keyboards/mechwild/waka60/info.json b/keyboards/mechwild/waka60/info.json index 8e9a2c11f12f158233c2028d1984439e6809fbcf..eb7d2d9f545396b4ad44f4d36580d6e97103818c 100644 --- a/keyboards/mechwild/waka60/info.json +++ b/keyboards/mechwild/waka60/info.json @@ -8,6 +8,11 @@ "pid": "0x1709", "device_version": "1.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A3", "pin_b": "A2"} + ] + }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/meletrix/zoom65/config.h b/keyboards/meletrix/zoom65/config.h index 0bf850043caffb39849489a96279bbc89dbb3f02..4c05b1d83bd211f1fdede3e6e56392eebd87c3f4 100644 --- a/keyboards/meletrix/zoom65/config.h +++ b/keyboards/meletrix/zoom65/config.h @@ -22,14 +22,6 @@ #define DIODE_DIRECTION COL2ROW -/* Enable encoder */ -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B0 } - -#define ENCODERS 1 - -#define ENCODER_RESOLUTION 2 - // Note: array is { col, row ) #define ENCODERS_CW_KEY { { 5, 4 } } #define ENCODERS_CCW_KEY { { 3, 4 } } diff --git a/keyboards/meletrix/zoom65/info.json b/keyboards/meletrix/zoom65/info.json index 18be91ee2633182c834f3fb3839c5703635a61d6..0968df479464504a95092c27534a3bc12bd119d1 100644 --- a/keyboards/meletrix/zoom65/info.json +++ b/keyboards/meletrix/zoom65/info.json @@ -8,6 +8,11 @@ "pid": "0x0004", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B0", "resolution": 2} + ] + }, "indicators": { "caps_lock": "F7", "on_state": 0 diff --git a/keyboards/meletrix/zoom65/zoom65.c b/keyboards/meletrix/zoom65/zoom65.c index f69ed547eff32b57ba02b7ca61f593b5c5c6a575..ff27a4442fab3094b3b2f5891e8efc5e97534fe7 100644 --- a/keyboards/meletrix/zoom65/zoom65.c +++ b/keyboards/meletrix/zoom65/zoom65.c @@ -17,13 +17,13 @@ #include "zoom65.h" #ifdef VIA_ENABLE -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { diff --git a/keyboards/meletrix/zoom65_lite/config.h b/keyboards/meletrix/zoom65_lite/config.h index 0bf850043caffb39849489a96279bbc89dbb3f02..4c05b1d83bd211f1fdede3e6e56392eebd87c3f4 100644 --- a/keyboards/meletrix/zoom65_lite/config.h +++ b/keyboards/meletrix/zoom65_lite/config.h @@ -22,14 +22,6 @@ #define DIODE_DIRECTION COL2ROW -/* Enable encoder */ -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B0 } - -#define ENCODERS 1 - -#define ENCODER_RESOLUTION 2 - // Note: array is { col, row ) #define ENCODERS_CW_KEY { { 5, 4 } } #define ENCODERS_CCW_KEY { { 3, 4 } } diff --git a/keyboards/meletrix/zoom65_lite/info.json b/keyboards/meletrix/zoom65_lite/info.json index f3839d2e883b3c1298622235c80e02d7a3a01fd3..d5dcd621ef4617015ab5588aefdc614a1f6f86fe 100644 --- a/keyboards/meletrix/zoom65_lite/info.json +++ b/keyboards/meletrix/zoom65_lite/info.json @@ -8,6 +8,11 @@ "pid": "0x0005", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B0", "resolution": 2} + ] + }, "indicators": { "caps_lock": "F7", "on_state": 0 diff --git a/keyboards/meletrix/zoom65_lite/keymaps/via/keymap.c b/keyboards/meletrix/zoom65_lite/keymaps/via/keymap.c index de44abe37e9013d479b81b4d181bf76ceda3d645..23729b43496f877d3149168d5e05ad542036af4a 100644 --- a/keyboards/meletrix/zoom65_lite/keymaps/via/keymap.c +++ b/keyboards/meletrix/zoom65_lite/keymaps/via/keymap.c @@ -16,14 +16,13 @@ #include QMK_KEYBOARD_H -#ifdef VIA_ENABLE -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { @@ -56,8 +55,7 @@ bool encoder_update_kb(uint8_t index, bool clockwise) { encoder_action_register(index, clockwise); return true; -}; -#endif +} const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [0] = LAYOUT_all( diff --git a/keyboards/merge/iso_macro/config.h b/keyboards/merge/iso_macro/config.h index cde82e73416ab87dfed4ca8671ed2c1ada45df5c..7bf2b1b33bbf607f7806eaa88e8c22c2e36ef6cd 100644 --- a/keyboards/merge/iso_macro/config.h +++ b/keyboards/merge/iso_macro/config.h @@ -22,8 +22,3 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW - - -#define ENCODERS_PAD_A { F0, D0 } -#define ENCODERS_PAD_B { F1, D1 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/merge/iso_macro/info.json b/keyboards/merge/iso_macro/info.json index 123438a5be923a05d4abadfb421449475e44336b..bc4269755fe17588f02bbd06eafb8cea8c3a7881 100644 --- a/keyboards/merge/iso_macro/info.json +++ b/keyboards/merge/iso_macro/info.json @@ -8,6 +8,12 @@ "pid": "0x1200", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1"}, + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "backlight": { "pin": "B7" }, diff --git a/keyboards/merge/uc1/config.h b/keyboards/merge/uc1/config.h index 488b2cfed3526e3626ed008b5472b45e0cc01b27..9dcfb6e07445e322cb60c3a733d4bda68a8d30c4 100644 --- a/keyboards/merge/uc1/config.h +++ b/keyboards/merge/uc1/config.h @@ -39,7 +39,3 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F6 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/merge/uc1/info.json b/keyboards/merge/uc1/info.json index d42f88c7948b12ac51d7a75e9f2f4c376f21a07e..55b68a4510c0931eed822d1bbda176dde12c5663 100644 --- a/keyboards/merge/uc1/info.json +++ b/keyboards/merge/uc1/info.json @@ -8,6 +8,11 @@ "pid": "0x5543", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/merge/um70/config.h b/keyboards/merge/um70/config.h index 69500ee603753c0173fcae8cc189a6e3e61302fb..c249a1816a6666f8376919403a121849be22d3fb 100644 --- a/keyboards/merge/um70/config.h +++ b/keyboards/merge/um70/config.h @@ -42,6 +42,3 @@ #ifdef AUDIO_ENABLE #define STARTUP_SONG SONG(STARTUP_SOUND) #endif - -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } diff --git a/keyboards/merge/um70/info.json b/keyboards/merge/um70/info.json index 3c57c774927116284a370988b639e581d09b00d2..e548d63151e2b5245bb42eb05bd3dc8893e49e0e 100644 --- a/keyboards/merge/um70/info.json +++ b/keyboards/merge/um70/info.json @@ -8,6 +8,11 @@ "pid": "0x3222", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/merge/um80/config.h b/keyboards/merge/um80/config.h index bba359e02f17bb46aa185dae9ff93c350f75155b..238e5f6d4369e1b3c34b0e2e8694b3d5d12968e2 100644 --- a/keyboards/merge/um80/config.h +++ b/keyboards/merge/um80/config.h @@ -42,6 +42,3 @@ #ifdef AUDIO_ENABLE #define STARTUP_SONG SONG(STARTUP_SOUND) #endif - -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } diff --git a/keyboards/merge/um80/info.json b/keyboards/merge/um80/info.json index a467a97c77c3a2cd4d705724b7df2d401534e107..e3e1359c9276d8888b02ebdb072da83c1d28df27 100644 --- a/keyboards/merge/um80/info.json +++ b/keyboards/merge/um80/info.json @@ -8,6 +8,11 @@ "pid": "0x3241", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/merge/uma/config.h b/keyboards/merge/uma/config.h index 4cbb58332125b2266deaf5755722e7b459c41627..6d21adc7741e3f2861f758a0619417ace8289529 100644 --- a/keyboards/merge/uma/config.h +++ b/keyboards/merge/uma/config.h @@ -24,6 +24,3 @@ #define SPLIT_USB_DETECT #define SPLIT_MODS_ENABLE - -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } diff --git a/keyboards/merge/uma/info.json b/keyboards/merge/uma/info.json index 11ccd102a52b5ae7dbd09df100b55dc27683cb44..1363705253614be5e558c1e9146c0d0b270796c8 100644 --- a/keyboards/merge/uma/info.json +++ b/keyboards/merge/uma/info.json @@ -11,6 +11,11 @@ "backlight": { "pin": "C6" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/metamechs/timberwolf/config.h b/keyboards/metamechs/timberwolf/config.h index 83501eb878d9f83ae3722d44635d0c0ee2280edb..916b315725542baf912091cf5482b7d77709d11f 100644 --- a/keyboards/metamechs/timberwolf/config.h +++ b/keyboards/metamechs/timberwolf/config.h @@ -34,16 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* Wncoswe pins */ -#define ENCODERS_PAD_A { B7 } -#define ENCODERS_PAD_B { B3 } - -/* Encoder resolution, lower number = more sensitive */ -#define ENCODER_RESOLUTION 2 - -/* Reverse encoder direction */ -// #define ENCODER_DIRECTION_FLIP - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/metamechs/timberwolf/info.json b/keyboards/metamechs/timberwolf/info.json index 4d6e82eec672fb005a511e8785fe6759e12b9af5..ae12912f00a36ba4e3bbe3023131b2e04c3d3a2e 100644 --- a/keyboards/metamechs/timberwolf/info.json +++ b/keyboards/metamechs/timberwolf/info.json @@ -12,6 +12,11 @@ "pin": "C6", "levels": 16 }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "B3", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mexsistor/ludmila/config.h b/keyboards/mexsistor/ludmila/config.h index 56d73345af2fee433dc1d9ca9a51191383943533..208e11fc1cb1ae8f3eda07512c8a68e953a5c45f 100644 --- a/keyboards/mexsistor/ludmila/config.h +++ b/keyboards/mexsistor/ludmila/config.h @@ -51,8 +51,3 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_RGB_TEST #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE - - -// Encoder -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F5 } diff --git a/keyboards/mexsistor/ludmila/info.json b/keyboards/mexsistor/ludmila/info.json index a5709d78284b5d80964f12de4a8f719e1194693b..ea42f18d3097a590804159107307ac5d96df48b0 100644 --- a/keyboards/mexsistor/ludmila/info.json +++ b/keyboards/mexsistor/ludmila/info.json @@ -8,6 +8,11 @@ "pid": "0x6BF6", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/millipad/config.h b/keyboards/millipad/config.h index bbdf124f0e9b61e2448520f79cef5a9b697b9381..ab1d6e7c516e7b120f4ded63edf43d8b73b80748 100644 --- a/keyboards/millipad/config.h +++ b/keyboards/millipad/config.h @@ -37,9 +37,3 @@ along with this program. If not, see . #define LOCKING_RESYNC_ENABLE #define FORCE_NKRO - -/* Encoder Definitions */ - -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/millipad/info.json b/keyboards/millipad/info.json index f0a0f2da180aabfc7aaae2bcb9604fb0548f656c..9469f2babaf142558d73fa0c71c5ed47f3edd061 100644 --- a/keyboards/millipad/info.json +++ b/keyboards/millipad/info.json @@ -8,6 +8,11 @@ "pid": "0x1A1B", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mincedshon/ecila/config.h b/keyboards/mincedshon/ecila/config.h index 915b3fccb488b62fcdc3b5c5abaeb715d81b9603..9c7e498de3d060905f27027237af680e785d7d8d 100644 --- a/keyboards/mincedshon/ecila/config.h +++ b/keyboards/mincedshon/ecila/config.h @@ -3,12 +3,6 @@ #pragma once -/* encoder */ -/* #define NUMBER_OF_ENCODERS 1 */ -//#define ENCODERS_PAD_A { D3 } -//#define ENCODERS_PAD_B { D2 } -//#define ENCODER_RESOLUTION 1 - #define RGB_DI_PIN B0 #define RGBLIGHT_EFFECT_BREATHING #define RGBLIGHT_EFFECT_RAINBOW_MOOD diff --git a/keyboards/mini_elixivy/config.h b/keyboards/mini_elixivy/config.h index 140214d7268ac8c67ddb656115063aff9182875f..fafc795574895d8761a38a396a59e596d0701841 100644 --- a/keyboards/mini_elixivy/config.h +++ b/keyboards/mini_elixivy/config.h @@ -30,8 +30,6 @@ along with this program. If not, see . */ #define MATRIX_ROW_PINS { B5, B6, E6, F6, C7 } #define MATRIX_COL_PINS { F7, F5, F4, F1, F0, B7, D0, D1, D2, D3, D4, D6, D7, B4, C6 } -#define ENCODERS_PAD_A { B0 } -#define ENCODERS_PAD_B { D5 } /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/mini_elixivy/info.json b/keyboards/mini_elixivy/info.json index 84ee3ee6f6a64b91a7eb6c44d01b677fff9d0c07..3567b555ac0c629b240aa0b61b7c61dcdcf90b04 100644 --- a/keyboards/mini_elixivy/info.json +++ b/keyboards/mini_elixivy/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "D5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "community_layouts": ["65_ansi", "65_iso"], diff --git a/keyboards/mini_ten_key_plus/config.h b/keyboards/mini_ten_key_plus/config.h index cfe0bc16b2e5cc2c0ee76719d55c106227450f89..1773beff05be174ebecc04d783264c6472a17a69 100644 --- a/keyboards/mini_ten_key_plus/config.h +++ b/keyboards/mini_ten_key_plus/config.h @@ -30,8 +30,6 @@ along with this program. If not, see . */ #define MATRIX_ROW_PINS { D4, B1, B5, B4, E6 } #define MATRIX_COL_PINS { F5, F4, B6, D7, C6 } -#define ENCODERS_PAD_A { F7 } -#define ENCODERS_PAD_B { F6 } /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW @@ -56,5 +54,3 @@ along with this program. If not, see . //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -#define ENCODER_RESOLUTION 2 diff --git a/keyboards/mini_ten_key_plus/info.json b/keyboards/mini_ten_key_plus/info.json index 70c1d76832d29fab46b89e60015abcebe2687090..e69e49b06b54052dbe39189ab90dce5ba77b5464 100644 --- a/keyboards/mini_ten_key_plus/info.json +++ b/keyboards/mini_ten_key_plus/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F7", "pin_b": "F6", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/minimacro5/config.h b/keyboards/minimacro5/config.h index 351fb8a5a5e5d4ec3b261ae709fd5e6ea55dd0ec..272c37ff5060c30fc0ddbe1a8eff1ff211bf59b6 100644 --- a/keyboards/minimacro5/config.h +++ b/keyboards/minimacro5/config.h @@ -20,12 +20,6 @@ along with this program. If not, see . //speed for double tap #define TAPPING_TERM 200 - -/* rotary encoder 1,2,3 closest to usb port is 0*/ -#define ENCODERS_PAD_B { D3, F6, F7, D4, C6} -#define ENCODERS_PAD_A { F5, D2, D1, D0, E6} -#define ENCODER_RESOLUTION 2 //default/suggested - /* ws2812 RGB LED */ #define RGB_DI_PIN B5 #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/minimacro5/info.json b/keyboards/minimacro5/info.json index a4969498ed0cb19c523e72142030e6a50205bfc2..7c6748c574c317faf538594ea54cfe9876785cec 100644 --- a/keyboards/minimacro5/info.json +++ b/keyboards/minimacro5/info.json @@ -8,6 +8,15 @@ "pid": "0x0007", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "F5", "resolution": 2}, + {"pin_a": "F6", "pin_b": "D2", "resolution": 2}, + {"pin_a": "F7", "pin_b": "D1", "resolution": 2}, + {"pin_a": "D4", "pin_b": "D0", "resolution": 2}, + {"pin_a": "C6", "pin_b": "E6", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/misonoworks/karina/config.h b/keyboards/misonoworks/karina/config.h index 95748659e48e07828ea0145d65004e228cf3ada1..2c71926b81e80d0ff28eed20d315061f882e4c0b 100644 --- a/keyboards/misonoworks/karina/config.h +++ b/keyboards/misonoworks/karina/config.h @@ -29,11 +29,6 @@ along with this program. If not, see . #define MK_3_SPEED #define TERMINAL_HELP -// encoders -#define ENCODERS_PAD_A { B2, F4 } -#define ENCODERS_PAD_B { B1, F5 } -#define ENCODER_RESOLUTION 3 - /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE diff --git a/keyboards/misonoworks/karina/info.json b/keyboards/misonoworks/karina/info.json index a9d1ecbd31c307bea917b17207cee06c78b647a2..922e4117e68c6488fc45fcfa746fe11023a6a73c 100644 --- a/keyboards/misonoworks/karina/info.json +++ b/keyboards/misonoworks/karina/info.json @@ -8,6 +8,12 @@ "pid": "0xC456", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1", "resolution": 3}, + {"pin_a": "F4", "pin_b": "F5", "resolution": 3} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mixi/config.h b/keyboards/mixi/config.h index e6b2ef0961133213225c809e720317407442e673..ed827231084c22f594fd0fb2950d451a706350cb 100644 --- a/keyboards/mixi/config.h +++ b/keyboards/mixi/config.h @@ -1,8 +1,5 @@ #pragma once -#define ENCODERS_PAD_A { D7, B1 } -#define ENCODERS_PAD_B { E6, B3 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/mixi/info.json b/keyboards/mixi/info.json index 584a8f85b78b8635024021b004735f89bd4dbd6c..3af1d02f47cf5ff0d1ac666e384164c32ecf649b 100644 --- a/keyboards/mixi/info.json +++ b/keyboards/mixi/info.json @@ -8,6 +8,12 @@ "pid": "0x4D49", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "E6"}, + {"pin_a": "B1", "pin_b": "B3"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/mk65/config.h b/keyboards/mk65/config.h index 400e3fa10e2b0ec8606d83ae3a415a81d0d9b10f..7fa60c79f830d5c12b8770dc41e07400faa52dae 100644 --- a/keyboards/mk65/config.h +++ b/keyboards/mk65/config.h @@ -16,9 +16,4 @@ #pragma once - -/* Encoders */ - -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B2 } #define TAP_CODE_DELAY 10 \ No newline at end of file diff --git a/keyboards/mk65/info.json b/keyboards/mk65/info.json index 01d226ce4c738d7120f67786b4a5e25b17ea7434..84cd0fbca184a047fcbcac2ab2b0592424dee533 100644 --- a/keyboards/mk65/info.json +++ b/keyboards/mk65/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/ml/gas75/config.h b/keyboards/ml/gas75/config.h index 0005f030e46fcdd2eaca8b0e1fd0a0cc675419b0..bd9c4b6e4e758b67065c5929b2032b9e82495791 100644 --- a/keyboards/ml/gas75/config.h +++ b/keyboards/ml/gas75/config.h @@ -27,10 +27,6 @@ /* Forcing to use NKRO instead 6KRO */ #define FORCE_NKRO -/* Encoder pins */ -#define ENCODERS_PAD_A { F0 } -#define ENCODERS_PAD_B { F1 } - #ifdef RGB_MATRIX_ENABLE #define RGB_MATRIX_LED_COUNT 3 #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 diff --git a/keyboards/ml/gas75/info.json b/keyboards/ml/gas75/info.json index 8ee1c8f94d1a0d8819afa478d75917b26afa9869..2687ada0d933a3d7eb497b81f6162d78dc08c69c 100644 --- a/keyboards/ml/gas75/info.json +++ b/keyboards/ml/gas75/info.json @@ -8,6 +8,11 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/ml/gas75/keymaps/via/keymap.c b/keyboards/ml/gas75/keymaps/via/keymap.c index b609f9d1429fa6ec2761527b52065c7b0a9ddd68..b5e3055427bbee0cf8dc1c9d2c167905234afac1 100644 --- a/keyboards/ml/gas75/keymaps/via/keymap.c +++ b/keyboards/ml/gas75/keymaps/via/keymap.c @@ -159,14 +159,12 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { } #ifdef ENCODER_ENABLE - -#define ENCODERS 1 -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = {{3, 5}}; -static keypos_t encoder_ccw[ENCODERS] = {{4, 5}}; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = {{3, 5}}; +static keypos_t encoder_ccw[NUM_ENCODERS] = {{4, 5}}; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], diff --git a/keyboards/mlego/m48/rev1/config.h b/keyboards/mlego/m48/rev1/config.h index ab6ad48938337a3afb90de44de6f43f226212732..04c1bb450927be519ba73e09667f5e130d4a6258 100644 --- a/keyboards/mlego/m48/rev1/config.h +++ b/keyboards/mlego/m48/rev1/config.h @@ -21,14 +21,6 @@ #define MATRIX_COL_PINS \ { A10, A15, B3, B4, B5, B7, B6, A1, A2, A3, A4, A5 } -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A \ - { A0 } -#define ENCODERS_PAD_B \ - { B8 } -#define ENCODER_RESOLUTION 4 -#endif - #ifdef RGBLIGHT_ENABLE #define RGBLIGHT_LAYERS #define RGB_DI_PIN B15 diff --git a/keyboards/mlego/m48/rev1/info.json b/keyboards/mlego/m48/rev1/info.json index 83eda36107d5f9ac48f68126fb10af103c76de41..ecfa4dc940a6b2d7dffd96923b40482fbba4f985 100644 --- a/keyboards/mlego/m48/rev1/info.json +++ b/keyboards/mlego/m48/rev1/info.json @@ -3,6 +3,11 @@ "pid": "0x6261", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "B8"} + ] + }, "indicators": { "caps_lock": "C13", "num_lock": "B12", diff --git a/keyboards/mlego/m60/rev1/config.h b/keyboards/mlego/m60/rev1/config.h index 5931171440104b9c78d17bee6a5d541ac02cdd9e..7805e6e82b14abef0cf6cf7eb78118871052a041 100644 --- a/keyboards/mlego/m60/rev1/config.h +++ b/keyboards/mlego/m60/rev1/config.h @@ -15,19 +15,11 @@ */ #pragma once -#ifdef ENCODER_ENABLE #define MATRIX_ROW_PINS \ { A6, A7, B0, B1, B10 } #define MATRIX_COL_PINS \ { A10, A15, B3, B4, B5, B7, B6, A1, A2, A3, A4, A5 } -#define ENCODERS_PAD_A \ - { A0 } -#define ENCODERS_PAD_B \ - { B8 } - -#endif - #ifdef RGBLIGHT_ENABLE #define RGB_DI_PIN B15 diff --git a/keyboards/mlego/m60/rev1/info.json b/keyboards/mlego/m60/rev1/info.json index 9363527fe91e44ca0a04c37ce16311f6b32ede70..e9e03cb18982df616a2f993a206da67c165e8e41 100644 --- a/keyboards/mlego/m60/rev1/info.json +++ b/keyboards/mlego/m60/rev1/info.json @@ -3,6 +3,11 @@ "pid": "0x6161", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "B8"} + ] + }, "indicators": { "caps_lock": "C13", "num_lock": "B12", diff --git a/keyboards/mlego/m60_split/rev1/config.h b/keyboards/mlego/m60_split/rev1/config.h index adb8bd0783f90d4fe89797a370e6ad4b269470a7..a835d8c4f315a84e236ef4073fb8f8ff545ca563 100644 --- a/keyboards/mlego/m60_split/rev1/config.h +++ b/keyboards/mlego/m60_split/rev1/config.h @@ -27,15 +27,6 @@ #define MATRIX_COL_PINS_RIGHT \ { B0, A3, A2, A1, B7, B5 } // cols are from right to left to match the layout -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A \ - { A0 } -#define ENCODERS_PAD_B \ - { B8 } -#define ENCODER_RESOLUTIONS \ - { 4 } -#endif - #define SPLIT_LAYER_STATE_ENABLE #define SPLIT_LED_STATE_ENABLE diff --git a/keyboards/mlego/m60_split/rev1/info.json b/keyboards/mlego/m60_split/rev1/info.json index fc9a608c9e3a85626668075e9579b0148038ca15..237b933eb03d2b9a12bc292fb2b7a477af063c90 100644 --- a/keyboards/mlego/m60_split/rev1/info.json +++ b/keyboards/mlego/m60_split/rev1/info.json @@ -3,6 +3,11 @@ "pid": "0x6361", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "B8"} + ] + }, "indicators": { "caps_lock": "C13", "num_lock": "B12", diff --git a/keyboards/mlego/m60_split/rev2/config.h b/keyboards/mlego/m60_split/rev2/config.h index e5ebf934382482e781ad084262c6a1278c79cdbe..2bb9334497d8c519888724aed432b03495e93d91 100644 --- a/keyboards/mlego/m60_split/rev2/config.h +++ b/keyboards/mlego/m60_split/rev2/config.h @@ -27,17 +27,6 @@ #define MATRIX_COL_PINS_RIGHT \ { B0, A3, A2, A1, B7, B5 } // cols are from right to left to match the layout - -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A \ - { A0 } -#define ENCODERS_PAD_B \ - { B8 } -#define ENCODER_RESOLUTIONS \ - { 4 } - -#endif - #define SPLIT_LAYER_STATE_ENABLE #define SPLIT_LED_STATE_ENABLE diff --git a/keyboards/mlego/m60_split/rev2/info.json b/keyboards/mlego/m60_split/rev2/info.json index b2b49279c1f6114fdb65effb1ebcf5ae28aa3e2c..4e281733e1c3438d89da306e80a838731898412f 100644 --- a/keyboards/mlego/m60_split/rev2/info.json +++ b/keyboards/mlego/m60_split/rev2/info.json @@ -3,6 +3,11 @@ "pid": "0x6362", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "B8"} + ] + }, "indicators": { "caps_lock": "C13", "num_lock": "B12", diff --git a/keyboards/mlego/m65/rev1/config.h b/keyboards/mlego/m65/rev1/config.h index ac1f935350cb3bb51e3812614d9a0edbfb7be2dd..d58ee7627ff1fbffc9bb0848c20105254bdfc4ab 100644 --- a/keyboards/mlego/m65/rev1/config.h +++ b/keyboards/mlego/m65/rev1/config.h @@ -24,17 +24,10 @@ along with this program. If not, see . #define MATRIX_COL_PINS \ { A10, A15, B3, B4, B5, B9, B8, B7, B6, C15, A0, A7, B10 } -#define ENCODERS_PAD_A \ - { A8 } -#define ENCODERS_PAD_B \ - { A9 } - #define RGB_DI_PIN B15 #define RGBLIGHT_LAYERS -#define ENCODER_RESOLUTION 4 - #undef RGBLED_NUM #define RGBLED_NUM 20 #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/mlego/m65/rev1/info.json b/keyboards/mlego/m65/rev1/info.json index 9635b31e59febf67afd81ff12339590e611afacc..f4d8ba75786b92b871a879c1e0d6fd11163e4723 100644 --- a/keyboards/mlego/m65/rev1/info.json +++ b/keyboards/mlego/m65/rev1/info.json @@ -3,6 +3,11 @@ "pid": "0x6061", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A8", "pin_b": "A9"} + ] + }, "indicators": { "caps_lock": "C13", "num_lock": "B12", diff --git a/keyboards/mlego/m65/rev2/config.h b/keyboards/mlego/m65/rev2/config.h index 3c2e877550573092d4d5b81f7d4e879c50644d3f..8094879b1c561811561af7ac82c6111e1597a37e 100644 --- a/keyboards/mlego/m65/rev2/config.h +++ b/keyboards/mlego/m65/rev2/config.h @@ -24,17 +24,10 @@ along with this program. If not, see . #define MATRIX_COL_PINS \ { A10, A15, B3, B4, B5, B9, B8, B7, B6, C15, A0, A7, B10 } -#define ENCODERS_PAD_A \ - { A8 } -#define ENCODERS_PAD_B \ - { A9 } - #define RGB_DI_PIN B15 #define RGBLIGHT_LAYERS -#define ENCODER_RESOLUTION 4 - #undef RGBLED_NUM #define RGBLED_NUM 20 #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/mlego/m65/rev2/info.json b/keyboards/mlego/m65/rev2/info.json index 2bde6bdef19670be9122232b438c66161035adc3..7d265197caee5f0fb60872578b419cac51d68440 100644 --- a/keyboards/mlego/m65/rev2/info.json +++ b/keyboards/mlego/m65/rev2/info.json @@ -3,6 +3,11 @@ "pid": "0x6061", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "A8", "pin_b": "A9"} + ] + }, "indicators": { "caps_lock": "B2", "num_lock": "B12", diff --git a/keyboards/mlego/m65/rev3/config.h b/keyboards/mlego/m65/rev3/config.h index abeaeffc8886d356029b49385ca8141d43ad8936..4a71449cb01ec6158dc233eab915c134588ae179 100644 --- a/keyboards/mlego/m65/rev3/config.h +++ b/keyboards/mlego/m65/rev3/config.h @@ -24,14 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS \ { A10, A15, B3, B4, B5, B9, B8, B7, A1, A2, A3, A4, B1 } -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A \ - { A0 } -#define ENCODERS_PAD_B \ - { B6 } -#define ENCODER_RESOLUTION 4 -#endif - #ifdef RGBLIGHT_ENABLE #define RGB_DI_PIN B15 diff --git a/keyboards/mlego/m65/rev3/info.json b/keyboards/mlego/m65/rev3/info.json index 8240ae7acebf739126d254a2856bec2e12da8004..39c26191c66725eddc1fecdfc36039460208d4c5 100644 --- a/keyboards/mlego/m65/rev3/info.json +++ b/keyboards/mlego/m65/rev3/info.json @@ -3,6 +3,11 @@ "pid": "0x6062", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "B6"} + ] + }, "indicators": { "caps_lock": "C13", "num_lock": "B12", diff --git a/keyboards/mlego/m65/rev4/config.h b/keyboards/mlego/m65/rev4/config.h index c2bd69f3638ced70880a3f979c340f652b7c90c6..a8b9b596d50edd22b302eca41da50d5d800efe55 100644 --- a/keyboards/mlego/m65/rev4/config.h +++ b/keyboards/mlego/m65/rev4/config.h @@ -24,14 +24,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS \ { B14, A8, A10, A15, B3, B4, B5, B7, A1, A2, A3, A4, B1 } -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A \ - { A0 } -#define ENCODERS_PAD_B \ - { B6 } -#define ENCODER_RESOLUTION 4 -#endif - #ifdef RGBLIGHT_ENABLE #define RGB_DI_PIN B15 diff --git a/keyboards/mlego/m65/rev4/info.json b/keyboards/mlego/m65/rev4/info.json index 465b61f2aa4922e1b49a7e3049d49c41f61f9add..91af43a6a1ff7532e48212e1185316f68fdcf566 100644 --- a/keyboards/mlego/m65/rev4/info.json +++ b/keyboards/mlego/m65/rev4/info.json @@ -3,6 +3,11 @@ "pid": "0x6062", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "B6"} + ] + }, "indicators": { "caps_lock": "C13", "num_lock": "B12", diff --git a/keyboards/monarch/config.h b/keyboards/monarch/config.h index 3f7a66bf06ec6bbc713686358e7c31a18489ad44..2d319c4fdf8904dfe0b674a888884083814f18cc 100644 --- a/keyboards/monarch/config.h +++ b/keyboards/monarch/config.h @@ -21,11 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { A15, B3, B11, A2, A1, B9 } #define DIODE_DIRECTION COL2ROW -/* Rotary encoder pins */ -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 1 - #define BACKLIGHT_PWM_DRIVER PWMD3 #define BACKLIGHT_PWM_CHANNEL 1 #define BACKLIGHT_PAL_MODE 1 diff --git a/keyboards/monarch/info.json b/keyboards/monarch/info.json index c4d1362a5b6d5ea1790f2d8a82ffe72eb846075a..95fafb5eb48c1599dfdba56e2292a589d10e2282 100644 --- a/keyboards/monarch/info.json +++ b/keyboards/monarch/info.json @@ -13,6 +13,11 @@ "levels": 24, "breathing": true }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5", "resolution": 1} + ] + }, "processor": "STM32F072", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/montsinger/rebound/rev2/config.h b/keyboards/montsinger/rebound/rev2/config.h index a2c4869690562c907d27f9b4586065974046ce4f..cbf4c9b8df703e84522b112cdcffbba7bd92dd48 100644 --- a/keyboards/montsinger/rebound/rev2/config.h +++ b/keyboards/montsinger/rebound/rev2/config.h @@ -30,9 +30,6 @@ diode) #define MATRIX_ROW_PINS { D1, B5, B2, B6, B0 } #define MATRIX_COL_PINS { D0, D4, C6, D7, E6, B4, B3, B1, F7, F6, F5, F4 } -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D3 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/montsinger/rebound/rev2/info.json b/keyboards/montsinger/rebound/rev2/info.json index cac145319ca3bc0b75b8fee5546c46b67994078a..8c2aec4e4d04f090ab4ee2d8beddb50cd84c6c31 100644 --- a/keyboards/montsinger/rebound/rev2/info.json +++ b/keyboards/montsinger/rebound/rev2/info.json @@ -8,6 +8,11 @@ "pid": "0x552F", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "community_layouts": ["ortho_4x12"], diff --git a/keyboards/montsinger/rebound/rev3/config.h b/keyboards/montsinger/rebound/rev3/config.h index fff82c341d33dd0778bfcb7cb56330ad73fc815a..00506c85bc8099e7a1db481d11227f89dd14d4c7 100644 --- a/keyboards/montsinger/rebound/rev3/config.h +++ b/keyboards/montsinger/rebound/rev3/config.h @@ -30,9 +30,6 @@ diode) #define MATRIX_ROW_PINS { F4, F5, D1, D0, B0 } #define MATRIX_COL_PINS { D4, C6, D7, E6, B4, B5, B6, B2, B3, B1, F7, F6 } -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/montsinger/rebound/rev3/info.json b/keyboards/montsinger/rebound/rev3/info.json index 3d0df4117767e53a408c24427ace6230816aa269..2f9338afc3413982830035684d7c433fafce3f6a 100644 --- a/keyboards/montsinger/rebound/rev3/info.json +++ b/keyboards/montsinger/rebound/rev3/info.json @@ -8,6 +8,11 @@ "pid": "0x552F", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "community_layouts": ["ortho_4x12"], diff --git a/keyboards/montsinger/rebound/rev4/config.h b/keyboards/montsinger/rebound/rev4/config.h index 3c89fff25ce9ca15109ee9f03ca55942000aa79d..58cf478e13a0a48bf5e338c2b682e7d88d9fbe9a 100644 --- a/keyboards/montsinger/rebound/rev4/config.h +++ b/keyboards/montsinger/rebound/rev4/config.h @@ -30,9 +30,6 @@ diode) #define MATRIX_ROW_PINS { D1, D0, D4, C6, F7, F6, F5, F4 } #define MATRIX_COL_PINS { D7, E6, B4, B5, B2, B3, B1 } -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D3 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/montsinger/rebound/rev4/info.json b/keyboards/montsinger/rebound/rev4/info.json index cde8ba679d09f7c6ce547d5b92594eef1666af7c..dd76ea25e9f3fda5077b709ac0d7ac264c04a5f3 100644 --- a/keyboards/montsinger/rebound/rev4/info.json +++ b/keyboards/montsinger/rebound/rev4/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "community_layouts": ["ortho_4x12"], diff --git a/keyboards/murcielago/info.json b/keyboards/murcielago/info.json index 14f87681bf248b3afa5224cd77389817de83308f..b54258280b7b9c0ab17c1611b199e3b951b51089 100644 --- a/keyboards/murcielago/info.json +++ b/keyboards/murcielago/info.json @@ -8,8 +8,20 @@ "pid": "0x0001", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1"} + ] + }, "split": { - "soft_serial_pin": "E6" + "soft_serial_pin": "E6", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F7"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/murcielago/rev1/config.h b/keyboards/murcielago/rev1/config.h index 223129a9e32dd3265bdb2bacf2a0a1383ee1456c..f334ebc63f4092aae05b7122bb8eded40882d2c2 100644 --- a/keyboards/murcielago/rev1/config.h +++ b/keyboards/murcielago/rev1/config.h @@ -36,12 +36,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS_RIGHT { B3, B7, D4, B6, C6, C7 } #define MATRIX_COL_PINS_RIGHT { D6, D7, D3, B2, B1, B0 } -#define ENCODERS_PAD_A { F0 } -#define ENCODERS_PAD_B { F1 } -#define ENCODERS_PAD_A_RIGHT { F6 } -#define ENCODERS_PAD_B_RIGHT { F7 } - - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/mwstudio/alicekk/config.h b/keyboards/mwstudio/alicekk/config.h index dc85bb4fc7d90a97df52b7cbe466f0dbc1cff9f9..290871bde5d9c149fede0d50a29344aac10f9858 100644 --- a/keyboards/mwstudio/alicekk/config.h +++ b/keyboards/mwstudio/alicekk/config.h @@ -48,6 +48,3 @@ #define RGBLIGHT_HUE_STEP 8 #define RGBLIGHT_SAT_STEP 8 #define RGBLIGHT_VAL_STEP 8 - -#define ENCODERS_PAD_A { B11 } -#define ENCODERS_PAD_B { B10 } diff --git a/keyboards/mwstudio/alicekk/info.json b/keyboards/mwstudio/alicekk/info.json index 19a735ebc5083d9c929cb62f510d7797878e8314..ec0d58b07ec7bf6a1e656ddc1153f5797afd273a 100644 --- a/keyboards/mwstudio/alicekk/info.json +++ b/keyboards/mwstudio/alicekk/info.json @@ -6,6 +6,11 @@ "pid": "0x3201", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B11", "pin_b": "B10"} + ] + }, "processor": "STM32F103", "bootloader": "stm32duino", "layouts": { diff --git a/keyboards/mwstudio/alicekk/keymaps/via/keymap.c b/keyboards/mwstudio/alicekk/keymaps/via/keymap.c index 62068bd43e3cd4b7d29ac246d57bc21afbcbbc65..6c21e053fa91079feb542aad54030d2ff112ff38 100644 --- a/keyboards/mwstudio/alicekk/keymaps/via/keymap.c +++ b/keyboards/mwstudio/alicekk/keymaps/via/keymap.c @@ -53,15 +53,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { #ifdef ENCODER_ENABLE -#define ENCODERS 1 -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = {{6, 4}}; -static keypos_t encoder_ccw[ENCODERS] = {{7, 4}}; - +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = {{6, 4}}; +static keypos_t encoder_ccw[NUM_ENCODERS] = {{7, 4}}; void encoder_action_unregister(void) { -#ifdef ENCODERS - for (uint8_t index = 0; index < ENCODERS; ++index) { + for (uint8_t index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -72,7 +69,6 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -#endif } void encoder_action_register(uint8_t index, bool clockwise) { diff --git a/keyboards/mwstudio/mw65_black/config.h b/keyboards/mwstudio/mw65_black/config.h index 3f5d53797de999f4a1d94e0c950c40a0dd271b23..79d1d5e1b245af9a635a0b9c987f41fa3277a586 100644 --- a/keyboards/mwstudio/mw65_black/config.h +++ b/keyboards/mwstudio/mw65_black/config.h @@ -31,6 +31,3 @@ #define RGBLIGHT_SAT_STEP 8 #define RGBLIGHT_VAL_STEP 8 #endif - -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { D6 } diff --git a/keyboards/mwstudio/mw65_black/info.json b/keyboards/mwstudio/mw65_black/info.json index 030936eaef626c0eb2ba9e04d0b635531ac045b1..23151df686894d687126e037c9d4f9888a02f454 100644 --- a/keyboards/mwstudio/mw65_black/info.json +++ b/keyboards/mwstudio/mw65_black/info.json @@ -8,6 +8,11 @@ "pid": "0x6500", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "D6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layout_aliases": { diff --git a/keyboards/mwstudio/mw65_rgb/config.h b/keyboards/mwstudio/mw65_rgb/config.h index 62cfab574b13ada3f4bca53792172d189060a3c5..2a90d77ee98b90221c979c3e721ba8d289be4419 100644 --- a/keyboards/mwstudio/mw65_rgb/config.h +++ b/keyboards/mwstudio/mw65_rgb/config.h @@ -24,10 +24,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Encoder pins */ -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B2 } - /* RGB Matrix config */ #define RGB_DI_PIN B3 diff --git a/keyboards/mwstudio/mw65_rgb/info.json b/keyboards/mwstudio/mw65_rgb/info.json index d09a0d7b3a7a4c18c345913b781498cca924e178..ee00dd70c13be4f43bcb0be7f8fb07b9c2be3737 100644 --- a/keyboards/mwstudio/mw65_rgb/info.json +++ b/keyboards/mwstudio/mw65_rgb/info.json @@ -8,6 +8,11 @@ "pid": "0x6502", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mwstudio/mw75/config.h b/keyboards/mwstudio/mw75/config.h index 7c8ab74588da9e22131e9b2d961ea2b127186d55..4cb7a8a22cdb972dcf76821a1bd14b2299ded77b 100644 --- a/keyboards/mwstudio/mw75/config.h +++ b/keyboards/mwstudio/mw75/config.h @@ -81,6 +81,3 @@ #define RGBLIGHT_HUE_STEP 8 #define RGBLIGHT_SAT_STEP 8 #define RGBLIGHT_VAL_STEP 8 - -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B2 } diff --git a/keyboards/mwstudio/mw75/info.json b/keyboards/mwstudio/mw75/info.json index bc4404203fc76851b4985a1fee21f2536377995d..866f488a6ee34d863976df6d5f6deb6629074119 100644 --- a/keyboards/mwstudio/mw75/info.json +++ b/keyboards/mwstudio/mw75/info.json @@ -8,6 +8,11 @@ "pid": "0x7501", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/mwstudio/mw75r2/config.h b/keyboards/mwstudio/mw75r2/config.h index bd39ed9b28044aa93023049ab931fae715c610cb..b5f4500d58ff354078158595167c2df2ff237ac2 100644 --- a/keyboards/mwstudio/mw75r2/config.h +++ b/keyboards/mwstudio/mw75r2/config.h @@ -56,6 +56,3 @@ #define RGBLIGHT_HUE_STEP 8 #define RGBLIGHT_SAT_STEP 8 #define RGBLIGHT_VAL_STEP 8 - -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B2 } diff --git a/keyboards/mwstudio/mw75r2/info.json b/keyboards/mwstudio/mw75r2/info.json index 621d9beafae3bf8fd9652750b21edd4d2b4978c2..4d794246eb2d6648f4c01e309155e1bc6065ccf6 100644 --- a/keyboards/mwstudio/mw75r2/info.json +++ b/keyboards/mwstudio/mw75r2/info.json @@ -8,6 +8,11 @@ "pid": "0x7502", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/mwstudio/mw75r2/keymaps/via/keymap.c b/keyboards/mwstudio/mw75r2/keymaps/via/keymap.c index e94667954eea4fc53f79e1305d9f7feb84713849..7b7e1877f5cb8598712c579d574e15dd341c00bd 100644 --- a/keyboards/mwstudio/mw75r2/keymaps/via/keymap.c +++ b/keyboards/mwstudio/mw75r2/keymaps/via/keymap.c @@ -105,15 +105,12 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { } #ifdef ENCODER_ENABLE -#define ENCODERS 1 -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = {{3, 5}}; -static keypos_t encoder_ccw[ENCODERS] = {{4, 5}}; - +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = {{3, 5}}; +static keypos_t encoder_ccw[NUM_ENCODERS] = {{4, 5}}; void encoder_action_unregister(void) { -#ifdef ENCODERS - for (uint8_t index = 0; index < ENCODERS; ++index) { + for (uint8_t index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -124,7 +121,6 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -#endif } void encoder_action_register(uint8_t index, bool clockwise) { diff --git a/keyboards/ncc1701kb/config.h b/keyboards/ncc1701kb/config.h index 959be9fb724e1d0763f6945efa1a46a8fa91c934..adfe863976b27d60a94721824ccfd246cf9f9336 100644 --- a/keyboards/ncc1701kb/config.h +++ b/keyboards/ncc1701kb/config.h @@ -22,11 +22,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D4, D6, D7 } #define MATRIX_COL_PINS { B4, B5, B6 } -/*Encoders */ -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } - - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/ncc1701kb/info.json b/keyboards/ncc1701kb/info.json index 9c26601ae944113d2df62a4b53d80b0f45c0af98..828eefef0255b347ab7d0cbe838d7d309f7a1b68 100644 --- a/keyboards/ncc1701kb/info.json +++ b/keyboards/ncc1701kb/info.json @@ -12,19 +12,24 @@ "pin": "B7", "breathing": true }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { "LAYOUT": { "layout": [ - {"x":0, "y":0}, - {"label":"Encoder", "x":1, "y":0}, - {"x":2, "y":0}, - {"x":0, "y":1}, - {"x":1, "y":1}, + {"x":0, "y":0}, + {"label":"Encoder", "x":1, "y":0}, + {"x":2, "y":0}, + {"x":0, "y":1}, + {"x":1, "y":1}, {"x":2, "y":1}, - {"x":0, "y":2}, - {"x":1, "y":2}, + {"x":0, "y":2}, + {"x":1, "y":2}, {"x":2, "y":2} ] } diff --git a/keyboards/neito/config.h b/keyboards/neito/config.h index b15db6b616782f085c103e879d8d2c454d12fe7e..0e5ca7a6b6fd0545ba2be9b9022a08d1ef4fce06 100644 --- a/keyboards/neito/config.h +++ b/keyboards/neito/config.h @@ -19,9 +19,6 @@ #define MATRIX_COL_PINS { F4, F1, F7, B2, D1, D2, B3, B1 } #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B7 } -#define ENCODERS_PAD_B { B0 } -#define ENCODER_RESOLUTION 4 #define GRAVE_ESC_CTRL_OVERRIDE diff --git a/keyboards/neito/info.json b/keyboards/neito/info.json index 09457315a78b9858c909a6cf0c14f70dbc4c7fe8..7455762b519dc778540346565ded10e8a36364d2 100644 --- a/keyboards/neito/info.json +++ b/keyboards/neito/info.json @@ -8,6 +8,11 @@ "pid": "0xB44C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "B0"} + ] + }, "backlight": { "pin": "B5", "levels": 5, diff --git a/keyboards/neopad/rev1/config.h b/keyboards/neopad/rev1/config.h index 74f394e8c7f8d66afcc5d88ed63fc91ace99d6e3..dce1020b444c2d55ef07d2f478504f768bbbeb13 100755 --- a/keyboards/neopad/rev1/config.h +++ b/keyboards/neopad/rev1/config.h @@ -21,10 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F5 } #define MATRIX_COL_PINS { B3, B2, B6 } -/* Dual rotary encoders */ -#define ENCODERS_PAD_A { D1, D4 } -#define ENCODERS_PAD_B { D0, C6 } - /* Onboard LEDs */ #define LED_00 F6 #define LED_01 F7 diff --git a/keyboards/neopad/rev1/info.json b/keyboards/neopad/rev1/info.json index f0ced98faae9311d0fe95fdab4b069a5061dd724..48654b6941194c7c4b74a609d196aa58ae9c1cce 100755 --- a/keyboards/neopad/rev1/info.json +++ b/keyboards/neopad/rev1/info.json @@ -8,6 +8,12 @@ "pid": "0x0913", "device_version": "0.1.0" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"}, + {"pin_a": "D4", "pin_b": "C6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/nightingale_studios/hailey/config.h b/keyboards/nightingale_studios/hailey/config.h index a0873dfce1a3bf085092b9b2917e94e9f1278a97..dece45d140d57b16a46aab65956c02cdb33b8fe3 100644 --- a/keyboards/nightingale_studios/hailey/config.h +++ b/keyboards/nightingale_studios/hailey/config.h @@ -34,9 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B4 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/nightingale_studios/hailey/info.json b/keyboards/nightingale_studios/hailey/info.json index 52f364ef0ac4751a3830dd3b173bc9c2e94e9608..7316afacb92b7e06b0d9ae05b910a42e3efb774a 100644 --- a/keyboards/nightingale_studios/hailey/info.json +++ b/keyboards/nightingale_studios/hailey/info.json @@ -7,6 +7,11 @@ "pid": "0x4879", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B4"} + ] + }, "processor": "STM32F072", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/nightly_boards/adellein/config.h b/keyboards/nightly_boards/adellein/config.h index 070224510ca9da88c9a46d1431dd69a2125b3309..e4e99106a383cfbc6234e9cb353dd7aade77efcc 100644 --- a/keyboards/nightly_boards/adellein/config.h +++ b/keyboards/nightly_boards/adellein/config.h @@ -51,12 +51,6 @@ along with this program. If not, see . #endif /* Encoders */ - -#define ENCODERS 1 - -#define ENCODERS_PAD_A { C7 } -#define ENCODERS_PAD_B { C6 } - #define ENCODERS_CW_KEY { { 3, 3 } } #define ENCODERS_CCW_KEY { { 1, 3 } } diff --git a/keyboards/nightly_boards/adellein/encoder_action.c b/keyboards/nightly_boards/adellein/encoder_action.c index 042a3871c979babfb6a2bab262abbdf20bf07268..6b553d3969eef52387dff825c7d85391e5093486 100644 --- a/keyboards/nightly_boards/adellein/encoder_action.c +++ b/keyboards/nightly_boards/adellein/encoder_action.c @@ -16,15 +16,12 @@ #include "encoder_action.h" -#ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -#endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -#ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -35,11 +32,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -#endif } void encoder_action_register(uint8_t index, bool clockwise) { -#ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -47,5 +42,4 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -#endif } diff --git a/keyboards/nightly_boards/adellein/info.json b/keyboards/nightly_boards/adellein/info.json index 58b49b329043b6578d8c3b5e84f3042b1e914c6d..7967cfc99b4385f617e097332791c18ae09ff724 100644 --- a/keyboards/nightly_boards/adellein/info.json +++ b/keyboards/nightly_boards/adellein/info.json @@ -8,6 +8,11 @@ "pid": "0x0010", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "C6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/nightly_boards/n40_o/config.h b/keyboards/nightly_boards/n40_o/config.h index 3bd829623a70a1a6a9a6ca8822e04f0f24e6f7a8..055aea6055abcdcb787ef385e42dd0ec8e9cac38 100644 --- a/keyboards/nightly_boards/n40_o/config.h +++ b/keyboards/nightly_boards/n40_o/config.h @@ -51,12 +51,6 @@ along with this program. If not, see . #endif /* Encoders */ - -#define ENCODERS 3 - -#define ENCODERS_PAD_A { F6, F4 , B6 } -#define ENCODERS_PAD_B { F7, F5 , C6 } - #define ENCODERS_CW_KEY { { 2, 4 },{ 4, 4 },{ 6, 4 } } #define ENCODERS_CCW_KEY { { 1, 4 },{ 3, 4 },{ 5, 4 } } diff --git a/keyboards/nightly_boards/n40_o/encoder_action.c b/keyboards/nightly_boards/n40_o/encoder_action.c index 042a3871c979babfb6a2bab262abbdf20bf07268..6b553d3969eef52387dff825c7d85391e5093486 100644 --- a/keyboards/nightly_boards/n40_o/encoder_action.c +++ b/keyboards/nightly_boards/n40_o/encoder_action.c @@ -16,15 +16,12 @@ #include "encoder_action.h" -#ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -#endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -#ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -35,11 +32,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -#endif } void encoder_action_register(uint8_t index, bool clockwise) { -#ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -47,5 +42,4 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -#endif } diff --git a/keyboards/nightly_boards/n40_o/info.json b/keyboards/nightly_boards/n40_o/info.json index e2ccad4db31578bf36406758a5faa9ba3feb44cb..f68bc89be36693d676c5baa19c619ce862fb879a 100644 --- a/keyboards/nightly_boards/n40_o/info.json +++ b/keyboards/nightly_boards/n40_o/info.json @@ -8,6 +8,13 @@ "pid": "0x0009", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F7"}, + {"pin_a": "F4", "pin_b": "F5"}, + {"pin_a": "B6", "pin_b": "C6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/nightly_boards/n60_s/config.h b/keyboards/nightly_boards/n60_s/config.h index c892acd41aa031d69018708dbd93fc3a5894fa21..7ec0b48079d93cd89c47b5d8a83a5e035ebab443 100644 --- a/keyboards/nightly_boards/n60_s/config.h +++ b/keyboards/nightly_boards/n60_s/config.h @@ -35,12 +35,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW /* Encoders */ - -#define ENCODERS 1 - -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D5 } - #define ENCODERS_CW_KEY { { 1, 5 } } #define ENCODERS_CCW_KEY { { 0, 5 } } diff --git a/keyboards/nightly_boards/n60_s/encoder_action.c b/keyboards/nightly_boards/n60_s/encoder_action.c index 042a3871c979babfb6a2bab262abbdf20bf07268..6b553d3969eef52387dff825c7d85391e5093486 100644 --- a/keyboards/nightly_boards/n60_s/encoder_action.c +++ b/keyboards/nightly_boards/n60_s/encoder_action.c @@ -16,15 +16,12 @@ #include "encoder_action.h" -#ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -#endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -#ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -35,11 +32,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -#endif } void encoder_action_register(uint8_t index, bool clockwise) { -#ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -47,5 +42,4 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -#endif } diff --git a/keyboards/nightly_boards/n60_s/info.json b/keyboards/nightly_boards/n60_s/info.json index 37a0d3895c5ee580dede8f758614404e23982ca4..519f31cf2865e9407b7b2ee74fe003c2c24f1018 100644 --- a/keyboards/nightly_boards/n60_s/info.json +++ b/keyboards/nightly_boards/n60_s/info.json @@ -8,6 +8,11 @@ "pid": "0x0007", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/nightly_boards/octopad/config.h b/keyboards/nightly_boards/octopad/config.h index e5e87f04dcd67cb8327fe38b8fd9bd1a94b4a6c8..44868adff68efd0b6daa63293f76d16f4808a2ca 100644 --- a/keyboards/nightly_boards/octopad/config.h +++ b/keyboards/nightly_boards/octopad/config.h @@ -51,12 +51,6 @@ along with this program. If not, see . #endif /* Encoders */ - -#define ENCODERS 2 - -#define ENCODERS_PAD_A { C7, F4 } -#define ENCODERS_PAD_B { C6, F5 } - #define ENCODERS_CW_KEY { { 3, 2 },{ 1, 2 } } #define ENCODERS_CCW_KEY { { 2, 2 },{ 0, 2 } } diff --git a/keyboards/nightly_boards/octopad/encoder_action.c b/keyboards/nightly_boards/octopad/encoder_action.c index 042a3871c979babfb6a2bab262abbdf20bf07268..6b553d3969eef52387dff825c7d85391e5093486 100644 --- a/keyboards/nightly_boards/octopad/encoder_action.c +++ b/keyboards/nightly_boards/octopad/encoder_action.c @@ -16,15 +16,12 @@ #include "encoder_action.h" -#ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -#endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -#ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -35,11 +32,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -#endif } void encoder_action_register(uint8_t index, bool clockwise) { -#ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -47,5 +42,4 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -#endif } diff --git a/keyboards/nightly_boards/octopad/info.json b/keyboards/nightly_boards/octopad/info.json index ce794f28a814dcb4408f3db2541897c851895d43..d6dfc74805f026579e0c675d2be7050ea271fbed 100644 --- a/keyboards/nightly_boards/octopad/info.json +++ b/keyboards/nightly_boards/octopad/info.json @@ -8,6 +8,12 @@ "pid": "0x0004", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C7", "pin_b": "C6"}, + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/nightly_boards/octopadplus/config.h b/keyboards/nightly_boards/octopadplus/config.h index dc61f0a039f17949c72a648af211a650cfe82669..5936e812c8287853eb68e99c2f497ec1f9941923 100644 --- a/keyboards/nightly_boards/octopadplus/config.h +++ b/keyboards/nightly_boards/octopadplus/config.h @@ -34,14 +34,7 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW - -/* Encoders */ - -#define ENCODERS 2 -#define ENCODERS_PAD_A { F0, D1 } -#define ENCODERS_PAD_B { F1, D0 } #define TAP_CODE_DELAY 10 -#define ENCODER_RESOLUTION 5 /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/nightly_boards/octopadplus/info.json b/keyboards/nightly_boards/octopadplus/info.json index 8f0d6766e0c37fe97c88f289def2048c419d651e..0dbd1dee7088ec4289e13c1219f06aa549d81a4f 100644 --- a/keyboards/nightly_boards/octopadplus/info.json +++ b/keyboards/nightly_boards/octopadplus/info.json @@ -8,6 +8,12 @@ "pid": "0x0014", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F0", "pin_b": "F1", "resolution": 5}, + {"pin_a": "D1", "pin_b": "D0", "resolution": 5} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "rgblight": { diff --git a/keyboards/nixkeyboards/day_off/config.h b/keyboards/nixkeyboards/day_off/config.h index 0d85df499763d5a8f0dc7723bd720ed203352a73..a280d81458de6b16354132a594be45dfff060645 100644 --- a/keyboards/nixkeyboards/day_off/config.h +++ b/keyboards/nixkeyboards/day_off/config.h @@ -22,10 +22,3 @@ #define MATRIX_COL_PINS \ { F0, F7, C7, C6, B6, B5, B4, D7, D6, D4, D5, D3, D2, D1, D0 } #define DIODE_DIRECTION COL2ROW - -/* encoder */ -#define ENCODERS_PAD_A \ - { B0 } -#define ENCODERS_PAD_B \ - { B1 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/nixkeyboards/day_off/info.json b/keyboards/nixkeyboards/day_off/info.json index 145da5d2f4a03f33a5226465ce40cf94793222ff..4a9d7bbff6e7413f328dc7536fdd638d960049fd 100644 --- a/keyboards/nixkeyboards/day_off/info.json +++ b/keyboards/nixkeyboards/day_off/info.json @@ -8,6 +8,11 @@ "pid": "0x444F", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "bootmagic": { "matrix": [0, 1] }, diff --git a/keyboards/nopunin10did/kastenwagen1840/config.h b/keyboards/nopunin10did/kastenwagen1840/config.h index 4f154d3c693caca6f2cf3a83f20e47109cc11bda..80a7793edb79e1344cf89c6d9717b7037e20c477 100644 --- a/keyboards/nopunin10did/kastenwagen1840/config.h +++ b/keyboards/nopunin10did/kastenwagen1840/config.h @@ -26,10 +26,5 @@ #define LED_INDICATOR_MID D4 #define LED_INDICATOR_BOT C6 -/* Rotary encoder rotation pins */ -#define ENCODERS_PAD_A { D0, D3 } -#define ENCODERS_PAD_B { D1, D2 } - - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/nopunin10did/kastenwagen1840/info.json b/keyboards/nopunin10did/kastenwagen1840/info.json index 07a1ce0a1025e9ee8b520acc26668e77afad5a4f..bf6b9234b068e5436430a922e95da46240945955 100644 --- a/keyboards/nopunin10did/kastenwagen1840/info.json +++ b/keyboards/nopunin10did/kastenwagen1840/info.json @@ -8,6 +8,12 @@ "pid": "0x4B57", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/nopunin10did/kastenwagen48/config.h b/keyboards/nopunin10did/kastenwagen48/config.h index 92a82ab267a9cff279cd7d7c0add3b3611fb2031..555a0c488f56829370e00f3240f4d68d3c6b7a0e 100644 --- a/keyboards/nopunin10did/kastenwagen48/config.h +++ b/keyboards/nopunin10did/kastenwagen48/config.h @@ -26,10 +26,5 @@ #define LED_INDICATOR_MID D4 #define LED_INDICATOR_BOT C6 -/* Rotary encoder rotation pins */ -#define ENCODERS_PAD_A { D0, D3 } -#define ENCODERS_PAD_B { D1, D2 } - - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/nopunin10did/kastenwagen48/info.json b/keyboards/nopunin10did/kastenwagen48/info.json index a1333c1c5e27f672bfe83b70a23c6e335ca5503e..00fe51e38139864a18a5c5c526b2412c68a36498 100644 --- a/keyboards/nopunin10did/kastenwagen48/info.json +++ b/keyboards/nopunin10did/kastenwagen48/info.json @@ -8,6 +8,12 @@ "pid": "0x4B30", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/np12/config.h b/keyboards/np12/config.h index cd4d98e943c16fef310ed4c34d06bc297cc2557f..3a09f4060d03ec7dd11649c485b9fda9cd9363d7 100644 --- a/keyboards/np12/config.h +++ b/keyboards/np12/config.h @@ -22,8 +22,3 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW - -#define ENCODERS_PAD_A { F4 } -#define ENCODERS_PAD_B { F5 } - - diff --git a/keyboards/np12/info.json b/keyboards/np12/info.json index a5612a8c1498487d406e44483e1f2068e564edd6..7ae6325768fac13e8bbb140b286d7b226b59c4f4 100644 --- a/keyboards/np12/info.json +++ b/keyboards/np12/info.json @@ -8,6 +8,11 @@ "pid": "0x4401", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/nullbitsco/nibble/config.h b/keyboards/nullbitsco/nibble/config.h index 2d203594bf75c8cbac3b1c4617300a67fca3ea38..af85027e64867261bc4948ddb21a96efb4dae936 100644 --- a/keyboards/nullbitsco/nibble/config.h +++ b/keyboards/nullbitsco/nibble/config.h @@ -52,7 +52,3 @@ #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE #define RGBLIGHT_SLEEP - -/* Optional encoder pins */ -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B4 } diff --git a/keyboards/nullbitsco/nibble/info.json b/keyboards/nullbitsco/nibble/info.json index b59fee241153b31d6245222f2abf572ed3cdfc79..5c69cb0e7ecf6d660a57e9d05de473173d54d67d 100644 --- a/keyboards/nullbitsco/nibble/info.json +++ b/keyboards/nullbitsco/nibble/info.json @@ -7,6 +7,11 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B4"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 10, diff --git a/keyboards/nullbitsco/scramble/v1/config.h b/keyboards/nullbitsco/scramble/v1/config.h index 6a7742ce8785fae8879179b5967334322569161e..bb0ee7d7854b4280b42e155f072afdddd8222228 100644 --- a/keyboards/nullbitsco/scramble/v1/config.h +++ b/keyboards/nullbitsco/scramble/v1/config.h @@ -19,7 +19,4 @@ along with this program. If not, see . #pragma once -/* Optional encoder pins */ -#define ENCODERS_PAD_A { D6 } -#define ENCODERS_PAD_B { D7 } #define TAP_CODE_DELAY 10 diff --git a/keyboards/nullbitsco/scramble/v1/info.json b/keyboards/nullbitsco/scramble/v1/info.json index 0acb6993735a047e459c307991bf7658fdfef6fb..77a00d91f4bf10002aab5fe6afebf9a4b1fcd6c2 100644 --- a/keyboards/nullbitsco/scramble/v1/info.json +++ b/keyboards/nullbitsco/scramble/v1/info.json @@ -1,4 +1,9 @@ { + "encoder": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D7"} + ] + }, "processor": "atmega328p", "bootloader": "usbasploader", "matrix_pins": { diff --git a/keyboards/nullbitsco/scramble/v2/config.h b/keyboards/nullbitsco/scramble/v2/config.h index dd2ae627496793288a8560de84733dd9d26cb6da..d3b3c44222cf39b54c6abadba2328deb6c86efaa 100644 --- a/keyboards/nullbitsco/scramble/v2/config.h +++ b/keyboards/nullbitsco/scramble/v2/config.h @@ -19,9 +19,6 @@ along with this program. If not, see . #pragma once -/* Optional encoder pins */ -#define ENCODERS_PAD_A { GP24 } -#define ENCODERS_PAD_B { GP25 } #define TAP_CODE_DELAY 10 /* RP2040-specific defines*/ diff --git a/keyboards/nullbitsco/scramble/v2/info.json b/keyboards/nullbitsco/scramble/v2/info.json index ba27823b3605d8fe1c86f7eb3b0a9b5a192170e9..5255c32205e72d621554dca74bfb2a142c1281be 100644 --- a/keyboards/nullbitsco/scramble/v2/info.json +++ b/keyboards/nullbitsco/scramble/v2/info.json @@ -1,4 +1,9 @@ { + "encoder": { + "rotary": [ + {"pin_a": "GP24", "pin_b": "GP25"} + ] + }, "processor": "RP2040", "bootloader": "rp2040", "matrix_pins": { diff --git a/keyboards/nullbitsco/tidbit/config.h b/keyboards/nullbitsco/tidbit/config.h index 37f05b06e2056b9195b52189fe6176da89af20f6..23b2f5f1a4cff737a678449b9486961215917c6e 100644 --- a/keyboards/nullbitsco/tidbit/config.h +++ b/keyboards/nullbitsco/tidbit/config.h @@ -42,8 +42,3 @@ #define RGBLIGHT_EFFECT_RGB_TEST #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE - -/* Optional encoder pins */ -// Encoders are defined in order. 1: B2 & B3, 2: B4 & B5, 3: D0 & D1, 4: D2 & D3 -#define ENCODERS_PAD_A { B2, B4, D0, D3 } -#define ENCODERS_PAD_B { B3, B5, D1, D2 } diff --git a/keyboards/nullbitsco/tidbit/info.json b/keyboards/nullbitsco/tidbit/info.json index ec014a66809c407af8e36531c1d8b5daeea60ade..cce2a2902cca1cded0a7060f2a1131306197cf9c 100644 --- a/keyboards/nullbitsco/tidbit/info.json +++ b/keyboards/nullbitsco/tidbit/info.json @@ -7,6 +7,14 @@ "pid": "0x6064", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"}, + {"pin_a": "B4", "pin_b": "B5"}, + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "D3", "pin_b": "D2"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/om60/config.h b/keyboards/om60/config.h index 6a647475a28a1214166fabef57bbf512f4d4a61d..9af406eec559736a6c2e49d722accd00b45111f2 100644 --- a/keyboards/om60/config.h +++ b/keyboards/om60/config.h @@ -95,6 +95,3 @@ along with this program. If not, see . #endif #define TAP_CODE_DELAY 10 - -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } diff --git a/keyboards/om60/info.json b/keyboards/om60/info.json index 4da5396c58b2ae1c703ca2035145814ac4cad43c..c33231efe8c6dbe3f6cb50cfe6ea9ab32b9c32e2 100644 --- a/keyboards/om60/info.json +++ b/keyboards/om60/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/onekeyco/dango40/config.h b/keyboards/onekeyco/dango40/config.h index 6d1cd822c9e0703cb55f0c33cecf69dc4c74147f..70eb0ad47f1de313f4477d8289b2a571bf3101d8 100644 --- a/keyboards/onekeyco/dango40/config.h +++ b/keyboards/onekeyco/dango40/config.h @@ -23,9 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F4, F1, F0, C6 } #define MATRIX_COL_PINS { F7, F6, F5, D3, D5, D4, D6, D7, B4, B5, B6, C7, B0 } -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D1 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/onekeyco/dango40/info.json b/keyboards/onekeyco/dango40/info.json index d964098f3d5ce34a5fa3347d158bf6bdb7a9bb02..20836516345179418862203894cfb0b6a4d95f77 100644 --- a/keyboards/onekeyco/dango40/info.json +++ b/keyboards/onekeyco/dango40/info.json @@ -8,6 +8,11 @@ "pid": "0xE9B9", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/orthocode/config.h b/keyboards/orthocode/config.h index adacefb87c973bca920ee8b2616ae58951fff39a..b6a1f1d52cc440f68834931010915b5b6e54ca89 100644 --- a/keyboards/orthocode/config.h +++ b/keyboards/orthocode/config.h @@ -36,9 +36,6 @@ along with this program. If not, see . #define USB_MAX_POWER_CONSUMPTION 100 -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } -#define ENCODER_RESOLUTION 1 #define TAP_CODE_DELAY 10 #define RGB_DI_PIN D5 diff --git a/keyboards/orthocode/info.json b/keyboards/orthocode/info.json index f918fbe2586fcd2a306da3204035bcba0e2223bd..578cb2b907be0b0f2139d103531a636e07eced96 100644 --- a/keyboards/orthocode/info.json +++ b/keyboards/orthocode/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0", "resolution": 1} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "debounce": 0, diff --git a/keyboards/owlab/voice65/hotswap/config.h b/keyboards/owlab/voice65/hotswap/config.h index d41fc84295d95d568e0fab36682ca2677b9e6a95..9a1aacc4fa0788939fe42df78904da5974a5a028 100644 --- a/keyboards/owlab/voice65/hotswap/config.h +++ b/keyboards/owlab/voice65/hotswap/config.h @@ -111,8 +111,4 @@ along with this program. If not, see . # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH #endif -/* Encoder */ -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 diff --git a/keyboards/owlab/voice65/hotswap/info.json b/keyboards/owlab/voice65/hotswap/info.json index b17375dd5cfdc263e126553c8f9621062c97028f..7a5215bf86a8227c15569a37490d59c37a03c4c1 100644 --- a/keyboards/owlab/voice65/hotswap/info.json +++ b/keyboards/owlab/voice65/hotswap/info.json @@ -8,6 +8,11 @@ "pid": "0x564F", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "layout_aliases": { diff --git a/keyboards/owlab/voice65/soldered/config.h b/keyboards/owlab/voice65/soldered/config.h index fb6cb8c7aab71e33b2ed857d203ed27d01c46616..fc5aafd1cef1a541ba297a3d9cd5994b018b12e4 100644 --- a/keyboards/owlab/voice65/soldered/config.h +++ b/keyboards/owlab/voice65/soldered/config.h @@ -112,8 +112,4 @@ along with this program. If not, see . # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH #endif -/* Encoder */ -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } -#define ENCODER_RESOLUTION 4 #define TAP_CODE_DELAY 10 diff --git a/keyboards/owlab/voice65/soldered/info.json b/keyboards/owlab/voice65/soldered/info.json index 8135dcf29d9227d6ffa72dabb7c0543ce8c46e9a..4a3c8a693663e0d11a7f67faa0b9a683714a1c5f 100644 --- a/keyboards/owlab/voice65/soldered/info.json +++ b/keyboards/owlab/voice65/soldered/info.json @@ -8,6 +8,11 @@ "pid": "0x5657", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "community_layouts": ["65_ansi_blocker", "65_ansi_blocker_split_bs", "65_ansi_blocker_tsangan", "65_iso_blocker", "65_iso_blocker_split_bs"], diff --git a/keyboards/p3d/glitch/config.h b/keyboards/p3d/glitch/config.h index c53685cf2ea9134f3722193738b96bce7d8709e3..961897c4d65777cc8db39d297e33520e613f7ed8 100644 --- a/keyboards/p3d/glitch/config.h +++ b/keyboards/p3d/glitch/config.h @@ -46,10 +46,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F7 } -#define ENCODER_RESOLUTION 2 - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/p3d/glitch/info.json b/keyboards/p3d/glitch/info.json index 9de0250289f764e66a5f5d8a79b6a1cb7b06133a..9aee029a07a1751de88d83e6c2c8e1331c81e155 100644 --- a/keyboards/p3d/glitch/info.json +++ b/keyboards/p3d/glitch/info.json @@ -8,6 +8,11 @@ "pid": "0x3568", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F7", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/pabile/p18/config.h b/keyboards/pabile/p18/config.h index 391e429afed72b45b29772f5ddd7e1d551af34f7..2b450e8fff3c520c724a9769f4f929dd605a1385 100644 --- a/keyboards/pabile/p18/config.h +++ b/keyboards/pabile/p18/config.h @@ -22,10 +22,6 @@ along with this program. If not, see . /* pin-out for PROMICRO */ #define MATRIX_ROW_PINS { D1, D0, D4, C6 } #define MATRIX_COL_PINS { D2, D7, E6, B4, B5 } - -/* Encoder position for PROMICRO */ -#define ENCODERS_PAD_A { B6, F6 } -#define ENCODERS_PAD_B { F4, F5 } /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/pabile/p18/info.json b/keyboards/pabile/p18/info.json index ce40842afee880692f8124efbf9b0493fbb79bac..3859d7852f759ed506649a3ee7880a796db6c932 100644 --- a/keyboards/pabile/p18/info.json +++ b/keyboards/pabile/p18/info.json @@ -8,6 +8,12 @@ "pid": "0x6668", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "F4"}, + {"pin_a": "F6", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/pabile/p20/ver1/config.h b/keyboards/pabile/p20/ver1/config.h index a8e50b43c4c9b8d21517d1e4d9b07a6c02aa2ee4..4505e2718e7abecccef5e652410bfbfd16c80e6a 100644 --- a/keyboards/pabile/p20/ver1/config.h +++ b/keyboards/pabile/p20/ver1/config.h @@ -21,9 +21,6 @@ along with this program. If not, see . /* pin-out */ #define MATRIX_ROW_PINS { B3, B4, B5, D7, E6 } #define MATRIX_COL_PINS { D0, B2, D4, B6 } - -#define ENCODERS_PAD_A { F5, F7 } -#define ENCODERS_PAD_B { F6, B1 } /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW \ No newline at end of file diff --git a/keyboards/pabile/p20/ver1/info.json b/keyboards/pabile/p20/ver1/info.json index cea8ee87a0b26f5e66ad1b715e94493639ee0ef0..1c5781995f62d60fc75dfdf469015124704b8428 100644 --- a/keyboards/pabile/p20/ver1/info.json +++ b/keyboards/pabile/p20/ver1/info.json @@ -3,6 +3,12 @@ "usb": { "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"}, + {"pin_a": "F7", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina" } diff --git a/keyboards/palette1202/config.h b/keyboards/palette1202/config.h index 34898d5ee9a2fb579bbbba1400e80068d0ba9740..d3c5f5edc07cafa704196a67f7f768ef293deca3 100644 --- a/keyboards/palette1202/config.h +++ b/keyboards/palette1202/config.h @@ -24,13 +24,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* Encoders */ -#define ENCODERS_PAD_A { F4, F6 } -#define ENCODERS_PAD_B { F5, F7 } -#define ENCODER_RESOLUTION 2 -// if you want to reverse encoder direction -// #define ENCODER_DIRECTION_FLIP - /* Register custom font file */ #ifdef OLED_ENABLE #define OLED_FONT_H "lib/glcdfont.c" diff --git a/keyboards/palette1202/info.json b/keyboards/palette1202/info.json index 0b33a8572276ac5daf091dc96ce3f0a73e37f6ee..6698af203be30488f58641163b608aa091b0d541 100644 --- a/keyboards/palette1202/info.json +++ b/keyboards/palette1202/info.json @@ -8,6 +8,12 @@ "pid": "0x1202", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5", "resolution": 2}, + {"pin_a": "F6", "pin_b": "F7", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/pauperboards/brick/info.json b/keyboards/pauperboards/brick/info.json index a5dd2522cd65539e5473e95419ec72a4a740606a..62a104a337b68999d1e072197be57f1ce370ca5d 100644 --- a/keyboards/pauperboards/brick/info.json +++ b/keyboards/pauperboards/brick/info.json @@ -28,7 +28,7 @@ }, "encoder": { "rotary": [ - { "pin_a": "F4", "pin_b": "F5", "resolution": 4 } + { "pin_a": "F4", "pin_b": "F5" } ] }, "rgblight": { diff --git a/keyboards/pearlboards/atlas/config.h b/keyboards/pearlboards/atlas/config.h index ee2c5f1490777fda499a34e05bfdef9cf20d8e57..92cef2fde0dc245026ee1eb7067049d57fa75432 100644 --- a/keyboards/pearlboards/atlas/config.h +++ b/keyboards/pearlboards/atlas/config.h @@ -34,12 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* Encoder Function */ -#define ENCODERS_PAD_A { E0 } -#define ENCODERS_PAD_B { D7 } -//#define ENCODER_DIRECTION_FLIP -#define ENCODER_RESOLUTION 1 - /* Audio Function */ #define AUDIO_CLICKY #define AUDIO_PIN C6 diff --git a/keyboards/pearlboards/atlas/info.json b/keyboards/pearlboards/atlas/info.json index 31cf97aa4edb72968d04b622957842d97ee38ff4..77c129e79fe9099d965917a7ebe90966ebe1c7c7 100644 --- a/keyboards/pearlboards/atlas/info.json +++ b/keyboards/pearlboards/atlas/info.json @@ -8,6 +8,11 @@ "pid": "0x6964", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E0", "pin_b": "D7", "resolution": 1} + ] + }, "indicators": { "caps_lock": "F4", "num_lock": "F5", diff --git a/keyboards/pearlboards/pandora/config.h b/keyboards/pearlboards/pandora/config.h index bd198d9758acac08f9706698b8fbfed8a109c091..c039db9a159c514ec561b127a726c6ed783172bf 100644 --- a/keyboards/pearlboards/pandora/config.h +++ b/keyboards/pearlboards/pandora/config.h @@ -34,11 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* Encoder Function */ -#define ENCODERS_PAD_A { F6 } -#define ENCODERS_PAD_B { F5 } -//#define ENCODER_DIRECTION_FLIP -#define ENCODER_RESOLUTION 1 #define DIP_SWITCH_PINS { B2, B5 } /*== all animations enabled ==*/ diff --git a/keyboards/pearlboards/pandora/info.json b/keyboards/pearlboards/pandora/info.json index 592fecff65df3bee0bd52566ae9f8786172c3556..0114fb8e78bf6916e5d143551f7c8892a386875d 100644 --- a/keyboards/pearlboards/pandora/info.json +++ b/keyboards/pearlboards/pandora/info.json @@ -8,6 +8,11 @@ "pid": "0x6963", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5", "resolution": 1} + ] + }, "indicators": { "caps_lock": "E6", "on_state": 0 diff --git a/keyboards/pearlboards/zeus/config.h b/keyboards/pearlboards/zeus/config.h index 99473d96e0bdf0f7662d06849d56ab6f12ec9491..deb979dd061dfb83baeee6bd0ee08ff25a6c172e 100644 --- a/keyboards/pearlboards/zeus/config.h +++ b/keyboards/pearlboards/zeus/config.h @@ -34,12 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* Encoder Function */ -#define ENCODERS_PAD_A { E7 } -#define ENCODERS_PAD_B { E6 } -//#define ENCODER_DIRECTION_FLIP -#define ENCODER_RESOLUTION 1 - /* Audio Function */ #define AUDIO_CLICKY #define AUDIO_PIN C6 diff --git a/keyboards/pearlboards/zeus/info.json b/keyboards/pearlboards/zeus/info.json index c5b1fb640c3985e925e13f05fda0f9b65d3779b8..3d2f44a892c9b2b49331414e573df76e13cab71a 100644 --- a/keyboards/pearlboards/zeus/info.json +++ b/keyboards/pearlboards/zeus/info.json @@ -8,6 +8,11 @@ "pid": "0x6966", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E7", "pin_b": "E6", "resolution": 1} + ] + }, "indicators": { "caps_lock": "C5", "num_lock": "C4", diff --git a/keyboards/pearlboards/zeuspad/config.h b/keyboards/pearlboards/zeuspad/config.h index 84c4f2d784f9e9767db46310921b6f0b5d4894dc..f61e11fca90403afbcf7a83004b0bf84c73aed28 100644 --- a/keyboards/pearlboards/zeuspad/config.h +++ b/keyboards/pearlboards/zeuspad/config.h @@ -41,12 +41,6 @@ along with this program. If not, see . #define AUDIO_CLICKY #define AUDIO_PIN C6 -/* Encoder Function */ -#define ENCODERS_PAD_A { D6 } -#define ENCODERS_PAD_B { D4 } -//#define ENCODER_DIRECTION_FLIP -#define ENCODER_RESOLUTION 1 - /*== all animations enabled ==*/ /* If RGBLIGHT_SLEEP defined, the RGB lighting will be switched off when the host goes to sleep */ #define RGB_DI_PIN B7 diff --git a/keyboards/pearlboards/zeuspad/info.json b/keyboards/pearlboards/zeuspad/info.json index 0558b83aad120fb1604f63a305ed4901b635b963..3258e758a87cc1f414d76849807a8eee014fc5d7 100644 --- a/keyboards/pearlboards/zeuspad/info.json +++ b/keyboards/pearlboards/zeuspad/info.json @@ -8,6 +8,11 @@ "pid": "0x6967", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D4", "resolution": 1} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 0, diff --git a/keyboards/pegasus/config.h b/keyboards/pegasus/config.h index d25cf13f5a7948f79cb4992a33ded9366d6b541b..78ade39d772151e27824cf50b069c5b2aa79c6a8 100644 --- a/keyboards/pegasus/config.h +++ b/keyboards/pegasus/config.h @@ -40,11 +40,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -/* Rotary Encoder Definitions */ -#define ENCODERS_PAD_A { D0, D5 } -#define ENCODERS_PAD_B { D1, D3 } - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/pegasus/info.json b/keyboards/pegasus/info.json index 597c7b98e540329207338f20df76377994e7a168..d6663796f870775b488f809cd814f69f1843b7e8 100644 --- a/keyboards/pegasus/info.json +++ b/keyboards/pegasus/info.json @@ -8,6 +8,12 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "D5", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/peranekofactory/tone/rev1/config.h b/keyboards/peranekofactory/tone/rev1/config.h index 9429a2261fc4078656cfd65653d4dad88a6e12e9..c97fab915a3b7dfcf0f5b7e822ad1d85e9d1cd00 100644 --- a/keyboards/peranekofactory/tone/rev1/config.h +++ b/keyboards/peranekofactory/tone/rev1/config.h @@ -17,9 +17,6 @@ along with this program. If not, see . #pragma once -/* Rotary encoder define*/ -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B4 } #define TAP_CODE_DELAY 100 /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ diff --git a/keyboards/peranekofactory/tone/rev1/info.json b/keyboards/peranekofactory/tone/rev1/info.json index 00afdbbdc7aa8ce5d62122a9e33f4f5e0928dc58..24e57770459ed8475968575d4a7ac5321d9030f2 100644 --- a/keyboards/peranekofactory/tone/rev1/info.json +++ b/keyboards/peranekofactory/tone/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B4"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/peranekofactory/tone/rev2/config.h b/keyboards/peranekofactory/tone/rev2/config.h index 9429a2261fc4078656cfd65653d4dad88a6e12e9..c97fab915a3b7dfcf0f5b7e822ad1d85e9d1cd00 100644 --- a/keyboards/peranekofactory/tone/rev2/config.h +++ b/keyboards/peranekofactory/tone/rev2/config.h @@ -17,9 +17,6 @@ along with this program. If not, see . #pragma once -/* Rotary encoder define*/ -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B4 } #define TAP_CODE_DELAY 100 /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ diff --git a/keyboards/peranekofactory/tone/rev2/info.json b/keyboards/peranekofactory/tone/rev2/info.json index 00afdbbdc7aa8ce5d62122a9e33f4f5e0928dc58..24e57770459ed8475968575d4a7ac5321d9030f2 100644 --- a/keyboards/peranekofactory/tone/rev2/info.json +++ b/keyboards/peranekofactory/tone/rev2/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B4"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/percent/canoe_gen2/config.h b/keyboards/percent/canoe_gen2/config.h index 15b2ad262fc8bedd0ad79a4a13d6923265065b9a..7138fe3939172d0595cf379a5f22ec78b7f39062 100644 --- a/keyboards/percent/canoe_gen2/config.h +++ b/keyboards/percent/canoe_gen2/config.h @@ -23,9 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS {B1,B3,B2,F5,F4} #define MATRIX_COL_PINS {B0,D0,C6,B6,B5,B4,D7,D6,D4,D5,D3,D2,D1,F6,F7} -/* Uncomment if your encoder doesn't react to every turn or skips */ -//#define ENCODER_RESOLUTION 2 - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/pica40/rev2/info.json b/keyboards/pica40/rev2/info.json index 99540900b9443d937a518d5a6365cbc29fcebb83..dbef8254ef969c80b8d46633fe1c9d3554218995 100644 --- a/keyboards/pica40/rev2/info.json +++ b/keyboards/pica40/rev2/info.json @@ -40,7 +40,7 @@ } }, "encoder": { - "rotary": [{ "pin_a": "GP7", "pin_b": "GP7" }] + "rotary": [{ "pin_a": "GP7", "pin_b": "GP7", "resolution": 4 }] }, "usb": { "device_version": "1.0.0", diff --git a/keyboards/pica40/rev2/rev2.h b/keyboards/pica40/rev2/rev2.h index 473011fbb030f465d2755048812e68a2a8e1ca4d..95932f781788e6caa473994f38e0e53e522ee127 100644 --- a/keyboards/pica40/rev2/rev2.h +++ b/keyboards/pica40/rev2/rev2.h @@ -16,7 +16,4 @@ # ifndef ENCODER_MAP_KEY_DELAY # define ENCODER_MAP_KEY_DELAY 2 # endif -# ifndef ENCODER_RESOLUTION -# define ENCODER_RESOLUTION 4 -# endif #endif diff --git a/keyboards/planck/ez/config.h b/keyboards/planck/ez/config.h index a569b3d59083ad16e464b34cc1032bf1e8ad7ab7..04bfc314ce6d54f7fc1f621a66cc530f3bf2b0b3 100644 --- a/keyboards/planck/ez/config.h +++ b/keyboards/planck/ez/config.h @@ -35,9 +35,6 @@ #define MATRIX_ROW_PINS { A10, A9, A8, B15, C13, C14, C15, A2 } #define MATRIX_COL_PINS { B11, B10, B2, B1, A7, B0 } -#define ENCODERS_PAD_A { B12 } -#define ENCODERS_PAD_B { B13 } - #define MUSIC_MAP #undef AUDIO_VOICES #undef AUDIO_PIN diff --git a/keyboards/planck/ez/info.json b/keyboards/planck/ez/info.json index 9e400ee45feb360e1d5d49ab77854e7f860ec9e9..ae67be691dde8c192ebfc606feeb70b833301b5b 100644 --- a/keyboards/planck/ez/info.json +++ b/keyboards/planck/ez/info.json @@ -6,6 +6,11 @@ "vid": "0x3297", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "community_layouts": ["ortho_4x12", "planck_mit"], diff --git a/keyboards/planck/rev6/config.h b/keyboards/planck/rev6/config.h index 0852b7baa96b78129146a21be2d7ce38c3e4dcff..a60c086b5b65dd160cceb7f8c1bc71014501f876 100644 --- a/keyboards/planck/rev6/config.h +++ b/keyboards/planck/rev6/config.h @@ -34,10 +34,6 @@ #define MATRIX_ROW_PINS { A10, A9, A8, B15, C13, C14, C15, A2 } #define MATRIX_COL_PINS { B11, B10, B2, B1, A7, B0 } - -#define ENCODERS_PAD_A { B12 } -#define ENCODERS_PAD_B { B13 } - #define DIP_SWITCH_PINS { B14, A15, A0, B9 } #define MUSIC_MAP diff --git a/keyboards/planck/rev6/info.json b/keyboards/planck/rev6/info.json index 6e46d01954c72e70fbc55ee282b948fb8bb587ad..9cc60ab5f021e0f88d67044e9f15651f58822330 100644 --- a/keyboards/planck/rev6/info.json +++ b/keyboards/planck/rev6/info.json @@ -8,6 +8,11 @@ "pid": "0xA4F9", "device_version": "0.0.6" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C", diff --git a/keyboards/planck/rev6_drop/config.h b/keyboards/planck/rev6_drop/config.h index bd78de6257d84247eff1e7b7ab3ba902f681eb1c..192d3fc6d8e9d502557463a31dbd084f4dd3d606 100644 --- a/keyboards/planck/rev6_drop/config.h +++ b/keyboards/planck/rev6_drop/config.h @@ -36,12 +36,6 @@ #define MATRIX_COL_PINS \ { B11, B10, B2, B1, A7, B0 } - -#define ENCODERS_PAD_A \ - { B12 } -#define ENCODERS_PAD_B \ - { B13 } - #define DIP_SWITCH_PINS \ { B14, A15, A0, B9 } diff --git a/keyboards/planck/rev6_drop/info.json b/keyboards/planck/rev6_drop/info.json index f2a3db5082698d9a0f0889699d77ebac8e381c32..828f0c20b8ec5af022867c757de14997f368d085 100644 --- a/keyboards/planck/rev6_drop/info.json +++ b/keyboards/planck/rev6_drop/info.json @@ -8,6 +8,11 @@ "pid": "0xA4F9", "device_version": "0.0.6" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "community_layouts": ["ortho_4x12", "planck_mit"], diff --git a/keyboards/planck/thk/config.h b/keyboards/planck/thk/config.h index ed6b52d05c4af116584c0f2f64eac34ecdd7c34b..bd93164345c56f91ba07b526127d7d2ce6c90f2a 100644 --- a/keyboards/planck/thk/config.h +++ b/keyboards/planck/thk/config.h @@ -26,9 +26,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { A7, A6, A5, A4 } #define MATRIX_COL_PINS { D7, C2, C3, C4, C5, C6, C7, A3, A2, A1, A0, B0 } -#define ENCODERS_PAD_A { B4, B2 } -#define ENCODERS_PAD_B { B3, B1 } - #define TAPPING_TOGGLE 3 #define DIP_SWITCH_PINS { D0, D1, D4, D6 } diff --git a/keyboards/planck/thk/info.json b/keyboards/planck/thk/info.json index 8824929a3900097d6d992d40c4eabb882f947550..50ee36da3bf364777028c387ef90979201539a21 100644 --- a/keyboards/planck/thk/info.json +++ b/keyboards/planck/thk/info.json @@ -8,6 +8,12 @@ "pid": "0x25A7", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B3"}, + {"pin_a": "B2", "pin_b": "B1"} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "layout_aliases": { diff --git a/keyboards/pluckey/config.h b/keyboards/pluckey/config.h index 47d5538ca83fe1df9ce44900ed965bc1e2b112fe..21c01e89ee57573ae7daeae45dc20496d28e7f35 100644 --- a/keyboards/pluckey/config.h +++ b/keyboards/pluckey/config.h @@ -31,14 +31,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS { D1, D0, D4, C6, D7, E6, F7 } #define DIODE_DIRECTION COL2ROW -/* encoder support */ -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } -#define ENCODER_RESOLUTION 2 -#define ENCODERS_PAD_A_RIGHT { B2 } -#define ENCODERS_PAD_B_RIGHT { B3 } -#define ENCODER_RESOLUTION_RIGHT 2 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/pluckey/info.json b/keyboards/pluckey/info.json index 019fdd1acde8e765854acc5782196f34bd91c893..faeb0df2f42acb68468ebc0d5b515fc6fb805106 100644 --- a/keyboards/pluckey/info.json +++ b/keyboards/pluckey/info.json @@ -8,8 +8,20 @@ "pid": "0x91CE", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2", "resolution": 2} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3", "resolution": 2} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/pohjolaworks/louhi/config.h b/keyboards/pohjolaworks/louhi/config.h index 11c688359045bd0b1d08013186f3513b2431938d..12721a16b05765ad209d94afaefdfa0c6fc5e62f 100644 --- a/keyboards/pohjolaworks/louhi/config.h +++ b/keyboards/pohjolaworks/louhi/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Encoder pins */ -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } - #define RGB_DI_PIN B5 #ifdef RGB_DI_PIN # define RGBLED_NUM 14 diff --git a/keyboards/pohjolaworks/louhi/info.json b/keyboards/pohjolaworks/louhi/info.json index a6d3fa1d357171f11947588c3bbc5a82e22703af..0185fe83bbda4cdd69e60419996d1a1dbc033ddd 100644 --- a/keyboards/pohjolaworks/louhi/info.json +++ b/keyboards/pohjolaworks/louhi/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/preonic/rev3/config.h b/keyboards/preonic/rev3/config.h index a777ded38b85d82b351c0feed84dd722d00417b9..2269aef97fe608a1f1da6e98c763aebf22ff1b77 100644 --- a/keyboards/preonic/rev3/config.h +++ b/keyboards/preonic/rev3/config.h @@ -22,9 +22,6 @@ #define MATRIX_ROW_PINS { A10, A9, A8, B15, C13, C14, C15, A2, A3, A6 } #define MATRIX_COL_PINS { B11, B10, B2, B1, A7, B0 } -#define ENCODERS_PAD_A { B12 } -#define ENCODERS_PAD_B { B13 } - #define DIP_SWITCH_PINS { B14, A15, A0, B9 } #define MUSIC_MAP diff --git a/keyboards/preonic/rev3/info.json b/keyboards/preonic/rev3/info.json index 0f396fc87efff8df1960caf6d37df8104f88b82d..cc3b9444712696f18b370e108faa9f95f2321e7a 100644 --- a/keyboards/preonic/rev3/info.json +++ b/keyboards/preonic/rev3/info.json @@ -6,6 +6,11 @@ "pid": "0xA649", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "board": "QMK_PROTON_C", diff --git a/keyboards/preonic/rev3_drop/config.h b/keyboards/preonic/rev3_drop/config.h index 071b7bc667af0a0d3e1c478d0cc1a1be71096d1e..4d1bfe67b9b52739772482683ff9f8bf046990b1 100644 --- a/keyboards/preonic/rev3_drop/config.h +++ b/keyboards/preonic/rev3_drop/config.h @@ -22,9 +22,6 @@ #define MATRIX_ROW_PINS { A10, A9, A8, B15, C13, C14, C15, A2, A3, A6 } #define MATRIX_COL_PINS { B11, B10, B2, B1, A7, B0 } -#define ENCODERS_PAD_A { B12 } -#define ENCODERS_PAD_B { B13 } - #define DIP_SWITCH_PINS { B14, A15, A0, B9 } #define MUSIC_MAP diff --git a/keyboards/preonic/rev3_drop/info.json b/keyboards/preonic/rev3_drop/info.json index c8095a62e6967764cf41386f980408deb8d0ea11..3f32a10b363d53e35e84ecea47e6c5e399caff52 100644 --- a/keyboards/preonic/rev3_drop/info.json +++ b/keyboards/preonic/rev3_drop/info.json @@ -6,6 +6,11 @@ "pid": "0xA649", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "B12", "pin_b": "B13"} + ] + }, "processor": "STM32F303", "bootloader": "stm32-dfu", "community_layouts": ["ortho_5x12"], diff --git a/keyboards/program_yoink/config.h b/keyboards/program_yoink/config.h index 417ab0e4730ac13b45dbc0a9565dff48255a0d40..261ebaca5bc81201d5f03c35e81ff3c26a77e5ae 100644 --- a/keyboards/program_yoink/config.h +++ b/keyboards/program_yoink/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/*Encoder Definition*/ -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } - /*RGB*/ #define RGB_DI_PIN D4 #ifdef RGB_DI_PIN diff --git a/keyboards/program_yoink/ortho/info.json b/keyboards/program_yoink/ortho/info.json index e27a7b6618004efe08af2e895eeb468e3424dd77..eeab79d169c3a7897cc3f547bc64a71d2667cc3a 100644 --- a/keyboards/program_yoink/ortho/info.json +++ b/keyboards/program_yoink/ortho/info.json @@ -8,6 +8,11 @@ "pid": "0xF10C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/program_yoink/staggered/info.json b/keyboards/program_yoink/staggered/info.json index 7c98c3ed717db2445bcd8d1e1fc4d6584e8dad56..252a110e8ba0a1060a6d15541323f6d6a45a7d86 100644 --- a/keyboards/program_yoink/staggered/info.json +++ b/keyboards/program_yoink/staggered/info.json @@ -8,6 +8,11 @@ "pid": "0xF10B", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/projectcain/relic/config.h b/keyboards/projectcain/relic/config.h index d93c7ee5d2a1457335bf72aed1b1fe83e215ae32..baa5b5263bd480f3f7e3df8be021aa8ba86d31d8 100644 --- a/keyboards/projectcain/relic/config.h +++ b/keyboards/projectcain/relic/config.h @@ -16,9 +16,6 @@ along with this program. If not, see . */ #pragma once -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { D6 } - /* * Keyboard Matrix Assignments diff --git a/keyboards/projectcain/relic/info.json b/keyboards/projectcain/relic/info.json index 5c07c8e1063c616424838aaf61e55b70eff88441..9d0820b4e6263e545b783c226f1bd7bce5a0e8eb 100644 --- a/keyboards/projectcain/relic/info.json +++ b/keyboards/projectcain/relic/info.json @@ -8,6 +8,11 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "D6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/projectcain/vault35/config.h b/keyboards/projectcain/vault35/config.h index 0d40b434e8ee5da867b282d7dc7015b6ec077185..457e2f0ab3843638da2ea83c3fd7f3c755bf1ae0 100644 --- a/keyboards/projectcain/vault35/config.h +++ b/keyboards/projectcain/vault35/config.h @@ -31,10 +31,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D6 } -#define ENCODERS_PAD_B { D7 } -#define ENCODER_RESOLUTION 2 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/projectcain/vault35/info.json b/keyboards/projectcain/vault35/info.json index 467c8293e8083fbfdf2578500d8fa18249765a66..488d81b6b845e339d7fb6714536c03c01d0aa0bd 100644 --- a/keyboards/projectcain/vault35/info.json +++ b/keyboards/projectcain/vault35/info.json @@ -8,6 +8,11 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D7", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/projectcain/vault45/config.h b/keyboards/projectcain/vault45/config.h index 1a54f1568768fd6a9ca05708df34bde0bf0e00a5..b70109bfa3077a7b80a19efb4fa80818a5541aaf 100644 --- a/keyboards/projectcain/vault45/config.h +++ b/keyboards/projectcain/vault45/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B3, D1 } -#define ENCODERS_PAD_B { B2, D2 } -#define ENCODER_RESOLUTION 2 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/projectcain/vault45/info.json b/keyboards/projectcain/vault45/info.json index a8a4dcba8ec9bcb52572ed3c13ec0fccf2ffdf98..ecfa953fd41e01a0e212062705ab5d7ad9dd2e1c 100644 --- a/keyboards/projectcain/vault45/info.json +++ b/keyboards/projectcain/vault45/info.json @@ -8,6 +8,12 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2", "resolution": 2}, + {"pin_a": "D1", "pin_b": "D2", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layout_aliases": { diff --git a/keyboards/protozoa/p01/config.h b/keyboards/protozoa/p01/config.h index 4ebfa1b381d48fc99c040be0d0b161e1b88390fb..e3f3faca9cc5d93cc767a90d8dc80056d28c6c52 100644 --- a/keyboards/protozoa/p01/config.h +++ b/keyboards/protozoa/p01/config.h @@ -21,11 +21,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B1, B2, B10, B11, B12, B13 } #define MATRIX_COL_PINS { A14, A15, B3, B4, B5, B6, B7, B8, B9, A0, A1, A2, A3, A4, A5, A6, A7, B0 } -/* Encoder */ -#define ENCODERS 1 -#define ENCODERS_PAD_A { B15 } -#define ENCODERS_PAD_B { B14 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/protozoa/p01/info.json b/keyboards/protozoa/p01/info.json index d4c6872ef5a20f28009a0b358aaec3d4e78c56a9..77e1449458bfacce924f767cbc762bb5ce939822 100644 --- a/keyboards/protozoa/p01/info.json +++ b/keyboards/protozoa/p01/info.json @@ -8,6 +8,11 @@ "pid": "0x5031", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B15", "pin_b": "B14"} + ] + }, "processor": "STM32F072", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/psuieee/pluto12/config.h b/keyboards/psuieee/pluto12/config.h index bcadefe2ff5941a049258fe1a997aa30f63df296..91922c6d95341437eb7c88a8f6e8b02ddd0633ef 100644 --- a/keyboards/psuieee/pluto12/config.h +++ b/keyboards/psuieee/pluto12/config.h @@ -8,11 +8,6 @@ #define MATRIX_ROW_PINS { D0, D4, C6 } #define MATRIX_COL_PINS { D7, E6, B4, B5 } -/* Encoder Assignments */ -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B2 } -#define ENCODER_RESOLUTION 4 - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/psuieee/pluto12/info.json b/keyboards/psuieee/pluto12/info.json index 422973a6d1a05c5da588e12252ba76f64c4da299..752b2ab97f257e4959f5892cf6193d31c0080cd1 100644 --- a/keyboards/psuieee/pluto12/info.json +++ b/keyboards/psuieee/pluto12/info.json @@ -8,6 +8,11 @@ "pid": "0x7012", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/pteron36/config.h b/keyboards/pteron36/config.h index a053dc0c1657083221ca9cbd2b99f59e07a9c3cd..be1de23f838896f1e38e6501f0d5116790c787dc 100644 --- a/keyboards/pteron36/config.h +++ b/keyboards/pteron36/config.h @@ -58,14 +58,6 @@ along with this program. If not, see . // for via #define DYNAMIC_KEYMAP_LAYER_COUNT 7 -//left encoder -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } - -//right encoder -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } - //RGB Underglow #define RGB_DI_PIN B6 #define RGBLED_NUM 10 diff --git a/keyboards/pteron36/info.json b/keyboards/pteron36/info.json index 6cd22fe6c794ddeea59364052877b286c3d3d4eb..c65b15cfb25370bd6ae9141a648b22be08c314cc 100644 --- a/keyboards/pteron36/info.json +++ b/keyboards/pteron36/info.json @@ -8,8 +8,20 @@ "pid": "0x5054", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "split": { - "soft_serial_pin": "D3" + "soft_serial_pin": "D3", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/punk75/config.h b/keyboards/punk75/config.h index 4e0699c9739bb02afea24ed9c098a41068d58274..ba9c6fdc712499b89abebfda8d27ee8f5e1844e7 100644 --- a/keyboards/punk75/config.h +++ b/keyboards/punk75/config.h @@ -32,10 +32,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS { C2, C3, C6, C5, C4, A7, A6, A5, A4, B4, A3, B3, A2, B2, A1 } #define LED A0 -#define ENCODERS_PAD_A { D0, B1} -#define ENCODERS_PAD_B { D1, B0 } - - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/punk75/info.json b/keyboards/punk75/info.json index 77d5495d8679fabe6a9766e48e6ee71329f2bf0d..b232007bb24fd15d287dabed39ca784abcbe7425 100644 --- a/keyboards/punk75/info.json +++ b/keyboards/punk75/info.json @@ -8,6 +8,12 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "B1", "pin_b": "B0"} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "community_layouts": ["ortho_5x15"], diff --git a/keyboards/qpockets/eggman/config.h b/keyboards/qpockets/eggman/config.h index c86f64f0894bf37c77259f5060e90be8c1a50361..eac213400ab6ee67c2cf617365a4f165848c2dc7 100644 --- a/keyboards/qpockets/eggman/config.h +++ b/keyboards/qpockets/eggman/config.h @@ -23,10 +23,3 @@ /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW - -/* ROTARY ENCODERS */ -#define ENCODERS_PAD_A { C6, D4 } -#define ENCODERS_PAD_B { C7, D5 } - -#define ENCODER_RESOLUTION 4 -//#define ENCODER_DIRECTION_FLIP diff --git a/keyboards/qpockets/eggman/info.json b/keyboards/qpockets/eggman/info.json index 5d63633cfaec80170a4cde22e0c659ea25d99754..989402411db8456701d96efe62cdaafb80fee22e 100644 --- a/keyboards/qpockets/eggman/info.json +++ b/keyboards/qpockets/eggman/info.json @@ -8,6 +8,12 @@ "pid": "0x656D", "device_version": "10.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "C7"}, + {"pin_a": "D4", "pin_b": "D5"} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/qpockets/space_space/rev1/config.h b/keyboards/qpockets/space_space/rev1/config.h index 3970a07197921870e400eb77d1fbd32d812f8811..22c2bc73dee2dcef6142cce4842c03bfac02af92 100644 --- a/keyboards/qpockets/space_space/rev1/config.h +++ b/keyboards/qpockets/space_space/rev1/config.h @@ -26,14 +26,4 @@ /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* ROTARY ENCODERS */ -#define ENCODERS_PAD_A \ - { B3, D6 } -#define ENCODERS_PAD_B \ - { B2, D7 } - -#define ENCODER_RESOLUTIONS \ - { 3, 4 } -//#define ENCODER_DIRECTION_FLIP - #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/qpockets/space_space/rev1/info.json b/keyboards/qpockets/space_space/rev1/info.json index 394a03b5ee031fd95ea7f18c0a25b4483c636002..cd9dcb56a8a3eda3125a2fa3f6fa57b2ecab894d 100644 --- a/keyboards/qpockets/space_space/rev1/info.json +++ b/keyboards/qpockets/space_space/rev1/info.json @@ -8,6 +8,12 @@ "pid": "0x7373", "device_version": "30.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2", "resolution": 3}, + {"pin_a": "D6", "pin_b": "D7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 7, diff --git a/keyboards/qpockets/space_space/rev2/config.h b/keyboards/qpockets/space_space/rev2/config.h index f3dff6bd3d51db320f8b14fefe120d832b1f4e04..26b85360c43fd26a8612d6dacf77441a75b066ca 100644 --- a/keyboards/qpockets/space_space/rev2/config.h +++ b/keyboards/qpockets/space_space/rev2/config.h @@ -26,14 +26,6 @@ /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* ROTARY ENCODERS */ -#define ENCODERS_PAD_A \ - { B4, C7 } -#define ENCODERS_PAD_B \ - { D7, F7 } - -#define ENCODER_RESOLUTION 3 - #define LOCKING_SUPPORT_ENABLE #define RGB_DI_PIN F0 diff --git a/keyboards/qpockets/space_space/rev2/info.json b/keyboards/qpockets/space_space/rev2/info.json index e895a35d4de326a808489783da536d22a9da7c91..580ab0a4d5238e255523f8c85a71ccfccc691708 100644 --- a/keyboards/qpockets/space_space/rev2/info.json +++ b/keyboards/qpockets/space_space/rev2/info.json @@ -8,6 +8,12 @@ "pid": "0x7373", "device_version": "30.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "D7", "resolution": 3}, + {"pin_a": "C7", "pin_b": "F7", "resolution": 3} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/qpockets/wanten/config.h b/keyboards/qpockets/wanten/config.h index 4672368ef5560166b522e13df283d04808c41cc6..a811be9a74c0c5c053c6b3138e342217dc32c246 100644 --- a/keyboards/qpockets/wanten/config.h +++ b/keyboards/qpockets/wanten/config.h @@ -34,13 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* ROTARY ENCODERS */ -#define ENCODERS_PAD_A { F5, D6 } -#define ENCODERS_PAD_B { F6, D7 } - -#define ENCODER_RESOLUTION 4 -//#define ENCODER_DIRECTION_FLIP - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/qpockets/wanten/info.json b/keyboards/qpockets/wanten/info.json index 61ff2f78dae7920a1c9b027afa75522af4415985..e35237a358b17c62d75d24e02185ed3824d184fc 100644 --- a/keyboards/qpockets/wanten/info.json +++ b/keyboards/qpockets/wanten/info.json @@ -8,6 +8,12 @@ "pid": "0x7774", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F6"}, + {"pin_a": "D6", "pin_b": "D7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 4, diff --git a/keyboards/qvex/lynepad/config.h b/keyboards/qvex/lynepad/config.h index 7c6547aabd408581641719a419aa0034abd8a837..830b5364a5e98e663929c9a2863c6bef59821c6e 100644 --- a/keyboards/qvex/lynepad/config.h +++ b/keyboards/qvex/lynepad/config.h @@ -25,10 +25,6 @@ along with this program. If not, see . /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Encoders */ -#define ENCODERS_PAD_A { D0, B5 } -#define ENCODERS_PAD_B { D1, D6 } - /* LEDs */ #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN diff --git a/keyboards/qvex/lynepad/info.json b/keyboards/qvex/lynepad/info.json index ef0088d47a531b47408a92a60b975304c9b53965..f2930137d26f59da182aa5e99ab0aa56ea065047 100644 --- a/keyboards/qvex/lynepad/info.json +++ b/keyboards/qvex/lynepad/info.json @@ -8,6 +8,12 @@ "pid": "0x4C50", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "B5", "pin_b": "D6"}, + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/qwertlekeys/calice/config.h b/keyboards/qwertlekeys/calice/config.h index 9eb4366cb0e9e2cba6a7e0b84c709b47d392d413..4de51720eaa05125696fab06456ded896b3226f5 100644 --- a/keyboards/qwertlekeys/calice/config.h +++ b/keyboards/qwertlekeys/calice/config.h @@ -20,10 +20,6 @@ #define MATRIX_ROW_PINS {F0, F1, F5, F4, C6, C7, B5, B6, D4, D2, D5, D3} #define MATRIX_COL_PINS {D7, B4, F7, F6, D1, B7, B3, B2} -/* Envoder */ -#define ENCODERS_PAD_A {B0} -#define ENCODERS_PAD_B {B1} - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/qwertlekeys/calice/info.json b/keyboards/qwertlekeys/calice/info.json index 1d3f5cb90a514959d1d37d6c8a557ba9801b5201..5a425f97a864046a541833e5a33a68e94041e62c 100644 --- a/keyboards/qwertlekeys/calice/info.json +++ b/keyboards/qwertlekeys/calice/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "indicators": { "caps_lock": "D6" }, diff --git a/keyboards/rainkeebs/rainkeeb/config.h b/keyboards/rainkeebs/rainkeeb/config.h index 8f7a2d21919105bd5f6989d97f8eb17e84fb9940..d26c7024d94383ab0d8bdb9a4e189dfd2015f4f9 100644 --- a/keyboards/rainkeebs/rainkeeb/config.h +++ b/keyboards/rainkeebs/rainkeeb/config.h @@ -28,8 +28,3 @@ /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -/* encoder pads */ -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B6 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/rainkeebs/rainkeeb/info.json b/keyboards/rainkeebs/rainkeeb/info.json index 34705a980a500da0b0e8c362fac2096eb445105b..bddacf6ddb171b69717bd4d3e5799f27914a5ca6 100644 --- a/keyboards/rainkeebs/rainkeeb/info.json +++ b/keyboards/rainkeebs/rainkeeb/info.json @@ -8,6 +8,11 @@ "pid": "0x726B", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/rart/rart4x4/config.h b/keyboards/rart/rart4x4/config.h index 6a050234236bfc4544d3feab0b7303f9f700dfb9..d884b126808348a67d895c8aa87e5e75035fb533 100644 --- a/keyboards/rart/rart4x4/config.h +++ b/keyboards/rart/rart4x4/config.h @@ -31,9 +31,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { F6, D7 } -#define ENCODERS_PAD_B { F5, E6 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/rart/rart4x4/info.json b/keyboards/rart/rart4x4/info.json index 1b01a4d22625f639c4a9a6391400173d9c4b22f1..ac3014fe7a14ae7295a105ecdd0a5a3d36e4d851 100644 --- a/keyboards/rart/rart4x4/info.json +++ b/keyboards/rart/rart4x4/info.json @@ -8,6 +8,12 @@ "pid": "0x0004", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F6", "pin_b": "F5"}, + {"pin_a": "D7", "pin_b": "E6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "community_layouts": ["ortho_4x4"], diff --git a/keyboards/rart/rart75/config.h b/keyboards/rart/rart75/config.h index 14d8f62893cc39ffdad77015fd23f6abfa8351ba..eb5b0be4227297d97fbbe21974cddbba3b8a12b7 100644 --- a/keyboards/rart/rart75/config.h +++ b/keyboards/rart/rart75/config.h @@ -30,6 +30,3 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -#define ENCODERS_PAD_A { E6 } -#define ENCODERS_PAD_B { B0 } diff --git a/keyboards/rart/rart75/info.json b/keyboards/rart/rart75/info.json index 81781cdb7e5bb589009b36528c0feaf05c19a6bf..40c5f39bebb9e41fd6314f42bfdaa5560684d663 100644 --- a/keyboards/rart/rart75/info.json +++ b/keyboards/rart/rart75/info.json @@ -8,6 +8,11 @@ "pid": "0x0075", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/rart/rart75hs/config.h b/keyboards/rart/rart75hs/config.h index dec3ab7cc22f5b20235c0df88d826827baa633dd..f6817e71cea3100db2965a335144f1fc9b2b94f4 100644 --- a/keyboards/rart/rart75hs/config.h +++ b/keyboards/rart/rart75hs/config.h @@ -31,10 +31,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { C1 } -#define ENCODERS_PAD_B { C2 } -#define ENCODER_RESOLUTION 4 //default/suggested - #define RGB_DI_PIN C0 #ifdef RGB_DI_PIN #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/rart/rart75hs/info.json b/keyboards/rart/rart75hs/info.json index a7ac977112b9d25f62c8f9ef96423a9ac6a8e7b2..27984a03d75cefc21385ce1415a4496495973611 100644 --- a/keyboards/rart/rart75hs/info.json +++ b/keyboards/rart/rart75hs/info.json @@ -8,6 +8,11 @@ "pid": "0x5575", "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "C1", "pin_b": "C2"} + ] + }, "indicators": { "caps_lock": "D4", "on_state": 0 diff --git a/keyboards/rart/rart75m/config.h b/keyboards/rart/rart75m/config.h index 1bb4ae52635893e71192da8cd49c318bf81dcd74..0b08f0322f27b79116698385468f209d9991d0ad 100644 --- a/keyboards/rart/rart75m/config.h +++ b/keyboards/rart/rart75m/config.h @@ -31,10 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { C7, B3, B1, B0, D3, D2 } #define MATRIX_COL_PINS { B2, D4, F0, C6, F1, D7, F4, E6, F5, B4, F6, B5, F7, B6 } -#define ENCODERS_PAD_B { B7 } -#define ENCODERS_PAD_A { D6 } -#define ENCODER_RESOLUTION 2 //default/suggested - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/rart/rart75m/info.json b/keyboards/rart/rart75m/info.json index 094bb55b8d0d2c5f15faa394c14f2b918da2946a..1d0f0e235804c3b5fa92f781e9545dacbd3948fd 100644 --- a/keyboards/rart/rart75m/info.json +++ b/keyboards/rart/rart75m/info.json @@ -8,6 +8,11 @@ "pid": "0x6075", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B7", "pin_b": "D6", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/rart/rartland/config.h b/keyboards/rart/rartland/config.h index facb9f1486ac67548930fcaaa1ee1b0dd717ad1e..aee0fdd862935db4e5c9b4f093d4656c3d7b0074 100644 --- a/keyboards/rart/rartland/config.h +++ b/keyboards/rart/rartland/config.h @@ -31,10 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B4, A7, A5, A6, C3 } #define MATRIX_COL_PINS { B0, A1, B1, A2, B2, A3, B3, A4, C7, C6, D0, C5, D1, C4 } -#define ENCODERS_PAD_B { D5 } -#define ENCODERS_PAD_A { C2 } -#define ENCODER_RESOLUTION 2 //default/suggested - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/rart/rartland/info.json b/keyboards/rart/rartland/info.json index 8dbc85f13f989e93351a971b806b7ea0afab1b8d..5cfc6b7b70ef176e15f292c05f6d8ea64eea5e72 100644 --- a/keyboards/rart/rartland/info.json +++ b/keyboards/rart/rartland/info.json @@ -8,6 +8,11 @@ "pid": "0x6065", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "C2", "resolution": 2} + ] + }, "indicators": { "caps_lock": "A0", "on_state": 0 diff --git a/keyboards/rart/rartpad/config.h b/keyboards/rart/rartpad/config.h index 5a8d6f7849c20d1a2bf9da9c589541977a3bd7ee..4a8e14be49f7934665cff049a33ed3b955d555fa 100644 --- a/keyboards/rart/rartpad/config.h +++ b/keyboards/rart/rartpad/config.h @@ -31,9 +31,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { B3, F5 } -#define ENCODERS_PAD_B { B1, F4 } - #define RGB_DI_PIN F7 #ifdef RGB_DI_PIN #define RGBLIGHT_EFFECT_BREATHING diff --git a/keyboards/rart/rartpad/info.json b/keyboards/rart/rartpad/info.json index 03918a6886d8ef9d48b26caf82a0ef5e021893b0..016b0c49c8333522782f37ad38d4ae6f7216d384 100644 --- a/keyboards/rart/rartpad/info.json +++ b/keyboards/rart/rartpad/info.json @@ -8,6 +8,12 @@ "pid": "0x0050", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B1"}, + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "indicators": { "caps_lock": "D7" }, diff --git a/keyboards/rate/pistachio_mp/config.h b/keyboards/rate/pistachio_mp/config.h index bdbe5de0da1c09a2ac8d6efad0df9db779bc3d29..948c87264a22c4376baca80dcc452cae52e631e5 100644 --- a/keyboards/rate/pistachio_mp/config.h +++ b/keyboards/rate/pistachio_mp/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once - -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A {F4} -#define ENCODERS_PAD_B {F5} -#endif - /* * Keyboard Matrix Assignments * diff --git a/keyboards/rate/pistachio_mp/info.json b/keyboards/rate/pistachio_mp/info.json index e0ad3440a3f53b1946cc8c016a7df55936a5e48f..cab8ef68b4230f75d75a12ed5e3a714f6e49dc51 100644 --- a/keyboards/rate/pistachio_mp/info.json +++ b/keyboards/rate/pistachio_mp/info.json @@ -8,6 +8,11 @@ "pid": "0xE212", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/rate/pistachio_pro/config.h b/keyboards/rate/pistachio_pro/config.h index 5f7185c9268acfd9fc3780f973f1b7efecbcb8da..b79e4dcbe3efbbe6206a008057baadfca933353a 100644 --- a/keyboards/rate/pistachio_pro/config.h +++ b/keyboards/rate/pistachio_pro/config.h @@ -17,10 +17,6 @@ along with this program. If not, see . #pragma once - -#define ENCODERS_PAD_A {D2} -#define ENCODERS_PAD_B {D3} - /* key matrix size */ #define MATRIX_ROWS 6 #define MATRIX_COLS 18 diff --git a/keyboards/rate/pistachio_pro/info.json b/keyboards/rate/pistachio_pro/info.json index 9a212a859bea61c4de61b4af4bea68b324b03022..743ff18155ef23aedbd1cebd07cb9a56a4ed8822 100644 --- a/keyboards/rate/pistachio_pro/info.json +++ b/keyboards/rate/pistachio_pro/info.json @@ -8,6 +8,11 @@ "pid": "0xF40C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/redox_media/config.h b/keyboards/redox_media/config.h index 587d3e0cc0586b2eafbb9b4b0831258ad747ea7a..c39e49f375eeeb8a5bc46232582a2839273c02f2 100644 --- a/keyboards/redox_media/config.h +++ b/keyboards/redox_media/config.h @@ -29,7 +29,3 @@ along with this program. If not, see . #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -#define ENCODERS_PAD_A { F4 } -#define ENCODERS_PAD_B { F5 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/redox_media/info.json b/keyboards/redox_media/info.json index 2404812e7def4011d64793cc577cecb87cb1670b..9f4442885c52e911d453052c80c405e0bbe9ce9f 100644 --- a/keyboards/redox_media/info.json +++ b/keyboards/redox_media/info.json @@ -8,6 +8,11 @@ "pid": "0x0000", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, "split": { "soft_serial_pin": "D0" }, diff --git a/keyboards/reedskeebs/alish40/info.json b/keyboards/reedskeebs/alish40/info.json index c1ae80e9cdfceeec16d1071bbdd852cf1a16e7d6..a4f862bec999f89b1e6274605f4b3447c95b9e2d 100644 --- a/keyboards/reedskeebs/alish40/info.json +++ b/keyboards/reedskeebs/alish40/info.json @@ -8,8 +8,7 @@ "rotary": [ { "pin_a": "B4", - "pin_b": "B5", - "resolution": 4 + "pin_b": "B5" } ] }, diff --git a/keyboards/reviung/reviung5/config.h b/keyboards/reviung/reviung5/config.h index 66552b7f97c30510f2559ca24d7e181fdfb90e4f..aceb9655f6c88ec8289c35be3ffb23a63af73624 100644 --- a/keyboards/reviung/reviung5/config.h +++ b/keyboards/reviung/reviung5/config.h @@ -36,12 +36,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Encoder */ -#define ENCODERS_PAD_A \ - { D0 } -#define ENCODERS_PAD_B \ - { D1 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN # define RGBLED_NUM 4 diff --git a/keyboards/reviung/reviung5/info.json b/keyboards/reviung/reviung5/info.json index 8422e881172ffe84636d200aece866bbc141ada4..622c880a42927915021d163f6e618e2e75029436 100644 --- a/keyboards/reviung/reviung5/info.json +++ b/keyboards/reviung/reviung5/info.json @@ -8,6 +8,11 @@ "pid": "0x4F0D", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layout_aliases": { diff --git a/keyboards/rgbkb/mun/config.h b/keyboards/rgbkb/mun/config.h index 5fbfc1cbfd143bb1addec31480227c7c2dae9f6c..8f961078bd462c5ef3ed43b8f346222160db01f3 100644 --- a/keyboards/rgbkb/mun/config.h +++ b/keyboards/rgbkb/mun/config.h @@ -25,10 +25,6 @@ #define TOUCH_RESOLUTION 25 // sensitivity of swipes, lower=faster #define TOUCH_SEGMENTS 3 -/* Encoder Configuration */ -#define ENCODERS_PAD_A { B8, B9 } -#define ENCODERS_PAD_B { A14, A15 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/rgbkb/mun/rev1/info.json b/keyboards/rgbkb/mun/rev1/info.json index 774fa27a9480325a054bb3714c925dca0aada16b..b68a1586c5663c3edd068007c65531fe4d2c5d32 100644 --- a/keyboards/rgbkb/mun/rev1/info.json +++ b/keyboards/rgbkb/mun/rev1/info.json @@ -8,6 +8,12 @@ "pid": "0x3505", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B8", "pin_b": "A14"}, + {"pin_a": "B9", "pin_b": "A15"} + ] + }, "split": { "soft_serial_pin": "A9" }, diff --git a/keyboards/rgbkb/pan/config.h b/keyboards/rgbkb/pan/config.h index 6f5c2c1db629bbdf2a2591b7c94e65be54e57dde..05d446d05da6b79cb556d6cad4535c5f77f3632e 100644 --- a/keyboards/rgbkb/pan/config.h +++ b/keyboards/rgbkb/pan/config.h @@ -16,8 +16,6 @@ along with this program. If not, see . #pragma once - -#define ENCODER_RESOLUTION 4 #define RGBLED_NUM 64 #define RGBLIGHT_EFFECT_BREATHING #define RGBLIGHT_EFFECT_RAINBOW_MOOD diff --git a/keyboards/rgbkb/pan/rev1/32a/config.h b/keyboards/rgbkb/pan/rev1/32a/config.h index 103cb4e5f880f4f3e7f6bcc9cbb80c7ed42de8ba..5e7c4babbd3dbf8fc01f35ce8b0db97cab55fa7a 100644 --- a/keyboards/rgbkb/pan/rev1/32a/config.h +++ b/keyboards/rgbkb/pan/rev1/32a/config.h @@ -18,6 +18,5 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D7, D1, D5, D6, C2 } #define MATRIX_COL_PINS { C3, C4, C5, C6, C7, A7, A6, A5, A4, A3, A2, A1, A0 } -#define ENCODERS_PAD_A { B0, D0 } -#define ENCODERS_PAD_B { B1, B2} + #define RGB_DI_PIN B3 diff --git a/keyboards/rgbkb/pan/rev1/32a/info.json b/keyboards/rgbkb/pan/rev1/32a/info.json index 32a75ca0fcbc9d7b82d790db35a85a2805e6a0d0..1f7ece37eb4457c84f42febd6f34cfa4202c1dda 100644 --- a/keyboards/rgbkb/pan/rev1/32a/info.json +++ b/keyboards/rgbkb/pan/rev1/32a/info.json @@ -1,4 +1,10 @@ { "processor": "atmega32a", - "bootloader": "usbasploader" + "bootloader": "usbasploader", + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"}, + {"pin_a": "D0", "pin_b": "B2"} + ] + } } diff --git a/keyboards/rgbkb/pan/rev1/proton_c/config.h b/keyboards/rgbkb/pan/rev1/proton_c/config.h index 988bf60eca1f398abb5e81fb66b38b04be454bba..f25713b2be3cbdc49dcb0bbf27e9bfdfaec0ce8f 100644 --- a/keyboards/rgbkb/pan/rev1/proton_c/config.h +++ b/keyboards/rgbkb/pan/rev1/proton_c/config.h @@ -18,6 +18,5 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { A15, B10, A14, A13, A7 } #define MATRIX_COL_PINS { A8, A6, B0, B1, B2, B4, B5, A1, A2, B3, B9, A10, A9 } -#define ENCODERS_PAD_A { B14, B11 } -#define ENCODERS_PAD_B { B15, B12 } + #define RGB_DI_PIN A3 diff --git a/keyboards/rgbkb/pan/rev1/proton_c/info.json b/keyboards/rgbkb/pan/rev1/proton_c/info.json index c06ffbaf069f8451e6e7dd41be285d49e238fd58..5fd7124b9c07836237df89f1e97f9f40a810853f 100644 --- a/keyboards/rgbkb/pan/rev1/proton_c/info.json +++ b/keyboards/rgbkb/pan/rev1/proton_c/info.json @@ -1,5 +1,11 @@ { "processor": "STM32F303", "bootloader": "stm32-dfu", - "board": "QMK_PROTON_C" + "board": "QMK_PROTON_C", + "encoder": { + "rotary": [ + {"pin_a": "B14", "pin_b": "B15"}, + {"pin_a": "B11", "pin_b": "B12"} + ] + } } diff --git a/keyboards/rgbkb/sol/rev1/config.h b/keyboards/rgbkb/sol/rev1/config.h index 48f341583d0d459455fba1fefdfba028445284a8..fcef317e1ffef77a8ec3d9dd9a2b58ff9bc5635b 100644 --- a/keyboards/rgbkb/sol/rev1/config.h +++ b/keyboards/rgbkb/sol/rev1/config.h @@ -29,7 +29,3 @@ along with this program. If not, see . #define RGB_MATRIX_LED_COUNT RGBLED_NUM #define RGB_MATRIX_CENTER { 112, 35 } - -// Encoder support -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D6 } diff --git a/keyboards/rgbkb/sol/rev1/info.json b/keyboards/rgbkb/sol/rev1/info.json index 4182ce4c03d1ba37bb07dd24cdb67e5a48fd86b1..eb742972b10f8a1d2325b435a4bf49ccd2ce824d 100644 --- a/keyboards/rgbkb/sol/rev1/info.json +++ b/keyboards/rgbkb/sol/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0x3060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D6"} + ] + }, "split": { "soft_serial_pin": "D3" }, diff --git a/keyboards/rgbkb/sol3/config.h b/keyboards/rgbkb/sol3/config.h index a4c7d1e30e3a0bf150a62d5953e2f510eb1a3354..727947ef0b9edae92cba99d1d49809868089bac6 100644 --- a/keyboards/rgbkb/sol3/config.h +++ b/keyboards/rgbkb/sol3/config.h @@ -28,14 +28,6 @@ #define TOUCH_RESOLUTION 25 // sensitivity of swipes, lower=faster #define TOUCH_SEGMENTS 3 -/* Encoder Configuration */ -// Matrix Entries k36/k35(E1SW>B13), k33/k32, k7/k28 -#define ENCODERS_PAD_A { A1, B10, A13 } -#define ENCODERS_PAD_B { A2, B11, B14 } -// Matrix Entries k72/k71(E5SW>B0), k69/k68, k43/k64 -#define ENCODERS_PAD_A_RIGHT { A1, C15, B3 } -#define ENCODERS_PAD_B_RIGHT { A2, C14, B13 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/rgbkb/sol3/rev1/info.json b/keyboards/rgbkb/sol3/rev1/info.json index 76eaf07f07500ea0ae972b43c816de00b4bd560c..046a56f390c12b741d157daa2111ecb6e9d92ab8 100644 --- a/keyboards/rgbkb/sol3/rev1/info.json +++ b/keyboards/rgbkb/sol3/rev1/info.json @@ -8,8 +8,24 @@ "pid": "0x3510", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A1", "pin_b": "A2"}, + {"pin_a": "B10", "pin_b": "B11"}, + {"pin_a": "A13", "pin_b": "B14"} + ] + }, "split": { - "soft_serial_pin": "A9" + "soft_serial_pin": "A9", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "A1", "pin_b": "A2"}, + {"pin_a": "C15", "pin_b": "C14"}, + {"pin_a": "B3", "pin_b": "B13"} + ] + } + } }, "processor": "STM32F303", "bootloader": "stm32-dfu", diff --git a/keyboards/rgbkb/zen/rev2/config.h b/keyboards/rgbkb/zen/rev2/config.h index 9ea7a3dc8fd35c1ef5834e74c742ee83afa64586..85b6a68b79d484df2a7f172b3e75ebb6ffe384f9 100644 --- a/keyboards/rgbkb/zen/rev2/config.h +++ b/keyboards/rgbkb/zen/rev2/config.h @@ -22,9 +22,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { C6, E6, B5, D7, B4 } #define MATRIX_COL_PINS { F4, F5, F6, F7, B3, B1, B2 } -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { D2 } - #define RGB_DI_PIN B6 /* COL2ROW or ROW2COL */ diff --git a/keyboards/rgbkb/zen/rev2/info.json b/keyboards/rgbkb/zen/rev2/info.json index d308819a423d3704ac55ff135f5b84d7dcdaf42e..cc25a74b730a07735501e5453c351af30d45b09b 100644 --- a/keyboards/rgbkb/zen/rev2/info.json +++ b/keyboards/rgbkb/zen/rev2/info.json @@ -8,6 +8,11 @@ "pid": "0x3061", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "D2"} + ] + }, "split": { "soft_serial_pin": "D3" }, diff --git a/keyboards/rgbkb/zygomorph/rev1/config.h b/keyboards/rgbkb/zygomorph/rev1/config.h index b92bc6d73f07086a0a8f2b5221b159a7cc50d164..df9875ed47a22d70e503e49d894a7a59b2c50471 100644 --- a/keyboards/rgbkb/zygomorph/rev1/config.h +++ b/keyboards/rgbkb/zygomorph/rev1/config.h @@ -28,9 +28,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D7 } - /* ws2812 RGB LED */ #define RGB_DI_PIN B7 #ifndef RGBLIGHT_SPLIT_ENABLE diff --git a/keyboards/rgbkb/zygomorph/rev1/info.json b/keyboards/rgbkb/zygomorph/rev1/info.json index e44966dabfb15de8910c4f7f487b850ac9827621..7bf6fe4b0dc2d54fc8ad6a49ff8c1afc8fdd9be5 100644 --- a/keyboards/rgbkb/zygomorph/rev1/info.json +++ b/keyboards/rgbkb/zygomorph/rev1/info.json @@ -8,6 +8,11 @@ "pid": "0x3060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D7"} + ] + }, "split": { "soft_serial_pin": "D3" }, diff --git a/keyboards/ristretto/config.h b/keyboards/ristretto/config.h index 286bb0397f8c3627c59351fe4cc20a140346f32f..290aad3ae70b93e090d2cd4365e2f8db619c95eb 100644 --- a/keyboards/ristretto/config.h +++ b/keyboards/ristretto/config.h @@ -29,7 +29,3 @@ /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE - -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { D6 } -#define ENCODER_RESOLUTION 4 diff --git a/keyboards/ristretto/info.json b/keyboards/ristretto/info.json index 3425dc03e6f843fa0b8ec4e78af48d7dc08207b7..ac6d80c3c7066242bb7181563596d91d93b5fca9 100644 --- a/keyboards/ristretto/info.json +++ b/keyboards/ristretto/info.json @@ -8,6 +8,11 @@ "pid": "0x7273", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "D6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/rmi_kb/chevron/config.h b/keyboards/rmi_kb/chevron/config.h index 0c9e3da4cadd54a090b8b4dcf63349cabd769ee9..cd4c43391bb75980e85ce5e55e8044a6f6d8409d 100644 --- a/keyboards/rmi_kb/chevron/config.h +++ b/keyboards/rmi_kb/chevron/config.h @@ -58,9 +58,3 @@ along with this program. If not, see . /* QoL improvements */ #define PERMISSIVE_HOLD #define IGNORE_MOD_TAP_INTERRUPT - -/* Encoder */ -#define ENCODERS_PAD_A { A0 } -#define ENCODERS_PAD_B { A1 } - -//#define ENCODER_DIRECTION_FLIP diff --git a/keyboards/rmi_kb/chevron/info.json b/keyboards/rmi_kb/chevron/info.json index 654da4ace8d51211fe887ff5928517c7a3ac06da..bdca6506f1c5b81545eb943c5464061d47180d94 100644 --- a/keyboards/rmi_kb/chevron/info.json +++ b/keyboards/rmi_kb/chevron/info.json @@ -8,6 +8,11 @@ "pid": "0xC4EE", "device_version": "0.1.2" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "A1"} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "layouts": { diff --git a/keyboards/rmi_kb/herringbone/pro/config.h b/keyboards/rmi_kb/herringbone/pro/config.h index e6195dc87c5bbb6937e14e783a74a89591c49902..ddf1d3199d4f27cb2e3a74cab7c3083aa31461dc 100644 --- a/keyboards/rmi_kb/herringbone/pro/config.h +++ b/keyboards/rmi_kb/herringbone/pro/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* Encoder pin assignment */ -#define ENCODERS_PAD_A { C3 } -#define ENCODERS_PAD_B { C2 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/rmi_kb/herringbone/pro/info.json b/keyboards/rmi_kb/herringbone/pro/info.json index 6a365b17c113a28da607cafb4e2e46d9ae5dfdce..5eebdf3b79cf0a647f3b8773fe268134bbe5e798 100644 --- a/keyboards/rmi_kb/herringbone/pro/info.json +++ b/keyboards/rmi_kb/herringbone/pro/info.json @@ -8,6 +8,11 @@ "pid": "0x440B", "device_version": "0.1.2" }, + "encoder": { + "rotary": [ + {"pin_a": "C3", "pin_b": "C2"} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "layouts": { diff --git a/keyboards/rmi_kb/squishytkl/config.h b/keyboards/rmi_kb/squishytkl/config.h index 07ac58f756866d9f09ee07466ac54937d7dde91b..20e98b3d53325ea1382a680be5a7484d139215a8 100644 --- a/keyboards/rmi_kb/squishytkl/config.h +++ b/keyboards/rmi_kb/squishytkl/config.h @@ -79,11 +79,3 @@ along with this program. If not, see . /* QoL improvements */ #define PERMISSIVE_HOLD #define IGNORE_MOD_TAP_INTERRUPT - -/* Rotary encoder */ -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B7 } - -#define ENCODER_RESOLUTION 1 - -//#define ENCODER_DIRECTION_FLIP diff --git a/keyboards/rmi_kb/squishytkl/info.json b/keyboards/rmi_kb/squishytkl/info.json index febd39bdf5cd854a71ccc7e7299b42cb53c5cde7..17236053cafe6d81dec8d3b801518a0cc0d2d12f 100644 --- a/keyboards/rmi_kb/squishytkl/info.json +++ b/keyboards/rmi_kb/squishytkl/info.json @@ -8,6 +8,11 @@ "pid": "0x00B1", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B7", "resolution": 1} + ] + }, "processor": "STM32F103", "bootloader": "stm32duino", "layouts": { diff --git a/keyboards/rmi_kb/wete/v2/config.h b/keyboards/rmi_kb/wete/v2/config.h index 194b0c9511bd26c060408af6272903ab6fc2bce1..baf134e5e92d71341498bd678345399f102e6de1 100644 --- a/keyboards/rmi_kb/wete/v2/config.h +++ b/keyboards/rmi_kb/wete/v2/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Encoder pins */ -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D1 } - #define RGBLIGHT_LAYERS #define RGBLIGHT_LAYERS_OVERRIDE_RGB_OFF diff --git a/keyboards/rmi_kb/wete/v2/info.json b/keyboards/rmi_kb/wete/v2/info.json index d1aa78333692df15d1d07e8851c1abbe3534c132..c4773046582b76c8a137328def25ac367f28a0aa 100644 --- a/keyboards/rmi_kb/wete/v2/info.json +++ b/keyboards/rmi_kb/wete/v2/info.json @@ -8,6 +8,11 @@ "pid": "0x00B3", "device_version": "35.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/rmkeebs/rm_numpad/config.h b/keyboards/rmkeebs/rm_numpad/config.h index 6988284d94450bcf6418326a8318fc9f3a0e1166..c2462c161990b51239a17a5594208aa6407775bf 100644 --- a/keyboards/rmkeebs/rm_numpad/config.h +++ b/keyboards/rmkeebs/rm_numpad/config.h @@ -36,10 +36,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* define encoder pins */ -#define ENCODERS_PAD_A { D7 } -#define ENCODERS_PAD_B { D4 } - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/rmkeebs/rm_numpad/info.json b/keyboards/rmkeebs/rm_numpad/info.json index b5638b1829c25461245361056d80a0879be4b113..520829d07e21669938503d8852c1ecd3739a8f27 100644 --- a/keyboards/rmkeebs/rm_numpad/info.json +++ b/keyboards/rmkeebs/rm_numpad/info.json @@ -8,6 +8,11 @@ "pid": "0x524E", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "D4"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "community_layouts": ["numpad_6x4", "ortho_6x4"], diff --git a/keyboards/rocketboard_16/config.h b/keyboards/rocketboard_16/config.h index 29db0066eb56f12efab97d2b86f33b419f4f4e3b..b6d39fd63dc3261b90836e158a8c168d8f25f8e3 100644 --- a/keyboards/rocketboard_16/config.h +++ b/keyboards/rocketboard_16/config.h @@ -43,12 +43,6 @@ along with this program. If not, see . // Allows for rotary encoder volume control #define TAP_CODE_DELAY 20 -/* Encoder stuff */ -#define ENCODERS_PAD_A \ - { A0, A2 } -#define ENCODERS_PAD_B \ - { A1, A3 } - #define LOCKING_SUPPORT_ENABLE #define LOCKING_RESYNC_ENABLE diff --git a/keyboards/rocketboard_16/info.json b/keyboards/rocketboard_16/info.json index 4e81d951a7b0a66d6446c69330d2991e608b95cd..793bad257cd057f37d3256f806f61c4ca1eb56fb 100644 --- a/keyboards/rocketboard_16/info.json +++ b/keyboards/rocketboard_16/info.json @@ -8,6 +8,12 @@ "pid": "0xFF16", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "A0", "pin_b": "A1"}, + {"pin_a": "A2", "pin_b": "A3"} + ] + }, "bootmagic": { "matrix": [4, 1] }, diff --git a/keyboards/rotr/config.h b/keyboards/rotr/config.h index 5acc8ffa5a6c7e18c43343ee46ef2d62a5497454..65a32fc35517c38c6954541aa1d85484670c27e6 100644 --- a/keyboards/rotr/config.h +++ b/keyboards/rotr/config.h @@ -5,14 +5,6 @@ #define MATRIX_ROW_PINS { E6 } #define MATRIX_COL_PINS { D1, D0, D4 } -/*Rotary Encoder Pins*/ -#define ENCODERS_PAD_A { C6 } -#define ENCODERS_PAD_B { D7 } - -/*Sets the number of pulses per increment*/ -#define ENCODER_RESOLUTION 2 - - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/rotr/info.json b/keyboards/rotr/info.json index 2bc5e96058eb0fa7edf580de452abddc5bba1f59..b893720ddfe1b46146204d608337d707bc408e28 100644 --- a/keyboards/rotr/info.json +++ b/keyboards/rotr/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "D7", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/rubi/config.h b/keyboards/rubi/config.h index 69ae795845d3ccc30305d04f960550504c5ae87e..d80fa7ec35cc1fcb41cf52836ae20b5a9768740a 100644 --- a/keyboards/rubi/config.h +++ b/keyboards/rubi/config.h @@ -31,9 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { F0, F1, F4, F5, F6 } #define MATRIX_COL_PINS { B3, B2, B1, F7 } -#define ENCODERS_PAD_A { D7 } -#define ENCODERS_PAD_B { D6 } - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/rubi/info.json b/keyboards/rubi/info.json index b8ad944792127709fbd752c9716b3cea88ce03ce..c9120a2f483b4aab5cf6ed83ba7123eed8dcbbe5 100644 --- a/keyboards/rubi/info.json +++ b/keyboards/rubi/info.json @@ -8,6 +8,11 @@ "pid": "0x5242", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "D6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/rura66/rev1/config.h b/keyboards/rura66/rev1/config.h index 3581b8adaabd543d8b64c85f360d869bab720e04..1a6ca8ac73c1648b85c16ff1bc0e1dec9eb3ea11 100644 --- a/keyboards/rura66/rev1/config.h +++ b/keyboards/rura66/rev1/config.h @@ -64,10 +64,6 @@ along with this program. If not, see . /* Custom font */ #define OLED_FONT_H "keyboards/rura66/common/glcdfont.c" -/* Encorder */ -// #define ENCODERS_PAD_A { B6 } -// #define ENCODERS_PAD_B { B5 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/sawnsprojects/krush/krush65/hotswap/config.h b/keyboards/sawnsprojects/krush/krush65/hotswap/config.h index 236de4d395abb5e5e9221a925f5092a7105b37c7..8a947093dc953af719c49bec3cf450c1061b9029 100644 --- a/keyboards/sawnsprojects/krush/krush65/hotswap/config.h +++ b/keyboards/sawnsprojects/krush/krush65/hotswap/config.h @@ -25,11 +25,6 @@ /* Encoders */ -#define ENCODERS 1 - -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D2 } - #define ENCODERS_CW_KEY { { 12, 3 } } #define ENCODERS_CCW_KEY { { 12, 4 } } diff --git a/keyboards/sawnsprojects/krush/krush65/hotswap/encoder_actions.c b/keyboards/sawnsprojects/krush/krush65/hotswap/encoder_actions.c index 039f8739b4d19cea066a9ba9f688a8ae57b07dd4..8a91dde19a4e1dd4458a3a249fcd522d39835f8f 100644 --- a/keyboards/sawnsprojects/krush/krush65/hotswap/encoder_actions.c +++ b/keyboards/sawnsprojects/krush/krush65/hotswap/encoder_actions.c @@ -20,16 +20,12 @@ #include "encoder_actions.h" #ifdef ENCODER_ENABLE - -# ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -# endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -# ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -40,11 +36,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -# endif } void encoder_action_register(uint8_t index, bool clockwise) { -# ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -52,7 +46,6 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -# endif } #endif \ No newline at end of file diff --git a/keyboards/sawnsprojects/krush/krush65/hotswap/info.json b/keyboards/sawnsprojects/krush/krush65/hotswap/info.json index 43faca4437691fdd20d4c081f502ef946426aa26..3872047ef8b98049944ad40a50e094d9244224ca 100644 --- a/keyboards/sawnsprojects/krush/krush65/hotswap/info.json +++ b/keyboards/sawnsprojects/krush/krush65/hotswap/info.json @@ -8,6 +8,11 @@ "pid": "0x5B31", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D2"} + ] + }, "indicators": { "caps_lock": "B0", "on_state": 0 diff --git a/keyboards/sawnsprojects/krush/krush65/solder/config.h b/keyboards/sawnsprojects/krush/krush65/solder/config.h index 22303a478df93cb9a53a03e5d06873168f215049..76f4acfbf6fbef04a43ae57f8845181981e5000b 100644 --- a/keyboards/sawnsprojects/krush/krush65/solder/config.h +++ b/keyboards/sawnsprojects/krush/krush65/solder/config.h @@ -23,11 +23,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* rotary */ -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { B3 } -#define ENCODER_RESOLUTION 4 - #define RGB_DI_PIN F1 #ifdef RGB_DI_PIN #define RGBLED_NUM 20 diff --git a/keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.c b/keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.c deleted file mode 100644 index 039f8739b4d19cea066a9ba9f688a8ae57b07dd4..0000000000000000000000000000000000000000 --- a/keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.c +++ /dev/null @@ -1,58 +0,0 @@ -/* Copyright 2020 Neil Brian Ramirez - * Copyright 2021 drashna jael're (@drashna) - * Copyright 2021 uybv - * Copyright 2021 SawnsProjects - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#include "encoder_actions.h" - -#ifdef ENCODER_ENABLE - -# ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -# endif - -void encoder_action_unregister(void) { -# ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { - if (encoder_state[index]) { - keyevent_t encoder_event = (keyevent_t) { - .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], - .pressed = false, - .time = (timer_read() | 1) - }; - encoder_state[index] = 0; - action_exec(encoder_event); - } - } -# endif -} - -void encoder_action_register(uint8_t index, bool clockwise) { -# ifdef ENCODERS - keyevent_t encoder_event = (keyevent_t) { - .key = clockwise ? encoder_cw[index] : encoder_ccw[index], - .pressed = true, - .time = (timer_read() | 1) - }; - encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); - action_exec(encoder_event); -# endif -} - -#endif \ No newline at end of file diff --git a/keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.h b/keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.h deleted file mode 100644 index fb226326324d0e247e4f6e2493aa1be459a578ee..0000000000000000000000000000000000000000 --- a/keyboards/sawnsprojects/krush/krush65/solder/encoder_actions.h +++ /dev/null @@ -1,23 +0,0 @@ -/* Copyright 2020 Neil Brian Ramirez - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#pragma once - -#include "quantum.h" - -void encoder_action_unregister(void); - -void encoder_action_register(uint8_t index, bool clockwise); \ No newline at end of file diff --git a/keyboards/sawnsprojects/krush/krush65/solder/info.json b/keyboards/sawnsprojects/krush/krush65/solder/info.json index a0661b715a6db7a6619e7222bd5e088e52d72318..96661272996c2e6463bed5a88c722804a7239d09 100644 --- a/keyboards/sawnsprojects/krush/krush65/solder/info.json +++ b/keyboards/sawnsprojects/krush/krush65/solder/info.json @@ -8,6 +8,11 @@ "pid": "0x6B31", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "B3"} + ] + }, "indicators": { "caps_lock": "F0", "on_state": 0 diff --git a/keyboards/sawnsprojects/krush/krush65/solder/solder.c b/keyboards/sawnsprojects/krush/krush65/solder/solder.c index b8a7729725ca8ddc22e3f67bce653c576be71e07..501d70d1bd68b0d443285bec5c8e2704bc86fe0e 100644 --- a/keyboards/sawnsprojects/krush/krush65/solder/solder.c +++ b/keyboards/sawnsprojects/krush/krush65/solder/solder.c @@ -15,7 +15,6 @@ */ #include "solder.h" -#include "encoder_actions.h" /* Custom encoder control - handles CW/CCW turning of encoder * Default behavior: diff --git a/keyboards/sck/gtm/config.h b/keyboards/sck/gtm/config.h index 15c3c5e114e1d3ae4955205de08a31b9fcdfda25..f4961f224259d0b97aa48b04b3f55b22819894e5 100644 --- a/keyboards/sck/gtm/config.h +++ b/keyboards/sck/gtm/config.h @@ -5,11 +5,6 @@ #define MATRIX_ROW_PINS { C4, C5, D1 } #define MATRIX_COL_PINS { B4, B5, B6, B7, C7, D0 } - -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D3 } -#define ENCODER_RESOLUTION 1 - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/sck/gtm/info.json b/keyboards/sck/gtm/info.json index 12ad6c917cfff94c2433e2b4664a1775afdfac0e..3f254f2c778f1ca3057240e3698863310e96b6cb 100644 --- a/keyboards/sck/gtm/info.json +++ b/keyboards/sck/gtm/info.json @@ -8,6 +8,11 @@ "pid": "0x6090", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3", "resolution": 1} + ] + }, "processor": "atmega32u2", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/sendyyeah/pix/config.h b/keyboards/sendyyeah/pix/config.h index 03b5e62bb55305befd73fa01b823550b6ef0d62a..5bbc6a38f9c02cdcf53ce7d9f97562295e1a8214 100644 --- a/keyboards/sendyyeah/pix/config.h +++ b/keyboards/sendyyeah/pix/config.h @@ -19,9 +19,6 @@ #define OLED_FONT_H "keymaps/default/glcdfont.c" #define OLED_TIMEOUT 600000 // Turn of after 10 minutes -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B3 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/sendyyeah/pix/info.json b/keyboards/sendyyeah/pix/info.json index 495a525a43c6a5d6d674bf3d2dc0a4afe957689a..178d763b0deeb41cdbda1a104fe400228bf3e11e 100644 --- a/keyboards/sendyyeah/pix/info.json +++ b/keyboards/sendyyeah/pix/info.json @@ -8,6 +8,11 @@ "pid": "0x4E34", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B3"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/sergiopoverony/creator_pro/config.h b/keyboards/sergiopoverony/creator_pro/config.h index 08941df1ac88ea782271502107ad4399be9b44ae..f1a5385a3cc0ac4f576d100ac0c3f6776d5a51f0 100644 --- a/keyboards/sergiopoverony/creator_pro/config.h +++ b/keyboards/sergiopoverony/creator_pro/config.h @@ -20,10 +20,3 @@ #define RED_LED D0 #define BLUE_LED B5 #define GREEN_LED B6 - -/* encoder pins*/ -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D3 } -#define ENCODER_RESOLUTION 1 - - diff --git a/keyboards/sergiopoverony/creator_pro/info.json b/keyboards/sergiopoverony/creator_pro/info.json index 46889dbd1e68d07ff13aa48a6be43763f5527aa5..9ac1a0a20c08d1466a1489160de95f0d077c01ad 100644 --- a/keyboards/sergiopoverony/creator_pro/info.json +++ b/keyboards/sergiopoverony/creator_pro/info.json @@ -8,6 +8,11 @@ "pid": "0x0C00", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D3", "resolution": 1} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/sidderskb/majbritt/rev2/config.h b/keyboards/sidderskb/majbritt/rev2/config.h index 3eef4a6d17d8e4b676a26e99754295c4240c743d..c0c6902e3b6f8cf33bd9412903e52be4f61f977a 100644 --- a/keyboards/sidderskb/majbritt/rev2/config.h +++ b/keyboards/sidderskb/majbritt/rev2/config.h @@ -22,9 +22,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { B0, B1, F7, C6, B5} #define MATRIX_COL_PINS { F0, F1, F4, F5, F6, C7, B6, D6, B4, D4, D7, D5 ,D3, D2, D1, D0} -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B7 } - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/sidderskb/majbritt/rev2/info.json b/keyboards/sidderskb/majbritt/rev2/info.json index 7de72f1abfa0aae9a712881a8f913fc75c5908ea..2ba227e4a8604e5bf7a1c086a544a903bb7a231b 100644 --- a/keyboards/sidderskb/majbritt/rev2/info.json +++ b/keyboards/sidderskb/majbritt/rev2/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/sneakbox/aliceclone/config.h b/keyboards/sneakbox/aliceclone/config.h index f1da1c329cea3600c3265e27fdd6db1822b1ee1e..cae120ac7e5e8f967132e0727f9abfaa805948a8 100644 --- a/keyboards/sneakbox/aliceclone/config.h +++ b/keyboards/sneakbox/aliceclone/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once -/* encoder */ -/* #define NUMBER_OF_ENCODERS 1 */ -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } -#define ENCODER_RESOLUTION 1 - /* key matrix pins */ #define MATRIX_ROW_PINS { F1, E6, F4, B1, F5, B2, F6, B3, F7, B7 } #define MATRIX_COL_PINS { F0, D0, C7, C6, B6, B5, B4, D1 } diff --git a/keyboards/sneakbox/aliceclone/info.json b/keyboards/sneakbox/aliceclone/info.json index c2c0b011a30c7cf973540fde2413a47c1f922dd9..6890765f7f92956238de8d9aa74f8cddc46e8ce4 100644 --- a/keyboards/sneakbox/aliceclone/info.json +++ b/keyboards/sneakbox/aliceclone/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2", "resolution": 1} + ] + }, "bootmagic": { "matrix": [2, 0] }, diff --git a/keyboards/sneakbox/aliceclonergb/config.h b/keyboards/sneakbox/aliceclonergb/config.h index 3369c06fbad78cbc2f621f6d4a734579d4dd4661..26bddb382a7a101484e2eddb3c2ed56a8374595a 100644 --- a/keyboards/sneakbox/aliceclonergb/config.h +++ b/keyboards/sneakbox/aliceclonergb/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once -/* encoder */ -/* #define NUMBER_OF_ENCODERS 1 */ -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } -#define ENCODER_RESOLUTION 1 - /* key matrix pins */ #define MATRIX_ROW_PINS { F1, E6, F4, B1, F5, B2, F6, B3, F7, B7 } #define MATRIX_COL_PINS { F0, D0, C7, C6, B6, B5, B4, D1 } diff --git a/keyboards/sneakbox/aliceclonergb/info.json b/keyboards/sneakbox/aliceclonergb/info.json index 02bf2c5e95a376bec816e2f8b871b88bf46d8c9b..cb7226ae81be07a87dabc2a2ccc27c55926be518 100644 --- a/keyboards/sneakbox/aliceclonergb/info.json +++ b/keyboards/sneakbox/aliceclonergb/info.json @@ -8,6 +8,11 @@ "pid": "0x0006", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2", "resolution": 1} + ] + }, "indicators": { "caps_lock": "D6", "num_lock": "D4", diff --git a/keyboards/sneakbox/ava/config.h b/keyboards/sneakbox/ava/config.h index 1528744d69f8952281ff5ff20b29c15d5e398462..23a01323059e4776000ddf5141aa4d6c79aa50bc 100644 --- a/keyboards/sneakbox/ava/config.h +++ b/keyboards/sneakbox/ava/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once -/* encoder */ -/* #define NUMBER_OF_ENCODERS 1 */ -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } -#define ENCODER_RESOLUTION 1 - /* key matrix pins */ #define MATRIX_ROW_PINS { F1, E6, F4, B1, F5, B2, F6, B3, B7 } #define MATRIX_COL_PINS { F0, D0, C7, C6, B6, B5, B4, D1 } diff --git a/keyboards/sneakbox/ava/info.json b/keyboards/sneakbox/ava/info.json index 2d07121a7a2de50baefe7cf99806604c770be65c..723fe70fb95a9da19e3dcaa61dc37c07a81acfc8 100644 --- a/keyboards/sneakbox/ava/info.json +++ b/keyboards/sneakbox/ava/info.json @@ -8,6 +8,11 @@ "pid": "0x0004", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2", "resolution": 1} + ] + }, "indicators": { "caps_lock": "D6", "num_lock": "D4" diff --git a/keyboards/sneakbox/disarray/ortho/config.h b/keyboards/sneakbox/disarray/ortho/config.h index f91a242b0825bb478b27081e02004c3920449256..78b024604c63ca7509ff6ec6ec05018d0c40b862 100644 --- a/keyboards/sneakbox/disarray/ortho/config.h +++ b/keyboards/sneakbox/disarray/ortho/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once -/* encoder */ -/* #define NUMBER_OF_ENCODERS 1 */ -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } -#define ENCODER_RESOLUTION 1 - /* key matrix pins */ #define MATRIX_ROW_PINS { B7, D0, D1, D2, D3, B0} #define MATRIX_COL_PINS { D5, D4, D6, D7, B4, B5, B6, C6, C7, F7, F6, F5, F4, F1, F0, E6} diff --git a/keyboards/sneakbox/disarray/ortho/info.json b/keyboards/sneakbox/disarray/ortho/info.json index 894e61c25620314a316f0a3cb3d40b03020ef473..65c8ff41d1e145f1f89c204f903a6a7f94fca2a2 100644 --- a/keyboards/sneakbox/disarray/ortho/info.json +++ b/keyboards/sneakbox/disarray/ortho/info.json @@ -8,6 +8,11 @@ "pid": "0x0003", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2", "resolution": 1} + ] + }, "indicators": { "num_lock": "B1" }, diff --git a/keyboards/sneakbox/disarray/staggered/config.h b/keyboards/sneakbox/disarray/staggered/config.h index 9eb0f90cfd08f80dbc72c7a6a250fa1446773103..486442bcf1f39694963c7076b977a5a373e41146 100644 --- a/keyboards/sneakbox/disarray/staggered/config.h +++ b/keyboards/sneakbox/disarray/staggered/config.h @@ -17,12 +17,6 @@ along with this program. If not, see . #pragma once -/* encoder */ -/* #define NUMBER_OF_ENCODERS 1 */ -#define ENCODERS_PAD_A { B3 } -#define ENCODERS_PAD_B { B2 } -#define ENCODER_RESOLUTION 1 - /* key matrix pins */ #define MATRIX_ROW_PINS { B7, D0, D1, D2, D3} #define MATRIX_COL_PINS { F0, F1, F4, F5, F6, F7, C7, C6, B6, B5, B4, D7, D6, D4, E6} diff --git a/keyboards/sneakbox/disarray/staggered/info.json b/keyboards/sneakbox/disarray/staggered/info.json index 536ae84ea77e999ac36e1cf4ebc6597fe47f6d20..1a788b77ec68002a6b56a1561c56e8e84a91af9f 100644 --- a/keyboards/sneakbox/disarray/staggered/info.json +++ b/keyboards/sneakbox/disarray/staggered/info.json @@ -8,6 +8,11 @@ "pid": "0x0002", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B3", "pin_b": "B2", "resolution": 1} + ] + }, "indicators": { "num_lock": "B1" }, diff --git a/keyboards/sofle/keyhive/config.h b/keyboards/sofle/keyhive/config.h index a3caf29ac4d27b41a412fc36a1826ebe47640ad8..c65caad1deb500f4945d8a2dea93917d11b25409 100755 --- a/keyboards/sofle/keyhive/config.h +++ b/keyboards/sofle/keyhive/config.h @@ -26,14 +26,6 @@ #define DIODE_DIRECTION COL2ROW -// Encoder support -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } -#define ENCODER_RESOLUTIONS { 4 } -#define ENCODER_RESOLUTIONS_RIGHT { 2 } // Left encoder seems to have double-output issue but right does not. - #define TAP_CODE_DELAY 10 // OLED settings diff --git a/keyboards/sofle/keyhive/info.json b/keyboards/sofle/keyhive/info.json index b8e0cccbab33948f38bb79fa2b9f6b458e7254cd..f1d76cb78895539847ecd135142daca91e304829 100644 --- a/keyboards/sofle/keyhive/info.json +++ b/keyboards/sofle/keyhive/info.json @@ -6,8 +6,20 @@ "pid": "0x1287", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5", "resolution": 2} + ] + } + } }, "processor": "atmega32u4", "bootloader": "atmel-dfu", diff --git a/keyboards/sofle/rev1/config.h b/keyboards/sofle/rev1/config.h index 8d928df4c6de1ed4aceabe4f6d359ba26d433445..34886b3be1c0e9a3cb0c2ed653529c7db3804b04 100644 --- a/keyboards/sofle/rev1/config.h +++ b/keyboards/sofle/rev1/config.h @@ -7,11 +7,4 @@ #define TAPPING_TERM 100 -/* encoder support */ -#define ENCODERS_PAD_A { F5 } -#define ENCODERS_PAD_B { F4 } -#define ENCODERS_PAD_A_RIGHT { F4 } -#define ENCODERS_PAD_B_RIGHT { F5 } -#define ENCODER_RESOLUTION 2 - #define TAP_CODE_DELAY 10 diff --git a/keyboards/sofle/rev1/info.json b/keyboards/sofle/rev1/info.json index 911f90ccbcf01261b0b74f070ac6da72e3129e18..4a113ec2f2895792f54b22959ceb19ed8c6d2488 100644 --- a/keyboards/sofle/rev1/info.json +++ b/keyboards/sofle/rev1/info.json @@ -8,8 +8,20 @@ "pid": "0x0287", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4", "resolution": 2} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5", "resolution": 2} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/spacey/config.h b/keyboards/spacey/config.h index 2f9127e4e85576704d442e7720e4e8b3746a35d6..411f2c257895aa5739377a0dfdf2283a40270766 100644 --- a/keyboards/spacey/config.h +++ b/keyboards/spacey/config.h @@ -17,11 +17,6 @@ along with this program. If not, see . #pragma once - -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } -#define ENCODER_RESOLUTION 4 - /* * Keyboard Matrix Assignments * diff --git a/keyboards/spacey/info.json b/keyboards/spacey/info.json index fc6b1d1f36720cc8fa93831ea5c2963a27e04a99..c24d46d753bd01360c048f0ee3c27279a130c580 100644 --- a/keyboards/spacey/info.json +++ b/keyboards/spacey/info.json @@ -8,6 +8,11 @@ "pid": "0x2045", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/splitkb/kyria/rev1/config.h b/keyboards/splitkb/kyria/rev1/config.h index 5c9c282e0007e67e3805c543e97b1f22cc89560e..8ca0d50ea65a860aad6b97a38ff007edc853164f 100644 --- a/keyboards/splitkb/kyria/rev1/config.h +++ b/keyboards/splitkb/kyria/rev1/config.h @@ -23,15 +23,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS \ { B6, B2, B3, B1, F7, F6, F5, F4 } -#define ENCODERS_PAD_A \ - { C6 } -#define ENCODERS_PAD_B \ - { B5 } -#define ENCODERS_PAD_A_RIGHT \ - { B5 } -#define ENCODERS_PAD_B_RIGHT \ - { C6 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/splitkb/kyria/rev1/info.json b/keyboards/splitkb/kyria/rev1/info.json index 86006546c790c08af3e7e15e95230b075a7e3f13..895f9283ac1ad27b68452534971b68613067b0e4 100644 --- a/keyboards/splitkb/kyria/rev1/info.json +++ b/keyboards/splitkb/kyria/rev1/info.json @@ -4,6 +4,20 @@ "pid": "0x9D9D", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "B5"} + ] + }, + "split": { + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B5", "pin_b": "C6"} + ] + } + } + }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/splitkb/kyria/rev2/config.h b/keyboards/splitkb/kyria/rev2/config.h index e26e0cffda959670877fd2701c7c8c30be13bd28..1799c6aa496910208fcceab70ae39d60f6f0b8ec 100644 --- a/keyboards/splitkb/kyria/rev2/config.h +++ b/keyboards/splitkb/kyria/rev2/config.h @@ -27,15 +27,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS_RIGHT \ { B4, B5, B6, B2, B3, B1, F7, F6 } -#define ENCODERS_PAD_A \ - { F4 } -#define ENCODERS_PAD_B \ - { F5 } -#define ENCODERS_PAD_A_RIGHT \ - { F5 } -#define ENCODERS_PAD_B_RIGHT \ - { F4 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/splitkb/kyria/rev2/info.json b/keyboards/splitkb/kyria/rev2/info.json index e30432b7183f4635b51dcad53d9f0555bad7d3bd..d21d820804e05c22b8005d62ae59740477cc7a6e 100644 --- a/keyboards/splitkb/kyria/rev2/info.json +++ b/keyboards/splitkb/kyria/rev2/info.json @@ -4,6 +4,20 @@ "pid": "0x9D9D", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F5"} + ] + }, + "split": { + "encoder": { + "right": { + "rotary": [ + {"pin_a": "F5", "pin_b": "F4"} + ] + } + } + }, "layouts": { "LAYOUT": { "layout": [ diff --git a/keyboards/splitkb/zima/config.h b/keyboards/splitkb/zima/config.h index 0cb93e77af5cdcf7d3a202f05a039d9085eaf94a..c06c192e0d106c1a98ede728dde8d71af546b8ee 100644 --- a/keyboards/splitkb/zima/config.h +++ b/keyboards/splitkb/zima/config.h @@ -17,9 +17,6 @@ along with this program. If not, see . #pragma once -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { D7 } - #define AUDIO_PIN B6 #define AUDIO_CLICKY #define NO_MUSIC_MODE @@ -47,7 +44,3 @@ along with this program. If not, see . #define DRV_GREETING alert_750ms #define DRV_MODE_DEFAULT buzz -// EC11K encoders have a different resolution than other EC11 encoders. -// When using the default resolution of 4, if you notice your encoder skipping -// every other tick, lower the resolution to 2. -#define ENCODER_RESOLUTION 2 diff --git a/keyboards/splitkb/zima/info.json b/keyboards/splitkb/zima/info.json index ab1b8ae020fbe190afa7903efc875ae2a1e384c3..077421904c08ae94830f507d6c4094cd0094e168 100644 --- a/keyboards/splitkb/zima/info.json +++ b/keyboards/splitkb/zima/info.json @@ -8,6 +8,11 @@ "pid": "0xF75B", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "D7", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/star75/config.h b/keyboards/star75/config.h index 2b69934ff2e1d03d7c0bb61f64377ba17b807120..e6162107051aa7f0fd39e8da749f16c26c0c916c 100644 --- a/keyboards/star75/config.h +++ b/keyboards/star75/config.h @@ -11,12 +11,6 @@ SPDX-License-Identifier: GPL-2.0-or-later */ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* encoder definitions */ -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B1 } -#endif - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/star75/info.json b/keyboards/star75/info.json index 516fcb7a72e3283d27ed36ceeaab6936face4622..4bf206e4e58817ecae0f844095b04ba913bcdbaa 100644 --- a/keyboards/star75/info.json +++ b/keyboards/star75/info.json @@ -8,6 +8,11 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layout_aliases": { diff --git a/keyboards/stello65/beta/config.h b/keyboards/stello65/beta/config.h index de6dd2ff20790a85a40bf04a9180089554016f50..4efc0635a17905b49768ed2bafa66923819eac9b 100644 --- a/keyboards/stello65/beta/config.h +++ b/keyboards/stello65/beta/config.h @@ -20,15 +20,8 @@ /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } -#define ENCODER_RESOLUTION 2 - -#define ENCODERS 1 #define ENCODERS_CW_KEY { { 4, 7 } } #define ENCODERS_CCW_KEY { { 4, 6 } } -#endif /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/stello65/beta/encoder_actions.c b/keyboards/stello65/beta/encoder_actions.c index 0f32ac2723add8083d2fc2167d12547557496c1b..72970a2ffc31954dd28769d47fade1500f18cc00 100644 --- a/keyboards/stello65/beta/encoder_actions.c +++ b/keyboards/stello65/beta/encoder_actions.c @@ -19,16 +19,12 @@ #include "encoder_actions.h" #ifdef ENCODER_ENABLE - -# ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -# endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -# ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -39,11 +35,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -# endif } void encoder_action_register(uint8_t index, bool clockwise) { -# ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -51,7 +45,6 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -# endif } #endif diff --git a/keyboards/stello65/beta/info.json b/keyboards/stello65/beta/info.json index b38ff6e3f37f5b309ad73fb8dd654594b08ad295..d4e73eba1d727daa38b2ea1d8424f449599b6699 100644 --- a/keyboards/stello65/beta/info.json +++ b/keyboards/stello65/beta/info.json @@ -8,6 +8,11 @@ "pid": "0x0003", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2", "resolution": 2} + ] + }, "indicators": { "caps_lock": "B3" }, diff --git a/keyboards/sthlmkb/lagom/info.json b/keyboards/sthlmkb/lagom/info.json index 932ba359d3fd46b8f58435663d1e433d720920e6..410d22512efa0da13097529a6af55a557f9a3ec5 100644 --- a/keyboards/sthlmkb/lagom/info.json +++ b/keyboards/sthlmkb/lagom/info.json @@ -396,8 +396,8 @@ }, "encoder": { "rotary": [ - { "pin_a": "D4", "pin_b": "C6", "resolution": 4 }, - { "pin_a": "F4", "pin_b": "F5", "resolution": 4 } + { "pin_a": "D4", "pin_b": "C6" }, + { "pin_a": "F4", "pin_b": "F5" } ] } } diff --git a/keyboards/sthlmkb/litl/info.json b/keyboards/sthlmkb/litl/info.json index 8340eb83725a9f0fc3723fba63fea352594d6f9a..232ada4bace9ee5135cd7906032336db02718367 100644 --- a/keyboards/sthlmkb/litl/info.json +++ b/keyboards/sthlmkb/litl/info.json @@ -43,7 +43,7 @@ }, "encoder": { "rotary": [ - { "pin_a": "D3", "pin_b": "D2", "resolution": 4 } + { "pin_a": "D3", "pin_b": "D2" } ] } } diff --git a/keyboards/swiftrax/retropad/config.h b/keyboards/swiftrax/retropad/config.h index 6cf8c0d22b2073c5547f0593e0c656673a074721..f963856c97cc63d8a6f0284b1fa5232551a02579 100644 --- a/keyboards/swiftrax/retropad/config.h +++ b/keyboards/swiftrax/retropad/config.h @@ -23,9 +23,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { C7, C6, B5 } #define MATRIX_COL_PINS { B4, D2 } -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/swiftrax/retropad/info.json b/keyboards/swiftrax/retropad/info.json index 700ec883b88bd68fc5e8744616c0702cc0b553bb..ea43a71b12b4e81ab16cec162c2aa5e49d03505f 100644 --- a/keyboards/swiftrax/retropad/info.json +++ b/keyboards/swiftrax/retropad/info.json @@ -8,6 +8,11 @@ "pid": "0xEB0C", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "bootmagic": { "matrix": [1, 0] }, diff --git a/keyboards/synapse/config.h b/keyboards/synapse/config.h index 0c3df697ef4e5c4ed2e625d52cd111d5716d4c57..f9b40cedee9b367e2a72e8730e868369ebc1ea46 100644 --- a/keyboards/synapse/config.h +++ b/keyboards/synapse/config.h @@ -26,12 +26,4 @@ /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -/* ROTARY ENCODERS */ -#define ENCODERS_PAD_A \ - { D7, C7 } -#define ENCODERS_PAD_B \ - { D6, C6 } - -#define ENCODER_RESOLUTION 4 - #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/synapse/info.json b/keyboards/synapse/info.json index 55860f9f2648d4d9d39c51beedf42422e7559e15..ff629b48c552e19a2fd731f9b53a7bbdf89e6379 100644 --- a/keyboards/synapse/info.json +++ b/keyboards/synapse/info.json @@ -8,6 +8,12 @@ "pid": "0x5359", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "D6"}, + {"pin_a": "C7", "pin_b": "C6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/synthlabs/solo/config.h b/keyboards/synthlabs/solo/config.h index da4499d8dd7b073b61f74a61809775ab29ad3739..3411aa9f688d4bb9ce05af86b70665373531187a 100644 --- a/keyboards/synthlabs/solo/config.h +++ b/keyboards/synthlabs/solo/config.h @@ -3,11 +3,6 @@ #pragma once - -#define ENCODERS 1 -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } #define ENCODERS_CW_KEY { { 2, 1 } } #define ENCODERS_CCW_KEY { { 0, 1 } } diff --git a/keyboards/synthlabs/solo/info.json b/keyboards/synthlabs/solo/info.json index 23566e95583a9b4bb7e32dc4e0afa07cfd757c6e..14d39d63ccdf40c1880ba0c7047966a79bbd4856 100644 --- a/keyboards/synthlabs/solo/info.json +++ b/keyboards/synthlabs/solo/info.json @@ -17,6 +17,11 @@ "pid": "0x3031", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "bootmagic": { "matrix": [1, 1] }, diff --git a/keyboards/synthlabs/solo/keymaps/via/keymap.c b/keyboards/synthlabs/solo/keymaps/via/keymap.c index 7949c61375f9bd922260cda1b7dd8c43dd71c0ea..c6634c42d428abf5e074a8021e02dede2e272657 100644 --- a/keyboards/synthlabs/solo/keymaps/via/keymap.c +++ b/keyboards/synthlabs/solo/keymaps/via/keymap.c @@ -27,16 +27,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { }; #if defined(VIA_ENABLE) && defined(ENCODER_ENABLE) - -#ifdef ENCODERS -static uint8_t encoder_state[] = {0}; -static keypos_t encoder_cw[] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[] = ENCODERS_CCW_KEY; -#endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -#ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -47,11 +43,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -#endif } void encoder_action_register(uint8_t index, bool clockwise) { -#ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -59,7 +53,6 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -#endif } void matrix_scan_user(void) { diff --git a/keyboards/takashicompany/center_enter/config.h b/keyboards/takashicompany/center_enter/config.h index 7407855ff2429acbd758a7c644ec34fe2e2a8701..f77a42f59f13b41ed6beed416a2c677d433a0c9a 100644 --- a/keyboards/takashicompany/center_enter/config.h +++ b/keyboards/takashicompany/center_enter/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODER_RESOLUTION 1 -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D1 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN # define RGBLED_NUM 6 diff --git a/keyboards/takashicompany/center_enter/info.json b/keyboards/takashicompany/center_enter/info.json index edc871c31755cdfee76ce77cc39ce9fc209c9ba4..7c268e3f63215cce567621b560d0cf3d25606e17 100644 --- a/keyboards/takashicompany/center_enter/info.json +++ b/keyboards/takashicompany/center_enter/info.json @@ -8,6 +8,11 @@ "pid": "0x0012", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D1", "resolution": 1} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/takashicompany/compacx/config.h b/keyboards/takashicompany/compacx/config.h index 24641f2071b9497c16192b64d018d1f448d71cb8..3f6f0115242b305da4619de09dea6b236999fcf4 100644 --- a/keyboards/takashicompany/compacx/config.h +++ b/keyboards/takashicompany/compacx/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { E6, B6 } -#define ENCODERS_PAD_B { B4, B5 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN # define RGBLED_NUM 12 diff --git a/keyboards/takashicompany/compacx/info.json b/keyboards/takashicompany/compacx/info.json index 08cd4a101090365c1e341f677938a0fd5c179ef9..bcd4489a98c76c83f2dfe9d42cc99d17fe77f172 100644 --- a/keyboards/takashicompany/compacx/info.json +++ b/keyboards/takashicompany/compacx/info.json @@ -8,6 +8,12 @@ "pid": "0x0014", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B4"}, + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/takashicompany/dogtag/config.h b/keyboards/takashicompany/dogtag/config.h index dc75fc44aba558e38ef6cc4cfc99864b26095b2b..4048cb9bf63fc99860d25bdeb32027ded543ace1 100644 --- a/keyboards/takashicompany/dogtag/config.h +++ b/keyboards/takashicompany/dogtag/config.h @@ -37,10 +37,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { D4 } -#define ENCODERS_PAD_B { C6 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN # define RGBLED_NUM 4 * 2 diff --git a/keyboards/takashicompany/dogtag/info.json b/keyboards/takashicompany/dogtag/info.json index cf6fd6713583246c0bef2ac2ee62267502d7a102..caa007fcc5d8dded4f6aa56b28a46905837b6181 100644 --- a/keyboards/takashicompany/dogtag/info.json +++ b/keyboards/takashicompany/dogtag/info.json @@ -8,6 +8,11 @@ "pid": "0x0018", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "C6"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/takashicompany/qoolee/config.h b/keyboards/takashicompany/qoolee/config.h index 1e050f5defbc2a722fc66fac73f253452ec4b970..726f4507c89f6bf375cd74041f165df1a36c6374 100644 --- a/keyboards/takashicompany/qoolee/config.h +++ b/keyboards/takashicompany/qoolee/config.h @@ -34,10 +34,6 @@ along with this program. If not, see . /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODER_RESOLUTION 1 -#define ENCODERS_PAD_A { D2 } -#define ENCODERS_PAD_B { D1 } - #define RGB_DI_PIN D3 #ifdef RGB_DI_PIN # define RGBLED_NUM 6 diff --git a/keyboards/takashicompany/qoolee/info.json b/keyboards/takashicompany/qoolee/info.json index b7ed85676f44213dee3bd3ab8a0290b68f073eb5..6f92e86c88232b952bc94e64a243af803684f108 100644 --- a/keyboards/takashicompany/qoolee/info.json +++ b/keyboards/takashicompany/qoolee/info.json @@ -8,6 +8,11 @@ "pid": "0x0013", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D1", "resolution": 1} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/takashicompany/spreadwriter/config.h b/keyboards/takashicompany/spreadwriter/config.h deleted file mode 100644 index 99bbfdf6713f8601e26a26a4b15f9700cdef4fbd..0000000000000000000000000000000000000000 --- a/keyboards/takashicompany/spreadwriter/config.h +++ /dev/null @@ -1,9 +0,0 @@ -// Copyright 2022 takashicompany (@takashicompany) -// SPDX-License-Identifier: GPL-2.0-or-later - -#pragma once - - -#define ENCODER_RESOLUTION 4 -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } diff --git a/keyboards/takashicompany/spreadwriter/info.json b/keyboards/takashicompany/spreadwriter/info.json index 86f250966a31796d7959bc1499ddd81fb79ece4a..16450db96e3da7aa8627fb5093b8ec722cd0ac5b 100644 --- a/keyboards/takashicompany/spreadwriter/info.json +++ b/keyboards/takashicompany/spreadwriter/info.json @@ -40,6 +40,11 @@ "pid": "0x0023", "vid": "0x7463" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "rgblight": { "led_count": 53, "pin": "D3", diff --git a/keyboards/takashicompany/spreadwriter/keymaps/via/config.h b/keyboards/takashicompany/spreadwriter/keymaps/via/config.h index adbbc6ce838ee6288ea84af3855b526a454f8f9c..9587fd7b6b883ee3deccfaa5ff86652f44026097 100644 --- a/keyboards/takashicompany/spreadwriter/keymaps/via/config.h +++ b/keyboards/takashicompany/spreadwriter/keymaps/via/config.h @@ -12,9 +12,6 @@ // when turn knob clockwise or counterclockwise. // This is handy to assign key codes by VIA. -// Number of endoder -#define ENCODERS 1 - // Mappings of encoder rotation to key position in key matrix. #define ENCODERS_CW_KEY { { 0, 4 }} #define ENCODERS_CCW_KEY { { 6, 0 }} \ No newline at end of file diff --git a/keyboards/takashicompany/spreadwriter/keymaps/via/keymap.c b/keyboards/takashicompany/spreadwriter/keymaps/via/keymap.c index 7d9a5cebf926f05436db649e6cfb272945edf6e9..e04c1fea0d33221d09d8938073472895ecf60577 100644 --- a/keyboards/takashicompany/spreadwriter/keymaps/via/keymap.c +++ b/keyboards/takashicompany/spreadwriter/keymaps/via/keymap.c @@ -88,12 +88,12 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { //------------------------------------------------------------------------------ // Rotary Encoder //------------------------------------------------------------------------------ -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], diff --git a/keyboards/taleguers/taleguers75/config.h b/keyboards/taleguers/taleguers75/config.h index e3c03f7afe4f01ab21ed58bb46562e224c349ce9..ac0ea7c3389a8327bb4908bda381777a1377f4ae 100644 --- a/keyboards/taleguers/taleguers75/config.h +++ b/keyboards/taleguers/taleguers75/config.h @@ -24,9 +24,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B5 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/taleguers/taleguers75/info.json b/keyboards/taleguers/taleguers75/info.json index 62761093d742432d73ef82e48e2ddbac4d389130..936086beb3df35435082ac804991405126c28673 100644 --- a/keyboards/taleguers/taleguers75/info.json +++ b/keyboards/taleguers/taleguers75/info.json @@ -8,6 +8,11 @@ "pid": "0x0075", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/terrazzo/config.h b/keyboards/terrazzo/config.h index 75ca5885a1e2a687c10fe51e3575d64edee3aa6f..6c0cbb80b9c8d00c5f14e184b32f8a510f32542d 100644 --- a/keyboards/terrazzo/config.h +++ b/keyboards/terrazzo/config.h @@ -25,44 +25,6 @@ #define DIODE_DIRECTION COL2ROW -/* ROTARY ENCODERS */ - -/* 4 encoder positions are supported. With multiple -encoder support when using the extra pins of -Elite-C controller. - -Use the following configuration guides for your -encoder layout. */ - -/* PRO MICRO CONFIGURATIONS */ - -/* If using a Pro Micro, only 1 encoder may be used, -and only in the top or bottom position. -Top and bottom encoders share the same net, -so there is only one configuration. */ - -/* TOP or BOTTOM */ -// #define ENCODERS_PAD_A { C6 } -// #define ENCODERS_PAD_B { D4 } - -/* ELITE-C ONLY CONFIGURATIONS */ - -/* TOP 3 - Default configuration */ -#define ENCODERS_PAD_A { C6 , B7, C7 } -#define ENCODERS_PAD_B { D4 , D5, F1 } - -/* BOTTOM 3 */ -// #define ENCODERS_PAD_A { B7, C7, C6 } -// #define ENCODERS_PAD_B { D5, F1, D4 } - -/* BOTTOM 2 */ -// #define ENCODERS_PAD_A { C7, C6 } -// #define ENCODERS_PAD_B { F1, D4 } - - -#define ENCODER_RESOLUTION 2 - #ifdef LED_MATRIX_ENABLE #define LED_DRIVER_ADDR_1 0x74 diff --git a/keyboards/terrazzo/info.json b/keyboards/terrazzo/info.json index 36382c46484ba8dcc1dbd14eb6a5061209bc16ea..fb59374d1d7ecb0edb4269dc016346696ce15959 100644 --- a/keyboards/terrazzo/info.json +++ b/keyboards/terrazzo/info.json @@ -8,6 +8,13 @@ "pid": "0x545A", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "D4", "resolution": 2}, + {"pin_a": "B7", "pin_b": "D5", "resolution": 2}, + {"pin_a": "C7", "pin_b": "F1", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/tetris/config.h b/keyboards/tetris/config.h index af42a6254331009f108c8c26b99a3ca9f27f2fa2..5cb9e23c57b03e958d3a2aba090aa18270d60b7a 100755 --- a/keyboards/tetris/config.h +++ b/keyboards/tetris/config.h @@ -20,9 +20,6 @@ #define NO_MUSIC_MODE #endif -#define ENCODERS_PAD_A { D1,F1 } -#define ENCODERS_PAD_B { D0,F0 } - #define RGB_DI_PIN F5 #define RGBLIGHT_EFFECT_BREATHING #define RGBLIGHT_EFFECT_RAINBOW_MOOD diff --git a/keyboards/tetris/info.json b/keyboards/tetris/info.json index c0b9742dd0140e983e81ef188dde58dc7bc7e9c7..382c4b28618e364e6a722003d6fb656106b25132 100644 --- a/keyboards/tetris/info.json +++ b/keyboards/tetris/info.json @@ -8,6 +8,12 @@ "pid": "0x6060", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"}, + {"pin_a": "F1", "pin_b": "F0"} + ] + }, "processor": "atmega32u4", "bootloader": "qmk-dfu", "layouts": { diff --git a/keyboards/themadnoodle/ncc1701kb/v2/config.h b/keyboards/themadnoodle/ncc1701kb/v2/config.h index 0349a424573d3988082afd5878e30a41f2f1c50e..a9b6cfc37df8621d67c6334052aea6c8b070bceb 100644 --- a/keyboards/themadnoodle/ncc1701kb/v2/config.h +++ b/keyboards/themadnoodle/ncc1701kb/v2/config.h @@ -36,10 +36,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_RGB_TEST #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -/*Encoders */ -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/themadnoodle/ncc1701kb/v2/info.json b/keyboards/themadnoodle/ncc1701kb/v2/info.json index 9c1a9c8f5f91f7acfa82da2ae3b0136d7db41acd..63ebced12b96da1746f8b0b14361d1e84ec190c0 100644 --- a/keyboards/themadnoodle/ncc1701kb/v2/info.json +++ b/keyboards/themadnoodle/ncc1701kb/v2/info.json @@ -8,6 +8,11 @@ "pid": "0x1701", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/themadnoodle/noodlepad/config.h b/keyboards/themadnoodle/noodlepad/config.h index 0349a424573d3988082afd5878e30a41f2f1c50e..a9b6cfc37df8621d67c6334052aea6c8b070bceb 100644 --- a/keyboards/themadnoodle/noodlepad/config.h +++ b/keyboards/themadnoodle/noodlepad/config.h @@ -36,10 +36,6 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_RGB_TEST #define RGBLIGHT_EFFECT_ALTERNATING #define RGBLIGHT_EFFECT_TWINKLE -/*Encoders */ -#define ENCODERS_PAD_A { D0 } -#define ENCODERS_PAD_B { D1 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/themadnoodle/noodlepad/info.json b/keyboards/themadnoodle/noodlepad/info.json index c6dc44ccec431cc0b6f9593cf9762f1549041af4..487680f137546db2b09a8b6503600313dd40205d 100644 --- a/keyboards/themadnoodle/noodlepad/info.json +++ b/keyboards/themadnoodle/noodlepad/info.json @@ -8,6 +8,11 @@ "pid": "0x1701", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/thepanduuh/degenpad/config.h b/keyboards/thepanduuh/degenpad/config.h index a2a171890d2a2276a60c5da18ba9f0b054b77f23..49f53eff7ae32628c37503d7b65a18bf33c0936f 100644 --- a/keyboards/thepanduuh/degenpad/config.h +++ b/keyboards/thepanduuh/degenpad/config.h @@ -21,8 +21,5 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D5, D6, D7, B4, B5, B6 } #define MATRIX_COL_PINS { F4, F5, B1, D3 } -#define ENCODERS_PAD_A { F1 } -#define ENCODERS_PAD_B { F0 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/thepanduuh/degenpad/info.json b/keyboards/thepanduuh/degenpad/info.json index ee19795db33b511f425922a980056b799a68c7fd..999de9648c3d6df0e0b368c4da553494dfd1a52e 100644 --- a/keyboards/thepanduuh/degenpad/info.json +++ b/keyboards/thepanduuh/degenpad/info.json @@ -8,6 +8,11 @@ "pid": "0x4447", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "F1", "pin_b": "F0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/tkc/portico75/config.h b/keyboards/tkc/portico75/config.h index c91329ccd3d8a5ecbd20de6fec4aed51f24c332b..04abd8bcc11fbb6aa8aca4511da086c6ebd22241 100644 --- a/keyboards/tkc/portico75/config.h +++ b/keyboards/tkc/portico75/config.h @@ -23,15 +23,6 @@ along with this program. If not, see . #define MATRIX_COL_PINS \ { F4, F5, F6, F7, C7, C6, B6, B5, B4, D7, D6, D4, D5, B3, B7 } -/*Rotary Encoder Pins*/ -#define ENCODERS_PAD_A \ - { B1 } -#define ENCODERS_PAD_B \ - { B2 } - -/*Sets the number of pulses per increment*/ -#define ENCODER_RESOLUTION 2 - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/tkc/portico75/info.json b/keyboards/tkc/portico75/info.json index c84a742761e43e5648e74a5cc99bb391cab9f155..bac10fbe13eb43fe2a876323b7ad50f89dd22681 100644 --- a/keyboards/tkc/portico75/info.json +++ b/keyboards/tkc/portico75/info.json @@ -8,6 +8,11 @@ "pid": "0x0011", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B2", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "debounce": 3, diff --git a/keyboards/tkw/grandiceps/config.h b/keyboards/tkw/grandiceps/config.h index 7c7c2dd940b20b230ff6804009f1403b2d7571bd..16d91b69a2eacdd6b44ee6bf0de03b0fe874146b 100644 --- a/keyboards/tkw/grandiceps/config.h +++ b/keyboards/tkw/grandiceps/config.h @@ -28,9 +28,6 @@ #define MATRIX_IO_DELAY 5 #define TAP_CODE_DELAY 10 -#define ENCODERS_PAD_A { B14 } -#define ENCODERS_PAD_B { B15 } - #define RGB_DI_PIN B1 #define RGBLED_NUM 16 #define RGBLED_SPLIT { 8,8 } diff --git a/keyboards/tkw/grandiceps/info.json b/keyboards/tkw/grandiceps/info.json index 356d54e67a5890b813002009de8a7644cff6be20..4d91a00c84bd1a24f8e2a23ae8999e15be6edb38 100644 --- a/keyboards/tkw/grandiceps/info.json +++ b/keyboards/tkw/grandiceps/info.json @@ -6,6 +6,11 @@ "vid": "0xFEED", "pid": "0x7812" }, + "encoder": { + "rotary": [ + {"pin_a": "B14", "pin_b": "B15"} + ] + }, "split": { "soft_serial_pin": "A15" }, diff --git a/keyboards/tkw/stoutgat/v1/config.h b/keyboards/tkw/stoutgat/v1/config.h index e069c29c86e36b6d910731be4a34e98bbf0afc47..1eda8feab41520389fdb5bd7d104f7b4cf77da55 100644 --- a/keyboards/tkw/stoutgat/v1/config.h +++ b/keyboards/tkw/stoutgat/v1/config.h @@ -21,8 +21,5 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D1, D0, A0, A1, A2 } #define MATRIX_COL_PINS { D6, D5, D7, C0, C1, C2, C3, C4, C5, C6, C7, A7, A6, A5, A4 } -#define ENCODERS_PAD_A { B4, B0 } -#define ENCODERS_PAD_B { B3, B1 } - #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/tkw/stoutgat/v1/info.json b/keyboards/tkw/stoutgat/v1/info.json index 2a8814d840adf21db0ecb95aa6223a8f52a6d65c..e94e8968582df968b8f127f41f0df373fad3587b 100644 --- a/keyboards/tkw/stoutgat/v1/info.json +++ b/keyboards/tkw/stoutgat/v1/info.json @@ -8,6 +8,12 @@ "pid": "0x7811", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B3"}, + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "processor": "atmega32a", "bootloader": "usbasploader", "community_layouts": ["65_iso", "65_ansi"], diff --git a/keyboards/tkw/stoutgat/v2/config.h b/keyboards/tkw/stoutgat/v2/config.h index 2594685f0543e8caccfc9bce84473ba5d127bad7..8161a873e515594dee1a71069dc8348747ab2195 100644 --- a/keyboards/tkw/stoutgat/v2/config.h +++ b/keyboards/tkw/stoutgat/v2/config.h @@ -24,9 +24,6 @@ #define MATRIX_IO_DELAY 5 #define TAP_CODE_DELAY 10 -#define ENCODERS_PAD_A { B14, B12} -#define ENCODERS_PAD_B { B15, B13 } - #define RGB_DI_PIN B1 #define RGBLED_NUM 13 #define RGBLIGHT_LIMIT_VAL 120 diff --git a/keyboards/tkw/stoutgat/v2/info.json b/keyboards/tkw/stoutgat/v2/info.json index 94b09cade1b02ea2eb779990b88554e2655d389d..0b0877b38bda4af2b7376f6c492921cccd906340 100644 --- a/keyboards/tkw/stoutgat/v2/info.json +++ b/keyboards/tkw/stoutgat/v2/info.json @@ -8,6 +8,12 @@ "pid": "0x7811", "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B14", "pin_b": "B15"}, + {"pin_a": "B12", "pin_b": "B13"} + ] + }, "community_layouts": ["65_iso", "65_ansi"], "layouts": { "LAYOUT_encoder": { diff --git a/keyboards/tominabox1/bigboy/config.h b/keyboards/tominabox1/bigboy/config.h index 70d1b76bea66be3130d260762dec544fc25d2c7f..b758c909d215df49efaed6d52016204bca040771 100755 --- a/keyboards/tominabox1/bigboy/config.h +++ b/keyboards/tominabox1/bigboy/config.h @@ -16,10 +16,6 @@ #pragma once -#define ENCODERS_PAD_A { C6 } -#define ENCODERS_PAD_B { B6 } -#define ENCODER_RESOLUTION 2 - #define RGB_DI_PIN B5 #ifdef RGB_DI_PIN diff --git a/keyboards/tominabox1/bigboy/info.json b/keyboards/tominabox1/bigboy/info.json index cdddc688d1df8a478cc2e69f6f7af3c691532414..9797c96f4674b96fca4cde77565779abfb13d776 100644 --- a/keyboards/tominabox1/bigboy/info.json +++ b/keyboards/tominabox1/bigboy/info.json @@ -8,6 +8,11 @@ "pid": "0x6262", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "B6", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/tominabox1/le_chiffre/he/config.h b/keyboards/tominabox1/le_chiffre/he/config.h index 3066ba475cdb77bc0359a6d8fae3ee507722049f..f6193c3581490fb83c505ff9f9b6b0cc0a4dd5e2 100644 --- a/keyboards/tominabox1/le_chiffre/he/config.h +++ b/keyboards/tominabox1/le_chiffre/he/config.h @@ -23,10 +23,6 @@ #define MATRIX_ROW_PINS { B3, D4, F1, C6 } #define MATRIX_COL_PINS { F4, F5, B0, B2, B1, B4, D7, C7, D2, F7 } -/* Define encoder pads */ -#define ENCODERS_PAD_A { D5 } -#define ENCODERS_PAD_B { D3 } - /* * WS2812 Underglow Matrix options */ diff --git a/keyboards/tominabox1/le_chiffre/he/info.json b/keyboards/tominabox1/le_chiffre/he/info.json index 14c0e6d7cb3fc893c18315e1ba99d6ba5637f321..8f667298f84be474dbe042528b1cd7ab75559999 100644 --- a/keyboards/tominabox1/le_chiffre/he/info.json +++ b/keyboards/tominabox1/le_chiffre/he/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.0.3" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu" } diff --git a/keyboards/tominabox1/le_chiffre/rev1/config.h b/keyboards/tominabox1/le_chiffre/rev1/config.h index 1b402683c789f604f33f3c2925f4acd32c831049..db5d26d665f04b945f0fc991b0f75f4dabedf3b3 100644 --- a/keyboards/tominabox1/le_chiffre/rev1/config.h +++ b/keyboards/tominabox1/le_chiffre/rev1/config.h @@ -29,10 +29,6 @@ #define MATRIX_ROW_PINS { B3, D4, F1, C6 } #define MATRIX_COL_PINS { F4, F5, B0, B2, B1, B4, D7, C7, D2, F7 } -/* Define encoder pads */ -#define ENCODERS_PAD_A { D5 } -#define ENCODERS_PAD_B { D3 } - /* * WS2812 Underglow Matrix options */ diff --git a/keyboards/tominabox1/le_chiffre/rev1/info.json b/keyboards/tominabox1/le_chiffre/rev1/info.json index dab37baf04567243ec99ff77298230abd0212075..ce90b22975d941d6b74efb3a199ef136d6c953e5 100644 --- a/keyboards/tominabox1/le_chiffre/rev1/info.json +++ b/keyboards/tominabox1/le_chiffre/rev1/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu" } diff --git a/keyboards/tominabox1/le_chiffre/rev2/config.h b/keyboards/tominabox1/le_chiffre/rev2/config.h index 98de5f0db1156ce2766fe55aaf90adb30148fc53..edde93be3ee1106f1d0c0ade71623bc6c8738423 100644 --- a/keyboards/tominabox1/le_chiffre/rev2/config.h +++ b/keyboards/tominabox1/le_chiffre/rev2/config.h @@ -29,10 +29,6 @@ #define MATRIX_ROW_PINS { B3, F6, F7, C7 } #define MATRIX_COL_PINS { B2, F0, F1, F4, F5, B5, B4, D7, D6, D4 } -/* Define encoder pads */ -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { C6 } - /* * WS2812 Underglow Matrix options */ diff --git a/keyboards/tominabox1/le_chiffre/rev2/info.json b/keyboards/tominabox1/le_chiffre/rev2/info.json index 65be217368d2adcb78ed61b2a71f6cbd1691f69d..3c20e5162e71cbe81872f6b132ed5cb6bab1f9ba 100644 --- a/keyboards/tominabox1/le_chiffre/rev2/info.json +++ b/keyboards/tominabox1/le_chiffre/rev2/info.json @@ -2,6 +2,11 @@ "usb": { "device_version": "0.0.2" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "C6"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu" } diff --git a/keyboards/torn/config.h b/keyboards/torn/config.h index 67d716127953f7fe09a51caa6e91dd0c6ef2feae..0b56ef812d1230b9b40901c63836ae5cb269032e 100644 --- a/keyboards/torn/config.h +++ b/keyboards/torn/config.h @@ -45,11 +45,6 @@ /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A \ - { B2 } -#define ENCODERS_PAD_B \ - { B1 } - #define USB_MAX_POWER_CONSUMPTION 100 #define OLED_TIMEOUT 60000 diff --git a/keyboards/torn/info.json b/keyboards/torn/info.json index 4f878b2620df3163ad8ec41ae730fb201cb20ded..44b2f9a5dd5c17b4f7dd4cfd5272924975f4039b 100644 --- a/keyboards/torn/info.json +++ b/keyboards/torn/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1"} + ] + }, "processor": "atmega328p", "bootloader": "usbasploader", "layouts": { diff --git a/keyboards/tunks/ergo33/config.h b/keyboards/tunks/ergo33/config.h index 5d51ecd9f44a436463286bc53ff328e2351a195a..04db2f166567ee34e6c4cd686302f12868482dd5 100644 --- a/keyboards/tunks/ergo33/config.h +++ b/keyboards/tunks/ergo33/config.h @@ -48,9 +48,6 @@ # define RGBLED_NUM 14 #endif -#define ENCODERS_PAD_A { D5 } -#define ENCODERS_PAD_B { D3 } - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/tunks/ergo33/info.json b/keyboards/tunks/ergo33/info.json index 2a11247d923be0200d82867953009d5966e1ec89..1495d5137a29eb1ee8569add6eaca8e3c9c37d1e 100644 --- a/keyboards/tunks/ergo33/info.json +++ b/keyboards/tunks/ergo33/info.json @@ -7,6 +7,11 @@ "pid": "0xA0A1", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D5", "pin_b": "D3"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/tzarc/djinn/config.h b/keyboards/tzarc/djinn/config.h index bb2bd6f6e2e3b3d1d4beefbf7a5d3b24103f9aff..e8b2abc1f63f1b5314f28dedd1a4f3f657fa20ec 100644 --- a/keyboards/tzarc/djinn/config.h +++ b/keyboards/tzarc/djinn/config.h @@ -2,20 +2,6 @@ // SPDX-License-Identifier: GPL-2.0-or-later #pragma once -// Encoders -- right-side is reversed -#define ENCODERS_PAD_A \ - { C14 } -#define ENCODERS_PAD_B \ - { C15 } -#define ENCODERS_PAD_A_RIGHT \ - { C15 } -#define ENCODERS_PAD_B_RIGHT \ - { C14 } - -#ifndef ENCODER_RESOLUTION -# define ENCODER_RESOLUTION 2 -#endif // ENCODER_RESOLUTION - // Bootloader #define STM32_BOOTLOADER_DUAL_BANK TRUE #define STM32_BOOTLOADER_DUAL_BANK_GPIO B7 diff --git a/keyboards/tzarc/djinn/info.json b/keyboards/tzarc/djinn/info.json index cceaf637e5a460aa0cb25c4bbce91eedabd3be71..19f5e520601e840f717babca17aed6cc0b60ac51 100644 --- a/keyboards/tzarc/djinn/info.json +++ b/keyboards/tzarc/djinn/info.json @@ -35,7 +35,19 @@ }, "split": { "enabled": true, - "main": "pin" + "main": "pin", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "C15", "pin_b": "C14", "resolution": 2} + ] + } + } + }, + "encoder": { + "rotary": [ + {"pin_a": "C14", "pin_b": "C15", "resolution": 2} + ] }, "layouts": { "LAYOUT_all": { diff --git a/keyboards/ungodly/launch_pad/config.h b/keyboards/ungodly/launch_pad/config.h index 2d7aa5fa0a9e9239452c61de095f4a639271e41a..dc63dc77bdfc9a684cc85b6c12ef05b720727947 100644 --- a/keyboards/ungodly/launch_pad/config.h +++ b/keyboards/ungodly/launch_pad/config.h @@ -25,13 +25,6 @@ /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW -/* Rotary Encoder Assignment */ -#define ENCODERS_PAD_A \ - { C6 } -#define ENCODERS_PAD_B \ - { B6 } -#define ENCODER_RESOLUTION 2 - /* Midi Slider */ #define SLIDER_PIN F6 #define MIDI_ADVANCED diff --git a/keyboards/ungodly/launch_pad/info.json b/keyboards/ungodly/launch_pad/info.json index 0adbbc45b151491d824182674d000d10fcddc08d..a6e12f3374d5f0a8f05bbbddcd1f445798389c59 100644 --- a/keyboards/ungodly/launch_pad/info.json +++ b/keyboards/ungodly/launch_pad/info.json @@ -8,6 +8,11 @@ "pid": "0x4C50", "device_version": "99.9.9" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "B6", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/ungodly/nines/config.h b/keyboards/ungodly/nines/config.h index 85880e4e637a1c7fb2a84df7ff87938e88b56328..ce4d927f09f64bed4414834b4f31411c111f9b5d 100644 --- a/keyboards/ungodly/nines/config.h +++ b/keyboards/ungodly/nines/config.h @@ -15,12 +15,6 @@ */ #pragma once -/* Rotary Encoder Assignments */ -#define ENCODERS_PAD_A { C6, E6 } -#define ENCODERS_PAD_B { D7, B4 } - -#define ENCODER_RESOLUTION 2 - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/ungodly/nines/info.json b/keyboards/ungodly/nines/info.json index 34b10245a873c972ab2b60c0a7cde507ef37bc32..23ffafcad1776efb2a949e859f9f6b0b66742b83 100644 --- a/keyboards/ungodly/nines/info.json +++ b/keyboards/ungodly/nines/info.json @@ -8,6 +8,12 @@ "pid": "0x544E", "device_version": "99.9.9" }, + "encoder": { + "rotary": [ + {"pin_a": "C6", "pin_b": "D7", "resolution": 2}, + {"pin_a": "E6", "pin_b": "B4", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/unison/v04/config.h b/keyboards/unison/v04/config.h index 4e95b4bba1643b2166a57d0fc350a1703fd3e81d..6e3ba625e28a309c572c2be84dc6f1a5b72db8d1 100644 --- a/keyboards/unison/v04/config.h +++ b/keyboards/unison/v04/config.h @@ -25,13 +25,6 @@ along with this program. If not, see . #define DIODE_DIRECTION COL2ROW -/* Rotary Encoder */ -#ifdef ENCODER_ENABLE - #define ENCODERS_PAD_A { B0, D2, D5, D6, B4 } - #define ENCODERS_PAD_B { B1, D3, D4, D7, B5 } - #define ENCODER_RESOLUTION 4 //the default & suggested is 4 -#endif - /* Audio */ #ifdef AUDIO_ENABLE #define AUDIO_PIN C6 diff --git a/keyboards/unison/v04/info.json b/keyboards/unison/v04/info.json index cc0c77609bf6d414c6090b2955dfb5852aaece6c..a772d344d251056e7f84fa32deb94d75f9ed50e9 100644 --- a/keyboards/unison/v04/info.json +++ b/keyboards/unison/v04/info.json @@ -8,6 +8,15 @@ "pid": "0x176A", "device_version": "0.4.0" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"}, + {"pin_a": "D2", "pin_b": "D3"}, + {"pin_a": "D5", "pin_b": "D4"}, + {"pin_a": "D6", "pin_b": "D7"}, + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "bootmagic": { "matrix": [5, 0] }, diff --git a/keyboards/viendi8l/config.h b/keyboards/viendi8l/config.h index 840413612ef390c8408a24338b0bb5b76b29291a..3036f0ac8fab79d9dc3adc1c284f7c4028730815 100644 --- a/keyboards/viendi8l/config.h +++ b/keyboards/viendi8l/config.h @@ -29,10 +29,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { B10 } -#define ENCODERS_PAD_B { B12 } -#define ENCODER_RESOLUTION 2 - #define TAPPING_TERM 200 #define I2C_DRIVER I2CD1 diff --git a/keyboards/viendi8l/info.json b/keyboards/viendi8l/info.json index 9b8591ee228d138844c14bc22218a17eaa08c9ac..312f97e7f1b32fa464c64636c32c70f0a782590b 100644 --- a/keyboards/viendi8l/info.json +++ b/keyboards/viendi8l/info.json @@ -8,6 +8,11 @@ "pid": "0x0877", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B10", "pin_b": "B12", "resolution": 2} + ] + }, "processor": "STM32F401", "bootloader": "stm32-dfu", "layouts": { diff --git a/keyboards/viktus/smolka/config.h b/keyboards/viktus/smolka/config.h index c8a560b40fb8bfe9b4111c52d483dfc5b2075ffe..a4789be9b7a5e121c373dadeded74b30ae44fbd5 100644 --- a/keyboards/viktus/smolka/config.h +++ b/keyboards/viktus/smolka/config.h @@ -39,11 +39,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define ENCODERS_PAD_A { D2, D5 } -#define ENCODERS_PAD_B { D1, D3 } - -#define ENCODER_RESOLUTIONS { 4, 2 } - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/viktus/smolka/info.json b/keyboards/viktus/smolka/info.json index cc6f72f76c2c822ea87e1f6a232b49795541e052..3e38c540e6bcb118e92f9e8a5a104232c7aa380f 100644 --- a/keyboards/viktus/smolka/info.json +++ b/keyboards/viktus/smolka/info.json @@ -8,6 +8,12 @@ "pid": "0x0010", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D2", "pin_b": "D1"}, + {"pin_a": "D5", "pin_b": "D3", "resolution": 2} + ] + }, "bootmagic": { "matrix": [1, 0] }, diff --git a/keyboards/viktus/sp_mini/config.h b/keyboards/viktus/sp_mini/config.h index 12d56ce32d8f797f7283a3df7bdbf75dcdae8257..8b7c6fdc7d7fa6ffdd5d0df167b4bdb6c01895a5 100644 --- a/keyboards/viktus/sp_mini/config.h +++ b/keyboards/viktus/sp_mini/config.h @@ -50,15 +50,6 @@ along with this program. If not, see . #define RGBLED_NUM 24 // Number of LEDs #define RGBLED_SPLIT { 12, 12 } - - -#define ENCODERS_PAD_A {F4} -#define ENCODERS_PAD_B {F1} -//#define ENCODERS_PAD_A_RIGHT {F4} -//#define ENCODERS_PAD_B_RIGHT {F1} - -#define ENCODER_RESOLUTIONS { 8 } - /* * Feature disable options * These options are also useful to firmware size reduction. diff --git a/keyboards/viktus/sp_mini/info.json b/keyboards/viktus/sp_mini/info.json index b84a224bce611ecc28c5abb68c6f9d0c181f3c12..33cc1f6dcb3ba86e1c84d629add786eeb88d106f 100644 --- a/keyboards/viktus/sp_mini/info.json +++ b/keyboards/viktus/sp_mini/info.json @@ -8,6 +8,11 @@ "pid": "0x534D", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "F4", "pin_b": "F1", "resolution": 8} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/walletburner/cajal/config.h b/keyboards/walletburner/cajal/config.h index 94165e1f7b0f4641e7150334c49b6ce748a5639c..61e2d421aebb6a731565692ea8346bb802fd4a75 100644 --- a/keyboards/walletburner/cajal/config.h +++ b/keyboards/walletburner/cajal/config.h @@ -21,9 +21,6 @@ #define MATRIX_ROW_PINS { D4, D5, C7, C6 } #define MATRIX_COL_PINS { F4, F1, F0, E6, B0, B1, B2, B3, D0, D1, D2, D3, B4, F6 } -#define ENCODERS_PAD_A { D6 } -#define ENCODERS_PAD_B { D7 } - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/walletburner/cajal/info.json b/keyboards/walletburner/cajal/info.json index 423ce13f6a9c6784c324992f044102ccb3cb732b..7aa0563d4c52343d2feab65167a1c17ad49d34ef 100644 --- a/keyboards/walletburner/cajal/info.json +++ b/keyboards/walletburner/cajal/info.json @@ -8,6 +8,11 @@ "pid": "0x6361", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D6", "pin_b": "D7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/waterfowl/config.h b/keyboards/waterfowl/config.h index 752f11ca3d29c8bd9416cade452ad41c615f1792..62f5ba6633c745798a3f2f718b4ea52256bc91b5 100644 --- a/keyboards/waterfowl/config.h +++ b/keyboards/waterfowl/config.h @@ -28,10 +28,5 @@ #define SPLIT_WPM_ENABLE #define SPLIT_USB_DETECT -// Encoders -#define ENCODERS_PAD_A { B4, B3 } -#define ENCODERS_PAD_B { B5, B2 } -#define ENCODER_RESOLUTIONS { 4, 2 } - // Tapping term #define TAPPING_TERM 200 \ No newline at end of file diff --git a/keyboards/waterfowl/info.json b/keyboards/waterfowl/info.json index fab5a603d3d61509c47667460fa529cd33cd156f..17f01e24e2df1282bc5e8a9af6b62adf95eae8bd 100644 --- a/keyboards/waterfowl/info.json +++ b/keyboards/waterfowl/info.json @@ -8,6 +8,12 @@ "pid": "0x9CE3", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"}, + {"pin_a": "B3", "pin_b": "B2", "resolution": 2}, + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/wekey/we27/config.h b/keyboards/wekey/we27/config.h index 605400150ec137df132a0b55238aa57dfe449de5..c720fc2103d1def8a918b100eaf6cca6ea42b8d2 100644 --- a/keyboards/wekey/we27/config.h +++ b/keyboards/wekey/we27/config.h @@ -99,19 +99,8 @@ along with this program. If not, see . #endif -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A { D3 } -# define ENCODERS_PAD_B \ - { D2 } -# define ENCODER_RESOLUTION 2 - -# define ENCODERS 1 -# define ENCODERS_CW_KEY \ - { \ - { 4, 5 } \ - } +#define ENCODERS_CW_KEY { { 4, 5 } } #define ENCODERS_CCW_KEY { { 4, 3 } } -#endif /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE diff --git a/keyboards/wekey/we27/encoder_actions.c b/keyboards/wekey/we27/encoder_actions.c index 0f32ac2723add8083d2fc2167d12547557496c1b..72970a2ffc31954dd28769d47fade1500f18cc00 100644 --- a/keyboards/wekey/we27/encoder_actions.c +++ b/keyboards/wekey/we27/encoder_actions.c @@ -19,16 +19,12 @@ #include "encoder_actions.h" #ifdef ENCODER_ENABLE - -# ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; -# endif +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { -# ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { keyevent_t encoder_event = (keyevent_t) { .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index], @@ -39,11 +35,9 @@ void encoder_action_unregister(void) { action_exec(encoder_event); } } -# endif } void encoder_action_register(uint8_t index, bool clockwise) { -# ifdef ENCODERS keyevent_t encoder_event = (keyevent_t) { .key = clockwise ? encoder_cw[index] : encoder_ccw[index], .pressed = true, @@ -51,7 +45,6 @@ void encoder_action_register(uint8_t index, bool clockwise) { }; encoder_state[index] = (clockwise ^ 1) | (clockwise << 1); action_exec(encoder_event); -# endif } #endif diff --git a/keyboards/wekey/we27/info.json b/keyboards/wekey/we27/info.json index e47fb3518590babe3acc3fce66977aa8e904123d..0a114ad5487deb0a5399b0cdfb6f258193ea958b 100644 --- a/keyboards/wekey/we27/info.json +++ b/keyboards/wekey/we27/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "community_layouts": ["numpad_6x5"], diff --git a/keyboards/winry/winry315/config.h b/keyboards/winry/winry315/config.h index f093f88b95bf8f478fc89ba956ee827b841346a2..620a7f6e6baef2d55afc20ebec8196f1c0b793ba 100644 --- a/keyboards/winry/winry315/config.h +++ b/keyboards/winry/winry315/config.h @@ -3,18 +3,7 @@ #pragma once -// Encoder pins. -// Encoder numbering (assuming the default board orientation with encoders on -// the top side): -// 0 - left -// 1 - center (with a longer shaft and a larger knob) -// 2 - right -#define ENCODERS_PAD_A { F1, B0, B3 } -#define ENCODERS_PAD_B { F0, B1, B7 } -#define ENCODER_RESOLUTION 4 - // Encoder mappings (used for VIA). -#define ENCODERS 3 #define ENCODERS_CW_KEY { { 22, 0 }, { 18, 0 }, { 20, 0 } } #define ENCODERS_CCW_KEY { { 23, 0 }, { 19, 0 }, { 21, 0 } } diff --git a/keyboards/winry/winry315/info.json b/keyboards/winry/winry315/info.json index 1b550c3122531a8895efcb9f5124cf5529bc8f9c..4039d5aaf585d2891f15a192cb49605960feb8ca 100644 --- a/keyboards/winry/winry315/info.json +++ b/keyboards/winry/winry315/info.json @@ -8,6 +8,13 @@ "pid": "0x0315", "vid": "0xF1F1" }, + "encoder": { + "rotary": [ + {"pin_a": "F1", "pin_b": "F0"}, + {"pin_a": "B0", "pin_b": "B1"}, + {"pin_a": "B3", "pin_b": "B7"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "matrix_pins": { diff --git a/keyboards/winry/winry315/keymaps/via/encoder_actions.c b/keyboards/winry/winry315/keymaps/via/encoder_actions.c index 96dfe74bcaf6078649bde86e0d2007bbab63063d..9a9092effd37fb943d88c3c788da87fbe303817c 100644 --- a/keyboards/winry/winry315/keymaps/via/encoder_actions.c +++ b/keyboards/winry/winry315/keymaps/via/encoder_actions.c @@ -27,11 +27,10 @@ # define ENCODER_STATE_CW 0x01 # define ENCODER_STATE_CCW 0x02 -# ifdef ENCODERS -static uint8_t encoder_state[ENCODERS] = {0}; -static uint16_t encoder_timer[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static uint16_t encoder_timer[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; static void exec_encoder_action(uint8_t index, bool clockwise, bool pressed) { // clang-format off @@ -43,22 +42,18 @@ static void exec_encoder_action(uint8_t index, bool clockwise, bool pressed) { // clang-format on action_exec(encoder_event); } -# endif void encoder_action_unregister(void) { -# ifdef ENCODERS - for (int index = 0; index < ENCODERS; ++index) { + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index] && (timer_elapsed(encoder_timer[index]) >= ENCODER_TAP_DURATION_MS)) { bool clockwise = !!(encoder_state[index] & ENCODER_STATE_CW); encoder_state[index] = 0; exec_encoder_action(index, clockwise, false); } } -# endif } void encoder_action_register(uint8_t index, bool clockwise) { -# ifdef ENCODERS if (encoder_state[index]) { bool was_clockwise = !!(encoder_state[index] & ENCODER_STATE_CW); encoder_state[index] = 0; @@ -67,7 +62,6 @@ void encoder_action_register(uint8_t index, bool clockwise) { encoder_state[index] = clockwise ? ENCODER_STATE_CW : ENCODER_STATE_CCW; encoder_timer[index] = timer_read(); exec_encoder_action(index, clockwise, true); -# endif } void matrix_scan_kb(void) { diff --git a/keyboards/work_louder/loop/config.h b/keyboards/work_louder/loop/config.h index 6b00a7f6c7eda6a65656eb7a2642432b9eacc3b2..1e17946cef677ac2e9a7c0438e5c5c72d1748639 100644 --- a/keyboards/work_louder/loop/config.h +++ b/keyboards/work_louder/loop/config.h @@ -130,6 +130,3 @@ along with this program. If not, see . //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -#define ENCODERS_PAD_A { D0, D2, D5 } -#define ENCODERS_PAD_B { D1, D3, D4 } diff --git a/keyboards/work_louder/loop/info.json b/keyboards/work_louder/loop/info.json index 25641426d1bfbe5f9797491be1770973b5eba793..df4a5c1be045003f1f013933e9d0d13b3fb86f8e 100644 --- a/keyboards/work_louder/loop/info.json +++ b/keyboards/work_louder/loop/info.json @@ -7,6 +7,13 @@ "vid": "0x574C", "pid": "0x1DF9" }, + "encoder": { + "rotary": [ + {"pin_a": "D0", "pin_b": "D1"}, + {"pin_a": "D2", "pin_b": "D3"}, + {"pin_a": "D5", "pin_b": "D4"} + ] + }, "bootmagic": { "matrix": [0, 11] }, diff --git a/keyboards/work_louder/micro/config.h b/keyboards/work_louder/micro/config.h index a874f21761ea725b58cf5691df28205a7350b2a5..bfe04592ac15e20aae9302be90efcca1e27b74da 100644 --- a/keyboards/work_louder/micro/config.h +++ b/keyboards/work_louder/micro/config.h @@ -80,11 +80,6 @@ //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT -#define ENCODERS_PAD_A \ - { D4, B0 } -#define ENCODERS_PAD_B \ - { D6, B1 } - #define WORK_LOUDER_LED_PIN_1 B6 #define WORK_LOUDER_LED_PIN_2 B7 #define WORK_LOUDER_LED_PIN_3 B5 diff --git a/keyboards/work_louder/micro/info.json b/keyboards/work_louder/micro/info.json index b3bfcd6a133c92f34c22bd66bcb6e1c9eb9196a3..3627122102f09d09e99c268fdc41022eee0e64ad 100644 --- a/keyboards/work_louder/micro/info.json +++ b/keyboards/work_louder/micro/info.json @@ -45,6 +45,12 @@ "pid": "0xE6E3", "vid": "0x574C" }, + "encoder": { + "rotary": [ + {"pin_a": "D4", "pin_b": "D6"}, + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "build": { "lto": true }, diff --git a/keyboards/work_louder/nano/config.h b/keyboards/work_louder/nano/config.h index 770da02bfee1a40b2aad8fb0dbf3135edb2de4ee..9148cf1abf84479d52b4cdbe1921b5a9855d0c38 100644 --- a/keyboards/work_louder/nano/config.h +++ b/keyboards/work_louder/nano/config.h @@ -130,8 +130,3 @@ along with this program. If not, see . //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT - -#define ENCODERS_PAD_A \ - { D7 } -#define ENCODERS_PAD_B \ - { B4 } diff --git a/keyboards/work_louder/nano/info.json b/keyboards/work_louder/nano/info.json index 1f33088a7c9885b62f74441469da077d858d4daa..3eb050b92adb99d9cf200ac34b8b6f52274ffc42 100644 --- a/keyboards/work_louder/nano/info.json +++ b/keyboards/work_louder/nano/info.json @@ -8,6 +8,11 @@ "pid": "0xE6F0", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D7", "pin_b": "B4"} + ] + }, "bootmagic": { "matrix": [0, 2] }, diff --git a/keyboards/work_louder/work_board/config.h b/keyboards/work_louder/work_board/config.h index 47bb15d1beb19123587929345ae1cfdccbce72e4..d9da63eb508347fd6ab409b9b7c25431befd5896 100644 --- a/keyboards/work_louder/work_board/config.h +++ b/keyboards/work_louder/work_board/config.h @@ -134,9 +134,4 @@ along with this program. If not, see . //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT -#define ENCODERS_PAD_A \ - { B0 } -#define ENCODERS_PAD_B \ - { B1 } - #define VIA_EEPROM_LAYOUT_OPTIONS_DEFAULT 0x1 diff --git a/keyboards/work_louder/work_board/info.json b/keyboards/work_louder/work_board/info.json index e354390d83a73768809b5b80e6546fa5d1b21ded..5e934e90e0d001d694a77190438b4eb2b2e1231a 100644 --- a/keyboards/work_louder/work_board/info.json +++ b/keyboards/work_louder/work_board/info.json @@ -7,6 +7,11 @@ "vid": "0x574C", "pid": "0xDCD1" }, + "encoder": { + "rotary": [ + {"pin_a": "B0", "pin_b": "B1"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/wren/config.h b/keyboards/wren/config.h index 41864db4ebca344bde8e58ae2bc452a30bb8d27f..72e110cc6baf830cb6c9548d23c9a5343d1122af 100644 --- a/keyboards/wren/config.h +++ b/keyboards/wren/config.h @@ -31,16 +31,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D3, D2, C6, D4, B5 } #define MATRIX_COL_PINS { B6, B2, B3, B1, F7, F6, F5, F4, D7, F0 } -// define encoders -#define ENCODERS_PAD_A \ - { E6 } -#define ENCODERS_PAD_B \ - { B4 } -#define ENCODERS_PAD_A_RIGHT \ - { B4 } -#define ENCODERS_PAD_B_RIGHT \ - { E6 } - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/wren/info.json b/keyboards/wren/info.json index 72e96144f154b9ba8d8838ca35909223d5a7b575..184ddea75b75c01b0ef907558e1d81a45505697b 100644 --- a/keyboards/wren/info.json +++ b/keyboards/wren/info.json @@ -7,6 +7,20 @@ "pid": "0x0000", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "E6", "pin_b": "B4"} + ] + }, + "split": { + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B4", "pin_b": "E6"} + ] + } + } + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/wuque/mammoth20x/config.h b/keyboards/wuque/mammoth20x/config.h index 3ae0303bebbd65a9f1802aca8da2b4bbc72a63b7..8d9a74f5aad68d890ba952f151b160ad4041f0f6 100644 --- a/keyboards/wuque/mammoth20x/config.h +++ b/keyboards/wuque/mammoth20x/config.h @@ -29,17 +29,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -/* Enable encoder */ -#define ENCODERS_PAD_A { D3 } -#define ENCODERS_PAD_B { D2 } - -#define ENCODERS 1 - -#ifdef ENCODER_RESOLUTION - #undef ENCODER_RESOLUTION -#endif -#define ENCODER_RESOLUTION 2 - // Note: array is { col, row ) #define ENCODERS_CW_KEY { { 3, 2 } } #define ENCODERS_CCW_KEY { { 3, 4 } } diff --git a/keyboards/wuque/mammoth20x/info.json b/keyboards/wuque/mammoth20x/info.json index a87798679f2c7fc7743cf051ab01b775070526f0..b251951becbd25c393932872806ed585ea549830 100644 --- a/keyboards/wuque/mammoth20x/info.json +++ b/keyboards/wuque/mammoth20x/info.json @@ -8,6 +8,11 @@ "pid": "0x0005", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D3", "pin_b": "D2", "resolution": 2} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layout_aliases": { diff --git a/keyboards/wuque/mammoth20x/mammoth20x.c b/keyboards/wuque/mammoth20x/mammoth20x.c index da6ccecd3be5c40aa421e6fb6ce44ab4035688a6..6cc1dee21ab067a64572849c4ed6d601bf421fe8 100644 --- a/keyboards/wuque/mammoth20x/mammoth20x.c +++ b/keyboards/wuque/mammoth20x/mammoth20x.c @@ -17,13 +17,13 @@ #include "mammoth20x.h" -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { diff --git a/keyboards/wuque/mammoth75x/config.h b/keyboards/wuque/mammoth75x/config.h index 94b05d1eb20baa7e2a60ca9636d755e46fb5bf7c..55702e33527b68aa69bd68c3ad82a1e7ef38283b 100644 --- a/keyboards/wuque/mammoth75x/config.h +++ b/keyboards/wuque/mammoth75x/config.h @@ -29,17 +29,6 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -/* Enable encoder */ -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B1 } - -#define ENCODERS 1 - -#ifdef ENCODER_RESOLUTION - #undef ENCODER_RESOLUTION -#endif -#define ENCODER_RESOLUTION 2 - // Note: array is { col, row ) #define ENCODERS_CW_KEY { { 3, 5 } } #define ENCODERS_CCW_KEY { { 5, 5 } } diff --git a/keyboards/wuque/mammoth75x/info.json b/keyboards/wuque/mammoth75x/info.json index 4bb3a29dd7176d656531bf590b7a0327ad37a135..b668948f46c0316a355479013e3f4f0a186654fb 100644 --- a/keyboards/wuque/mammoth75x/info.json +++ b/keyboards/wuque/mammoth75x/info.json @@ -8,6 +8,11 @@ "pid": "0x0004", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B1", "resolution": 2} + ] + }, "indicators": { "caps_lock": "B6", "on_state": 0 diff --git a/keyboards/wuque/mammoth75x/mammoth75x.c b/keyboards/wuque/mammoth75x/mammoth75x.c index 6f14657f889977ee95d780fd60013dcbea2c900e..c2bf2bbe3778acb555104aecc7776b2f0e6c9f7e 100644 --- a/keyboards/wuque/mammoth75x/mammoth75x.c +++ b/keyboards/wuque/mammoth75x/mammoth75x.c @@ -17,13 +17,13 @@ #include "mammoth75x.h" #ifdef VIA_ENABLE -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { diff --git a/keyboards/wuque/serneity65/config.h b/keyboards/wuque/serneity65/config.h index 1d03da2c2766681c88bc3621ea85fa63c8996557..036181772b1185c8c2900221b1098bdb3d6441de 100644 --- a/keyboards/wuque/serneity65/config.h +++ b/keyboards/wuque/serneity65/config.h @@ -22,11 +22,6 @@ #define DIODE_DIRECTION COL2ROW -/* Enable encoder */ -#define ENCODERS_PAD_A { B2 } -#define ENCODERS_PAD_B { B3 } - -#define ENCODERS 1 // Note: array is { col, row ) #define ENCODERS_CW_KEY { { 3, 4 } } #define ENCODERS_CCW_KEY { { 5, 4 } } diff --git a/keyboards/wuque/serneity65/info.json b/keyboards/wuque/serneity65/info.json index d564e1223680468ba3035194e3b3f77f8d6ab09d..744b112f70a8401ec6c6d0348db67873b4bbb677 100644 --- a/keyboards/wuque/serneity65/info.json +++ b/keyboards/wuque/serneity65/info.json @@ -8,6 +8,11 @@ "pid": "0x0003", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B2", "pin_b": "B3"} + ] + }, "indicators": { "caps_lock": "C6", "on_state": 0 diff --git a/keyboards/wuque/serneity65/serneity65.c b/keyboards/wuque/serneity65/serneity65.c index 6a7c64157f87070357530474b4c6c737c444586b..1222722b4b2ea8b8fef15665eef4774e4ee69d15 100644 --- a/keyboards/wuque/serneity65/serneity65.c +++ b/keyboards/wuque/serneity65/serneity65.c @@ -17,13 +17,13 @@ #include "serneity65.h" #ifdef VIA_ENABLE -static uint8_t encoder_state[ENCODERS] = {0}; -static keypos_t encoder_cw[ENCODERS] = ENCODERS_CW_KEY; -static keypos_t encoder_ccw[ENCODERS] = ENCODERS_CCW_KEY; +static uint8_t encoder_state[NUM_ENCODERS] = {0}; +static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY; +static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY; void encoder_action_unregister(void) { - for (int index = 0; index < ENCODERS; ++index) + for (int index = 0; index < NUM_ENCODERS; ++index) { if (encoder_state[index]) { diff --git a/keyboards/xenon/config.h b/keyboards/xenon/config.h index 4f44a9e9b073ea317605cd776f5e053d2aec28cd..61fda0e20a76be9e085c040d329f6967db885d33 100644 --- a/keyboards/xenon/config.h +++ b/keyboards/xenon/config.h @@ -22,9 +22,6 @@ along with this program. If not, see . #define MATRIX_ROW_PINS { D4, C6, D7, E6, B4 } #define MATRIX_COL_PINS { B2, B3, B1, F7, F6, F5, F4 } -#define ENCODERS_PAD_A { B6 } -#define ENCODERS_PAD_B { B5 } - /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/xenon/info.json b/keyboards/xenon/info.json index f0fd2f7bf84b17f9667902bd67b425ff98bdb5a7..5f74a9bbadd4489c9bdd41b989b00829152aab82 100644 --- a/keyboards/xenon/info.json +++ b/keyboards/xenon/info.json @@ -8,6 +8,11 @@ "pid": "0x3404", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + }, "split": { "soft_serial_pin": "D2" }, diff --git a/keyboards/yandrstudio/nz67v2/config.h b/keyboards/yandrstudio/nz67v2/config.h index 5e36cf0b6b49ec70005d2b454197568a24b211ee..a3d9bb74c5b520ae57a62bc49397a4e7da2babfc 100644 --- a/keyboards/yandrstudio/nz67v2/config.h +++ b/keyboards/yandrstudio/nz67v2/config.h @@ -26,13 +26,6 @@ #define TAP_CODE_DELAY 15 -#ifdef ENCODER_ENABLE - -# define ENCODERS_PAD_A { A9 } -# define ENCODERS_PAD_B { A10 } - -#endif - /* RGB Matrix */ #ifdef RGB_MATRIX_ENABLE diff --git a/keyboards/yandrstudio/nz67v2/info.json b/keyboards/yandrstudio/nz67v2/info.json index 033b05a3cba849d2ba2ad0c67079150dc4d2d142..ed063749761cf53a0d03854fe05d1d88180e7f0a 100644 --- a/keyboards/yandrstudio/nz67v2/info.json +++ b/keyboards/yandrstudio/nz67v2/info.json @@ -6,6 +6,11 @@ "pid": "0xAA83", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "A9", "pin_b": "A10"} + ] + }, "layouts": { "LAYOUT_all": { "layout": [ diff --git a/keyboards/yanghu/unicorne/config.h b/keyboards/yanghu/unicorne/config.h index 3fc834909e3c0248bdb258fe258018ef0748f2bb..e53141a7725800598def36fd23f17ed0d36fed89 100644 --- a/keyboards/yanghu/unicorne/config.h +++ b/keyboards/yanghu/unicorne/config.h @@ -25,11 +25,6 @@ /* COL2ROW, ROW2COL*/ #define DIODE_DIRECTION COL2ROW -#define ENCODERS_PAD_A \ - { B10, B2 } -#define ENCODERS_PAD_B \ - { B12, B0 } - /* I2C - required for custom i2c_init */ #define I2C1_SCL_PIN B6 #define I2C1_SDA_PIN B7 diff --git a/keyboards/yanghu/unicorne/info.json b/keyboards/yanghu/unicorne/info.json index 67bb7f657d66f66be87bd26c975b177f8f062902..85b39abe9b133006327b213c578d87bdbc8a2bae 100644 --- a/keyboards/yanghu/unicorne/info.json +++ b/keyboards/yanghu/unicorne/info.json @@ -8,6 +8,12 @@ "pid": "0x0204", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B10", "pin_b": "B12"}, + {"pin_a": "B2", "pin_b": "B0"} + ] + }, "layout_aliases": { "LAYOUT": "LAYOUT_split_3x6_4" }, diff --git a/keyboards/yeehaw/config.h b/keyboards/yeehaw/config.h index b14cd03b1b2f514192610885f7ae714e50ce86c7..4ead2dc6f27f64ef12da17e5f11af9109485dbc3 100644 --- a/keyboards/yeehaw/config.h +++ b/keyboards/yeehaw/config.h @@ -15,9 +15,6 @@ */ #pragma once -#define ENCODERS_PAD_A { D1 } -#define ENCODERS_PAD_B { D0 } - #define RGB_DI_PIN B2 #ifdef RGB_DI_PIN #define RGBLED_NUM 7 diff --git a/keyboards/yeehaw/info.json b/keyboards/yeehaw/info.json index c82f1fd5ff8bd8d0feaa884c3b6c7537cd6cb212..6c0a2b165edbbf844940f790e14e920feea20018 100644 --- a/keyboards/yeehaw/info.json +++ b/keyboards/yeehaw/info.json @@ -8,6 +8,11 @@ "pid": "0x5458", "device_version": "1.0.0" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/yushakobo/navpad/10/config.h b/keyboards/yushakobo/navpad/10/config.h index 4a03473d7d092a0bd9e9832e95134f1d6c72949a..7f1153299c849dda0d81628e2f8b7e906cc40a94 100644 --- a/keyboards/yushakobo/navpad/10/config.h +++ b/keyboards/yushakobo/navpad/10/config.h @@ -17,10 +17,6 @@ along with this program. If not, see . #pragma once - -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B6 } - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/yushakobo/navpad/10/info.json b/keyboards/yushakobo/navpad/10/info.json index bf006e158d265c4ac4f58207a1a16c3bcc8b50a0..a6b946367f4e403638b1826a9dbe8ce06d244765 100644 --- a/keyboards/yushakobo/navpad/10/info.json +++ b/keyboards/yushakobo/navpad/10/info.json @@ -7,6 +7,11 @@ "vid": "0x3265", "pid": "0x0008" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/yushakobo/navpad/10_helix_r/config.h b/keyboards/yushakobo/navpad/10_helix_r/config.h index ae32db05bc3b02c7da9391a1287b3228e4e752ad..5b0e667cc9c4198d71423e377746158f2d4398ce 100644 --- a/keyboards/yushakobo/navpad/10_helix_r/config.h +++ b/keyboards/yushakobo/navpad/10_helix_r/config.h @@ -44,12 +44,6 @@ along with this program. If not, see . 34, 35, 36, 37, 38, 39, 40 } #endif -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { B6 } - -#define ENCODERS_PAD_A_RIGHT { B6 } -#define ENCODERS_PAD_B_RIGHT { B5 } - /* COL2ROW, ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/yushakobo/navpad/10_helix_r/info.json b/keyboards/yushakobo/navpad/10_helix_r/info.json index 76dd055e46cae064826dc19313a4ea8bd40b88ef..19b8c31efb443009ab85bd96bbf8da76a58950d7 100644 --- a/keyboards/yushakobo/navpad/10_helix_r/info.json +++ b/keyboards/yushakobo/navpad/10_helix_r/info.json @@ -8,8 +8,20 @@ "pid": "0x0008", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B6"} + ] + }, "split": { - "soft_serial_pin": "D2" + "soft_serial_pin": "D2", + "encoder": { + "right": { + "rotary": [ + {"pin_a": "B6", "pin_b": "B5"} + ] + } + } }, "processor": "atmega32u4", "bootloader": "caterina", diff --git a/keyboards/yushakobo/quick17/config.h b/keyboards/yushakobo/quick17/config.h index b805030bda1a931ef19b1c0bb36ef283ce27cddf..3df5c25081bfe8bb8ed0a9eed0303fda6b4b18aa 100644 --- a/keyboards/yushakobo/quick17/config.h +++ b/keyboards/yushakobo/quick17/config.h @@ -85,11 +85,6 @@ along with this program. If not, see . #endif -#ifdef ENCODER_ENABLE -#define ENCODERS_PAD_A { B4 } -#define ENCODERS_PAD_B { B5 } -#endif - /* disable action features */ //#define NO_ACTION_LAYER //#define NO_ACTION_TAPPING diff --git a/keyboards/yushakobo/quick17/info.json b/keyboards/yushakobo/quick17/info.json index 1fbc570b6c1bda2f67cc8d962e9645b4f3e7c1d0..7d062aef1611979ebd189c36cf2ebf4b6ffbcf07 100644 --- a/keyboards/yushakobo/quick17/info.json +++ b/keyboards/yushakobo/quick17/info.json @@ -8,6 +8,11 @@ "pid": "0x0006", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B4", "pin_b": "B5"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "layouts": { diff --git a/keyboards/yushakobo/quick7/config.h b/keyboards/yushakobo/quick7/config.h index 5aaf1891c4d5a55aae793d7e79128432fdbf7da2..96656f70c8c67bb43e5ec12cf3c7632a87cfea50 100644 --- a/keyboards/yushakobo/quick7/config.h +++ b/keyboards/yushakobo/quick7/config.h @@ -17,9 +17,6 @@ along with this program. If not, see . #pragma once -#define ENCODERS_PAD_A { D1, F5 } -#define ENCODERS_PAD_B { D0, F6 } - #ifdef RGBLIGHT_ENABLE # define RGB_DI_PIN D3 # define RGBLED_NUM 13 diff --git a/keyboards/yushakobo/quick7/info.json b/keyboards/yushakobo/quick7/info.json index dfcd0e4f42b80101a6bd0230d2fbac728f994ffc..4413c06defa329394de2489c2a091b79cd66ffe8 100644 --- a/keyboards/yushakobo/quick7/info.json +++ b/keyboards/yushakobo/quick7/info.json @@ -8,6 +8,12 @@ "pid": "0x0002", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "D1", "pin_b": "D0"}, + {"pin_a": "F5", "pin_b": "F6"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/z12/config.h b/keyboards/z12/config.h index 6ee032f5c864e183992c8e0c265a6fe562f50b3b..fef7fb59bd16a889198ea116fdbf8adfe7ba5ca6 100644 --- a/keyboards/z12/config.h +++ b/keyboards/z12/config.h @@ -16,10 +16,6 @@ along with this program. If not, see . #pragma once - -#define ENCODERS_PAD_A { B5, B6 } -#define ENCODERS_PAD_B { B4, B2 } - /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ #define LOCKING_SUPPORT_ENABLE /* Locking resynchronize hack */ diff --git a/keyboards/z12/info.json b/keyboards/z12/info.json index 4f899bf7d68ee056676b28e2b89a3d717e8bd060..8a88206df8b588ffd7cdb847681f46d1a79c3e76 100644 --- a/keyboards/z12/info.json +++ b/keyboards/z12/info.json @@ -8,6 +8,12 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "B4"}, + {"pin_a": "B6", "pin_b": "B2"} + ] + }, "processor": "atmega32u4", "bootloader": "caterina", "matrix_pins": { diff --git a/keyboards/ztboards/after/config.h b/keyboards/ztboards/after/config.h index 3459ddb63cfca4c26889ca3c1ba1a7b595d81050..7c0453e3ae8f1a6e99c73fb0966db6155c428bb8 100644 --- a/keyboards/ztboards/after/config.h +++ b/keyboards/ztboards/after/config.h @@ -20,8 +20,6 @@ /* key matrix pins */ #define MATRIX_ROW_PINS { B3, F6, F5, D5, B2 } #define MATRIX_COL_PINS { D0, D1, D2, D3, D7, D6, D4, C7, C6, B6, B5, B4, F7, F0, F4, F1 } -#define ENCODERS_PAD_A { B1 } -#define ENCODERS_PAD_B { B0 } /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/ztboards/after/info.json b/keyboards/ztboards/after/info.json index ab0e4472e5319f83cf38eadeb187adb72dd030ec..875478ec1096a464336ebd73aee640e577699d9c 100644 --- a/keyboards/ztboards/after/info.json +++ b/keyboards/ztboards/after/info.json @@ -8,6 +8,11 @@ "pid": "0x0001", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B1", "pin_b": "B0"} + ] + }, "processor": "atmega32u4", "bootloader": "atmel-dfu", "layouts": { diff --git a/keyboards/zvecr/zv48/config.h b/keyboards/zvecr/zv48/config.h index 8ae21a3b53f88e643bb9a36fa904819e18b78936..97b0393aab6dacb7f02ed83c3e9122519fe70add 100644 --- a/keyboards/zvecr/zv48/config.h +++ b/keyboards/zvecr/zv48/config.h @@ -40,9 +40,6 @@ //#define SELECT_SOFT_SERIAL_SPEED 0 #define SERIAL_USART_SPEED 921600 -#define ENCODERS_PAD_A { B5 } -#define ENCODERS_PAD_B { A2 } - #define RGB_DI_PIN B1 #define RGBLED_NUM 48 #define RGBLED_SPLIT {24, 24} diff --git a/keyboards/zvecr/zv48/info.json b/keyboards/zvecr/zv48/info.json index 84b50063693e9ca9be6670782e7cbff6078d859d..f3519b94f49211abd79562e31b8c58345323e4b1 100644 --- a/keyboards/zvecr/zv48/info.json +++ b/keyboards/zvecr/zv48/info.json @@ -8,6 +8,11 @@ "pid": "0x0048", "device_version": "0.0.1" }, + "encoder": { + "rotary": [ + {"pin_a": "B5", "pin_b": "A2"} + ] + }, "split": { "soft_serial_pin": "B6", "bootmagic": {