trunk/src/mess/drivers/msx.c
r32651 | r32652 | |
1332 | 1332 | MCFG_CPU_VBLANK_INT_DRIVER("screen", msx_state, msx_interrupt) /* Needed for mouse updates */ |
1333 | 1333 | MCFG_QUANTUM_TIME(attotime::from_hz(60)) |
1334 | 1334 | |
1335 | | MCFG_MACHINE_START_OVERRIDE(msx_state, msx ) |
1336 | | MCFG_MACHINE_RESET_OVERRIDE(msx_state, msx ) |
1337 | | |
1338 | 1335 | MCFG_DEVICE_ADD("ppi8255", I8255, 0) |
1339 | 1336 | MCFG_I8255_OUT_PORTA_CB(WRITE8(msx_state, msx_ppi_port_a_w)) |
1340 | 1337 | MCFG_I8255_IN_PORTB_CB(READ8(msx_state, msx_ppi_port_b_r)) |
r32651 | r32652 | |
1411 | 1408 | MCFG_TIMER_DRIVER_ADD_SCANLINE("scantimer", msx_state, msx2_interrupt, "screen", 0, 2) |
1412 | 1409 | MCFG_QUANTUM_TIME(attotime::from_hz(60)) |
1413 | 1410 | |
1414 | | MCFG_MACHINE_START_OVERRIDE(msx_state, msx2 ) |
1415 | | MCFG_MACHINE_RESET_OVERRIDE(msx_state, msx2 ) |
1416 | | |
1417 | 1411 | MCFG_DEVICE_ADD("ppi8255", I8255, 0) |
1418 | 1412 | MCFG_I8255_OUT_PORTA_CB(WRITE8(msx_state, msx_ppi_port_a_w)) |
1419 | 1413 | MCFG_I8255_IN_PORTB_CB(READ8(msx_state, msx_ppi_port_b_r)) |
r32651 | r32652 | |
1479 | 1473 | MCFG_TIMER_DRIVER_ADD_SCANLINE("scantimer", msx_state, msx2p_interrupt, "screen", 0, 2) |
1480 | 1474 | MCFG_QUANTUM_TIME(attotime::from_hz(60)) |
1481 | 1475 | |
1482 | | MCFG_MACHINE_START_OVERRIDE(msx_state, msx2 ) |
1483 | | MCFG_MACHINE_RESET_OVERRIDE(msx_state, msx2 ) |
1484 | | |
1485 | 1476 | MCFG_DEVICE_ADD("ppi8255", I8255, 0) |
1486 | 1477 | MCFG_I8255_OUT_PORTA_CB(WRITE8(msx_state, msx_ppi_port_a_w)) |
1487 | 1478 | MCFG_I8255_IN_PORTB_CB(READ8(msx_state, msx_ppi_port_b_r)) |
trunk/src/mess/machine/msx.c
r32651 | r32652 | |
41 | 41 | } |
42 | 42 | |
43 | 43 | |
44 | | void msx_state::msx_ch_reset_core () |
| 44 | void msx_state::machine_reset() |
45 | 45 | { |
46 | 46 | msx_memory_reset (); |
47 | 47 | msx_memory_map_all (); |
r32651 | r32652 | |
52 | 52 | check_irq(); |
53 | 53 | } |
54 | 54 | |
55 | | MACHINE_START_MEMBER(msx_state,msx) |
56 | | { |
57 | | MACHINE_START_CALL_MEMBER( msx2 ); |
58 | | } |
59 | 55 | |
60 | | MACHINE_START_MEMBER(msx_state,msx2) |
| 56 | void msx_state::machine_start() |
61 | 57 | { |
62 | 58 | m_port_c_old = 0xff; |
63 | 59 | } |
64 | 60 | |
65 | | MACHINE_RESET_MEMBER(msx_state,msx) |
66 | | { |
67 | | msx_ch_reset_core (); |
68 | | } |
69 | 61 | |
70 | | MACHINE_RESET_MEMBER(msx_state,msx2) |
71 | | { |
72 | | msx_ch_reset_core (); |
73 | | } |
74 | | |
75 | | |
76 | 62 | static const UINT8 cc_op[0x100] = { |
77 | 63 | 4+1,10+1, 7+1, 6+1, 4+1, 4+1, 7+1, 4+1, 4+1,11+1, 7+1, 6+1, 4+1, 4+1, 7+1, 4+1, |
78 | 64 | 8+1,10+1, 7+1, 6+1, 4+1, 4+1, 7+1, 4+1,12+1,11+1, 7+1, 6+1, 4+1, 4+1, 7+1, 4+1, |
trunk/src/mess/includes/msx.h
r32651 | r32652 | |
168 | 168 | // static configuration helpers |
169 | 169 | static void install_slot_pages(device_t &owner, UINT8 prim, UINT8 sec, UINT8 page, UINT8 numpages, device_t *device); |
170 | 170 | |
| 171 | virtual void machine_start(); |
| 172 | virtual void machine_reset(); |
| 173 | |
171 | 174 | DECLARE_ADDRESS_MAP(switched_device_map, 8); |
172 | 175 | DECLARE_WRITE8_MEMBER(msx_sec_slot_w); |
173 | 176 | DECLARE_READ8_MEMBER(msx_sec_slot_r); |
r32651 | r32652 | |
187 | 190 | |
188 | 191 | void msx_memory_map_all(); |
189 | 192 | void msx_memory_map_page(UINT8 page); |
190 | | void msx_ch_reset_core(); |
191 | 193 | void msx_memory_reset(); |
192 | 194 | |
193 | 195 | DECLARE_FLOPPY_FORMATS(floppy_formats); |
r32651 | r32652 | |
197 | 199 | DECLARE_WRITE8_MEMBER(msx_psg_port_a_w); |
198 | 200 | DECLARE_WRITE8_MEMBER(msx_psg_port_b_w); |
199 | 201 | DECLARE_DRIVER_INIT(msx); |
200 | | DECLARE_MACHINE_START(msx); |
201 | | DECLARE_MACHINE_RESET(msx); |
202 | | DECLARE_MACHINE_START(msx2); |
203 | | DECLARE_MACHINE_RESET(msx2); |
204 | 202 | INTERRUPT_GEN_MEMBER(msx_interrupt); |
205 | 203 | TIMER_DEVICE_CALLBACK_MEMBER(msx2_interrupt); |
206 | 204 | TIMER_DEVICE_CALLBACK_MEMBER(msx2p_interrupt); |