Previous 199869 Revisions Next

r31116 Thursday 26th June, 2014 at 07:48:10 UTC by Fabio Priuli
devcb write8 was in fact enough for rev.31113 (thanks AWJ for noticing). nw.
[src/emu/cpu/m6809]konami.c konami.h
[src/mame/drivers]88games.c aliens.c blockhl.c crimfght.c gbusters.c parodius.c rollerg.c simpsons.c surpratk.c thunderx.c vendetta.c
[src/mame/includes]88games.h aliens.h blockhl.h crimfght.h gbusters.h parodius.h rollerg.h simpsons.h surpratk.h thunderx.h vendetta.h
[src/mame/machine]simpsons.c

trunk/src/emu/cpu/m6809/konami.c
r31115r31116
8585//-------------------------------------------------
8686
8787konami_cpu_device::konami_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
88      : m6809_base_device(mconfig, "KONAMI CPU", tag, owner, clock, KONAMI, 1, "konami_cpu", __FILE__)
88      : m6809_base_device(mconfig, "KONAMI CPU", tag, owner, clock, KONAMI, 1, "konami_cpu", __FILE__),
89         m_set_lines(*this)
8990{
9091}
9192
r31115r31116
9899{
99100   super::device_start();
100101   
101   // bind callbacks
102   m_set_lines.bind_relative_to(*owner());
102   // resolve callbacks
103   m_set_lines.resolve();
103104}
104105
105106
r31115r31116
347348void konami_cpu_device::set_lines(UINT8 data)
348349{
349350   if (!m_set_lines.isnull())
350      m_set_lines(data);
351      m_set_lines((offs_t)0, data);
351352}
352353
353354
trunk/src/emu/cpu/m6809/konami.h
r31115r31116
1818//  TYPE DEFINITIONS
1919//**************************************************************************
2020
21typedef device_delegate<void (int lines)> konami_line_cb_delegate;
22#define KONAMICPU_LINE_CB_MEMBER(_name)   void _name(int lines)
21#define MCFG_KONAMICPU_LINE_CB(_devcb) \
22   devcb = &konami_cpu_device::set_line_callback(*device, DEVCB_##_devcb);
2323
24#define MCFG_KONAMICPU_LINE_CB(_class, _method) \
25   konami_cpu_device::set_line_callback(*device, konami_line_cb_delegate(&_class::_method, #_class "::" #_method, downcast<_class *>(owner)));
2624
27
2825// device type definition
2926extern const device_type KONAMI;
3027
r31115r31116
3734   konami_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock);
3835
3936   // configuration
40   static void set_line_callback(device_t &device, konami_line_cb_delegate callback) { downcast<konami_cpu_device &>(device).m_set_lines = callback; }
37   template<class _Object> static devcb_base &set_line_callback(device_t &device, _Object object) { return downcast<konami_cpu_device &>(device).m_set_lines.set_callback(object); }
4138
4239protected:
4340   // device-level overrides
r31115r31116
5350   typedef m6809_base_device super;
5451
5552   // incidentals
56   konami_line_cb_delegate m_set_lines;
53   devcb_write8 m_set_lines;
5754
5855   // konami-specific addressing modes
5956   UINT16 &ireg();
trunk/src/mame/machine/simpsons.c
r31115r31116
6060
6161***************************************************************************/
6262
63KONAMICPU_LINE_CB_MEMBER( simpsons_state::banking_callback )
63WRITE8_MEMBER( simpsons_state::banking_callback )
6464{
65   membank("bank1")->set_entry(lines & 0x3f);
65   membank("bank1")->set_entry(data & 0x3f);
6666}
6767
6868void simpsons_state::machine_start()
trunk/src/mame/includes/88games.h
r31115r31116
6565   K051316_CB_MEMBER(zoom_callback);
6666   K052109_CB_MEMBER(tile_callback);
6767   K051960_CB_MEMBER(sprite_callback);
68   KONAMICPU_LINE_CB_MEMBER(banking_callback);
68   DECLARE_WRITE8_MEMBER(banking_callback);
6969};
trunk/src/mame/includes/surpratk.h
r31115r31116
4444
4545   K05324X_CB_MEMBER(sprite_callback);
4646   K052109_CB_MEMBER(tile_callback);
47   KONAMICPU_LINE_CB_MEMBER(banking_callback);
47   DECLARE_WRITE8_MEMBER(banking_callback);
4848};
trunk/src/mame/includes/aliens.h
r31115r31116
4646   DECLARE_WRITE8_MEMBER(volume_callback);
4747   K052109_CB_MEMBER(tile_callback);
4848   K051960_CB_MEMBER(sprite_callback);
49   KONAMICPU_LINE_CB_MEMBER(banking_callback);
49   DECLARE_WRITE8_MEMBER(banking_callback);
5050};
trunk/src/mame/includes/gbusters.h
r31115r31116
5858   DECLARE_WRITE8_MEMBER(volume_callback);
5959   K052109_CB_MEMBER(tile_callback);
6060   K051960_CB_MEMBER(sprite_callback);
61   KONAMICPU_LINE_CB_MEMBER(banking_callback);
61   DECLARE_WRITE8_MEMBER(banking_callback);
6262};
trunk/src/mame/includes/thunderx.h
r31115r31116
7474   DECLARE_WRITE8_MEMBER(volume_callback);
7575   K052109_CB_MEMBER(tile_callback);
7676   K051960_CB_MEMBER(sprite_callback);
77   KONAMICPU_LINE_CB_MEMBER(thunderx_banking_callback);
77   DECLARE_WRITE8_MEMBER(thunderx_banking_callback);
7878
7979protected:
8080   virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
trunk/src/mame/includes/blockhl.h
r31115r31116
5050   INTERRUPT_GEN_MEMBER(blockhl_interrupt);
5151   K052109_CB_MEMBER(tile_callback);
5252   K051960_CB_MEMBER(sprite_callback);
53   KONAMICPU_LINE_CB_MEMBER(banking_callback);
53   DECLARE_WRITE8_MEMBER(banking_callback);
5454};
trunk/src/mame/includes/parodius.h
r31115r31116
5858   INTERRUPT_GEN_MEMBER(parodius_interrupt);
5959   K05324X_CB_MEMBER(sprite_callback);
6060   K052109_CB_MEMBER(tile_callback);
61   KONAMICPU_LINE_CB_MEMBER(banking_callback);
61   DECLARE_WRITE8_MEMBER(banking_callback);
6262
6363protected:
6464   virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
trunk/src/mame/includes/vendetta.h
r31115r31116
7171   void vendetta_video_banking( int select );
7272   K052109_CB_MEMBER(vendetta_tile_callback);
7373   K052109_CB_MEMBER(esckids_tile_callback);
74   KONAMICPU_LINE_CB_MEMBER(banking_callback);
74   DECLARE_WRITE8_MEMBER(banking_callback);
7575
7676protected:
7777   virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
trunk/src/mame/includes/crimfght.h
r31115r31116
4848   DECLARE_WRITE8_MEMBER(volume_callback);
4949   K052109_CB_MEMBER(tile_callback);
5050   K051960_CB_MEMBER(sprite_callback);
51   KONAMICPU_LINE_CB_MEMBER(banking_callback);
51   DECLARE_WRITE8_MEMBER(banking_callback);
5252};
trunk/src/mame/includes/rollerg.h
r31115r31116
5757   UINT32 screen_update_rollerg(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5858   K05324X_CB_MEMBER(sprite_callback);
5959   K051316_CB_MEMBER(zoom_callback);
60   KONAMICPU_LINE_CB_MEMBER(banking_callback);
60   DECLARE_WRITE8_MEMBER(banking_callback);
6161
6262protected:
6363   virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
trunk/src/mame/includes/simpsons.h
r31115r31116
6666   void sound_nmi_callback(int param);
6767   void simpsons_objdma();
6868   K052109_CB_MEMBER(tile_callback);
69   KONAMICPU_LINE_CB_MEMBER(banking_callback);
69   DECLARE_WRITE8_MEMBER(banking_callback);
7070
7171protected:
7272   virtual void device_timer(emu_timer &timer, device_timer_id id, int param, void *ptr);
trunk/src/mame/drivers/simpsons.c
r31115r31116
327327   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/2/4) /* 053248, the clock input is 12MHz, and internal CPU divider of 4 */
328328   MCFG_CPU_PROGRAM_MAP(main_map)
329329   MCFG_CPU_VBLANK_INT_DRIVER("screen", simpsons_state,  simpsons_irq) /* IRQ triggered by the 052109, FIRQ by the sprite hardware */
330   MCFG_KONAMICPU_LINE_CB(simpsons_state, banking_callback)
330   MCFG_KONAMICPU_LINE_CB(WRITE8(simpsons_state, banking_callback))
331331
332332   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
333333   MCFG_CPU_PROGRAM_MAP(z80_map)
trunk/src/mame/drivers/aliens.c
r31115r31116
186186   m_bank0000->set_bank(0);
187187}
188188
189KONAMICPU_LINE_CB_MEMBER( aliens_state::banking_callback )
189WRITE8_MEMBER( aliens_state::banking_callback )
190190{
191   membank("bank1")->set_entry(lines & 0x1f);
191   membank("bank1")->set_entry(data & 0x1f);
192192}
193193
194194static MACHINE_CONFIG_START( aliens, aliens_state )
r31115r31116
197197   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8)       /* 052001 (verified on pcb) */
198198   MCFG_CPU_PROGRAM_MAP(aliens_map)
199199   MCFG_CPU_VBLANK_INT_DRIVER("screen", aliens_state, aliens_interrupt)
200   MCFG_KONAMICPU_LINE_CB(aliens_state, banking_callback)
200   MCFG_KONAMICPU_LINE_CB(WRITE8(aliens_state, banking_callback))
201201
202202   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)     /* verified on pcb */
203203   MCFG_CPU_PROGRAM_MAP(aliens_sound_map)
trunk/src/mame/drivers/parodius.c
r31115r31116
217217   m_bank2000->set_bank(0);
218218}
219219
220KONAMICPU_LINE_CB_MEMBER( parodius_state::banking_callback )
220WRITE8_MEMBER( parodius_state::banking_callback )
221221{
222   if (lines & 0xf0)
223      logerror("%04x: setlines %02x\n", machine().device("maincpu")->safe_pc(), lines);
222   if (data & 0xf0)
223      logerror("%04x: setlines %02x\n", machine().device("maincpu")->safe_pc(), data);
224224   
225   membank("bank1")->set_entry((lines & 0x0f) ^ 0x0f);
225   membank("bank1")->set_entry((data & 0x0f) ^ 0x0f);
226226}
227227
228228static MACHINE_CONFIG_START( parodius, parodius_state )
r31115r31116
231231   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)        /* 053248 */
232232   MCFG_CPU_PROGRAM_MAP(parodius_map)
233233   MCFG_CPU_VBLANK_INT_DRIVER("screen", parodius_state,  parodius_interrupt)
234   MCFG_KONAMICPU_LINE_CB(parodius_state, banking_callback)
234   MCFG_KONAMICPU_LINE_CB(WRITE8(parodius_state, banking_callback))
235235
236236   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
237   MCFG_CPU_PROGRAM_MAP(parodius_sound_map)
238                        /* NMIs are triggered by the 053260 */
237   MCFG_CPU_PROGRAM_MAP(parodius_sound_map)   /* NMIs are triggered by the 053260 */
239238
240239   MCFG_DEVICE_ADD("bank0000", ADDRESS_MAP_BANK, 0)
241240   MCFG_DEVICE_PROGRAM_MAP(bank0000_map)
trunk/src/mame/drivers/vendetta.c
r31115r31116
445445   vendetta_video_banking(0);
446446}
447447
448KONAMICPU_LINE_CB_MEMBER( vendetta_state::banking_callback )
448WRITE8_MEMBER( vendetta_state::banking_callback )
449449{
450   if (lines >= 0x1c)
451      logerror("PC = %04x : Unknown bank selected %02x\n", machine().device("maincpu")->safe_pc(), lines);
450   if (data >= 0x1c)
451      logerror("PC = %04x : Unknown bank selected %02x\n", machine().device("maincpu")->safe_pc(), data);
452452   else
453      membank("bank1")->set_entry(lines);
453      membank("bank1")->set_entry(data);
454454}
455455
456456static MACHINE_CONFIG_START( vendetta, vendetta_state )
r31115r31116
459459   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8)   /* 052001 (verified on pcb) */
460460   MCFG_CPU_PROGRAM_MAP(main_map)
461461   MCFG_CPU_VBLANK_INT_DRIVER("screen", vendetta_state,  vendetta_irq)
462   MCFG_KONAMICPU_LINE_CB(vendetta_state, banking_callback)
462   MCFG_KONAMICPU_LINE_CB(WRITE8(vendetta_state, banking_callback))
463463
464464   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified with PCB */
465465   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/crimfght.c
r31115r31116
230230   membank("bank2")->set_entry(0);
231231}
232232
233KONAMICPU_LINE_CB_MEMBER( crimfght_state::banking_callback )
233WRITE8_MEMBER( crimfght_state::banking_callback )
234234{
235235   /* bit 5 = select work RAM or palette */
236   if (lines & 0x20)
236   if (data & 0x20)
237237   {
238238      m_maincpu->space(AS_PROGRAM).install_read_bank(0x0000, 0x03ff, "bank3");
239239      m_maincpu->space(AS_PROGRAM).install_write_handler(0x0000, 0x03ff, write8_delegate(FUNC(palette_device::write), m_palette.target()));
r31115r31116
243243      m_maincpu->space(AS_PROGRAM).install_readwrite_bank(0x0000, 0x03ff, "bank1");                             /* RAM */
244244   
245245   /* bit 6 = enable char ROM reading through the video RAM */
246   m_k052109->set_rmrd_line((lines & 0x40) ? ASSERT_LINE : CLEAR_LINE);
246   m_k052109->set_rmrd_line((data & 0x40) ? ASSERT_LINE : CLEAR_LINE);
247247
248   membank("bank2")->set_entry(lines & 0x0f);
248   membank("bank2")->set_entry(data & 0x0f);
249249}
250250
251251static MACHINE_CONFIG_START( crimfght, crimfght_state )
r31115r31116
254254   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8)       /* 052001 (verified on pcb) */
255255   MCFG_CPU_PROGRAM_MAP(crimfght_map)
256256   MCFG_CPU_VBLANK_INT_DRIVER("screen", crimfght_state,  crimfght_interrupt)
257   MCFG_KONAMICPU_LINE_CB(crimfght_state, banking_callback)
257   MCFG_KONAMICPU_LINE_CB(WRITE8(crimfght_state, banking_callback))
258258
259259   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)     /* verified on pcb */
260260   MCFG_CPU_PROGRAM_MAP(crimfght_sound_map)
trunk/src/mame/drivers/blockhl.c
r31115r31116
181181   m_rombank = 0;
182182}
183183
184KONAMICPU_LINE_CB_MEMBER( blockhl_state::banking_callback )
184WRITE8_MEMBER( blockhl_state::banking_callback )
185185{
186186   /* bits 0-1 = ROM bank */
187   m_rombank = lines & 0x03;
187   m_rombank = data & 0x03;
188188   membank("bank1")->set_entry(m_rombank);
189189   
190190   /* bits 3/4 = coin counters */
191   coin_counter_w(machine(), 0, lines & 0x08);
192   coin_counter_w(machine(), 1, lines & 0x10);
191   coin_counter_w(machine(), 0, data & 0x08);
192   coin_counter_w(machine(), 1, data & 0x10);
193193   
194194   /* bit 5 = select palette RAM or work RAM at 5800-5fff */
195   m_palette_selected = ~lines & 0x20;
195   m_palette_selected = ~data & 0x20;
196196   
197197   /* bit 6 = enable char ROM reading through the video RAM */
198   m_k052109->set_rmrd_line((lines & 0x40) ? ASSERT_LINE : CLEAR_LINE);
198   m_k052109->set_rmrd_line((data & 0x40) ? ASSERT_LINE : CLEAR_LINE);
199199   
200200   /* bit 7 used but unknown */
201201   
202202   /* other bits unknown */
203203   
204   if ((lines & 0x84) != 0x80)
205      logerror("%04x: setlines %02x\n", machine().device("maincpu")->safe_pc(), lines);
204   if ((data & 0x84) != 0x80)
205      logerror("%04x: setlines %02x\n", machine().device("maincpu")->safe_pc(), data);
206206}
207207
208208static MACHINE_CONFIG_START( blockhl, blockhl_state )
r31115r31116
211211   MCFG_CPU_ADD("maincpu", KONAMI,3000000)     /* Konami custom 052526 */
212212   MCFG_CPU_PROGRAM_MAP(main_map)
213213   MCFG_CPU_VBLANK_INT_DRIVER("screen", blockhl_state,  blockhl_interrupt)
214   MCFG_KONAMICPU_LINE_CB(blockhl_state, banking_callback)
214   MCFG_KONAMICPU_LINE_CB(WRITE8(blockhl_state, banking_callback))
215215
216216   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
217217   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/surpratk.c
r31115r31116
154154   m_sprite_colorbase = 0;
155155}
156156
157KONAMICPU_LINE_CB_MEMBER( surpratk_state::banking_callback )
157WRITE8_MEMBER( surpratk_state::banking_callback )
158158{
159//   logerror("%04x: setlines %02x\n", machine().device("maincpu")->safe_pc(), lines);
160   membank("bank1")->set_entry(lines & 0x1f);
159//   logerror("%04x: setlines %02x\n", machine().device("maincpu")->safe_pc(), data);
160   membank("bank1")->set_entry(data & 0x1f);
161161}
162162
163163static MACHINE_CONFIG_START( surpratk, surpratk_state )
r31115r31116
166166   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/2/4) /* 053248, the clock input is 12MHz, and internal CPU divider of 4 */
167167   MCFG_CPU_PROGRAM_MAP(surpratk_map)
168168   MCFG_CPU_VBLANK_INT_DRIVER("screen", surpratk_state,  surpratk_interrupt)
169   MCFG_KONAMICPU_LINE_CB(surpratk_state, banking_callback)
169   MCFG_KONAMICPU_LINE_CB(WRITE8(surpratk_state, banking_callback))
170170
171171   MCFG_DEVICE_ADD("bank0000", ADDRESS_MAP_BANK, 0)
172172   MCFG_DEVICE_PROGRAM_MAP(bank0000_map)
trunk/src/mame/drivers/rollerg.c
r31115r31116
235235   m_readzoomroms = 0;
236236}
237237
238KONAMICPU_LINE_CB_MEMBER( rollerg_state::banking_callback )
238WRITE8_MEMBER( rollerg_state::banking_callback )
239239{
240   membank("bank1")->set_entry(lines & 0x07);
240   membank("bank1")->set_entry(data & 0x07);
241241}
242242
243243
r31115r31116
247247   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)        /* ? */
248248   MCFG_CPU_PROGRAM_MAP(rollerg_map)
249249   MCFG_CPU_VBLANK_INT_DRIVER("screen", rollerg_state, irq0_line_assert)
250   MCFG_KONAMICPU_LINE_CB(rollerg_state, banking_callback)
250   MCFG_KONAMICPU_LINE_CB(WRITE8(rollerg_state, banking_callback))
251251
252252   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
253   MCFG_CPU_PROGRAM_MAP(rollerg_sound_map)
254                        /* NMIs are generated by the 053260 */
253   MCFG_CPU_PROGRAM_MAP(rollerg_sound_map)   /* NMIs are generated by the 053260 */
255254
256255   /* video hardware */
257256   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/gbusters.c
r31115r31116
258258   m_priority = 0;
259259}
260260
261KONAMICPU_LINE_CB_MEMBER( gbusters_state::banking_callback )
261WRITE8_MEMBER( gbusters_state::banking_callback )
262262{
263263   /* bits 0-3 ROM bank */
264   membank("bank1")->set_entry(lines & 0x0f);
264   membank("bank1")->set_entry(data & 0x0f);
265265   
266   if (lines & 0xf0)
266   if (data & 0xf0)
267267   {
268      //logerror("%04x: (lines) write %02x\n",device->safe_pc(), lines);
269      //popmessage("lines = %02x", lines);
268      //logerror("%04x: (lines) write %02x\n",device->safe_pc(), data);
269      //popmessage("lines = %02x", data);
270270   }
271271   
272272   /* other bits unknown */
r31115r31116
278278   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)    /* Konami custom 052526 */
279279   MCFG_CPU_PROGRAM_MAP(gbusters_map)
280280   MCFG_CPU_VBLANK_INT_DRIVER("screen", gbusters_state,  gbusters_interrupt)
281   MCFG_KONAMICPU_LINE_CB(gbusters_state, banking_callback)
281   MCFG_KONAMICPU_LINE_CB(WRITE8(gbusters_state, banking_callback))
282282
283283   MCFG_CPU_ADD("audiocpu", Z80, 3579545)      /* ? */
284284   MCFG_CPU_PROGRAM_MAP(gbusters_sound_map)
trunk/src/mame/drivers/thunderx.c
r31115r31116
659659MACHINE_CONFIG_END
660660
661661
662KONAMICPU_LINE_CB_MEMBER( thunderx_state::thunderx_banking_callback )
662WRITE8_MEMBER( thunderx_state::thunderx_banking_callback )
663663{
664   //logerror("thunderx %04x: bank select %02x\n", machine().device("maincpu")->safe_pc(), lines);
665   membank("bank1")->set_entry(((lines & 0x0f) ^ 0x08));
664   //logerror("thunderx %04x: bank select %02x\n", machine().device("maincpu")->safe_pc(), data);
665   membank("bank1")->set_entry(((data & 0x0f) ^ 0x08));
666666}
667667
668668static MACHINE_CONFIG_START( thunderx, thunderx_state )
r31115r31116
671671   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/2/4)     /* 052001 (verified on pcb) */
672672   MCFG_CPU_PROGRAM_MAP(thunderx_map)
673673   MCFG_CPU_VBLANK_INT_DRIVER("screen", thunderx_state,  scontra_interrupt)
674   MCFG_KONAMICPU_LINE_CB(thunderx_state, thunderx_banking_callback)
674   MCFG_KONAMICPU_LINE_CB(WRITE8(thunderx_state, thunderx_banking_callback))
675675
676676   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)     /* verified on pcb */
677677   MCFG_CPU_PROGRAM_MAP(thunderx_sound_map)
trunk/src/mame/drivers/88games.c
r31115r31116
251251 *
252252 *************************************/
253253
254KONAMICPU_LINE_CB_MEMBER( _88games_state::banking_callback )
254WRITE8_MEMBER( _88games_state::banking_callback )
255255{
256   logerror("%04x: bank select %02x\n", machine().device("maincpu")->safe_pc(), lines);
256   logerror("%04x: bank select %02x\n", machine().device("maincpu")->safe_pc(), data);
257257
258258   /* bits 0-2 select ROM bank for 0000-1fff */
259259   /* bit 3: when 1, palette RAM at 1000-1fff */
260260   /* bit 4: when 0, 051316 RAM at 3800-3fff; when 1, work RAM at 2000-3fff (NVRAM 3700-37ff) */
261   int rombank = lines & 0x07;
261   int rombank = data & 0x07;
262262   m_bank0000->set_entry(rombank);
263   m_bank1000->set_entry((lines & 0x08) ? 8 : rombank);
264   m_videobank = lines & 0x10;
263   m_bank1000->set_entry((data & 0x08) ? 8 : rombank);
264   m_videobank = data & 0x10;
265265
266266   /* bit 5 = enable char ROM reading through the video RAM */
267   m_k052109->set_rmrd_line((lines & 0x20) ? ASSERT_LINE : CLEAR_LINE);
267   m_k052109->set_rmrd_line((data & 0x20) ? ASSERT_LINE : CLEAR_LINE);
268268
269269   /* bit 6 is unknown, 1 most of the time */
270270
271271   /* bit 7 controls layer priority */
272   m_k88games_priority = lines & 0x80;
272   m_k88games_priority = data & 0x80;
273273}
274274
275275void _88games_state::machine_start()
r31115r31116
308308   MCFG_CPU_ADD("maincpu", KONAMI, 3000000) /* ? */
309309   MCFG_CPU_PROGRAM_MAP(main_map)
310310   MCFG_CPU_VBLANK_INT_DRIVER("screen", _88games_state,  k88games_interrupt)
311   MCFG_KONAMICPU_LINE_CB(_88games_state, banking_callback)
311   MCFG_KONAMICPU_LINE_CB(WRITE8(_88games_state, banking_callback))
312312
313313   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
314314   MCFG_CPU_PROGRAM_MAP(sound_map)

Previous 199869 Revisions Next


© 1997-2024 The MAME Team