public void handler() {
            PORT_START(); 	/* IN0 */

            PORT_BIT(0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT | IPF_8WAY | IPF_PLAYER1);
            PORT_BIT(0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT | IPF_8WAY | IPF_PLAYER1);
            PORT_BIT(0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_UP | IPF_8WAY | IPF_PLAYER1);
            PORT_BIT(0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN | IPF_8WAY | IPF_PLAYER1);
            PORT_BIT(0x0010, IP_ACTIVE_LOW, IPT_BUTTON1 | IPF_PLAYER1);
            PORT_BIT(0x0020, IP_ACTIVE_LOW, IPT_BUTTON2 | IPF_PLAYER1);
            PORT_BIT(0x0040, IP_ACTIVE_LOW, IPT_BUTTON3 | IPF_PLAYER1);
            PORT_BIT(0x0080, IP_ACTIVE_LOW, IPT_BUTTON4 | IPF_PLAYER1);
            PORT_BIT(0x0100, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT | IPF_8WAY | IPF_PLAYER2);
            PORT_BIT(0x0200, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT | IPF_8WAY | IPF_PLAYER2);
            PORT_BIT(0x0400, IP_ACTIVE_LOW, IPT_JOYSTICK_UP | IPF_8WAY | IPF_PLAYER2);
            PORT_BIT(0x0800, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN | IPF_8WAY | IPF_PLAYER2);
            PORT_BIT(0x1000, IP_ACTIVE_LOW, IPT_BUTTON1 | IPF_PLAYER2);
            PORT_BIT(0x2000, IP_ACTIVE_LOW, IPT_BUTTON2 | IPF_PLAYER2);
            PORT_BIT(0x4000, IP_ACTIVE_LOW, IPT_BUTTON3 | IPF_PLAYER2);
            PORT_BIT(0x8000, IP_ACTIVE_LOW, IPT_BUTTON4 | IPF_PLAYER2);

            PORT_START(); 	/* IN1 */

            PORT_BIT(0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT | IPF_8WAY | IPF_PLAYER3);
            PORT_BIT(0x0002, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT | IPF_8WAY | IPF_PLAYER3);
            PORT_BIT(0x0004, IP_ACTIVE_LOW, IPT_JOYSTICK_UP | IPF_8WAY | IPF_PLAYER3);
            PORT_BIT(0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN | IPF_8WAY | IPF_PLAYER3);
            PORT_BIT(0x0010, IP_ACTIVE_LOW, IPT_BUTTON1 | IPF_PLAYER3);
            PORT_BIT(0x0020, IP_ACTIVE_LOW, IPT_BUTTON2 | IPF_PLAYER3);
            PORT_BIT(0x0040, IP_ACTIVE_LOW, IPT_BUTTON3 | IPF_PLAYER3);
            PORT_BIT(0x0080, IP_ACTIVE_LOW, IPT_BUTTON4 | IPF_PLAYER3);
            PORT_BIT(0x0100, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT | IPF_8WAY | IPF_PLAYER4);
            PORT_BIT(0x0200, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT | IPF_8WAY | IPF_PLAYER4);
            PORT_BIT(0x0400, IP_ACTIVE_LOW, IPT_JOYSTICK_UP | IPF_8WAY | IPF_PLAYER4);
            PORT_BIT(0x0800, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN | IPF_8WAY | IPF_PLAYER4);
            PORT_BIT(0x1000, IP_ACTIVE_LOW, IPT_BUTTON1 | IPF_PLAYER4);
            PORT_BIT(0x2000, IP_ACTIVE_LOW, IPT_BUTTON2 | IPF_PLAYER4);
            PORT_BIT(0x4000, IP_ACTIVE_LOW, IPT_BUTTON3 | IPF_PLAYER4);
            PORT_BIT(0x8000, IP_ACTIVE_LOW, IPT_BUTTON4 | IPF_PLAYER4);

            PORT_START();
            PORT_DIPNAME(0x000f, 0x000f, DEF_STR("Coin_A"));
            PORT_DIPSETTING(0x0002, DEF_STR("4C_1C"));
            PORT_DIPSETTING(0x0005, DEF_STR("3C_1C"));
            PORT_DIPSETTING(0x0008, DEF_STR("2C_1C"));
            PORT_DIPSETTING(0x0004, DEF_STR("3C_2C"));
            PORT_DIPSETTING(0x0001, DEF_STR("4C_3C"));
            PORT_DIPSETTING(0x000f, DEF_STR("1C_1C"));
            PORT_DIPSETTING(0x0003, DEF_STR("3C_4C"));
            PORT_DIPSETTING(0x0007, DEF_STR("2C_3C"));
            PORT_DIPSETTING(0x000e, DEF_STR("1C_2C"));
            PORT_DIPSETTING(0x0006, DEF_STR("2C_5C"));
            PORT_DIPSETTING(0x000d, DEF_STR("1C_3C"));
            PORT_DIPSETTING(0x000c, DEF_STR("1C_4C"));
            PORT_DIPSETTING(0x000b, DEF_STR("1C_5C"));
            PORT_DIPSETTING(0x000a, DEF_STR("1C_6C"));
            PORT_DIPSETTING(0x0009, DEF_STR("1C_7C"));
            PORT_DIPSETTING(0x0000, DEF_STR("Free_Play"));
            PORT_DIPNAME(0x00f0, 0x00f0, DEF_STR("Coin_B"));
            PORT_DIPSETTING(0x0020, DEF_STR("4C_1C"));
            PORT_DIPSETTING(0x0050, DEF_STR("3C_1C"));
            PORT_DIPSETTING(0x0080, DEF_STR("2C_1C"));
            PORT_DIPSETTING(0x0040, DEF_STR("3C_2C"));
            PORT_DIPSETTING(0x0010, DEF_STR("4C_3C"));
            PORT_DIPSETTING(0x00f0, DEF_STR("1C_1C"));
            PORT_DIPSETTING(0x0030, DEF_STR("3C_4C"));
            PORT_DIPSETTING(0x0070, DEF_STR("2C_3C"));
            PORT_DIPSETTING(0x00e0, DEF_STR("1C_2C"));
            PORT_DIPSETTING(0x0060, DEF_STR("2C_5C"));
            PORT_DIPSETTING(0x00d0, DEF_STR("1C_3C"));
            PORT_DIPSETTING(0x00c0, DEF_STR("1C_4C"));
            PORT_DIPSETTING(0x00b0, DEF_STR("1C_5C"));
            PORT_DIPSETTING(0x00a0, DEF_STR("1C_6C"));
            PORT_DIPSETTING(0x0090, DEF_STR("1C_7C"));
            //	PORT_DIPSETTING(      0x0000, "Invalid" );
            PORT_DIPNAME(0x0300, 0x0100, "Players/Controllers");
            PORT_DIPSETTING(0x0300, "4/1");
            PORT_DIPSETTING(0x0200, "4/2");
            PORT_DIPSETTING(0x0100, "4/4");
            PORT_DIPSETTING(0x0000, "3/3");
            PORT_DIPNAME(0x0400, 0x0000, "Sound");
            PORT_DIPSETTING(0x0400, "Mono");
            PORT_DIPSETTING(0x0000, "Stereo");
            PORT_DIPNAME(0x1800, 0x1800, "Initial/Maximum Credit");
            PORT_DIPSETTING(0x1800, "2/3");
            PORT_DIPSETTING(0x1000, "2/4");
            PORT_DIPSETTING(0x0800, "2/5");
            PORT_DIPSETTING(0x0000, "3/5");
            PORT_DIPNAME(0x6000, 0x4000, DEF_STR("Difficulty"));
            PORT_DIPSETTING(0x6000, "Easy");
            PORT_DIPSETTING(0x4000, "Normal");
            PORT_DIPSETTING(0x2000, "Hard");
            PORT_DIPSETTING(0x0000, "Hardest");
            PORT_DIPNAME(0x8000, 0x0000, DEF_STR("Demo_Sounds"));
            PORT_DIPSETTING(0x8000, DEF_STR("Off"));
            PORT_DIPSETTING(0x0000, DEF_STR("On"));

            PORT_START();
            PORT_BIT(0x0001, IP_ACTIVE_LOW, IPT_COIN1);
            PORT_BIT(0x0002, IP_ACTIVE_LOW, IPT_COIN2);
            PORT_BIT(0x0004, IP_ACTIVE_LOW, IPT_COIN3);
            PORT_BIT(0x0008, IP_ACTIVE_LOW, IPT_COIN4);
            PORT_BIT(0x0010, IP_ACTIVE_LOW, IPT_SERVICE1);/* service coin */

            PORT_BIT(0x0020, IP_ACTIVE_LOW, IPT_UNKNOWN);
            PORT_BIT(0x0040, IP_ACTIVE_LOW, IPT_UNKNOWN);
            PORT_BIT(0x0080, IP_ACTIVE_LOW, IPT_UNKNOWN);
            PORT_BIT(0x0100, IP_ACTIVE_LOW, IPT_START1);
            PORT_BIT(0x0200, IP_ACTIVE_LOW, IPT_START2);
            PORT_BITX(0x0400, IP_ACTIVE_LOW, IPT_SERVICE, DEF_STR("Service_Mode"), KEYCODE_F2, IP_JOY_NONE);
            PORT_DIPNAME(0x8000, 0x0000, "Freeze");/* ?? VBLANK ?? */

            PORT_DIPSETTING(0x0000, DEF_STR("Off"));
            PORT_DIPSETTING(0x8000, DEF_STR("On"));
            PORT_DIPNAME(0x1000, 0x1000, DEF_STR("Flip_Screen"));
            PORT_DIPSETTING(0x1000, DEF_STR("Off"));
            PORT_DIPSETTING(0x0000, DEF_STR("On"));
            PORT_DIPNAME(0x2000, 0x2000, DEF_STR("Unknown"));
            PORT_DIPSETTING(0x2000, DEF_STR("Off"));
            PORT_DIPSETTING(0x0000, DEF_STR("On"));
            //	PORT_SERVICE( 0x4000, IP_ACTIVE_LOW );
            PORT_BIT(0x4000, IP_ACTIVE_LOW, IPT_SERVICE);
            PORT_DIPNAME(0x8000, 0x8000, DEF_STR("Unknown"));
            PORT_DIPSETTING(0x8000, DEF_STR("Off"));
            PORT_DIPSETTING(0x0000, DEF_STR("On"));
            INPUT_PORTS_END();
        }