diff options
| author | Xelus22 <17491233+Xelus22@users.noreply.github.com> | 2021-08-24 16:28:26 +1000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-08-24 16:28:26 +1000 |
| commit | 4e1c5887c5c08ebd2cf7868c8d9292aa728e7bf0 (patch) | |
| tree | 24ff5bdf570a6a9f5a77a517005bffbb35e46b22 /keyboards/anavi | |
| parent | 6fd20acf4be76e7a2bd82d3dfd0a9bcca8c507eb (diff) | |
| download | qmk_firmware-4e1c5887c5c08ebd2cf7868c8d9292aa728e7bf0.tar.gz qmk_firmware-4e1c5887c5c08ebd2cf7868c8d9292aa728e7bf0.zip | |
[Core] Refactor OLED to allow easy addition of other types (#13454)
* add docs
* core changes
* update keyboards to new OLED
* updated users to new OLED
* update layouts to new OLED
* fixup docs
* drashna's suggestion
* fix up docs
* new keyboards with oled
* core split changes
* remaining keyboard files
* Fix The Helix keyboards oled options
* reflect develop
Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: mtei <2170248+mtei@users.noreply.github.com>
Diffstat (limited to 'keyboards/anavi')
| -rw-r--r-- | keyboards/anavi/macropad8/config.h | 2 | ||||
| -rw-r--r-- | keyboards/anavi/macropad8/keymaps/default/keymap.c | 2 | ||||
| -rw-r--r-- | keyboards/anavi/macropad8/keymaps/git/keymap.c | 2 | ||||
| -rw-r--r-- | keyboards/anavi/macropad8/keymaps/kicad/keymap.c | 4 | ||||
| -rw-r--r-- | keyboards/anavi/macropad8/keymaps/kodi/keymap.c | 2 | ||||
| -rw-r--r-- | keyboards/anavi/macropad8/keymaps/obs/keymap.c | 2 | ||||
| -rw-r--r-- | keyboards/anavi/macropad8/keymaps/zoom/keymap.c | 2 | ||||
| -rw-r--r-- | keyboards/anavi/macropad8/rules.mk | 3 |
8 files changed, 10 insertions, 9 deletions
diff --git a/keyboards/anavi/macropad8/config.h b/keyboards/anavi/macropad8/config.h index fd9d6e357..4ec8c7312 100644 --- a/keyboards/anavi/macropad8/config.h +++ b/keyboards/anavi/macropad8/config.h | |||
| @@ -64,7 +64,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. | |||
| 64 | # define RGBLIGHT_LIMIT_VAL 255 | 64 | # define RGBLIGHT_LIMIT_VAL 255 |
| 65 | #endif | 65 | #endif |
| 66 | 66 | ||
| 67 | #ifdef OLED_DRIVER_ENABLE | 67 | #ifdef OLED_ENABLE |
| 68 | # define OLED_DISPLAY_128X64 | 68 | # define OLED_DISPLAY_128X64 |
| 69 | # define OLED_TIMEOUT 60000 | 69 | # define OLED_TIMEOUT 60000 |
| 70 | # define OLED_FONT_H "keyboards/anavi/macropad8/glcdfont.c" | 70 | # define OLED_FONT_H "keyboards/anavi/macropad8/glcdfont.c" |
diff --git a/keyboards/anavi/macropad8/keymaps/default/keymap.c b/keyboards/anavi/macropad8/keymaps/default/keymap.c index 68fbdf0d1..5b69532e1 100644 --- a/keyboards/anavi/macropad8/keymaps/default/keymap.c +++ b/keyboards/anavi/macropad8/keymaps/default/keymap.c | |||
| @@ -17,7 +17,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
| 17 | ) | 17 | ) |
| 18 | }; | 18 | }; |
| 19 | 19 | ||
| 20 | #ifdef OLED_DRIVER_ENABLE | 20 | #ifdef OLED_ENABLE |
| 21 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { | 21 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { |
| 22 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand | 22 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand |
| 23 | } | 23 | } |
diff --git a/keyboards/anavi/macropad8/keymaps/git/keymap.c b/keyboards/anavi/macropad8/keymaps/git/keymap.c index 0b0099fd5..c1f1681ec 100644 --- a/keyboards/anavi/macropad8/keymaps/git/keymap.c +++ b/keyboards/anavi/macropad8/keymaps/git/keymap.c | |||
| @@ -100,7 +100,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
| 100 | ) | 100 | ) |
| 101 | }; | 101 | }; |
| 102 | 102 | ||
| 103 | #ifdef OLED_DRIVER_ENABLE | 103 | #ifdef OLED_ENABLE |
| 104 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { | 104 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { |
| 105 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand | 105 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand |
| 106 | } | 106 | } |
diff --git a/keyboards/anavi/macropad8/keymaps/kicad/keymap.c b/keyboards/anavi/macropad8/keymaps/kicad/keymap.c index 938d0d53f..ba4755034 100644 --- a/keyboards/anavi/macropad8/keymaps/kicad/keymap.c +++ b/keyboards/anavi/macropad8/keymaps/kicad/keymap.c | |||
| @@ -50,7 +50,7 @@ const uint8_t RGBLED_RAINBOW_SWIRL_INTERVALS[] PROGMEM = {20, 10, 4}; | |||
| 50 | * F1 - zoom in | 50 | * F1 - zoom in |
| 51 | * F2 - zoom out | 51 | * F2 - zoom out |
| 52 | * F4 - zoom center | 52 | * F4 - zoom center |
| 53 | * | 53 | * |
| 54 | */ | 54 | */ |
| 55 | 55 | ||
| 56 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | 56 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { |
| @@ -70,7 +70,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
| 70 | ) | 70 | ) |
| 71 | }; | 71 | }; |
| 72 | 72 | ||
| 73 | #ifdef OLED_DRIVER_ENABLE | 73 | #ifdef OLED_ENABLE |
| 74 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { | 74 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { |
| 75 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand | 75 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand |
| 76 | } | 76 | } |
diff --git a/keyboards/anavi/macropad8/keymaps/kodi/keymap.c b/keyboards/anavi/macropad8/keymaps/kodi/keymap.c index 72022a01b..61cedc810 100644 --- a/keyboards/anavi/macropad8/keymaps/kodi/keymap.c +++ b/keyboards/anavi/macropad8/keymaps/kodi/keymap.c | |||
| @@ -36,7 +36,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
| 36 | ) | 36 | ) |
| 37 | }; | 37 | }; |
| 38 | 38 | ||
| 39 | #ifdef OLED_DRIVER_ENABLE | 39 | #ifdef OLED_ENABLE |
| 40 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { | 40 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { |
| 41 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand | 41 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand |
| 42 | } | 42 | } |
diff --git a/keyboards/anavi/macropad8/keymaps/obs/keymap.c b/keyboards/anavi/macropad8/keymaps/obs/keymap.c index 0c78883cf..e740482bb 100644 --- a/keyboards/anavi/macropad8/keymaps/obs/keymap.c +++ b/keyboards/anavi/macropad8/keymaps/obs/keymap.c | |||
| @@ -53,7 +53,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
| 53 | ) | 53 | ) |
| 54 | }; | 54 | }; |
| 55 | 55 | ||
| 56 | #ifdef OLED_DRIVER_ENABLE | 56 | #ifdef OLED_ENABLE |
| 57 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { | 57 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { |
| 58 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand | 58 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand |
| 59 | } | 59 | } |
diff --git a/keyboards/anavi/macropad8/keymaps/zoom/keymap.c b/keyboards/anavi/macropad8/keymaps/zoom/keymap.c index 64f4f5b01..ef47102fa 100644 --- a/keyboards/anavi/macropad8/keymaps/zoom/keymap.c +++ b/keyboards/anavi/macropad8/keymaps/zoom/keymap.c | |||
| @@ -52,7 +52,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | |||
| 52 | ) | 52 | ) |
| 53 | }; | 53 | }; |
| 54 | 54 | ||
| 55 | #ifdef OLED_DRIVER_ENABLE | 55 | #ifdef OLED_ENABLE |
| 56 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { | 56 | oled_rotation_t oled_init_user(oled_rotation_t rotation) { |
| 57 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand | 57 | return OLED_ROTATION_180; // flips the display 180 degrees if offhand |
| 58 | } | 58 | } |
diff --git a/keyboards/anavi/macropad8/rules.mk b/keyboards/anavi/macropad8/rules.mk index 961ed63e0..63a7bb719 100644 --- a/keyboards/anavi/macropad8/rules.mk +++ b/keyboards/anavi/macropad8/rules.mk | |||
| @@ -24,7 +24,8 @@ BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality | |||
| 24 | AUDIO_ENABLE = no # Audio output on port C6 | 24 | AUDIO_ENABLE = no # Audio output on port C6 |
| 25 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID | 25 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID |
| 26 | RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight. | 26 | RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight. |
| 27 | OLED_DRIVER_ENABLE = yes # Enable Support for SSD1306 or SH1106 OLED Displays; Communicating over I2C | 27 | OLED_ENABLE = yes |
| 28 | OLED_DRIVER = SSD1306 # Enable Support for SSD1306 or SH1106 OLED Displays; Communicating over I2C | ||
| 28 | 29 | ||
| 29 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | 30 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE |
| 30 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend | 31 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
