trunk/src/mess/drivers/merlin.c
| r0 | r18799 | |
| 1 | #include "emu.h" |
| 2 | #include "cpu/tms0980/tms0980.h" |
| 3 | |
| 4 | /* Layout */ |
| 5 | #include "merlin.lh" |
| 6 | |
| 7 | |
| 8 | class merlin_state : public driver_device |
| 9 | { |
| 10 | public: |
| 11 | merlin_state(const machine_config &mconfig, device_type type, const char *tag) |
| 12 | : driver_device(mconfig, type, tag) { } |
| 13 | |
| 14 | DECLARE_READ8_MEMBER(read_k); |
| 15 | DECLARE_WRITE16_MEMBER(write_o); |
| 16 | DECLARE_WRITE16_MEMBER(write_r); |
| 17 | }; |
| 18 | |
| 19 | |
| 20 | |
| 21 | #define LOG 1 |
| 22 | |
| 23 | static INPUT_PORTS_START( merlin ) |
| 24 | INPUT_PORTS_END |
| 25 | |
| 26 | |
| 27 | READ8_MEMBER(merlin_state::read_k) |
| 28 | { |
| 29 | UINT8 data = 0xFF; |
| 30 | |
| 31 | if (LOG) |
| 32 | logerror( "read_k\n" ); |
| 33 | |
| 34 | return data; |
| 35 | } |
| 36 | |
| 37 | |
| 38 | WRITE16_MEMBER(merlin_state::write_o) |
| 39 | { |
| 40 | if (LOG) |
| 41 | logerror( "write_o: write %02x\n", data ); |
| 42 | } |
| 43 | |
| 44 | |
| 45 | WRITE16_MEMBER(merlin_state::write_r) |
| 46 | { |
| 47 | if (LOG) |
| 48 | logerror( "write_r: write %04x\n", data ); |
| 49 | } |
| 50 | |
| 51 | |
| 52 | static const tms0980_config merlin_tms0980_config = |
| 53 | { |
| 54 | { |
| 55 | /* O output PLA configuration currently unknown */ |
| 56 | { 0x01, 0x01 }, { 0x02, 0x02 }, { 0x03, 0x03 }, { 0x04, 0x04 }, |
| 57 | { 0x05, 0x05 }, { 0x06, 0x06 }, { 0x07, 0x07 }, { 0x08, 0x08 }, |
| 58 | { 0x09, 0x09 }, { 0x0a, 0x0a }, { 0x0b, 0x0b }, { 0x0c, 0x0c }, |
| 59 | { 0x0d, 0x0d }, { 0x0e, 0x0e }, { 0x0f, 0x0f }, { 0x10, 0x10 }, |
| 60 | { 0x11, 0x11 }, { 0x12, 0x12 }, { 0x13, 0x13 }, { 0x14, 0x14 } |
| 61 | }, |
| 62 | DEVCB_DRIVER_MEMBER(merlin_state, read_k), |
| 63 | DEVCB_DRIVER_MEMBER16(merlin_state, write_o), |
| 64 | DEVCB_DRIVER_MEMBER16(merlin_state, write_r) |
| 65 | }; |
| 66 | |
| 67 | |
| 68 | static MACHINE_CONFIG_START( merlin, merlin_state ) |
| 69 | MCFG_CPU_ADD( "maincpu", TMS1100, 5000000 ) /* Clock is wrong */ |
| 70 | MCFG_CPU_CONFIG( merlin_tms0980_config ) |
| 71 | |
| 72 | MCFG_DEFAULT_LAYOUT(layout_merlin) |
| 73 | MACHINE_CONFIG_END |
| 74 | |
| 75 | ROM_START( merlin ) |
| 76 | ROM_REGION( 0x800, "maincpu", 0 ) |
| 77 | ROM_LOAD( "mp3404", 0x0000, 0x800, CRC(9362d9f9) SHA1(266d2a4a98cc33944a4fc7ed073ba9321bba8e05) ) |
| 78 | ROM_END |
| 79 | |
| 80 | /*************************************************************************** |
| 81 | |
| 82 | Game driver(s) |
| 83 | |
| 84 | ***************************************************************************/ |
| 85 | |
| 86 | /* YEAR NAME PARENT COMPAT MACHINE INPUT INIT COMPANY FULLNAME FLAGS */ |
| 87 | CONS( 1978, merlin, 0, 0, merlin, merlin, driver_device, 0, "Parker Brothers", "Merlin", GAME_IS_SKELETON ) |
| 88 | |
| 89 | |