|
|
|
@ -36,6 +36,8 @@ extern Bounce but[2]; |
|
|
|
|
// Global vars
|
|
|
|
|
uint8_t main_menu_selector = 0; |
|
|
|
|
|
|
|
|
|
enum { BUT_L, BUT_R }; |
|
|
|
|
|
|
|
|
|
// Main menu
|
|
|
|
|
const char text10[] PROGMEM = "Favorites "; |
|
|
|
|
const char text11[] PROGMEM = "Sound "; |
|
|
|
@ -60,8 +62,14 @@ LiquidLine sound_line4(0, 1, text23); |
|
|
|
|
LiquidScreen sound_screen(sound_line1, sound_line2, sound_line3, sound_line4); |
|
|
|
|
LiquidMenu sound_menu(lcd, sound_screen); |
|
|
|
|
|
|
|
|
|
// Info menu
|
|
|
|
|
const char text40[] PROGMEM = "INFO "; |
|
|
|
|
LiquidLine info_line1(0, 0, text40); |
|
|
|
|
LiquidScreen info_screen(info_line1); |
|
|
|
|
LiquidMenu info_menu(lcd, info_screen); |
|
|
|
|
|
|
|
|
|
// System menu
|
|
|
|
|
LiquidSystem menu_system(main_menu, sound_menu); |
|
|
|
|
LiquidSystem menu_system(main_menu, sound_menu, info_menu); |
|
|
|
|
|
|
|
|
|
void callback_favorites_function() { |
|
|
|
|
Serial.println(F("callback_favorites_function")); |
|
|
|
@ -122,11 +130,13 @@ void handle_ui(void) |
|
|
|
|
|
|
|
|
|
switch (i) |
|
|
|
|
{ |
|
|
|
|
case 1: |
|
|
|
|
if (but[i].risingEdge() || but[i].fallingEdge()) |
|
|
|
|
case BUT_R: // SELECT
|
|
|
|
|
if (but[i].fallingEdge()) |
|
|
|
|
{ |
|
|
|
|
Serial.println(F("B0")); |
|
|
|
|
main_menu.switch_focus(); |
|
|
|
|
#ifdef DEBUG |
|
|
|
|
Serial.println(F("SELECT-R")); |
|
|
|
|
#endif |
|
|
|
|
menu_system.next_screen(); |
|
|
|
|
} |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|