src/mess/drivers/exidy.c
| r2236 | r2237 | |
| 515 | 515 | - tied high, allowing PARIN and PAROUT bios routines to run */ |
| 516 | 516 | |
| 517 | 517 | UINT8 data=0xc0; |
| 518 | char port[7]; |
| 518 | 519 | |
| 519 | 520 | /* bit 5 - vsync (inverted) */ |
| 520 | 521 | data |= (((~readinputportbytag("VS")) & 0x01)<<5); |
| 521 | 522 | |
| 522 | 523 | /* bits 4..0 - keyboard data */ |
| 523 | | data |= (readinputport(exidy_keyboard_line+1) & 0x01f); |
| 524 | sprintf(port, "LINE%d", exidy_keyboard_line); |
| 525 | data |= (readinputportbytag(port) & 0x01f); |
| 524 | 526 | |
| 525 | 527 | return data; |
| 526 | 528 | } |
| r2236 | r2237 | |
| 586 | 588 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_VBLANK) |
| 587 | 589 | |
| 588 | 590 | /* line 0 */ |
| 589 | | PORT_START |
| 591 | PORT_START_TAG("LINE0") |
| 590 | 592 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Shift") PORT_CODE(KEYCODE_LSHIFT) PORT_CHAR(UCHAR_SHIFT_1) |
| 591 | 593 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Shift") PORT_CODE(KEYCODE_RSHIFT) PORT_CHAR(UCHAR_SHIFT_1) |
| 592 | 594 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Shift Lock") PORT_CODE(KEYCODE_CAPSLOCK) PORT_TOGGLE |
| r2236 | r2237 | |
| 595 | 597 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Graphic") PORT_CODE(KEYCODE_F1) |
| 596 | 598 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Stop") PORT_CODE(KEYCODE_ESC) PORT_CHAR(27) |
| 597 | 599 | /* line 1 */ |
| 598 | | PORT_START |
| 600 | PORT_START_TAG("LINE1") |
| 599 | 601 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("(Sel)") PORT_CODE(KEYCODE_F2) PORT_CHAR(27) |
| 600 | 602 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Skip") PORT_CODE(KEYCODE_TAB) PORT_CHAR(9) |
| 601 | 603 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Space") PORT_CODE(KEYCODE_SPACE) PORT_CHAR(' ') |
| 602 | 604 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Repeat") PORT_CODE(KEYCODE_F4) |
| 603 | 605 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Clear") PORT_CODE(KEYCODE_F5) PORT_CHAR(12) |
| 604 | 606 | /* line 2 */ |
| 605 | | PORT_START |
| 607 | PORT_START_TAG("LINE2") |
| 606 | 608 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("1") PORT_CODE(KEYCODE_1) PORT_CHAR('1') PORT_CHAR('!') |
| 607 | 609 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Q") PORT_CODE(KEYCODE_Q) PORT_CHAR('Q') |
| 608 | 610 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A") PORT_CODE(KEYCODE_A) PORT_CHAR('A') |
| 609 | 611 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Z") PORT_CODE(KEYCODE_Z) PORT_CHAR('Z') |
| 610 | 612 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("X") PORT_CODE(KEYCODE_X) PORT_CHAR('X') |
| 611 | 613 | /* line 3 */ |
| 612 | | PORT_START |
| 614 | PORT_START_TAG("LINE3") |
| 613 | 615 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("2") PORT_CODE(KEYCODE_2) PORT_CHAR('2') PORT_CHAR('\"') |
| 614 | 616 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("W") PORT_CODE(KEYCODE_W) PORT_CHAR('W') |
| 615 | 617 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("S") PORT_CODE(KEYCODE_S) PORT_CHAR('S') |
| 616 | 618 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("D") PORT_CODE(KEYCODE_D) PORT_CHAR('D') |
| 617 | 619 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("C") PORT_CODE(KEYCODE_C) PORT_CHAR('C') |
| 618 | 620 | /* line 4 */ |
| 619 | | PORT_START |
| 621 | PORT_START_TAG("LINE4") |
| 620 | 622 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("3") PORT_CODE(KEYCODE_3) PORT_CHAR('3') PORT_CHAR('#') |
| 621 | 623 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("4") PORT_CODE(KEYCODE_4) PORT_CHAR('4') PORT_CHAR('$') |
| 622 | 624 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("E") PORT_CODE(KEYCODE_E) PORT_CHAR('E') |
| 623 | 625 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("R") PORT_CODE(KEYCODE_R) PORT_CHAR('R') |
| 624 | 626 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F") PORT_CODE(KEYCODE_F) PORT_CHAR('F') |
| 625 | 627 | /* line 5 */ |
| 626 | | PORT_START |
| 628 | PORT_START_TAG("LINE5") |
| 627 | 629 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("5") PORT_CODE(KEYCODE_5) PORT_CHAR('5') PORT_CHAR('%') |
| 628 | 630 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("T") PORT_CODE(KEYCODE_T) PORT_CHAR('T') |
| 629 | 631 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G") PORT_CODE(KEYCODE_G) PORT_CHAR('G') |
| 630 | 632 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("V") PORT_CODE(KEYCODE_V) PORT_CHAR('V') |
| 631 | 633 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B") PORT_CODE(KEYCODE_B) PORT_CHAR('B') |
| 632 | 634 | /* line 6 */ |
| 633 | | PORT_START |
| 635 | PORT_START_TAG("LINE6") |
| 634 | 636 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6") PORT_CODE(KEYCODE_6) PORT_CHAR('6') PORT_CHAR('&') |
| 635 | 637 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Y") PORT_CODE(KEYCODE_Y) PORT_CHAR('Y') |
| 636 | 638 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("H") PORT_CODE(KEYCODE_H) PORT_CHAR('H') |
| 637 | 639 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("N") PORT_CODE(KEYCODE_N) PORT_CHAR('N') |
| 638 | 640 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("M") PORT_CODE(KEYCODE_M) PORT_CHAR('M') |
| 639 | 641 | /* line 7 */ |
| 640 | | PORT_START |
| 642 | PORT_START_TAG("LINE7") |
| 641 | 643 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7") PORT_CODE(KEYCODE_7) PORT_CHAR('7') PORT_CHAR('\'') |
| 642 | 644 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("U") PORT_CODE(KEYCODE_U) PORT_CHAR('U') |
| 643 | 645 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("J") PORT_CODE(KEYCODE_J) PORT_CHAR('J') |
| 644 | 646 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("I") PORT_CODE(KEYCODE_I) PORT_CHAR('I') |
| 645 | 647 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("K") PORT_CODE(KEYCODE_K) PORT_CHAR('K') |
| 646 | 648 | /* line 8 */ |
| 647 | | PORT_START |
| 649 | PORT_START_TAG("LINE8") |
| 648 | 650 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("8") PORT_CODE(KEYCODE_8) PORT_CHAR('8') PORT_CHAR('(') |
| 649 | 651 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9") PORT_CODE(KEYCODE_9) PORT_CHAR('9') PORT_CHAR(')') |
| 650 | 652 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("O") PORT_CODE(KEYCODE_O) PORT_CHAR('O') |
| 651 | 653 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("L") PORT_CODE(KEYCODE_L) PORT_CHAR('L') |
| 652 | 654 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(",") PORT_CODE(KEYCODE_COMMA) PORT_CHAR(',') PORT_CHAR('<') |
| 653 | 655 | /* line 9 */ |
| 654 | | PORT_START |
| 656 | PORT_START_TAG("LINE9") |
| 655 | 657 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("0") PORT_CODE(KEYCODE_0) PORT_CHAR('0') |
| 656 | 658 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("P") PORT_CODE(KEYCODE_P) PORT_CHAR('P') |
| 657 | 659 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("; +") PORT_CODE(KEYCODE_COLON) PORT_CHAR(';') PORT_CHAR('+') |
| 658 | 660 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(". >") PORT_CODE(KEYCODE_STOP) PORT_CHAR('.') PORT_CHAR('>') |
| 659 | 661 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("/ ?") PORT_CODE(KEYCODE_SLASH) PORT_CHAR('/') PORT_CHAR('?') |
| 660 | 662 | /* line 10 */ |
| 661 | | PORT_START |
| 663 | PORT_START_TAG("LINE10") |
| 662 | 664 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(": *") PORT_CODE(KEYCODE_QUOTE) PORT_CHAR(':') PORT_CHAR('*') |
| 663 | 665 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("[ {") PORT_CODE(KEYCODE_OPENBRACE) PORT_CHAR('[') PORT_CHAR('{') |
| 664 | 666 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("] }") PORT_CODE(KEYCODE_CLOSEBRACE) PORT_CHAR(']') PORT_CHAR('}') |
| 665 | 667 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("@ `") PORT_CODE(KEYCODE_F7) PORT_CHAR('@') PORT_CHAR('`') |
| 666 | 668 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("\\ |") PORT_CODE(KEYCODE_BACKSLASH) PORT_CHAR('\\') PORT_CHAR('|') |
| 667 | 669 | /* line 11 */ |
| 668 | | PORT_START |
| 670 | PORT_START_TAG("LINE11") |
| 669 | 671 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("- =") PORT_CODE(KEYCODE_MINUS) PORT_CHAR('-') PORT_CHAR('=') |
| 670 | 672 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("^ ~") PORT_CODE(KEYCODE_EQUALS) PORT_CHAR('^') PORT_CHAR('~') |
| 671 | 673 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("LINE FEED") PORT_CODE(KEYCODE_F6) PORT_CHAR(10) |
| 672 | 674 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("RETURN") PORT_CODE(KEYCODE_ENTER) PORT_CODE(KEYCODE_ENTER_PAD) PORT_CHAR(13) |
| 673 | 675 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("_ Rub") PORT_CODE(KEYCODE_BACKSPACE) PORT_CHAR('_') PORT_CHAR(8) |
| 674 | 676 | /* line 12 */ |
| 675 | | PORT_START |
| 677 | PORT_START_TAG("LINE12") |
| 676 | 678 | PORT_BIT (0x10, 0x10, IPT_UNUSED) |
| 677 | 679 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("- (PAD)") PORT_CODE(KEYCODE_MINUS_PAD) PORT_CHAR(UCHAR_MAMEKEY(MINUS_PAD)) |
| 678 | 680 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("/ (PAD)") PORT_CODE(KEYCODE_SLASH_PAD) |
| 679 | 681 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("* (PAD)") PORT_CODE(KEYCODE_ASTERISK) |
| 680 | 682 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("+ (PAD)") PORT_CODE(KEYCODE_PLUS_PAD) PORT_CHAR(UCHAR_MAMEKEY(PLUS_PAD)) |
| 681 | 683 | /* line 13 */ |
| 682 | | PORT_START |
| 684 | PORT_START_TAG("LINE13") |
| 683 | 685 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7 (PAD)") PORT_CODE(KEYCODE_7_PAD) PORT_CHAR(UCHAR_MAMEKEY(7_PAD)) |
| 684 | 686 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("8 (PAD)") PORT_CODE(KEYCODE_8_PAD) PORT_CODE(KEYCODE_UP) PORT_CHAR(UCHAR_MAMEKEY(UP)) PORT_CHAR(UCHAR_MAMEKEY(8_PAD)) |
| 685 | 687 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("4 (PAD)") PORT_CODE(KEYCODE_4_PAD) PORT_CODE(KEYCODE_LEFT) PORT_CHAR(UCHAR_MAMEKEY(LEFT)) PORT_CHAR(UCHAR_MAMEKEY(4_PAD)) |
| 686 | 688 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("1 (PAD)") PORT_CODE(KEYCODE_1_PAD) PORT_CHAR(UCHAR_MAMEKEY(1_PAD)) |
| 687 | 689 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("0 (PAD)") PORT_CODE(KEYCODE_0_PAD) PORT_CHAR(UCHAR_MAMEKEY(0_PAD)) |
| 688 | 690 | /* line 14 */ |
| 689 | | PORT_START |
| 691 | PORT_START_TAG("LINE14") |
| 690 | 692 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9 (PAD)") PORT_CODE(KEYCODE_9_PAD) PORT_CHAR(UCHAR_MAMEKEY(9_PAD)) |
| 691 | 693 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6 (PAD)") PORT_CODE(KEYCODE_6_PAD) PORT_CODE(KEYCODE_RIGHT) PORT_CHAR(UCHAR_MAMEKEY(RIGHT)) PORT_CHAR(UCHAR_MAMEKEY(6_PAD)) |
| 692 | 694 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("5 (PAD)") PORT_CODE(KEYCODE_5_PAD) PORT_CHAR(UCHAR_MAMEKEY(5_PAD)) |
| 693 | 695 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("2 (PAD)") PORT_CODE(KEYCODE_2_PAD) PORT_CODE(KEYCODE_DOWN) PORT_CHAR(UCHAR_MAMEKEY(DOWN)) PORT_CHAR(UCHAR_MAMEKEY(2_PAD)) |
| 694 | 696 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(". (PAD)") PORT_CODE(KEYCODE_DEL_PAD) PORT_CHAR(UCHAR_MAMEKEY(DEL_PAD)) |
| 695 | 697 | /* line 15 */ |
| 696 | | PORT_START |
| 698 | PORT_START_TAG("LINE15") |
| 697 | 699 | PORT_BIT(0x10, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("3 (PAD)") PORT_CODE(KEYCODE_3_PAD) PORT_CHAR(UCHAR_MAMEKEY(3_PAD)) |
| 698 | 700 | PORT_BIT(0x08, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("= (PAD)") PORT_CODE(KEYCODE_NUMLOCK) |
| 699 | 701 | PORT_BIT (0x04, 0x04, IPT_UNUSED) |
src/mess/drivers/bw2.c
| r2236 | r2237 | |
| 246 | 246 | */ |
| 247 | 247 | |
| 248 | 248 | UINT8 row; |
| 249 | char port[5]; |
| 249 | 250 | |
| 250 | 251 | row = ppi8255_peek(0, 0) & 0x0f; |
| 251 | 252 | if (row <= 9) |
| 252 | 253 | { |
| 253 | | return readinputport(row); |
| 254 | sprintf(port, "ROW%d", row); |
| 255 | return readinputportbytag(port); |
| 254 | 256 | } |
| 255 | 257 | |
| 256 | 258 | return 0xff; |
| r2236 | r2237 | |
| 440 | 442 | +-----+-----+-----+-----+-----+-----+-----+-----+ |
| 441 | 443 | Y4 | ESC | | | B | G | T | 6 & | F5 | |
| 442 | 444 | +-----+-----+-----+-----+-----+-----+-----+-----+ |
| 443 | | Y3 | TAB | : * |ENTER| N | H | Y | 7 ´ | F6 | |
| 445 | Y3 | TAB | : * |ENTER| N | H | Y | 7 ' | F6 | |
| 444 | 446 | +-----+-----+-----+-----+-----+-----+-----+-----+ |
| 445 | 447 | Y2 |DOWN | ^ ~ | [ { | M | J | U | 8 ( | F7 | |
| 446 | 448 | +-----+-----+-----+-----+-----+-----+-----+-----+ |
| r2236 | r2237 | |
| 451 | 453 | */ |
| 452 | 454 | |
| 453 | 455 | static INPUT_PORTS_START( bw2 ) |
| 454 | | PORT_START /* 0 */ |
| 456 | PORT_START_TAG("ROW0") /* 0 */ |
| 455 | 457 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("LEFT") PORT_CODE(KEYCODE_LEFT) |
| 456 | 458 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("BS") PORT_CODE(KEYCODE_BACKSPACE) |
| 457 | 459 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("/ ?") PORT_CODE(KEYCODE_SLASH) |
| r2236 | r2237 | |
| 460 | 462 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("o O") PORT_CODE(KEYCODE_O) |
| 461 | 463 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("0 _") PORT_CODE(KEYCODE_0) |
| 462 | 464 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("DEL") PORT_CODE(KEYCODE_DEL) |
| 463 | | PORT_START /* 1 */ |
| 465 | PORT_START_TAG("ROW1") /* 1 */ |
| 464 | 466 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("RIGHT") PORT_CODE(KEYCODE_RIGHT) |
| 465 | 467 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("; +") PORT_CODE(KEYCODE_COLON) |
| 466 | 468 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("] }") PORT_CODE(KEYCODE_CLOSEBRACE) |
| r2236 | r2237 | |
| 469 | 471 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("i I") PORT_CODE(KEYCODE_I) |
| 470 | 472 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9 )") PORT_CODE(KEYCODE_9) |
| 471 | 473 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F8") PORT_CODE(KEYCODE_F8) |
| 472 | | PORT_START /* 2 */ |
| 474 | PORT_START_TAG("ROW2") /* 2 */ |
| 473 | 475 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("DOWN") PORT_CODE(KEYCODE_DOWN) |
| 474 | 476 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("^ ~") PORT_CODE(KEYCODE_TILDE) |
| 475 | 477 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("[ {") PORT_CODE(KEYCODE_OPENBRACE) |
| r2236 | r2237 | |
| 478 | 480 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("u U") PORT_CODE(KEYCODE_U) |
| 479 | 481 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("8 (") PORT_CODE(KEYCODE_8) |
| 480 | 482 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F7") PORT_CODE(KEYCODE_F7) |
| 481 | | PORT_START /* 3 */ |
| 483 | PORT_START_TAG("ROW3") /* 3 */ |
| 482 | 484 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("TAB") PORT_CODE(KEYCODE_TAB) |
| 483 | 485 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(": *") PORT_CODE(KEYCODE_EQUALS) |
| 484 | 486 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("ENTER") PORT_CODE(KEYCODE_ENTER) |
| r2236 | r2237 | |
| 487 | 489 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("y Y") PORT_CODE(KEYCODE_Y) |
| 488 | 490 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7 '") PORT_CODE(KEYCODE_7) |
| 489 | 491 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F6") PORT_CODE(KEYCODE_F6) |
| 490 | | PORT_START /* 4 */ |
| 492 | PORT_START_TAG("ROW4") /* 4 */ |
| 491 | 493 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("ESC") PORT_CODE(KEYCODE_ESC) |
| 492 | 494 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_UNUSED) |
| 493 | 495 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_UNUSED) |
| r2236 | r2237 | |
| 496 | 498 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("t T") PORT_CODE(KEYCODE_T) |
| 497 | 499 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6 &") PORT_CODE(KEYCODE_6) |
| 498 | 500 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F5") PORT_CODE(KEYCODE_F5) |
| 499 | | PORT_START /* 5 */ |
| 501 | PORT_START_TAG("ROW5") /* 5 */ |
| 500 | 502 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("1 !") PORT_CODE(KEYCODE_1) |
| 501 | 503 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_UNUSED) |
| 502 | 504 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_UNUSED) |
| r2236 | r2237 | |
| 505 | 507 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("r R") PORT_CODE(KEYCODE_R) |
| 506 | 508 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("5 %") PORT_CODE(KEYCODE_5) |
| 507 | 509 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F4") PORT_CODE(KEYCODE_F4) |
| 508 | | PORT_START /* 6 */ |
| 510 | PORT_START_TAG("ROW6") /* 6 */ |
| 509 | 511 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("@ `") PORT_CODE(KEYCODE_QUOTE) |
| 510 | 512 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("p P") PORT_CODE(KEYCODE_P) |
| 511 | 513 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("UP") PORT_CODE(KEYCODE_UP) |
| r2236 | r2237 | |
| 514 | 516 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("e E") PORT_CODE(KEYCODE_E) |
| 515 | 517 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("4 $") PORT_CODE(KEYCODE_4) |
| 516 | 518 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F3") PORT_CODE(KEYCODE_F3) |
| 517 | | PORT_START /* 7 */ |
| 519 | PORT_START_TAG("ROW7") /* 7 */ |
| 518 | 520 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("CTRL") PORT_CODE(KEYCODE_LCONTROL) |
| 519 | 521 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("- =") PORT_CODE(KEYCODE_MINUS) |
| 520 | 522 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("\\ |") PORT_CODE(KEYCODE_BACKSLASH) |
| r2236 | r2237 | |
| 523 | 525 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("w W") PORT_CODE(KEYCODE_W) |
| 524 | 526 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("3 #") PORT_CODE(KEYCODE_3) |
| 525 | 527 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F2") PORT_CODE(KEYCODE_F2) |
| 526 | | PORT_START /* 8 */ |
| 528 | PORT_START_TAG("ROW8") /* 8 */ |
| 527 | 529 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("SHIFT") PORT_CODE(KEYCODE_LSHIFT) |
| 528 | 530 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_UNUSED) |
| 529 | 531 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("SPACE") PORT_CODE(KEYCODE_SPACE) |
| r2236 | r2237 | |
| 532 | 534 | PORT_BIT (0x20, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("q Q") PORT_CODE(KEYCODE_Q) |
| 533 | 535 | PORT_BIT (0x40, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("2 \"") PORT_CODE(KEYCODE_2) |
| 534 | 536 | PORT_BIT (0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F1") PORT_CODE(KEYCODE_F1) |
| 535 | | PORT_START /* 9 */ |
| 537 | PORT_START_TAG("ROW9") /* 9 */ |
| 536 | 538 | PORT_BIT (0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("CAPS") PORT_CODE(KEYCODE_CAPSLOCK) |
| 537 | 539 | PORT_BIT (0x02, IP_ACTIVE_LOW, IPT_UNUSED) |
| 538 | 540 | PORT_BIT (0x04, IP_ACTIVE_LOW, IPT_UNUSED) |
src/mess/drivers/enterp.c
| r2236 | r2237 | |
| 126 | 126 | { |
| 127 | 127 | case 0x015: |
| 128 | 128 | { |
| 129 | | /* read keyboard line */ |
| 130 | | Dave_setreg(machine, 0x015, |
| 131 | | readinputport(Enterprise_KeyboardLine)); |
| 129 | char port[6]; |
| 130 | |
| 131 | /* read keyboard line */ |
| 132 | sprintf(port, "LINE%d", Enterprise_KeyboardLine); |
| 133 | Dave_setreg(machine, 0x015, readinputportbytag(port)); |
| 132 | 134 | } |
| 133 | 135 | break; |
| 134 | 136 | |
| 135 | | case 0x016: |
| 137 | case 0x016: |
| 138 | { |
| 139 | int ExternalJoystickInputs; |
| 140 | int ExternalJoystickPortInput = readinputportbytag("JOY1"); |
| 141 | |
| 142 | if (Enterprise_KeyboardLine<=4) |
| 136 | 143 | { |
| 137 | | int ExternalJoystickInputs; |
| 138 | | int ExternalJoystickPortInput = readinputport(10); |
| 144 | ExternalJoystickInputs = ExternalJoystickPortInput>>(4-Enterprise_KeyboardLine); |
| 145 | } |
| 146 | else |
| 147 | { |
| 148 | ExternalJoystickInputs = 1; |
| 149 | } |
| 139 | 150 | |
| 140 | | if (Enterprise_KeyboardLine<=4) |
| 141 | | { |
| 142 | | ExternalJoystickInputs = ExternalJoystickPortInput>>(4-Enterprise_KeyboardLine); |
| 143 | | } |
| 144 | | else |
| 145 | | { |
| 146 | | ExternalJoystickInputs = 1; |
| 147 | | } |
| 151 | Dave_setreg(machine, 0x016, (0x0fe | (ExternalJoystickInputs & 0x01))); |
| 152 | } |
| 153 | break; |
| 148 | 154 | |
| 149 | | Dave_setreg(machine, 0x016, (0x0fe | (ExternalJoystickInputs & 0x01))); |
| 150 | | } |
| 151 | | break; |
| 152 | | |
| 153 | 155 | default: |
| 154 | 156 | break; |
| 155 | 157 | } |
| r2236 | r2237 | |
| 403 | 405 | |
| 404 | 406 | static INPUT_PORTS_START( ep128 ) |
| 405 | 407 | /* keyboard line 0 */ |
| 406 | | PORT_START |
| 408 | PORT_START_TAG("LINE0") |
| 407 | 409 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n") PORT_CODE(KEYCODE_N) |
| 408 | 410 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("\\") PORT_CODE(KEYCODE_SLASH) |
| 409 | 411 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("b") PORT_CODE(KEYCODE_B) |
| r2236 | r2237 | |
| 414 | 416 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("SHIFT") PORT_CODE(KEYCODE_LSHIFT) |
| 415 | 417 | |
| 416 | 418 | /* keyboard line 1 */ |
| 417 | | PORT_START |
| 419 | PORT_START_TAG("LINE1") |
| 418 | 420 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("h") PORT_CODE(KEYCODE_H) |
| 419 | 421 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 420 | 422 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("g") PORT_CODE(KEYCODE_G) |
| r2236 | r2237 | |
| 425 | 427 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("CTRL") PORT_CODE(KEYCODE_LCONTROL) |
| 426 | 428 | |
| 427 | 429 | /* keyboard line 2 */ |
| 428 | | PORT_START |
| 430 | PORT_START_TAG("LINE2") |
| 429 | 431 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("u") PORT_CODE(KEYCODE_U) |
| 430 | 432 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("q") PORT_CODE(KEYCODE_Q) |
| 431 | 433 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("y") PORT_CODE(KEYCODE_Y) |
| r2236 | r2237 | |
| 436 | 438 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("TAB") PORT_CODE(KEYCODE_TAB) |
| 437 | 439 | |
| 438 | 440 | /* keyboard line 3 */ |
| 439 | | PORT_START |
| 441 | PORT_START_TAG("LINE3") |
| 440 | 442 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7") PORT_CODE(KEYCODE_7) |
| 441 | 443 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("1") PORT_CODE(KEYCODE_1) |
| 442 | 444 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6") PORT_CODE(KEYCODE_6) |
| r2236 | r2237 | |
| 447 | 449 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 448 | 450 | |
| 449 | 451 | /* keyboard line 4 */ |
| 450 | | PORT_START |
| 452 | PORT_START_TAG("LINE4") |
| 451 | 453 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("f4") PORT_CODE(KEYCODE_F4) |
| 452 | 454 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("f8") PORT_CODE(KEYCODE_F8) |
| 453 | 455 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("f3") PORT_CODE(KEYCODE_F3) |
| r2236 | r2237 | |
| 458 | 460 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("f1") PORT_CODE(KEYCODE_F1) |
| 459 | 461 | |
| 460 | 462 | /* keyboard line 5 */ |
| 461 | | PORT_START |
| 463 | PORT_START_TAG("LINE5") |
| 462 | 464 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("8") PORT_CODE(KEYCODE_8) |
| 463 | 465 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 464 | 466 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9") PORT_CODE(KEYCODE_9) |
| r2236 | r2237 | |
| 469 | 471 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 470 | 472 | |
| 471 | 473 | /* keyboard line 6 */ |
| 472 | | PORT_START |
| 474 | PORT_START_TAG("LINE6") |
| 473 | 475 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("j") PORT_CODE(KEYCODE_J) |
| 474 | 476 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 475 | 477 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("k") PORT_CODE(KEYCODE_K) |
| r2236 | r2237 | |
| 480 | 482 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 481 | 483 | |
| 482 | 484 | /* keyboard line 7 */ |
| 483 | | PORT_START |
| 485 | PORT_START_TAG("LINE7") |
| 484 | 486 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("STOP") PORT_CODE(KEYCODE_END) |
| 485 | 487 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("DOWN") PORT_CODE(KEYCODE_DOWN) PORT_CODE(JOYCODE_Y_DOWN_SWITCH) |
| 486 | 488 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("RIGHT") PORT_CODE(KEYCODE_RIGHT) PORT_CODE(JOYCODE_X_RIGHT_SWITCH) |
| r2236 | r2237 | |
| 492 | 494 | |
| 493 | 495 | |
| 494 | 496 | /* keyboard line 8 */ |
| 495 | | PORT_START |
| 497 | PORT_START_TAG("LINE8") |
| 496 | 498 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("m") PORT_CODE(KEYCODE_M) |
| 497 | 499 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("ERASE") PORT_CODE(KEYCODE_DEL) |
| 498 | 500 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(",") PORT_CODE(KEYCODE_COMMA) |
| r2236 | r2237 | |
| 504 | 506 | |
| 505 | 507 | |
| 506 | 508 | /* keyboard line 9 */ |
| 507 | | PORT_START |
| 509 | PORT_START_TAG("LINE9") |
| 508 | 510 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("i") PORT_CODE(KEYCODE_I) |
| 509 | 511 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 510 | 512 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("o") PORT_CODE(KEYCODE_O) |
| r2236 | r2237 | |
| 515 | 517 | PORT_BIT(0x80, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("n/c") |
| 516 | 518 | |
| 517 | 519 | /* external joystick 1 */ |
| 518 | | PORT_START |
| 520 | PORT_START_TAG("JOY1") |
| 519 | 521 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("EXTERNAL JOYSTICK 1 RIGHT") PORT_CODE(KEYCODE_RIGHT) PORT_CODE(JOYCODE_X_RIGHT_SWITCH) |
| 520 | 522 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("EXTERNAL JOYSTICK 1 LEFT") PORT_CODE(KEYCODE_LEFT) PORT_CODE(JOYCODE_X_LEFT_SWITCH) |
| 521 | 523 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("EXTERNAL JOYSTICK 1 DOWN") PORT_CODE(KEYCODE_DOWN) PORT_CODE(JOYCODE_Y_DOWN_SWITCH) |
src/mess/drivers/channelf.c
| r2236 | r2237 | |
| 47 | 47 | |
| 48 | 48 | static READ8_HANDLER( channelf_port_0_r ) |
| 49 | 49 | { |
| 50 | | return port_read_with_latch(readinputport(0),latch[0]); |
| 50 | return port_read_with_latch(readinputportbytag("PANEL"),latch[0]); |
| 51 | 51 | } |
| 52 | 52 | |
| 53 | 53 | static READ8_HANDLER( channelf_port_1_r ) |
| r2236 | r2237 | |
| 56 | 56 | |
| 57 | 57 | if ((latch[0] & 0x40) == 0) |
| 58 | 58 | { |
| 59 | | ext_value = readinputport(1); |
| 59 | ext_value = readinputportbytag("RIGHT_C"); |
| 60 | 60 | } |
| 61 | 61 | else |
| 62 | 62 | { |
| 63 | | ext_value = 0xc0 | readinputport(1); |
| 63 | ext_value = 0xc0 | readinputportbytag("RIGHT_C"); |
| 64 | 64 | } |
| 65 | 65 | return port_read_with_latch(ext_value,latch[1]); |
| 66 | 66 | } |
| r2236 | r2237 | |
| 71 | 71 | |
| 72 | 72 | if ((latch[0] & 0x40) == 0) |
| 73 | 73 | { |
| 74 | | ext_value = readinputport(2); |
| 74 | ext_value = readinputportbytag("LEFT_C"); |
| 75 | 75 | } |
| 76 | 76 | else |
| 77 | 77 | { |
| r2236 | r2237 | |
| 196 | 196 | |
| 197 | 197 | |
| 198 | 198 | static INPUT_PORTS_START( channelf ) |
| 199 | | PORT_START /* Front panel buttons */ |
| 199 | PORT_START_TAG("PANEL") /* Front panel buttons */ |
| 200 | 200 | PORT_BIT ( 0x01, IP_ACTIVE_HIGH, IPT_START ) /* TIME (1) */ |
| 201 | 201 | PORT_BIT ( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON5 ) /* HOLD (2) */ |
| 202 | 202 | PORT_BIT ( 0x04, IP_ACTIVE_HIGH, IPT_BUTTON6 ) /* MODE (3) */ |
| 203 | 203 | PORT_BIT ( 0x08, IP_ACTIVE_HIGH, IPT_BUTTON7 ) /* START (4) */ |
| 204 | 204 | PORT_BIT ( 0xf0, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 205 | 205 | |
| 206 | | PORT_START /* Right controller */ |
| 206 | PORT_START_TAG("RIGHT_C") /* Right controller */ |
| 207 | 207 | PORT_BIT ( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT) PORT_PLAYER(1) |
| 208 | 208 | PORT_BIT ( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT) PORT_PLAYER(1) |
| 209 | 209 | PORT_BIT ( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN) PORT_PLAYER(1) |
| r2236 | r2237 | |
| 213 | 213 | PORT_BIT ( 0x40, IP_ACTIVE_HIGH, IPT_BUTTON2) /* PULL UP */ PORT_PLAYER(1) |
| 214 | 214 | PORT_BIT ( 0x80, IP_ACTIVE_HIGH, IPT_BUTTON1) /* PUSH DOWN */ PORT_PLAYER(1) |
| 215 | 215 | |
| 216 | | PORT_START /* Left controller */ |
| 216 | PORT_START_TAG("LEFT_C") /* Left controller */ |
| 217 | 217 | PORT_BIT ( 0x01, IP_ACTIVE_HIGH, IPT_JOYSTICK_RIGHT) PORT_PLAYER(2) |
| 218 | 218 | PORT_BIT ( 0x02, IP_ACTIVE_HIGH, IPT_JOYSTICK_LEFT) PORT_PLAYER(2) |
| 219 | 219 | PORT_BIT ( 0x04, IP_ACTIVE_HIGH, IPT_JOYSTICK_DOWN) PORT_PLAYER(2) |
src/mess/drivers/einstein.c
| r2236 | r2237 | |
| 337 | 337 | { |
| 338 | 338 | unsigned char data = 0x0ff; |
| 339 | 339 | int i; |
| 340 | char port[6]; |
| 340 | 341 | |
| 341 | 342 | for (i=0; i<8; i++) |
| 342 | 343 | { |
| 343 | 344 | if ((einstein_keyboard_line & (1<<i))==0) |
| 344 | 345 | { |
| 345 | | data &= readinputport(i); |
| 346 | sprintf(port, "LINE%d", i); |
| 347 | data &= readinputportbytag(port); |
| 346 | 348 | } |
| 347 | 349 | } |
| 348 | 350 | |
| r2236 | r2237 | |
| 375 | 377 | einstein_scan_keyboard(); |
| 376 | 378 | |
| 377 | 379 | /* if /fire1 or /fire2 is 0, then trigger a fire interrupt if the interrupt is enabled */ |
| 378 | | if ((readinputport(9) & 0x03)!=0) |
| 380 | if ((readinputportbytag("BUTTONS") & 0x03)!=0) |
| 379 | 381 | { |
| 380 | 382 | einstein_int |= EINSTEIN_FIRE_INT; |
| 381 | 383 | } |
| r2236 | r2237 | |
| 870 | 872 | /* bit 2: 1=printer busy */ |
| 871 | 873 | /* bit 1: fire 1 */ |
| 872 | 874 | /* bit 0: fire 0 */ |
| 873 | | data = ((readinputport(8) & 0x07)<<5) | (readinputport(9) & 0x03) | 0x01c; |
| 875 | data = ((readinputportbytag("EXTRA") & 0x07)<<5) | (readinputportbytag("BUTTONS") & 0x03) | 0x01c; |
| 874 | 876 | |
| 875 | 877 | /* error? */ |
| 876 | 878 | if (centronics_handshake & CENTRONICS_NO_ERROR) |
| r2236 | r2237 | |
| 1477 | 1479 | |
| 1478 | 1480 | static INPUT_PORTS_START(einstein) |
| 1479 | 1481 | /* line 0 */ |
| 1480 | | PORT_START |
| 1482 | PORT_START_TAG("LINE0") |
| 1481 | 1483 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("BREAK") PORT_CODE(KEYCODE_LALT) |
| 1482 | 1484 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("?") PORT_CODE(KEYCODE_1_PAD) |
| 1483 | 1485 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F0") PORT_CODE(KEYCODE_F1) |
| r2236 | r2237 | |
| 1487 | 1489 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("SPACE") PORT_CODE(KEYCODE_SPACE) |
| 1488 | 1490 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("ESC") PORT_CODE(KEYCODE_ESC) |
| 1489 | 1491 | /* line 1 */ |
| 1490 | | PORT_START |
| 1492 | PORT_START_TAG("LINE1") |
| 1491 | 1493 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("I") PORT_CODE(KEYCODE_I) |
| 1492 | 1494 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("O") PORT_CODE(KEYCODE_O) |
| 1493 | 1495 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("P") PORT_CODE(KEYCODE_P) |
| r2236 | r2237 | |
| 1497 | 1499 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("||") PORT_CODE(KEYCODE_BACKSLASH) |
| 1498 | 1500 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("0") PORT_CODE(KEYCODE_0) |
| 1499 | 1501 | /* line 2 */ |
| 1500 | | PORT_START |
| 1502 | PORT_START_TAG("LINE2") |
| 1501 | 1503 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("K") PORT_CODE(KEYCODE_K) |
| 1502 | 1504 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("L") PORT_CODE(KEYCODE_L) |
| 1503 | 1505 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(";") PORT_CODE(KEYCODE_COLON) |
| r2236 | r2237 | |
| 1507 | 1509 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("9") PORT_CODE(KEYCODE_9) |
| 1508 | 1510 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F5") PORT_CODE(KEYCODE_F6) |
| 1509 | 1511 | /* line 3 */ |
| 1510 | | PORT_START |
| 1512 | PORT_START_TAG("LINE3") |
| 1511 | 1513 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(",") PORT_CODE(KEYCODE_COMMA) |
| 1512 | 1514 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME(".") PORT_CODE(KEYCODE_STOP) |
| 1513 | 1515 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("/") PORT_CODE(KEYCODE_SLASH) |
| r2236 | r2237 | |
| 1517 | 1519 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("UP") PORT_CODE(KEYCODE_UP) |
| 1518 | 1520 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F4") PORT_CODE(KEYCODE_F5) |
| 1519 | 1521 | /* line 4 */ |
| 1520 | | PORT_START |
| 1522 | PORT_START_TAG("LINE4") |
| 1521 | 1523 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("7") PORT_CODE(KEYCODE_7) |
| 1522 | 1524 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("6") PORT_CODE(KEYCODE_6) |
| 1523 | 1525 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("5") PORT_CODE(KEYCODE_5) |
| r2236 | r2237 | |
| 1527 | 1529 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("1") PORT_CODE(KEYCODE_1) |
| 1528 | 1530 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F3") PORT_CODE(KEYCODE_F4) |
| 1529 | 1531 | /* line 5 */ |
| 1530 | | PORT_START |
| 1532 | PORT_START_TAG("LINE5") |
| 1531 | 1533 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("U") PORT_CODE(KEYCODE_U) |
| 1532 | 1534 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Y") PORT_CODE(KEYCODE_Y) |
| 1533 | 1535 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("T") PORT_CODE(KEYCODE_T) |
| r2236 | r2237 | |
| 1537 | 1539 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Q") PORT_CODE(KEYCODE_Q) |
| 1538 | 1540 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F2") PORT_CODE(KEYCODE_F3) |
| 1539 | 1541 | /* line 6 */ |
| 1540 | | PORT_START |
| 1542 | PORT_START_TAG("LINE6") |
| 1541 | 1543 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("J") PORT_CODE(KEYCODE_J) |
| 1542 | 1544 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("H") PORT_CODE(KEYCODE_H) |
| 1543 | 1545 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("G") PORT_CODE(KEYCODE_G) |
| r2236 | r2237 | |
| 1547 | 1549 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("A") PORT_CODE(KEYCODE_A) |
| 1548 | 1550 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F1") PORT_CODE(KEYCODE_F2) |
| 1549 | 1551 | /* line 7 */ |
| 1550 | | PORT_START |
| 1552 | PORT_START_TAG("LINE7") |
| 1551 | 1553 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("M") PORT_CODE(KEYCODE_M) |
| 1552 | 1554 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("N") PORT_CODE(KEYCODE_N) |
| 1553 | 1555 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("B") PORT_CODE(KEYCODE_B) |
| r2236 | r2237 | |
| 1557 | 1559 | PORT_BIT(0x040, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("Z") PORT_CODE(KEYCODE_Z) |
| 1558 | 1560 | PORT_BIT(0x080, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("F6") PORT_CODE(KEYCODE_F7) |
| 1559 | 1561 | /* extra */ |
| 1560 | | PORT_START |
| 1562 | PORT_START_TAG("EXTRA") |
| 1561 | 1563 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("GRPH") PORT_CODE(KEYCODE_F1) |
| 1562 | 1564 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("CONTROL") PORT_CODE(KEYCODE_LCONTROL) |
| 1563 | 1565 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("CONTROL") PORT_CODE(KEYCODE_RCONTROL) |
| r2236 | r2237 | |
| 1565 | 1567 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("SHIFT") PORT_CODE(KEYCODE_RSHIFT) |
| 1566 | 1568 | |
| 1567 | 1569 | /* fire buttons for analogue joysticks */ |
| 1568 | | PORT_START |
| 1570 | PORT_START_TAG("BUTTONS") |
| 1569 | 1571 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_BUTTON1) PORT_NAME("Joystick 1 Button 1") |
| 1570 | 1572 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1) PORT_NAME("Joystick 2 Button 1") PORT_PLAYER(2) |
| 1571 | 1573 | |
| 1572 | 1574 | /* analog joystick 1 x axis */ |
| 1573 | | PORT_START |
| 1575 | PORT_START_TAG("JOY1_X") |
| 1574 | 1576 | PORT_BIT(0xff,0x80,IPT_AD_STICK_X) PORT_SENSITIVITY(100) PORT_KEYDELTA(1) PORT_MINMAX(1,0xff) PORT_CODE_DEC(JOYCODE_X_LEFT_SWITCH) PORT_CODE_INC(JOYCODE_X_RIGHT_SWITCH) PORT_REVERSE |
| 1575 | 1577 | |
| 1576 | 1578 | /* analog joystick 1 y axis */ |
| 1577 | | PORT_START |
| 1579 | PORT_START_TAG("JOY1_Y") |
| 1578 | 1580 | PORT_BIT(0xff,0x80,IPT_AD_STICK_Y) PORT_SENSITIVITY(100) PORT_KEYDELTA(1) PORT_MINMAX(1,0xff) PORT_CODE_DEC(JOYCODE_Y_UP_SWITCH) PORT_CODE_INC(JOYCODE_Y_DOWN_SWITCH) PORT_REVERSE |
| 1579 | 1581 | |
| 1580 | 1582 | /* analog joystick 2 x axis */ |
| 1581 | | PORT_START |
| 1583 | PORT_START_TAG("JOY2_X") |
| 1582 | 1584 | PORT_BIT(0xff,0x80,IPT_AD_STICK_X) PORT_SENSITIVITY(100) PORT_KEYDELTA(1) PORT_MINMAX(1,0xff) PORT_CODE_DEC(JOYCODE_X_LEFT_SWITCH) PORT_CODE_INC(JOYCODE_X_RIGHT_SWITCH) PORT_PLAYER(2) PORT_REVERSE |
| 1583 | 1585 | |
| 1584 | 1586 | /* analog joystick 2 Y axis */ |
| 1585 | | PORT_START |
| 1587 | PORT_START_TAG("JOY2_Y") |
| 1586 | 1588 | PORT_BIT(0xff,0x80,IPT_AD_STICK_Y) PORT_SENSITIVITY(100) PORT_KEYDELTA(1) PORT_MINMAX(1,0xff) PORT_CODE_DEC(JOYCODE_Y_UP_SWITCH) PORT_CODE_INC(JOYCODE_Y_DOWN_SWITCH) PORT_PLAYER(2) PORT_REVERSE |
| 1587 | 1589 | |
| 1588 | 1590 | INPUT_PORTS_END |
src/mess/drivers/avigo.c
| r2236 | r2237 | |
| 178 | 178 | int changed; |
| 179 | 179 | static int ox = 0, oy = 0; |
| 180 | 180 | int nx,ny; |
| 181 | | int dx, dy; |
| 181 | int dx, dy; |
| 182 | char port[6]; |
| 182 | 183 | |
| 183 | 184 | for (i=0; i<4; i++) |
| 184 | 185 | { |
| 185 | | current_input_port_data[i] = readinputport(i); |
| 186 | sprintf(port, "LINE%d", i); |
| 187 | current_input_port_data[i] = readinputportbytag(port); |
| 186 | 188 | } |
| 187 | 189 | |
| 188 | 190 | changed = current_input_port_data[3]^previous_input_port_data[3]; |
| r2236 | r2237 | |
| 220 | 222 | previous_input_port_data[i] = current_input_port_data[i]; |
| 221 | 223 | } |
| 222 | 224 | |
| 223 | | nx = readinputport(4); |
| 225 | nx = readinputportbytag("POSX"); |
| 224 | 226 | if (nx>=0x800) nx-=0x1000; |
| 225 | 227 | else if (nx<=-0x800) nx+=0x1000; |
| 226 | 228 | |
| 227 | 229 | dx = nx - ox; |
| 228 | 230 | ox = nx; |
| 229 | 231 | |
| 230 | | ny = readinputport(5); |
| 232 | ny = readinputportbytag("POSY"); |
| 231 | 233 | if (ny>=0x800) ny-=0x1000; |
| 232 | 234 | else if (ny<=-0x800) ny+=0x1000; |
| 233 | 235 | |
| r2236 | r2237 | |
| 403 | 405 | { |
| 404 | 406 | int i; |
| 405 | 407 | unsigned char *addr; |
| 408 | char port[6]; |
| 406 | 409 | |
| 407 | 410 | memset(avigo_banked_opbase, 0, sizeof(avigo_banked_opbase)); |
| 408 | 411 | |
| r2236 | r2237 | |
| 420 | 423 | /* initialise settings for port data */ |
| 421 | 424 | for (i=0; i<4; i++) |
| 422 | 425 | { |
| 423 | | previous_input_port_data[i] = readinputport(i); |
| 426 | sprintf(port, "LINE%d", i); |
| 427 | previous_input_port_data[i] = readinputportbytag(port); |
| 424 | 428 | } |
| 425 | 429 | |
| 426 | 430 | avigo_irq = 0; |
| r2236 | r2237 | |
| 476 | 480 | |
| 477 | 481 | if (avigo_key_line & 0x01) |
| 478 | 482 | { |
| 479 | | data &= readinputport(0); |
| 483 | data &= readinputportbytag("LINE0"); |
| 480 | 484 | } |
| 481 | 485 | |
| 482 | 486 | if (avigo_key_line & 0x02) |
| 483 | 487 | { |
| 484 | | data &= readinputport(1); |
| 488 | data &= readinputportbytag("LINE1"); |
| 485 | 489 | } |
| 486 | 490 | |
| 487 | 491 | if (avigo_key_line & 0x04) |
| 488 | 492 | { |
| 489 | | data &= readinputport(2); |
| 493 | data &= readinputportbytag("LINE2"); |
| 490 | 494 | |
| 491 | 495 | } |
| 492 | 496 | |
| r2236 | r2237 | |
| 807 | 811 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 808 | 812 | |
| 809 | 813 | AM_RANGE(0x000, 0x000) AM_READ( avigo_unmapped_r) |
| 810 | | AM_RANGE(0x001, 0x001) AM_READWRITE( avigo_key_data_read_r, avigo_set_key_line_w ) |
| 814 | AM_RANGE(0x001, 0x001) AM_READWRITE( avigo_key_data_read_r, avigo_set_key_line_w ) |
| 811 | 815 | AM_RANGE(0x002, 0x002) AM_READ( avigo_unmapped_r) |
| 812 | 816 | AM_RANGE(0x003, 0x003) AM_READWRITE( avigo_irq_r, avigo_irq_w ) |
| 813 | 817 | AM_RANGE(0x004, 0x004) AM_READ( avigo_04_r) |
| r2236 | r2237 | |
| 815 | 819 | AM_RANGE(0x006, 0x006) AM_READWRITE( avigo_rom_bank_h_r, avigo_rom_bank_h_w ) |
| 816 | 820 | AM_RANGE(0x007, 0x007) AM_READWRITE( avigo_ram_bank_l_r, avigo_ram_bank_l_w ) |
| 817 | 821 | AM_RANGE(0x008, 0x008) AM_READWRITE( avigo_ram_bank_h_r, avigo_ram_bank_h_w ) |
| 818 | | AM_RANGE(0x009, 0x009) AM_READWRITE( avigo_ad_control_status_r, avigo_ad_control_status_w ) |
| 822 | AM_RANGE(0x009, 0x009) AM_READWRITE( avigo_ad_control_status_r, avigo_ad_control_status_w ) |
| 819 | 823 | AM_RANGE(0x00a, 0x00f) AM_READ( avigo_unmapped_r) |
| 820 | 824 | AM_RANGE(0x010, 0x01f) AM_READWRITE( tc8521_r, tc8521_w ) |
| 821 | 825 | AM_RANGE(0x020, 0x02c) AM_READ( avigo_unmapped_r) |
| 822 | 826 | AM_RANGE(0x028, 0x028) AM_WRITE( avigo_speaker_w) |
| 823 | | AM_RANGE(0x02d, 0x02d) AM_READ( avigo_ad_data_r) |
| 827 | AM_RANGE(0x02d, 0x02d) AM_READ( avigo_ad_data_r) |
| 824 | 828 | AM_RANGE(0x02e, 0x02f) AM_READ( avigo_unmapped_r) |
| 825 | 829 | AM_RANGE(0x030, 0x037) AM_READWRITE( uart8250_0_r, uart8250_0_w ) |
| 826 | 830 | AM_RANGE(0x038, 0x0ff) AM_READ( avigo_unmapped_r) |
| r2236 | r2237 | |
| 829 | 833 | |
| 830 | 834 | |
| 831 | 835 | static INPUT_PORTS_START(avigo) |
| 832 | | PORT_START |
| 836 | PORT_START_TAG("LINE0") |
| 833 | 837 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("PAGE UP") PORT_CODE(KEYCODE_PGUP) |
| 834 | 838 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("PAGE DOWN") PORT_CODE(KEYCODE_PGDN) |
| 835 | 839 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("LIGHT") PORT_CODE(KEYCODE_L) |
| 836 | | PORT_BIT (0x0f7, 0xf7, IPT_UNUSED) |
| 840 | PORT_BIT(0x0f7, 0xf7, IPT_UNUSED) |
| 837 | 841 | |
| 838 | | PORT_START |
| 842 | PORT_START_TAG("LINE1") |
| 839 | 843 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("TO DO") PORT_CODE(KEYCODE_T) |
| 840 | 844 | PORT_BIT(0x02, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("ADDRESS") PORT_CODE(KEYCODE_A) |
| 841 | 845 | PORT_BIT(0x04, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("SCHEDULE") PORT_CODE(KEYCODE_S) |
| 842 | | PORT_BIT (0x0f7, 0xf7, IPT_UNUSED) |
| 846 | PORT_BIT(0x0f7, 0xf7, IPT_UNUSED) |
| 843 | 847 | |
| 844 | | PORT_START |
| 845 | | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("MEMO") PORT_CODE(KEYCODE_M) |
| 846 | | PORT_BIT (0x0fe, 0xfe, IPT_UNUSED) |
| 848 | PORT_START_TAG("LINE2") |
| 849 | PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_KEYBOARD) PORT_NAME("MEMO") PORT_CODE(KEYCODE_M) |
| 850 | PORT_BIT(0x0fe, 0xfe, IPT_UNUSED) |
| 847 | 851 | |
| 848 | | PORT_START |
| 849 | | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Pen/Stylus pressed") PORT_CODE(KEYCODE_Q) PORT_CODE(JOYCODE_BUTTON1) |
| 850 | | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("?? Causes a NMI") PORT_CODE(KEYCODE_W) PORT_CODE(JOYCODE_BUTTON2) |
| 852 | PORT_START_TAG("LINE3") |
| 853 | PORT_BIT(0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("Pen/Stylus pressed") PORT_CODE(KEYCODE_Q) PORT_CODE(JOYCODE_BUTTON1) |
| 854 | PORT_BIT(0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD) PORT_NAME("?? Causes a NMI") PORT_CODE(KEYCODE_W) PORT_CODE(JOYCODE_BUTTON2) |
| 851 | 855 | |
| 852 | 856 | /* these two ports are used to emulate the position of the pen/stylus on the screen */ |
| 853 | 857 | /* a cursor is drawn to indicate the position, so when a click is done, it will occur in the correct place */ |
| 854 | | PORT_START /* Mouse - X AXIS */ |
| 855 | | PORT_BIT( 0xfff, 0x00, IPT_MOUSE_X) PORT_SENSITIVITY(100) PORT_KEYDELTA(0) PORT_PLAYER(1) |
| 858 | /* To be converted to crosshair code? */ |
| 859 | PORT_START_TAG("POSX") /* Mouse - X AXIS */ |
| 860 | PORT_BIT(0xfff, 0x00, IPT_MOUSE_X) PORT_SENSITIVITY(100) PORT_KEYDELTA(0) PORT_PLAYER(1) |
| 856 | 861 | |
| 857 | | PORT_START /* Mouse - Y AXIS */ |
| 858 | | PORT_BIT( 0xfff, 0x00, IPT_MOUSE_Y) PORT_SENSITIVITY(100) PORT_KEYDELTA(0) PORT_PLAYER(1) |
| 859 | | |
| 862 | PORT_START_TAG("POSY") /* Mouse - Y AXIS */ |
| 863 | PORT_BIT(0xfff, 0x00, IPT_MOUSE_Y) PORT_SENSITIVITY(100) PORT_KEYDELTA(0) PORT_PLAYER(1) |
| 860 | 864 | INPUT_PORTS_END |
| 861 | 865 | |
| 862 | 866 | |