BTN_VOL_UP = 23, BTN_VOL_DOWN = 22, BTN_PUSH = 27 };
static const char * const in_gp2x_prefix = IN_PREFIX;
-static const char * const in_gp2x_keys[IN_GP2X_NBUTTONS] = {
+static const char *in_gp2x_keys[IN_GP2X_NBUTTONS] = {
[0 ... IN_GP2X_NBUTTONS-1] = NULL,
[BTN_UP] = "UP", [BTN_LEFT] = "LEFT", [BTN_DOWN] = "DOWN", [BTN_RIGHT] = "RIGHT",
[BTN_START] = "START", [BTN_SELECT] = "SELECT", [BTN_L] = "L", [BTN_R] = "R",
static int in_gp2x_get_wiz_bits(void)
{
- int value = 0;
- read(gpiodev, &value, 4);
+ int r, value = 0;
+ r = read(gpiodev, &value, 4);
if (value & 0x02)
value |= 0x05;
if (value & 0x08)
}
#ifdef FAKE_IN_GP2X
+volatile unsigned short *gp2x_memregs;
+gp2x_soc_t soc_detect(void) { return -1; }
+
static int in_gp2x_get_fake_bits(void)
{
extern int current_keys;
void in_gp2x_init(void *vdrv)
{
in_drv_t *drv = vdrv;
+ gp2x_soc_t soc;
+ soc = soc_detect();
+ if (soc == SOCID_POLLUX)
+ in_gp2x_keys[BTN_START] = "MENU";
+
in_gp2x_combo_keys = in_gp2x_combo_acts = 0;
drv->prefix = in_gp2x_prefix;