Improve U8G+SPI delay override (#18386)
Co-authored-by: Scott Lahteine <github@thinkyhead.com>
This commit is contained in:
@ -237,9 +237,15 @@
|
||||
|
||||
// Alter timing for graphical display
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#ifndef BOARD_ST7920_DELAY_1
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_2
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_3
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif // HAS_SPI_LCD
|
||||
|
@ -328,9 +328,10 @@
|
||||
#define LCD_PINS_ENABLE PG5
|
||||
#define LCD_PINS_D4 PG7
|
||||
|
||||
//#undef ST7920_DELAY_1
|
||||
//#undef ST7920_DELAY_2
|
||||
//#undef ST7920_DELAY_3
|
||||
// CR10_STOCKDISPLAY default timing is too fast
|
||||
#undef BOARD_ST7920_DELAY_1
|
||||
#undef BOARD_ST7920_DELAY_2
|
||||
#undef BOARD_ST7920_DELAY_3
|
||||
|
||||
#else
|
||||
|
||||
@ -377,9 +378,15 @@
|
||||
|
||||
// Alter timing for graphical display
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#ifndef BOARD_ST7920_DELAY_1
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_2
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_3
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
//#define DOGLCD_CS PB12
|
||||
|
@ -275,11 +275,10 @@
|
||||
#define LCD_PINS_ENABLE PG7
|
||||
#define LCD_PINS_D4 PG3
|
||||
|
||||
// CR10_Stock Display needs a different delay setting on SKR PRO v1.1, so undef it here.
|
||||
// It will be defined again at the #HAS_GRAPHICAL_LCD section below.
|
||||
#undef ST7920_DELAY_1
|
||||
#undef ST7920_DELAY_2
|
||||
#undef ST7920_DELAY_3
|
||||
// CR10_STOCKDISPLAY default timing is too fast
|
||||
#undef BOARD_ST7920_DELAY_1
|
||||
#undef BOARD_ST7920_DELAY_2
|
||||
#undef BOARD_ST7920_DELAY_3
|
||||
|
||||
#elif ENABLED(MKS_MINI_12864)
|
||||
#define DOGLCD_A0 PG6
|
||||
@ -328,9 +327,15 @@
|
||||
|
||||
// Alter timing for graphical display
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#ifndef BOARD_ST7920_DELAY_1
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_2
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_3
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif // HAS_SPI_LCD
|
||||
|
@ -191,11 +191,10 @@
|
||||
#define LCD_PINS_ENABLE PD1
|
||||
#define LCD_PINS_D4 PC12
|
||||
|
||||
// CR10_Stock Display needs a different delay setting on SKR PRO v1.1, so undef it here.
|
||||
// It will be defined again at the #HAS_GRAPHICAL_LCD section below.
|
||||
#undef ST7920_DELAY_1
|
||||
#undef ST7920_DELAY_2
|
||||
#undef ST7920_DELAY_3
|
||||
// CR10_STOCKDISPLAY default timing is too fast
|
||||
#undef BOARD_ST7920_DELAY_1
|
||||
#undef BOARD_ST7920_DELAY_2
|
||||
#undef BOARD_ST7920_DELAY_3
|
||||
|
||||
#else
|
||||
|
||||
|
@ -185,7 +185,13 @@
|
||||
// ST7920 Delays
|
||||
//
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(715)
|
||||
#ifndef BOARD_ST7920_DELAY_1
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_2
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_3
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(715)
|
||||
#endif
|
||||
#endif
|
||||
|
@ -173,7 +173,13 @@
|
||||
// ST7920 Delays
|
||||
//
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(715)
|
||||
#ifndef BOARD_ST7920_DELAY_1
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_2
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_3
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(715)
|
||||
#endif
|
||||
#endif
|
||||
|
@ -170,7 +170,13 @@
|
||||
// ST7920 Delays
|
||||
//
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(715)
|
||||
#ifndef BOARD_ST7920_DELAY_1
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_2
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef BOARD_ST7920_DELAY_3
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(715)
|
||||
#endif
|
||||
#endif
|
||||
|
@ -37,7 +37,7 @@
|
||||
|
||||
#if NO_EEPROM_SELECTED
|
||||
#define FLASH_EEPROM_EMULATION
|
||||
#define MARLIN_EEPROM_SIZE 0x1000 // 4KB
|
||||
#define MARLIN_EEPROM_SIZE 0x1000 // 4KB
|
||||
#endif
|
||||
|
||||
#if ENABLED(FLASH_EEPROM_EMULATION)
|
||||
|
@ -44,10 +44,10 @@
|
||||
// TIM7 is used for SERVO
|
||||
// TIMER_SERIAL defaults to TIM7 so we'll override it here
|
||||
//
|
||||
#define STEP_TIMER 10
|
||||
#define TEMP_TIMER 14
|
||||
#define STEP_TIMER 10
|
||||
#define TEMP_TIMER 14
|
||||
#define TIMER_SERIAL TIM9
|
||||
#define HAL_TIMER_RATE F_CPU
|
||||
#define HAL_TIMER_RATE F_CPU
|
||||
|
||||
//
|
||||
// Limit Switches
|
||||
|
Reference in New Issue
Block a user