Skip to content

Commit

Permalink
Add MKS_LCD12864B
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed May 5, 2021
1 parent fccfcfb commit 301ee6c
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 7 deletions.
3 changes: 2 additions & 1 deletion Marlin/Configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -2260,7 +2260,8 @@
// MKS LCD12864A/B with graphic controller and SD support. Follows MKS_MINI_12864 pinout.
// https://www.aliexpress.com/item/33018110072.html
//
//#define MKS_LCD12864
//#define MKS_LCD12864A
//#define MKS_LCD12864B

//
// FYSETC variant of the MINI12864 graphic controller with SD support
Expand Down
4 changes: 2 additions & 2 deletions Marlin/src/inc/Conditionals_LCD.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@
* Conditionals that need to be set before Configuration_adv.h or pins.h
*/

// MKS_LCD12864 is a variant of MKS_MINI_12864
#if ENABLED(MKS_LCD12864)
// MKS_LCD12864A/B is a variant of MKS_MINI_12864
#if EITHER(MKS_LCD12864A, MKS_LCD12864B)
#define MKS_MINI_12864
#endif

Expand Down
2 changes: 1 addition & 1 deletion Marlin/src/inc/Conditionals_post.h
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@
#elif ENABLED(AZSMZ_12864)
#define _LCD_CONTRAST_MIN 120
#define _LCD_CONTRAST_INIT 190
#elif ENABLED(MKS_LCD12864)
#elif EITHER(MKS_LCD12864A, MKS_LCD12864B)
#define _LCD_CONTRAST_MIN 120
#define _LCD_CONTRAST_INIT 205
#elif EITHER(MKS_MINI_12864, ENDER2_STOCKDISPLAY)
Expand Down
7 changes: 5 additions & 2 deletions Marlin/src/inc/SanityCheck.h
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,8 @@
#error "MEATPACK is now enabled with MEATPACK_ON_SERIAL_PORT_1, MEATPACK_ON_SERIAL_PORT_2, etc."
#elif defined(CUSTOM_USER_MENUS)
#error "CUSTOM_USER_MENUS has been replaced by CUSTOM_MENU_MAIN and CUSTOM_MENU_CONFIG."
#elif defined(MKS_LCD12864)
#error "MKS_LCD12864 is now MKS_LCD12864A or MKS_LCD12864B."
#endif

/**
Expand Down Expand Up @@ -2359,7 +2361,7 @@ static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal
+ ENABLED(REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER) \
+ (ENABLED(U8GLIB_SSD1306) && DISABLED(IS_U8GLIB_SSD1306)) \
+ (ENABLED(MINIPANEL) && NONE(MKS_MINI_12864, ENDER2_STOCKDISPLAY)) \
+ (ENABLED(MKS_MINI_12864) && DISABLED(MKS_LCD12864)) \
+ (ENABLED(MKS_MINI_12864) && NONE(MKS_LCD12864A, MKS_LCD12864B)) \
+ (ENABLED(EXTENSIBLE_UI) && DISABLED(IS_EXTUI)) \
+ (DISABLED(IS_LEGACY_TFT) && ENABLED(TFT_GENERIC)) \
+ (ENABLED(IS_LEGACY_TFT) && COUNT_ENABLED(TFT_320x240, TFT_320x240_SPI, TFT_480x320, TFT_480x320_SPI)) \
Expand Down Expand Up @@ -2390,7 +2392,8 @@ static_assert(hbm[Z_AXIS] >= 0, "HOMING_BUMP_MM.Z must be greater than or equal
+ ENABLED(MAKRPANEL) \
+ ENABLED(MALYAN_LCD) \
+ ENABLED(NEXTION_TFT) \
+ ENABLED(MKS_LCD12864) \
+ ENABLED(MKS_LCD12864A) \
+ ENABLED(MKS_LCD12864B) \
+ ENABLED(OLED_PANEL_TINYBOY2) \
+ ENABLED(OVERLORD_OLED) \
+ ENABLED(PANEL_ONE) \
Expand Down
2 changes: 1 addition & 1 deletion Marlin/src/pins/stm32f1/pins_BTT_SKR_E3_DIP.h
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@
#define LCD_BACKLIGHT_PIN -1

#else
#error "Only CR10_STOCKDISPLAY, ZONESTAR_LCD, ENDER2_STOCKDISPLAY, MKS_MINI_12864, and MKS_LCD12864 are currently supported on the BIGTREE_SKR_E3_DIP."
#error "Only CR10_STOCKDISPLAY, ZONESTAR_LCD, ENDER2_STOCKDISPLAY, MKS_MINI_12864, and MKS_LCD12864A/B are currently supported on the BIGTREE_SKR_E3_DIP."
#endif

#endif // HAS_WIRED_LCD
Expand Down

0 comments on commit 301ee6c

Please sign in to comment.