Commit 8d13047a authored by MagoKimbra's avatar MagoKimbra

Fix lcd

parent 7abefaf8
...@@ -24,18 +24,18 @@ ...@@ -24,18 +24,18 @@
#define BLEN_B 1 #define BLEN_B 1
#define BLEN_A 0 #define BLEN_A 0
#define EN_B BIT(BLEN_B) // The two encoder pins are connected through BTN_EN1 and BTN_EN2 #define EN_B (_BV(BLEN_B)) // The two encoder pins are connected through BTN_EN1 and BTN_EN2
#define EN_A BIT(BLEN_A) #define EN_A (_BV(BLEN_A))
#if ENABLED(BTN_ENC) && BTN_ENC > 0 #if defined(BTN_ENC) && BTN_ENC > -1
// encoder click is directly connected // encoder click is directly connected
#define BLEN_C 2 #define BLEN_C 2
#define EN_C BIT(BLEN_C) #define EN_C (_BV(BLEN_C))
#endif #endif
#if ENABLED(BTN_BACK) && BTN_BACK > 0 #if ENABLED(BTN_BACK) && BTN_BACK > 0
#define BLEN_D 3 #define BLEN_D 3
#define EN_D BIT(BLEN_D) #define EN_D (_BV(BLEN_D))
#endif #endif
// //
...@@ -107,14 +107,14 @@ ...@@ -107,14 +107,14 @@
#define REPRAPWORLD_BTN_OFFSET 0 // bit offset into buttons for shift register values #define REPRAPWORLD_BTN_OFFSET 0 // bit offset into buttons for shift register values
#define EN_REPRAPWORLD_KEYPAD_F3 BIT((BLEN_REPRAPWORLD_KEYPAD_F3+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_F3 (_BV(BLEN_REPRAPWORLD_KEYPAD_F3+REPRAPWORLD_BTN_OFFSET))
#define EN_REPRAPWORLD_KEYPAD_F2 BIT((BLEN_REPRAPWORLD_KEYPAD_F2+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_F2 (_BV(BLEN_REPRAPWORLD_KEYPAD_F2+REPRAPWORLD_BTN_OFFSET))
#define EN_REPRAPWORLD_KEYPAD_F1 BIT((BLEN_REPRAPWORLD_KEYPAD_F1+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_F1 (_BV(BLEN_REPRAPWORLD_KEYPAD_F1+REPRAPWORLD_BTN_OFFSET))
#define EN_REPRAPWORLD_KEYPAD_UP BIT((BLEN_REPRAPWORLD_KEYPAD_UP+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_UP (_BV(BLEN_REPRAPWORLD_KEYPAD_UP+REPRAPWORLD_BTN_OFFSET))
#define EN_REPRAPWORLD_KEYPAD_RIGHT BIT((BLEN_REPRAPWORLD_KEYPAD_RIGHT+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_RIGHT (_BV(BLEN_REPRAPWORLD_KEYPAD_RIGHT+REPRAPWORLD_BTN_OFFSET))
#define EN_REPRAPWORLD_KEYPAD_MIDDLE BIT((BLEN_REPRAPWORLD_KEYPAD_MIDDLE+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_MIDDLE (_BV(BLEN_REPRAPWORLD_KEYPAD_MIDDLE+REPRAPWORLD_BTN_OFFSET))
#define EN_REPRAPWORLD_KEYPAD_DOWN BIT((BLEN_REPRAPWORLD_KEYPAD_DOWN+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_DOWN (_BV(BLEN_REPRAPWORLD_KEYPAD_DOWN+REPRAPWORLD_BTN_OFFSET))
#define EN_REPRAPWORLD_KEYPAD_LEFT BIT((BLEN_REPRAPWORLD_KEYPAD_LEFT+REPRAPWORLD_BTN_OFFSET)) #define EN_REPRAPWORLD_KEYPAD_LEFT (_BV(BLEN_REPRAPWORLD_KEYPAD_LEFT+REPRAPWORLD_BTN_OFFSET))
/* /*
#if ENABLED(INVERT_CLICK_BUTTON) #if ENABLED(INVERT_CLICK_BUTTON)
...@@ -152,12 +152,12 @@ ...@@ -152,12 +152,12 @@
#define BL_ST 2 #define BL_ST 2
//automatic, do not change //automatic, do not change
#define B_LE BIT(BL_LE) #define B_LE (_BV(BL_LE))
#define B_UP BIT(BL_UP) #define B_UP (_BV(BL_UP))
#define B_MI BIT(BL_MI) #define B_MI (_BV(BL_MI))
#define B_DW BIT(BL_DW) #define B_DW (_BV(BL_DW))
#define B_RI BIT(BL_RI) #define B_RI (_BV(BL_RI))
#define B_ST BIT(BL_ST) #define B_ST (_BV(BL_ST))
#if ENABLED(INVERT_CLICK_BUTTON) #if ENABLED(INVERT_CLICK_BUTTON)
#define LCD_CLICKED !(buttons&(B_MI|B_ST)) #define LCD_CLICKED !(buttons&(B_MI|B_ST))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment