Board-based LCD delays
This commit is contained in:
parent
6e0bcb80a2
commit
7010f92c4b
@ -1165,4 +1165,20 @@
|
||||
#define Z3_MS3_PIN -1
|
||||
#endif
|
||||
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#if !defined(ST7920_DELAY_1) && defined(BOARD_ST7920_DELAY_1)
|
||||
#define ST7920_DELAY_1 BOARD_ST7920_DELAY_1
|
||||
#endif
|
||||
#if !defined(ST7920_DELAY_2) && defined(BOARD_ST7920_DELAY_2)
|
||||
#define ST7920_DELAY_2 BOARD_ST7920_DELAY_2
|
||||
#endif
|
||||
#if !defined(ST7920_DELAY_3) && defined(BOARD_ST7920_DELAY_3)
|
||||
#define ST7920_DELAY_3 BOARD_ST7920_DELAY_3
|
||||
#endif
|
||||
#else
|
||||
#undef ST7920_DELAY_1
|
||||
#undef ST7920_DELAY_2
|
||||
#undef ST7920_DELAY_3
|
||||
#endif
|
||||
|
||||
#undef HAS_FREE_AUX2_PINS
|
||||
|
@ -175,15 +175,9 @@
|
||||
#define BTN_EN1 11
|
||||
#define BTN_EN2 10
|
||||
#define BTN_ENC 16
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(0)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(63)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(125)
|
||||
#endif
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(63)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(125)
|
||||
#define STD_ENCODER_PULSES_PER_STEP 4
|
||||
#define STD_ENCODER_STEPS_PER_MENU_ITEM 1
|
||||
#endif
|
||||
|
@ -59,14 +59,10 @@
|
||||
#endif
|
||||
|
||||
// Alter timing for graphical display
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(125)
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(125)
|
||||
#endif
|
||||
|
||||
#if ENABLED(MINIPANEL)
|
||||
|
@ -44,12 +44,8 @@
|
||||
#define BTN_ENC 28
|
||||
|
||||
// Alter timing for graphical display
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(125)
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(125)
|
||||
#endif
|
||||
|
@ -51,12 +51,8 @@
|
||||
#define BTN_EN2 11
|
||||
#define BTN_ENC 26
|
||||
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(0)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(0)
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(0)
|
||||
#endif
|
||||
|
@ -235,15 +235,9 @@
|
||||
#define BTN_EN1 29
|
||||
#define BTN_EN2 30
|
||||
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(0)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(188)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(0)
|
||||
#endif
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(0)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(188)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(0)
|
||||
|
||||
#elif ENABLED(ZONESTAR_LCD) // For the Tronxy Melzi boards
|
||||
|
||||
|
@ -243,15 +243,9 @@
|
||||
|
||||
// Alter timing for graphical display
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(600)
|
||||
#endif
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#endif
|
||||
|
||||
#endif // HAS_SPI_LCD
|
||||
|
@ -209,13 +209,8 @@
|
||||
#define ON_BOARD_SPI_DEVICE 1 //SPI1
|
||||
#define ONBOARD_SD_CS_PIN PA4 // Chip select for "System" SD card
|
||||
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(125)
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(125)
|
||||
#endif
|
||||
|
||||
|
@ -260,15 +260,9 @@
|
||||
|
||||
// Alter timing for graphical display
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(600)
|
||||
#endif
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(96)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(48)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(600)
|
||||
#endif
|
||||
|
||||
#endif // HAS_SPI_LCD
|
||||
|
@ -183,14 +183,8 @@
|
||||
//
|
||||
// ST7920 Delays
|
||||
//
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(715)
|
||||
#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)
|
||||
#endif
|
||||
|
@ -153,14 +153,10 @@
|
||||
//#define LCD_UART_RX PD9
|
||||
#endif
|
||||
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(715)
|
||||
#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)
|
||||
#endif
|
||||
|
||||
#endif // HAS_SPI_LCD
|
||||
|
@ -170,12 +170,8 @@
|
||||
//
|
||||
// ST7920 Delays
|
||||
//
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(715)
|
||||
#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)
|
||||
#endif
|
||||
|
@ -167,12 +167,8 @@
|
||||
//
|
||||
// ST7920 Delays
|
||||
//
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(96)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(48)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(715)
|
||||
#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)
|
||||
#endif
|
||||
|
@ -132,12 +132,8 @@
|
||||
#define MOSI_PIN P1B5
|
||||
#define SS_PIN PA15
|
||||
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(125)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(125)
|
||||
#if HAS_GRAPHICAL_LCD
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(125)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(125)
|
||||
#endif
|
||||
|
@ -247,15 +247,9 @@
|
||||
//#define MISO 23 // 13 B3 ICSP-06 EXP2-05
|
||||
|
||||
// increase delays
|
||||
#ifndef ST7920_DELAY_1
|
||||
#define ST7920_DELAY_1 DELAY_NS(313)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_2
|
||||
#define ST7920_DELAY_2 DELAY_NS(313)
|
||||
#endif
|
||||
#ifndef ST7920_DELAY_3
|
||||
#define ST7920_DELAY_3 DELAY_NS(313)
|
||||
#endif
|
||||
#define BOARD_ST7920_DELAY_1 DELAY_NS(313)
|
||||
#define BOARD_ST7920_DELAY_2 DELAY_NS(313)
|
||||
#define BOARD_ST7920_DELAY_3 DELAY_NS(313)
|
||||
|
||||
#else
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user