From 8d69f78423978e20997b34709d5b6d39896c9237 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Fri, 12 Dec 2003 13:29:11 +0000 Subject: Additional Neo support git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4132 a1c6a512-1295-4272-9138-f99709370657 --- firmware/export/button.h | 48 ++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) (limited to 'firmware/export/button.h') diff --git a/firmware/export/button.h b/firmware/export/button.h index e3c37f9382..d6503d93b7 100644 --- a/firmware/export/button.h +++ b/firmware/export/button.h @@ -30,8 +30,49 @@ void button_init (void); int button_get (bool block); int button_get_w_tmo(int ticks); -/* Shared button codes */ #define BUTTON_NONE 0x0000 + +#ifdef HAVE_NEO_KEYPAD + +#define BUTTON_UP 0x0080 +#define BUTTON_DOWN 0x0010 +#define BUTTON_LEFT 0x0001 +#define BUTTON_RIGHT 0x0002 + +#define BUTTON_SELECT 0x0040 +#define BUTTON_PROGRAM 0x0020 +#define BUTTON_MENU 0x0004 +#define BUTTON_PLAY 0x0008 +#define BUTTON_STOP 0x0100 + +#define BUTTON_IR 0x2000 +#define BUTTON_REPEAT 0x4000 +#define BUTTON_REL 0x8000 + +#define BUTTON_FLAG_MASK 0xF000 +#define BUTTON_MASK 0x0FFF +#define BUTTON_ALL BUTTON_MASK +#define BUTTON_ALL_FLAGS BUTTON_FLAG_MASK + +#define NEO_IR_BUTTON_POWER 0x0001 +#define NEO_IR_BUTTON_SETTING 0x0002 +#define NEO_IR_BUTTON_REWIND 0x0004 +#define NEO_IR_BUTTON_FFORWARD 0x0008 +#define NEO_IR_BUTTON_PLAY 0x0010 +#define NEO_IR_BUTTON_VOLUP 0x0020 +#define NEO_IR_BUTTON_VOLDN 0x0040 +#define NEO_IR_BUTTON_BROWSE 0x0080 +#define NEO_IR_BUTTON_EQ 0x0100 +#define NEO_IR_BUTTON_MUTE 0x0200 +#define NEO_IR_BUTTON_PROGRAM 0x0400 +#define NEO_IR_BUTTON_STOP 0x0800 +#define NEO_IR_BUTTON_NONE 0x0000 + +#define NEO_IR_BUTTON_REPEAT 0x1000 + +#else + +/* Shared button codes */ #define BUTTON_ON 0x0001 #define BUTTON_UP 0x0010 #define BUTTON_DOWN 0x0020 @@ -69,4 +110,7 @@ int button_get_w_tmo(int ticks); #endif /* HAVE_PLAYER_KEYPAD */ -#endif +#endif /* HAVE_NEO_KEYPAD */ + +#endif /* _BUTTON_H_ */ + -- cgit v1.2.3