Add support for BACK button (RADDS) (#9835)

This commit is contained in:
Scott Lahteine
2018-02-26 22:52:57 -06:00
committed by GitHub
parent 0bc4c216ac
commit 35ec67885a
3 changed files with 32 additions and 14 deletions

View File

@ -78,13 +78,12 @@ extern volatile uint8_t buttons; //an extended version of the last checked butt
#define B_DW (BUTTON_DOWN<<B_I2C_BTN_OFFSET)
#define B_RI (BUTTON_RIGHT<<B_I2C_BTN_OFFSET)
#undef LCD_CLICKED
#if BUTTON_EXISTS(ENC)
// the pause/stop/restart button is connected to BTN_ENC when used
#define B_ST (EN_C) // Map the pause/stop/resume button into its normalized functional name
#undef LCD_CLICKED
#define LCD_CLICKED (buttons&(B_MI|B_RI|B_ST)) // pause/stop button also acts as click until we implement proper pause/stop.
#else
#undef LCD_CLICKED
#define LCD_CLICKED (buttons&(B_MI|B_RI))
#endif