added OLED support

This commit is contained in:
Jack Hartstein 2021-01-02 16:45:06 -08:00
parent eadff9ee85
commit 087f4a50ee
5 changed files with 26 additions and 3 deletions

View file

@ -2,7 +2,7 @@
Last Updated: 1 Jan 2021 Last Updated: 1 Jan 2021
**_warning:_** this is beta firmware, certain functions may not work fully **_warning:_** this is beta firmware, some features may have bugs
Please message me on [discord](https://discord.gg/K3SJrtN5PJ) if you find any bugs Please message me on [discord](https://discord.gg/K3SJrtN5PJ) if you find any bugs

View file

@ -2,7 +2,6 @@
* SPDX-License-Identifier: MIT * SPDX-License-Identifier: MIT
* *
* Author: Jack Hartstein * Author: Jack Hartstein
* Last Edited: Dec 20 2020
*/ */
&spi1 { &spi1 {

View file

@ -15,8 +15,11 @@ CONFIG_WS2812_STRIP=y
# Increase BT radio power # Increase BT radio power
CONFIG_BT_CTLR_TX_PWR_PLUS_8=y CONFIG_BT_CTLR_TX_PWR_PLUS_8=y
# USB debugging settings # OLED setup
CONFIG_I2C=y
CONFIG_ZMK_DISPLAY=y
# USB debugging settings
# Turn on logging, and set ZMK logging to debug output # Turn on logging, and set ZMK logging to debug output
CONFIG_LOG=y CONFIG_LOG=y
CONFIG_ZMK_LOG_LEVEL_DBG=y CONFIG_ZMK_LOG_LEVEL_DBG=y
@ -40,4 +43,5 @@ CONFIG_UART_CONSOLE=y
CONFIG_USB_UART_CONSOLE=y CONFIG_USB_UART_CONSOLE=y
CONFIG_UART_CONSOLE_ON_DEV_NAME="CDC_ACM_0" CONFIG_UART_CONSOLE_ON_DEV_NAME="CDC_ACM_0"
# Increase log buffer size for serial debugging
CONFIG_LOG_BUFFER_SIZE=32768 CONFIG_LOG_BUFFER_SIZE=32768

View file

@ -17,3 +17,23 @@
sensors = <&left_encoder>; sensors = <&left_encoder>;
}; };
}; };
&pro_micro_i2c {
status = "okay";
oled: ssd1306@3c {
compatible = "solomon,ssd1306fb";
reg = <0x3c>;
label = "DISPLAY";
width = <128>;
height = <32>;
segment-offset = <0>;
page-offset = <0>;
display-offset = <0>;
multiplex-ratio = <31>;
segment-remap;
com-invdir;
com-sequential;
prechargep = <0x22>;
};
};