diff --git a/apps/plugins/battery_bench.c b/apps/plugins/battery_bench.c index 2cdf510b3a..bb9c3b0e6f 100644 --- a/apps/plugins/battery_bench.c +++ b/apps/plugins/battery_bench.c @@ -273,6 +273,12 @@ #define BATTERY_OFF_TXT "Power" #define BATTERY_ON_TXT "Menu - start" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define BATTERY_ON BUTTON_LEFT +#define BATTERY_OFF BUTTON_RIGHT +#define BATTERY_OFF_TXT "Right" +#define BATTERY_ON_TXT "Left - start" + #else #error No keymap defined! #endif diff --git a/apps/plugins/blackjack.c b/apps/plugins/blackjack.c index bd89d5a985..411ff3970b 100644 --- a/apps/plugins/blackjack.c +++ b/apps/plugins/blackjack.c @@ -559,6 +559,20 @@ enum { #define BJACK_QUIT BUTTON_POWER #define BJACK_QUIT_NAME "Power" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define BJACK_SELECT BUTTON_SELECT +#define BJACK_QUIT BUTTON_POWER +#define BJACK_STAY (BUTTON_VOLUP|BUTTON_SELECT) +#define BJACK_DOUBLEDOWN (BUTTON_VOLUP|BUTTON_DOWN) +#define BJACK_UP BUTTON_UP +#define BJACK_DOWN BUTTON_DOWN +#define BJACK_RIGHT BUTTON_RIGHT +#define BJACK_LEFT BUTTON_LEFT +#define BJACK_SELECT_NAME "Select" +#define BJACK_STAY_NAME "Option+Select" +#define BJACK_QUIT_NAME "Volume up" +#define BJACK_DOUBLE_NAME "Option+Down" + #else #error No keymap defined! #endif diff --git a/apps/plugins/brickmania.c b/apps/plugins/brickmania.c index 34a8338e65..3fc30819b9 100644 --- a/apps/plugins/brickmania.c +++ b/apps/plugins/brickmania.c @@ -324,6 +324,14 @@ CONFIG_KEYPAD == SANSA_CONNECT_PAD #define SELECT BUTTON_MENU #define CONTINUE_TEXT "Press MENU To Continue" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define QUIT BUTTON_POWER +#define LEFT BUTTON_LEFT +#define RIGHT BUTTON_RIGHT +#define SELECT BUTTON_SELECT +#define UP BUTTON_UP +#define DOWN BUTTON_DOWN + #else #error No keymap defined! #endif diff --git a/apps/plugins/calculator.c b/apps/plugins/calculator.c index 25128d69be..a30ccdc83d 100644 --- a/apps/plugins/calculator.c +++ b/apps/plugins/calculator.c @@ -515,6 +515,16 @@ F3: equal to "=" #define CALCULATOR_QUIT BUTTON_POWER #define CALCULATOR_INPUT BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define CALCULATOR_LEFT BUTTON_LEFT +#define CALCULATOR_RIGHT BUTTON_RIGHT +#define CALCULATOR_UP BUTTON_UP +#define CALCULATOR_DOWN BUTTON_DOWN +#define CALCULATOR_QUIT BUTTON_POWER +#define CALCULATOR_INPUT BUTTON_SELECT +#define CALCULATOR_CALC BUTTON_VOLUP +#define CALCULATOR_CLEAR (BUTTON_SELECT|BUTTON_REPEAT) + #else #error No keymap defined! #endif diff --git a/apps/plugins/calendar.c b/apps/plugins/calendar.c index 65c29742e8..23446beb40 100644 --- a/apps/plugins/calendar.c +++ b/apps/plugins/calendar.c @@ -403,6 +403,16 @@ #define CALENDAR_SELECT BUTTON_MENU #define CALENDAR_EVENT_MENU_NAME "menu" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define CALENDAR_QUIT BUTTON_POWER +#define CALENDAR_SELECT BUTTON_SELECT +#define CALENDAR_NEXT_DAY BUTTON_RIGHT +#define CALENDAR_PREV_DAY BUTTON_LEFT +#define CALENDAR_NEXT_WEEK BUTTON_DOWN +#define CALENDAR_PREV_WEEK BUTTON_UP +#define CALENDAR_NEXT_MONTH (BUTTON_VOLDOWN) +#define CALENDAR_PREV_MONTH (BUTTON_VOLUP) + #else #error "No keypad setting." #endif diff --git a/apps/plugins/chessbox/chessbox_pgn.h b/apps/plugins/chessbox/chessbox_pgn.h index 34f68cb325..fe50297732 100644 --- a/apps/plugins/chessbox/chessbox_pgn.h +++ b/apps/plugins/chessbox/chessbox_pgn.h @@ -544,6 +544,20 @@ #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define CB_MENU BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define CB_SELECT BUTTON_SELECT +#define CB_UP BUTTON_UP +#define CB_DOWN BUTTON_DOWN +#define CB_LEFT BUTTON_LEFT +#define CB_RIGHT BUTTON_RIGHT +#define CB_PLAY BUTTON_VOLDOWN +#define CB_MENU BUTTON_POWER +#define CB_LEVEL BUTTON_VOLUP +#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT) +#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT) +#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT) +#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT) + #else #error No keymap defined! #endif diff --git a/apps/plugins/chessclock.c b/apps/plugins/chessclock.c index 7473c47024..bc907feec3 100644 --- a/apps/plugins/chessclock.c +++ b/apps/plugins/chessclock.c @@ -402,6 +402,16 @@ #define CHC_QUIT BUTTON_POWER #define CHC_STARTSTOP BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define CHC_QUIT (BUTTON_POWER|BUTTON_REPEAT) +#define CHC_RESET (BUTTON_LEFT) +#define CHC_MENU BUTTON_RIGHT +#define CHC_STARTSTOP BUTTON_SELECT +#define CHC_SETTINGS_INC BUTTON_VOLUP +#define CHC_SETTINGS_DEC BUTTON_VOLDOWN +#define CHC_SETTINGS_CANCEL BUTTON_RIGHT +#define CHC_SETTINGS_OK (BUTTON_SELECT|BUTTON_REPEAT) + #else #error No keymap defined! #endif diff --git a/apps/plugins/chip8.c b/apps/plugins/chip8.c index 316852c14f..5fb55ae011 100644 --- a/apps/plugins/chip8.c +++ b/apps/plugins/chip8.c @@ -1275,6 +1275,14 @@ CONFIG_KEYPAD == MROBE500_PAD #define CHIP8_KEY8 BUTTON_BOTTOMMIDDLE #define CHIP8_KEY9 BUTTON_BOTTOMRIGHT +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define CHIP8_OFF BUTTON_POWER +#define CHIP8_KEY2 BUTTON_UP +#define CHIP8_KEY4 BUTTON_DOWN +#define CHIP8_KEY5 BUTTON_SELECT +#define CHIP8_KEY6 BUTTON_RIGHT +#define CHIP8_KEY8 BUTTON_LEFT + #else #error No keymap defined! #endif diff --git a/apps/plugins/chopper.c b/apps/plugins/chopper.c index 3c47633f85..4a838c44ae 100644 --- a/apps/plugins/chopper.c +++ b/apps/plugins/chopper.c @@ -204,6 +204,11 @@ CONFIG_KEYPAD == MROBE500_PAD #define ACTION BUTTON_SELECT #define ACTIONTEXT "Select" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define QUIT BUTTON_POWER +#define ACTION BUTTON_SELECT +#define ACTIONTEXT "Select" + #elif !defined(HAVE_TOUCHSCREEN) #error No keymap defined! diff --git a/apps/plugins/clix.c b/apps/plugins/clix.c index 5ad556d2ce..b47fe69952 100644 --- a/apps/plugins/clix.c +++ b/apps/plugins/clix.c @@ -266,6 +266,16 @@ #define CLIX_BUTTON_RIGHT BUTTON_MIDRIGHT #define CLIX_BUTTON_CLICK BUTTON_CENTER +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define CLIX_BUTTON_QUIT BUTTON_POWER +#define CLIX_BUTTON_UP BUTTON_UP +#define CLIX_BUTTON_DOWN BUTTON_DOWN +#define CLIX_BUTTON_SCROLL_FWD (BUTTON_VOLUP) +#define CLIX_BUTTON_SCROLL_BACK (BUTTON_VOLDOWN) +#define CLIX_BUTTON_LEFT BUTTON_LEFT +#define CLIX_BUTTON_RIGHT BUTTON_RIGHT +#define CLIX_BUTTON_CLICK BUTTON_SELECT + #else #error "no keymap" #endif diff --git a/apps/plugins/cube.c b/apps/plugins/cube.c index 53f0d7d949..04cb013f26 100644 --- a/apps/plugins/cube.c +++ b/apps/plugins/cube.c @@ -403,6 +403,16 @@ #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define CUBE_QUIT BUTTON_POWER +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define CUBE_QUIT (BUTTON_POWER|BUTTON_REL) +#define CUBE_NEXT BUTTON_RIGHT +#define CUBE_PREV BUTTON_LEFT +#define CUBE_INC BUTTON_VOLUP +#define CUBE_DEC BUTTON_VOLDOWN +#define CUBE_MODE BUTTON_SELECT +#define CUBE_HIGHSPEED (BUTTON_SELECT | BUTTON_REPEAT) +#define CUBE_PAUSE (BUTTON_LEFT | BUTTON_REPEAT) + #else #error No keymap defined! #endif diff --git a/apps/plugins/doom/i_video.c b/apps/plugins/doom/i_video.c index 2a6868778b..5535f08b6e 100644 --- a/apps/plugins/doom/i_video.c +++ b/apps/plugins/doom/i_video.c @@ -543,6 +543,18 @@ void I_ShutdownGraphics(void) #define DOOMBUTTON_SHOOT BUTTON_MENU #define DOOMBUTTON_MAP BUTTON_TOPLEFT +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define DOOMBUTTON_UP BUTTON_UP +#define DOOMBUTTON_DOWN BUTTON_DOWN +#define DOOMBUTTON_LEFT BUTTON_LEFT +#define DOOMBUTTON_RIGHT BUTTON_RIGHT +#define DOOMBUTTON_OPEN BUTTON_VOLDOWN +#define DOOMBUTTON_ESC (BUTTON_POWER|BUTTON_REPEAT) +#define DOOMBUTTON_ENTER BUTTON_SELECT +#define DOOMBUTTON_SHOOT BUTTON_SELECT +#define DOOMBUTTON_WEAPON BUTTON_VOLUP +#define DOOMBUTTON_MAP (BUTTON_VOLUP|BUTTON_REPEAT) + #else #error Keymap not defined! #endif diff --git a/apps/plugins/fft/fft.c b/apps/plugins/fft/fft.c index 3e88722b23..a83bd36557 100644 --- a/apps/plugins/fft/fft.c +++ b/apps/plugins/fft/fft.c @@ -325,6 +325,15 @@ GREY_INFO_STRUCT # define FFT_PREV_GRAPH BUTTON_VOL_UP # define FFT_NEXT_GRAPH BUTTON_VOL_DOWN +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +# define FFT_PREV_GRAPH BUTTON_LEFT +# define FFT_NEXT_GRAPH BUTTON_RIGHT +# define FFT_AMP_SCALE BUTTON_UP +# define FFT_FREQ_SCALE BUTTON_DOWN +# define FFT_QUIT BUTTON_POWER +# define FFT_ORIENTATION BUTTON_SELECT +# define FFT_WINDOW BUTTON_VOLDOWN + #elif !defined(HAVE_TOUCHSCREEN) #error No keymap defined! #endif diff --git a/apps/plugins/flipit.c b/apps/plugins/flipit.c index 158d69da8d..fafc1f9c08 100644 --- a/apps/plugins/flipit.c +++ b/apps/plugins/flipit.c @@ -470,6 +470,18 @@ #define FLIPIT_QUIT BUTTON_POWER #define FLIPIT_TOGGLE BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD + +#define FLIPIT_LEFT BUTTON_LEFT +#define FLIPIT_RIGHT BUTTON_RIGHT +#define FLIPIT_UP BUTTON_UP +#define FLIPIT_DOWN BUTTON_DOWN +#define FLIPIT_QUIT (BUTTON_POWER|BUTTON_REL) +#define FLIPIT_SHUFFLE (BUTTON_VOLDOWN) +#define FLIPIT_SOLVE (BUTTON_SELECT|BUTTON_VOLUP) +#define FLIPIT_STEP_BY_STEP (BUTTON_LEFT|BUTTON_VOLUP) +#define FLIPIT_TOGGLE BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/fractals/fractal.h b/apps/plugins/fractals/fractal.h index d9c4a88bdf..aa8c31f093 100644 --- a/apps/plugins/fractals/fractal.h +++ b/apps/plugins/fractals/fractal.h @@ -472,6 +472,18 @@ #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define FRACTAL_QUIT BUTTON_POWER +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define FRACTAL_QUIT BUTTON_POWER +#define FRACTAL_UP BUTTON_UP +#define FRACTAL_DOWN BUTTON_DOWN +#define FRACTAL_RIGHT BUTTON_RIGHT +#define FRACTAL_LEFT BUTTON_LEFT +#define FRACTAL_ZOOM_IN (BUTTON_VOLUP|BUTTON_UP) +#define FRACTAL_ZOOM_OUT (BUTTON_VOLUP|BUTTON_DOWN) +#define FRACTAL_PRECISION_INC (BUTTON_VOLUP|BUTTON_RIGHT) +#define FRACTAL_PRECISION_DEC (BUTTON_VOLUP|BUTTON_LEFT) +#define FRACTAL_RESET BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/goban/goban.h b/apps/plugins/goban/goban.h index 261fd8ebcc..135b9dbe95 100644 --- a/apps/plugins/goban/goban.h +++ b/apps/plugins/goban/goban.h @@ -443,6 +443,15 @@ #elif (CONFIG_KEYPAD == DX50_PAD) #define GBN_BUTTON_MENU (BUTTON_POWER|BUTTON_REL) +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define GBN_BUTTON_UP BUTTON_UP +#define GBN_BUTTON_DOWN BUTTON_DOWN +#define GBN_BUTTON_LEFT BUTTON_LEFT +#define GBN_BUTTON_RIGHT BUTTON_RIGHT +#define GBN_BUTTON_MENU BUTTON_POWER +#define GBN_BUTTON_PLAY (BUTTON_SELECT | BUTTON_REL) +#define GBN_BUTTON_NAV_MODE BUTTON_VOLUP + #else #error Unsupported keypad #endif diff --git a/apps/plugins/imageviewer/imageviewer_button.h b/apps/plugins/imageviewer/imageviewer_button.h index 13502369ee..abd84f1710 100644 --- a/apps/plugins/imageviewer/imageviewer_button.h +++ b/apps/plugins/imageviewer/imageviewer_button.h @@ -483,6 +483,18 @@ #define IMGVIEW_QUIT BUTTON_POWER #define IMGVIEW_MENU BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define IMGVIEW_ZOOM_IN BUTTON_VOLUP +#define IMGVIEW_ZOOM_OUT BUTTON_VOLDOWN +#define IMGVIEW_UP BUTTON_UP +#define IMGVIEW_DOWN BUTTON_DOWN +#define IMGVIEW_LEFT BUTTON_LEFT +#define IMGVIEW_RIGHT BUTTON_RIGHT +#define IMGVIEW_NEXT (BUTTON_SELECT|BUTTON_RIGHT) +#define IMGVIEW_PREVIOUS (BUTTON_SELECT|BUTTON_LEFT) +#define IMGVIEW_QUIT (BUTTON_POWER|BUTTON_REL) +#define IMGVIEW_MENU (BUTTON_SELECT|BUTTON_REL) + #else #error No keymap defined! #endif diff --git a/apps/plugins/jewels.c b/apps/plugins/jewels.c index 9fd57873f0..97531a001c 100644 --- a/apps/plugins/jewels.c +++ b/apps/plugins/jewels.c @@ -348,6 +348,16 @@ CONFIG_KEYPAD == MROBE500_PAD #define HK_SELECT "SELECT" #define HK_CANCEL "POWER" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define JEWELS_LEFT BUTTON_LEFT +#define JEWELS_RIGHT BUTTON_RIGHT +#define JEWELS_UP BUTTON_UP +#define JEWELS_DOWN BUTTON_DOWN +#define JEWELS_SELECT BUTTON_SELECT +#define JEWELS_CANCEL BUTTON_POWER +#define HK_SELECT "SELECT" +#define HK_CANCEL "POWER" + #elif (CONFIG_KEYPAD == HM60X_PAD) || \ (CONFIG_KEYPAD == HM801_PAD) #define JEWELS_LEFT BUTTON_LEFT diff --git a/apps/plugins/lib/keymaps.h b/apps/plugins/lib/keymaps.h index c079a9080b..64deccf513 100644 --- a/apps/plugins/lib/keymaps.h +++ b/apps/plugins/lib/keymaps.h @@ -60,7 +60,8 @@ (CONFIG_KEYPAD == SAMSUNG_YPR0_PAD) || \ (CONFIG_KEYPAD == IRIVER_H300_PAD) || \ (CONFIG_KEYPAD == HM801_PAD) || \ - (CONFIG_KEYPAD == HM60X_PAD) + (CONFIG_KEYPAD == HM60X_PAD) || \ + (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) #define BTN_UP BUTTON_UP #define BTN_DOWN BUTTON_DOWN #define BTN_LEFT BUTTON_LEFT @@ -83,6 +84,10 @@ #define BTN_UP_RIGHT BUTTON_TOPRIGHT #endif +#if (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define BTN_FIRE BUTTON_SELECT +#define BTN_PAUSE BUTTON_POWER +#endif #if (CONFIG_KEYPAD == HM60X_PAD) #define BTN_FIRE BUTTON_POWER diff --git a/apps/plugins/lib/osd.c b/apps/plugins/lib/osd.c index e6fc39178a..d2e0fe3e50 100644 --- a/apps/plugins/lib/osd.c +++ b/apps/plugins/lib/osd.c @@ -115,6 +115,9 @@ static struct osd grey_osd; #elif LCD_DEPTH == 24 # define _OSD_WIDTH2BYTES(w) ((w)*3) # define _OSD_BYTES2WIDTH(b) ((b)/3) +#elif LCD_DEPTH == 32 +# define _OSD_WIDTH2BYTES(w) ((w)*4) +# define _OSD_BYTES2WIDTH(b) ((b)/4) #else /* other LCD depth */ # error Unknown LCD depth; please define macros #endif /* LCD_DEPTH */ diff --git a/apps/plugins/lib/pluginlib_actions.c b/apps/plugins/lib/pluginlib_actions.c index 2f550f817c..f9addb32f4 100644 --- a/apps/plugins/lib/pluginlib_actions.c +++ b/apps/plugins/lib/pluginlib_actions.c @@ -123,7 +123,8 @@ const struct button_mapping pla_main_ctx[] = || (CONFIG_KEYPAD == HM60X_PAD) \ || (CONFIG_KEYPAD == HM801_PAD) \ || (CONFIG_KEYPAD == SONY_NWZ_PAD) \ - || (CONFIG_KEYPAD == CREATIVE_ZEN_PAD)) + || (CONFIG_KEYPAD == CREATIVE_ZEN_PAD) \ + || (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD)) { PLA_UP, BUTTON_UP, BUTTON_NONE }, { PLA_DOWN, BUTTON_DOWN, BUTTON_NONE }, { PLA_LEFT, BUTTON_LEFT, BUTTON_NONE }, @@ -422,6 +423,12 @@ const struct button_mapping pla_main_ctx[] = {PLA_SELECT, BUTTON_SELECT, BUTTON_NONE}, {PLA_SELECT_REL, BUTTON_SELECT|BUTTON_REL, BUTTON_SELECT}, {PLA_SELECT_REPEAT, BUTTON_SELECT|BUTTON_REPEAT, BUTTON_NONE}, +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) + {PLA_CANCEL, BUTTON_VOLUP, BUTTON_NONE}, + {PLA_EXIT, BUTTON_POWER, BUTTON_NONE}, + {PLA_SELECT, BUTTON_SELECT, BUTTON_NONE}, + {PLA_SELECT_REL, BUTTON_SELECT|BUTTON_REL, BUTTON_SELECT}, + {PLA_SELECT_REPEAT, BUTTON_SELECT|BUTTON_REPEAT, BUTTON_NONE}, #elif (CONFIG_KEYPAD == CREATIVE_ZENXFI3_PAD) {PLA_CANCEL, BUTTON_POWER|BUTTON_REL, BUTTON_NONE}, {PLA_EXIT, BUTTON_POWER|BUTTON_REPEAT, BUTTON_NONE}, diff --git a/apps/plugins/midi/midiplay.c b/apps/plugins/midi/midiplay.c index 5e329cef06..418f72b6a5 100644 --- a/apps/plugins/midi/midiplay.c +++ b/apps/plugins/midi/midiplay.c @@ -285,6 +285,14 @@ #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define MIDI_QUIT BUTTON_POWER +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define MIDI_QUIT BUTTON_POWER +#define MIDI_FFWD BUTTON_RIGHT +#define MIDI_REWIND BUTTON_LEFT +#define MIDI_VOL_UP BUTTON_VOLUP +#define MIDI_VOL_DOWN BUTTON_VOLDOWN +#define MIDI_PLAYPAUSE BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/minesweeper.c b/apps/plugins/minesweeper.c index d83a24370b..98eb8d9e7a 100644 --- a/apps/plugins/minesweeper.c +++ b/apps/plugins/minesweeper.c @@ -388,6 +388,16 @@ CONFIG_KEYPAD == MROBE500_PAD #define MINESWP_DISCOVER BUTTON_SELECT #define MINESWP_INFO BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define MINESWP_LEFT BUTTON_LEFT +#define MINESWP_RIGHT BUTTON_RIGHT +#define MINESWP_UP BUTTON_UP +#define MINESWP_DOWN BUTTON_DOWN +#define MINESWP_QUIT BUTTON_POWER +#define MINESWP_TOGGLE BUTTON_VOLUP +#define MINESWP_DISCOVER BUTTON_SELECT +#define MINESWP_INFO BUTTON_VOLDOWN + #elif (CONFIG_KEYPAD == DX50_PAD) # define MINESWP_QUIT (BUTTON_POWER|BUTTON_REL) diff --git a/apps/plugins/mp3_encoder.c b/apps/plugins/mp3_encoder.c index c9be9e4260..e86e74f408 100644 --- a/apps/plugins/mp3_encoder.c +++ b/apps/plugins/mp3_encoder.c @@ -2550,6 +2550,12 @@ CONFIG_KEYPAD == MROBE500_PAD #define MP3ENC_DONE BUTTON_POWER #define MP3ENC_SELECT BUTTON_MENU +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define MP3ENC_PREV BUTTON_LEFT +#define MP3ENC_NEXT BUTTON_RIGHT +#define MP3ENC_DONE BUTTON_POWER +#define MP3ENC_SELECT BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/mpegplayer/mpeg_settings.c b/apps/plugins/mpegplayer/mpeg_settings.c index d6b926b585..fc9bcb6ec4 100644 --- a/apps/plugins/mpegplayer/mpeg_settings.c +++ b/apps/plugins/mpegplayer/mpeg_settings.c @@ -298,6 +298,13 @@ struct mpeg_settings settings; #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define MPEG_START_TIME_EXIT BUTTON_POWER +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define MPEG_START_TIME_SELECT BUTTON_SELECT +#define MPEG_START_TIME_LEFT BUTTON_LEFT +#define MPEG_START_TIME_RIGHT BUTTON_RIGHT +#define MPEG_START_TIME_UP BUTTON_UP +#define MPEG_START_TIME_DOWN BUTTON_DOWN + #else #error No keymap defined! #endif diff --git a/apps/plugins/mpegplayer/mpegplayer.c b/apps/plugins/mpegplayer/mpegplayer.c index 056b46c7a1..07cf8ba8e2 100644 --- a/apps/plugins/mpegplayer/mpegplayer.c +++ b/apps/plugins/mpegplayer/mpegplayer.c @@ -432,6 +432,15 @@ CONFIG_KEYPAD == SANSA_M200_PAD #define MPEG_PAUSE BUTTON_MENU #define MPEG_STOP (BUTTON_MENU|BUTTON_REPEAT) +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define MPEG_MENU BUTTON_POWER +#define MPEG_PAUSE BUTTON_SELECT +#define MPEG_STOP BUTTON_DOWN +#define MPEG_VOLDOWN BUTTON_VOLDOWN +#define MPEG_VOLUP BUTTON_VOLUP +#define MPEG_RW BUTTON_LEFT +#define MPEG_FF BUTTON_RIGHT + #else #error No keymap defined! #endif diff --git a/apps/plugins/oscilloscope.c b/apps/plugins/oscilloscope.c index 07c40c2b4e..85cbf2bfb2 100644 --- a/apps/plugins/oscilloscope.c +++ b/apps/plugins/oscilloscope.c @@ -493,6 +493,17 @@ #define OSCILLOSCOPE_ORIENTATION BUTTON_TOPLEFT #define OSCILLOSCOPE_GRAPHMODE BUTTON_BOTTOMLEFT +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define OSCILLOSCOPE_QUIT BUTTON_POWER +#define OSCILLOSCOPE_DRAWMODE (BUTTON_SELECT|BUTTON_UP) +#define OSCILLOSCOPE_ADVMODE BUTTON_DOWN +#define OSCILLOSCOPE_ORIENTATION BUTTON_UP +#define OSCILLOSCOPE_PAUSE BUTTON_SELECT +#define OSCILLOSCOPE_SPEED_UP BUTTON_RIGHT +#define OSCILLOSCOPE_SPEED_DOWN BUTTON_LEFT +#define OSCILLOSCOPE_VOL_UP BUTTON_VOLUP +#define OSCILLOSCOPE_VOL_DOWN BUTTON_VOLDOWN + #else #error No keymap defined! #endif diff --git a/apps/plugins/pacbox/pacbox.h b/apps/plugins/pacbox/pacbox.h index 9c4c305539..5eb9103d90 100644 --- a/apps/plugins/pacbox/pacbox.h +++ b/apps/plugins/pacbox/pacbox.h @@ -354,6 +354,15 @@ #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define PACMAN_MENU BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define PACMAN_UP BUTTON_UP +#define PACMAN_DOWN BUTTON_DOWN +#define PACMAN_LEFT BUTTON_LEFT +#define PACMAN_RIGHT BUTTON_RIGHT +#define PACMAN_MENU BUTTON_POWER +#define PACMAN_1UP BUTTON_VOLUP +#define PACMAN_COIN BUTTON_VOLDOWN + #else #error Keymap not defined! diff --git a/apps/plugins/pegbox.c b/apps/plugins/pegbox.c index 4692a1a766..dcc6176d2b 100644 --- a/apps/plugins/pegbox.c +++ b/apps/plugins/pegbox.c @@ -599,6 +599,21 @@ CONFIG_KEYPAD == MROBE500_PAD #define LVL_DOWN_TEXT "" #define SELECT_TEXT "PLAY" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define PEGBOX_RIGHT BUTTON_RIGHT +#define PEGBOX_LEFT BUTTON_LEFT +#define PEGBOX_UP BUTTON_UP +#define PEGBOX_DOWN BUTTON_DOWN +#define PEGBOX_QUIT BUTTON_POWER +#define PEGBOX_SELECT BUTTON_SELECT +#define PEGBOX_RESTART BUTTON_VOLUP + +#define QUIT_TEXT "POWER" +#define RESTART_TEXT "VOLUP" +#define LVL_UP_TEXT "" +#define LVL_DOWN_TEXT "" +#define SELECT_TEXT "SELECT" + #elif CONFIG_KEYPAD == CREATIVE_ZEN_PAD #define PEGBOX_RIGHT BUTTON_RIGHT #define PEGBOX_LEFT BUTTON_LEFT diff --git a/apps/plugins/pictureflow/pictureflow.c b/apps/plugins/pictureflow/pictureflow.c index 4db3ad366d..6e47418e93 100644 --- a/apps/plugins/pictureflow/pictureflow.c +++ b/apps/plugins/pictureflow/pictureflow.c @@ -1826,7 +1826,7 @@ static inline pix_t fade_color(pix_t c, unsigned a) result >>= 8; return result; -#elif LCD_PIXELFORMAT == RGB888 +#elif (LCD_PIXELFORMAT == RGB888 || LCD_PIXELFORMAT == XRGB8888) // FIXME: check this unsigned int pixel = FB_UNPACK_SCALAR_LCD(c); unsigned int result; a = (a + 2) & 0x1fc; diff --git a/apps/plugins/pong.c b/apps/plugins/pong.c index e097480e85..016d548675 100644 --- a/apps/plugins/pong.c +++ b/apps/plugins/pong.c @@ -294,6 +294,14 @@ CONFIG_KEYPAD == MROBE500_PAD #define PONG_RIGHT_UP BUTTON_RIGHT #define PONG_RIGHT_DOWN BUTTON_LEFT +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define PONG_QUIT BUTTON_POWER +#define PONG_PAUSE BUTTON_SELECT +#define PONG_LEFT_UP BUTTON_UP +#define PONG_LEFT_DOWN BUTTON_DOWN +#define PONG_RIGHT_UP BUTTON_RIGHT +#define PONG_RIGHT_DOWN BUTTON_LEFT + #elif (CONFIG_KEYPAD == DX50_PAD) #define PONG_QUIT (BUTTON_POWER|BUTTON_REL) diff --git a/apps/plugins/puzzles/rockbox.c b/apps/plugins/puzzles/rockbox.c index e681db3c16..88186b5154 100644 --- a/apps/plugins/puzzles/rockbox.c +++ b/apps/plugins/puzzles/rockbox.c @@ -177,7 +177,13 @@ static void zoom_drawpixel(int x, int y) if(x < zoom_clipl || x >= zoom_clipr) return; -#if LCD_DEPTH == 24 +#if LCD_DEPTH > 24 + unsigned int pix = rb->lcd_get_foreground(); + zoom_fb[y * zoom_w + x].b = RGB_UNPACK_BLUE(pix); + zoom_fb[y * zoom_w + x].g = RGB_UNPACK_GREEN(pix); + zoom_fb[y * zoom_w + x].r = RGB_UNPACK_RED(pix); + zoom_fb[y * zoom_w + x].x = 255; +#elif LCD_DEPTH == 24 /* I hate these */ unsigned int pix = rb->lcd_get_foreground(); zoom_fb[y * zoom_w + x].b = RGB_UNPACK_BLUE(pix); @@ -204,7 +210,13 @@ static void zoom_hline(int l, int r, int y) if(r >= zoom_clipr) r = zoom_clipr; -#if LCD_DEPTH == 24 +#if LCD_DEPTH > 24 + fb_data pixel = { RGB_UNPACK_BLUE(rb->lcd_get_foreground()), + RGB_UNPACK_GREEN(rb->lcd_get_foreground()), + RGB_UNPACK_RED(rb->lcd_get_foreground()), + 255 + }; +#elif LCD_DEPTH == 24 fb_data pixel = { RGB_UNPACK_BLUE(rb->lcd_get_foreground()), RGB_UNPACK_GREEN(rb->lcd_get_foreground()), RGB_UNPACK_RED(rb->lcd_get_foreground()) }; @@ -285,7 +297,12 @@ static void zoom_mono_bitmap(const unsigned char *bits, int x, int y, int w, int { if(column & 1) { -#if LCD_DEPTH == 24 +#if LCD_DEPTH > 24 + zoom_fb[(y + i * 8 + dy) * zoom_w + x + j].b = RGB_UNPACK_BLUE(pix); + zoom_fb[(y + i * 8 + dy) * zoom_w + x + j].g = RGB_UNPACK_GREEN(pix); + zoom_fb[(y + i * 8 + dy) * zoom_w + x + j].r = RGB_UNPACK_RED(pix); + zoom_fb[(y + i * 8 + dy) * zoom_w + x + j].r = 255; +#elif LCD_DEPTH == 24 zoom_fb[(y + i * 8 + dy) * zoom_w + x + j].b = RGB_UNPACK_BLUE(pix); zoom_fb[(y + i * 8 + dy) * zoom_w + x + j].g = RGB_UNPACK_GREEN(pix); zoom_fb[(y + i * 8 + dy) * zoom_w + x + j].r = RGB_UNPACK_RED(pix); @@ -625,7 +642,7 @@ static inline void plot(fb_data *fb, int w, int h, fb_data *ptr = fb + y * w + x; fb_data orig = *ptr; unsigned long r2, g2, b2; -#if LCD_DEPTH != 24 +#if LCD_DEPTH < 24 r2 = RGB_UNPACK_RED(orig); g2 = RGB_UNPACK_GREEN(orig); b2 = RGB_UNPACK_BLUE(orig); @@ -640,8 +657,10 @@ static inline void plot(fb_data *fb, int w, int h, g = ((g1 * a) + (g2 * (256 - a))) >> 8; b = ((b1 * a) + (b2 * (256 - a))) >> 8; -#if LCD_DEPTH != 24 +#if LCD_DEPTH < 24 *ptr = LCD_RGBPACK(r, g, b); +#elif LCD_DEPTH > 24 + *ptr = (fb_data) {b, g, r, 255}; #else *ptr = (fb_data) {b, g, r}; #endif @@ -1454,7 +1473,7 @@ void get_random_seed(void **randseed, int *randseedsize) static void timer_cb(void) { -#if LCD_DEPTH != 24 +#if LCD_DEPTH < 24 if(debug_settings.timerflash) { static bool what = false; diff --git a/apps/plugins/reversi/reversi-gui.h b/apps/plugins/reversi/reversi-gui.h index 37833c10f1..67897a9772 100644 --- a/apps/plugins/reversi/reversi-gui.h +++ b/apps/plugins/reversi/reversi-gui.h @@ -320,6 +320,14 @@ #define REVERSI_BUTTON_QUIT BUTTON_POWER #define REVERSI_BUTTON_MENU BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define REVERSI_BUTTON_UP BUTTON_UP +#define REVERSI_BUTTON_DOWN BUTTON_DOWN +#define REVERSI_BUTTON_LEFT BUTTON_LEFT +#define REVERSI_BUTTON_RIGHT BUTTON_RIGHT +#define REVERSI_BUTTON_MAKE_MOVE BUTTON_SELECT +#define REVERSI_BUTTON_MENU BUTTON_POWER + #else #error No keymap defined! #endif diff --git a/apps/plugins/rockblox.c b/apps/plugins/rockblox.c index 14ded91961..a0814beda1 100644 --- a/apps/plugins/rockblox.c +++ b/apps/plugins/rockblox.c @@ -470,6 +470,16 @@ #define ROCKBLOX_OFF BUTTON_POWER #define ROCKBLOX_ROTATE BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define ROCKBLOX_OFF BUTTON_POWER +#define ROCKBLOX_LEFT BUTTON_LEFT +#define ROCKBLOX_RIGHT BUTTON_RIGHT +#define ROCKBLOX_DROP BUTTON_UP +#define ROCKBLOX_RESTART (BUTTON_SELECT|BUTTON_LEFT) +#define ROCKBLOX_ROTATE_CW BUTTON_VOLUP +#define ROCKBLOX_ROTATE_CCW BUTTON_VOLDOWN +#define ROCKBLOX_DOWN BUTTON_DOWN + #else #error No keymap defined! #endif diff --git a/apps/plugins/rockboy/rockboy.c b/apps/plugins/rockboy/rockboy.c index bbcfde8442..38536d1375 100644 --- a/apps/plugins/rockboy/rockboy.c +++ b/apps/plugins/rockboy/rockboy.c @@ -411,6 +411,18 @@ static void setoptions (void) #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD options.MENU = BUTTON_POWER; +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD + options.UP = BUTTON_UP; + options.DOWN = BUTTON_DOWN; + options.LEFT = BUTTON_LEFT; + options.RIGHT = BUTTON_RIGHT; + + options.START = BUTTON_SELECT; + options.MENU = BUTTON_POWER; + options.SELECT = BUTTON_SELECT|BUTTON_REPEAT; + options.A = BUTTON_VOLDOWN; + options.B = BUTTON_VOLUP; + #else #error No Keymap Defined! #endif diff --git a/apps/plugins/sliding_puzzle.c b/apps/plugins/sliding_puzzle.c index 97a393c260..d43c3d527f 100644 --- a/apps/plugins/sliding_puzzle.c +++ b/apps/plugins/sliding_puzzle.c @@ -322,6 +322,15 @@ CONFIG_KEYPAD == MROBE500_PAD #define PUZZLE_QUIT_TEXT "[POWER]" #define PUZZLE_SHUFFLE_TEXT "[MENU]" +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define PUZZLE_QUIT (BUTTON_POWER|BUTTON_REPEAT) +#define PUZZLE_LEFT BUTTON_LEFT +#define PUZZLE_RIGHT BUTTON_RIGHT +#define PUZZLE_UP BUTTON_UP +#define PUZZLE_DOWN BUTTON_DOWN +#define PUZZLE_SHUFFLE BUTTON_POWER +#define PUZZLE_PICTURE BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/snake.c b/apps/plugins/snake.c index d457d3dbd6..a73e61d9ec 100644 --- a/apps/plugins/snake.c +++ b/apps/plugins/snake.c @@ -281,6 +281,14 @@ dir is the current direction of the snake - 0=up, 1=right, 2=down, 3=left; #define SNAKE_QUIT BUTTON_POWER #define SNAKE_PLAYPAUSE BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define SNAKE_QUIT BUTTON_POWER +#define SNAKE_LEFT BUTTON_LEFT +#define SNAKE_RIGHT BUTTON_RIGHT +#define SNAKE_UP BUTTON_UP +#define SNAKE_DOWN BUTTON_DOWN +#define SNAKE_PLAYPAUSE BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/snake2.c b/apps/plugins/snake2.c index 818dbfedf2..f32012e029 100644 --- a/apps/plugins/snake2.c +++ b/apps/plugins/snake2.c @@ -410,6 +410,15 @@ CONFIG_KEYPAD == MROBE500_PAD #define SNAKE2_PLAYPAUSE BUTTON_MENU #define SNAKE2_PLAYPAUSE_TEXT "Menu" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define SNAKE2_LEFT BUTTON_LEFT +#define SNAKE2_RIGHT BUTTON_RIGHT +#define SNAKE2_UP BUTTON_UP +#define SNAKE2_DOWN BUTTON_DOWN +#define SNAKE2_QUIT BUTTON_POWER +#define SNAKE2_PLAYPAUSE BUTTON_SELECT +#define SNAKE2_PLAYPAUSE_TEXT "Select" + #else #error No keymap defined! #endif diff --git a/apps/plugins/sokoban.c b/apps/plugins/sokoban.c index 4903e47cf5..af369f82a6 100644 --- a/apps/plugins/sokoban.c +++ b/apps/plugins/sokoban.c @@ -416,6 +416,18 @@ #define BUTTON_SAVE BUTTON_PLAYPAUSE #define BUTTON_SAVE_NAME "Play/pause" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define SOKOBAN_LEFT BUTTON_LEFT +#define SOKOBAN_RIGHT BUTTON_RIGHT +#define SOKOBAN_UP BUTTON_UP +#define SOKOBAN_DOWN BUTTON_DOWN +#define SOKOBAN_MENU BUTTON_POWER +#define SOKOBAN_UNDO BUTTON_VOLUP +#define SOKOBAN_REDO BUTTON_VOLDOWN +#define SOKOBAN_PAUSE BUTTON_SELECT +#define BUTTON_SAVE BUTTON_SELECT +#define BUTTON_SAVE_NAME "Select" + #elif CONFIG_KEYPAD == PHILIPS_HDD1630_PAD #define SOKOBAN_LEFT BUTTON_LEFT #define SOKOBAN_RIGHT BUTTON_RIGHT diff --git a/apps/plugins/solitaire.c b/apps/plugins/solitaire.c index affa4a314d..ee3742472b 100644 --- a/apps/plugins/solitaire.c +++ b/apps/plugins/solitaire.c @@ -647,6 +647,23 @@ CONFIG_KEYPAD == MROBE500_PAD #define HK_CUR2STACK "Option+Left" #define HK_REM2STACK "Option+Right" +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define SOL_QUIT BUTTON_POWER +#define SOL_UP BUTTON_UP +#define SOL_DOWN BUTTON_DOWN +#define SOL_LEFT BUTTON_LEFT +#define SOL_RIGHT BUTTON_RIGHT +#define SOL_MOVE BUTTON_SELECT +#define SOL_DRAW (BUTTON_VOLUP|BUTTON_UP) +#define SOL_REM2CUR (BUTTON_VOLUP|BUTTON_DOWN) +#define SOL_CUR2STACK (BUTTON_VOLUP|BUTTON_LEFT) +#define SOL_REM2STACK (BUTTON_VOLUP|BUTTON_RIGHT) +#define HK_MOVE "Select" +#define HK_DRAW "Option+Up" +#define HK_REM2CUR "Option+Down" +#define HK_CUR2STACK "Option+Left" +#define HK_REM2STACK "Option+Right" + #elif (CONFIG_KEYPAD == CREATIVE_ZEN_PAD) #define SOL_QUIT BUTTON_POWER #define SOL_UP BUTTON_UP diff --git a/apps/plugins/spacerocks.c b/apps/plugins/spacerocks.c index 819ecf87f2..7a22de814b 100644 --- a/apps/plugins/spacerocks.c +++ b/apps/plugins/spacerocks.c @@ -346,6 +346,14 @@ #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define AST_QUIT BUTTON_POWER +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define AST_QUIT BUTTON_POWER +#define AST_THRUST BUTTON_UP +#define AST_HYPERSPACE BUTTON_VOLUP +#define AST_LEFT BUTTON_LEFT +#define AST_RIGHT BUTTON_RIGHT +#define AST_FIRE BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/star.c b/apps/plugins/star.c index 3560c077f5..6d0cd65e20 100644 --- a/apps/plugins/star.c +++ b/apps/plugins/star.c @@ -607,6 +607,22 @@ #define STAR_TOGGLE_CONTROL BUTTON_MENU #define STAR_TOGGLE_CONTROL_NAME "MENU" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define STAR_QUIT BUTTON_POWER +#define STAR_LEFT BUTTON_LEFT +#define STAR_RIGHT BUTTON_RIGHT +#define STAR_UP BUTTON_UP +#define STAR_DOWN BUTTON_DOWN +#define STAR_TOGGLE_CONTROL BUTTON_SELECT +#define STAR_LEVEL_UP (BUTTON_VOLUP|BUTTON_UP) +#define STAR_LEVEL_DOWN (BUTTON_VOLUP|BUTTON_DOWN) +#define STAR_LEVEL_REPEAT (BUTTON_VOLUP|BUTTON_SELECT) +#define STAR_LEVEL_UP_NAME "Option+Up" +#define STAR_LEVEL_DOWN_NAME "Option+Down" +#define STAR_LEVEL_REPEAT_NAME "Option+Play" +#define STAR_TOGGLE_CONTROL_NAME "Play" +#define STAR_QUIT_NAME "Back" + #else #error No keymap defined! #endif diff --git a/apps/plugins/stopwatch.c b/apps/plugins/stopwatch.c index 3bfad97d9a..8d99178e48 100644 --- a/apps/plugins/stopwatch.c +++ b/apps/plugins/stopwatch.c @@ -305,6 +305,14 @@ #define STOPWATCH_SCROLL_UP BUTTON_UP #define STOPWATCH_SCROLL_DOWN BUTTON_DOWN +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define STOPWATCH_QUIT BUTTON_POWER +#define STOPWATCH_START_STOP BUTTON_SELECT +#define STOPWATCH_RESET_TIMER BUTTON_LEFT +#define STOPWATCH_LAP_TIMER BUTTON_RIGHT +#define STOPWATCH_SCROLL_UP BUTTON_UP +#define STOPWATCH_SCROLL_DOWN BUTTON_DOWN + #else #error No keymap defined! #endif diff --git a/apps/plugins/sudoku/sudoku.h b/apps/plugins/sudoku/sudoku.h index ca17399e8b..8d871c7b2d 100644 --- a/apps/plugins/sudoku/sudoku.h +++ b/apps/plugins/sudoku/sudoku.h @@ -414,6 +414,15 @@ #define SUDOKU_BUTTON_QUIT BUTTON_POWER #define SUDOKU_BUTTON_MENU BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define SUDOKU_BUTTON_MENU BUTTON_POWER +#define SUDOKU_BUTTON_UP BUTTON_UP +#define SUDOKU_BUTTON_DOWN BUTTON_DOWN +#define SUDOKU_BUTTON_LEFT BUTTON_LEFT +#define SUDOKU_BUTTON_RIGHT BUTTON_RIGHT +#define SUDOKU_BUTTON_TOGGLE BUTTON_SELECT +#define SUDOKU_BUTTON_POSSIBLE BUTTON_VOLUP + #else #error No keymap defined! #endif diff --git a/apps/plugins/text_viewer/tv_button.h b/apps/plugins/text_viewer/tv_button.h index 3ea41614a3..9d1b5afa88 100644 --- a/apps/plugins/text_viewer/tv_button.h +++ b/apps/plugins/text_viewer/tv_button.h @@ -540,6 +540,16 @@ #define TV_MENU BUTTON_MENU #define TV_BOOKMARK BUTTON_BOTTOMLEFT +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define TV_QUIT BUTTON_POWER +#define TV_SCROLL_UP BUTTON_UP +#define TV_SCROLL_DOWN BUTTON_DOWN +#define TV_SCREEN_LEFT BUTTON_LEFT +#define TV_SCREEN_RIGHT BUTTON_RIGHT +#define TV_MENU BUTTON_SELECT +#define TV_AUTOSCROLL BUTTON_VOLDOWN +#define TV_BOOKMARK BUTTON_VOLUP + #else #error No keymap defined! #endif diff --git a/apps/plugins/vu_meter.c b/apps/plugins/vu_meter.c index 12cc127002..8c80066c67 100644 --- a/apps/plugins/vu_meter.c +++ b/apps/plugins/vu_meter.c @@ -409,6 +409,18 @@ #define LABEL_QUIT "Power" #define LABEL_MENU "Menu" +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define VUMETER_QUIT (BUTTON_POWER|BUTTON_REL) +#define VUMETER_MENU BUTTON_SELECT +#define VUMETER_UP BUTTON_VOLUP +#define VUMETER_DOWN BUTTON_VOLDOWN +#define VUMETER_HELP BUTTON_UP +#define LABEL_QUIT "Power" +#define LABEL_MENU "Select" +#define LABEL_HELP "Up" +#define LABEL_VOLUME "Vol Up/Down" +#define LABEL_MENU "Select" + #else #error No keymap defined! #endif diff --git a/apps/plugins/wormlet.c b/apps/plugins/wormlet.c index 33076df57e..f1ccaec782 100644 --- a/apps/plugins/wormlet.c +++ b/apps/plugins/wormlet.c @@ -384,6 +384,15 @@ CONFIG_KEYPAD == MROBE500_PAD #define BTN_STARTPAUSE BUTTON_MENU #define BTN_STOPRESET (BUTTON_MENU|BUTTON_REPEAT) +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define BTN_DIR_UP BUTTON_UP +#define BTN_DIR_DOWN BUTTON_DOWN +#define BTN_DIR_LEFT BUTTON_LEFT +#define BTN_DIR_RIGHT BUTTON_RIGHT +#define BTN_STARTPAUSE BUTTON_SELECT +#define BTN_QUIT BUTTON_POWER +#define BTN_STOPRESET (BUTTON_SELECT|BUTTON_REPEAT) + #else #error No keymap defined! #endif diff --git a/apps/plugins/xobox.c b/apps/plugins/xobox.c index ada33dafdd..f5c4a29bdf 100644 --- a/apps/plugins/xobox.c +++ b/apps/plugins/xobox.c @@ -334,6 +334,14 @@ CONFIG_KEYPAD == MROBE500_PAD #define QUIT BUTTON_POWER #define PAUSE BUTTON_MENU +#elif CONFIG_KEYPAD == AGPTEK_ROCKER_PAD +#define QUIT BUTTON_POWER +#define LEFT BUTTON_LEFT +#define RIGHT BUTTON_RIGHT +#define UP BUTTON_UP +#define DOWN BUTTON_DOWN +#define PAUSE BUTTON_SELECT + #else #error No keymap defined! #endif diff --git a/apps/plugins/xworld/sys.c b/apps/plugins/xworld/sys.c index a240c75924..22fc92f7e2 100644 --- a/apps/plugins/xworld/sys.c +++ b/apps/plugins/xworld/sys.c @@ -448,7 +448,11 @@ void sys_setPalette(struct System* sys, uint8_t start, uint8_t n, const uint8_t uint8_t col = buf[i * 3 + j]; c[j] = (col << 2) | (col & 3); } -#if (LCD_DEPTH > 16) && (LCD_DEPTH <= 24) +#if (LCD_DEPTH > 24) + sys->palette[i] = (fb_data) { + c[2], c[1], c[0], 255 + }; +#elif (LCD_DEPTH > 16) && (LCD_DEPTH <= 24) sys->palette[i] = (fb_data) { c[2], c[1], c[0] }; @@ -621,7 +625,12 @@ void sys_copyRect(struct System* sys, uint16_t x, uint16_t y, uint16_t w, uint16 #ifdef HAVE_LCD_COLOR int r, g, b; fb_data pix = rb->lcd_framebuffer[y * LCD_WIDTH + x]; -#if (LCD_DEPTH == 24) +#if (LCD_DEPTH > 24) + r = 0xff - pix.r; + g = 0xff - pix.g; + b = 0xff - pix.b; + rb->lcd_framebuffer[y * LCD_WIDTH + x] = (fb_data) { b, g, r, 255 }; +#elif (LCD_DEPTH == 24) r = 0xff - pix.r; g = 0xff - pix.g; b = 0xff - pix.b; diff --git a/apps/plugins/zxbox/keymaps.h b/apps/plugins/zxbox/keymaps.h index 47ee8ed1e1..d10eeb67e7 100644 --- a/apps/plugins/zxbox/keymaps.h +++ b/apps/plugins/zxbox/keymaps.h @@ -274,6 +274,14 @@ #elif CONFIG_KEYPAD == CREATIVE_ZENXFI2_PAD #define ZX_MENU BUTTON_MENU +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define ZX_MENU BUTTON_POWER +#define ZX_UP BUTTON_UP +#define ZX_DOWN BUTTON_DOWN +#define ZX_LEFT BUTTON_LEFT +#define ZX_RIGHT BUTTON_RIGHT +#define ZX_SELECT BUTTON_SELECT + #else #error Keymap not defined! diff --git a/apps/plugins/zxbox/zxbox_keyb.c b/apps/plugins/zxbox/zxbox_keyb.c index 7fbad173ec..2931c8ea32 100644 --- a/apps/plugins/zxbox/zxbox_keyb.c +++ b/apps/plugins/zxbox/zxbox_keyb.c @@ -270,6 +270,14 @@ #define KBD_UP BUTTON_UP #define KBD_DOWN BUTTON_DOWN +#elif (CONFIG_KEYPAD == AGPTEK_ROCKER_PAD) +#define KBD_SELECT BUTTON_SELECT +#define KBD_ABORT BUTTON_POWER +#define KBD_LEFT BUTTON_LEFT +#define KBD_RIGHT BUTTON_RIGHT +#define KBD_UP BUTTON_UP +#define KBD_DOWN BUTTON_DOWN + #endif #ifdef HAVE_TOUCHSCREEN diff --git a/tools/configure b/tools/configure index 963bb62804..1d93fd025f 100755 --- a/tools/configure +++ b/tools/configure @@ -4206,7 +4206,7 @@ fi output="rockbox.rocker" bootoutput="bootloader.rocker" appextra="recorder:gui:hosted" - plugins="" + plugins="yes" swcodec="yes" # architecture, manufacturer and model for the target-tree build t_cpu="hosted"