Previous 15994 Revisions Next

r8467 Saturday 10th July, 2010 at 18:48:39 UTC by Angelo Salese
[PASOPIA7]: fixed a bunch of quirks
[src/mess/drivers]pasopia.c

src/mess/drivers/pasopia.c
r8466r8467
4646static READ8_HANDLER( vram_r )
4747{
4848   if(vram_sel)
49      return 0xff;
49      return 0xff; //TODO: investigate on this
5050
5151   return p7_vram[offset];
5252}
r8466r8467
141141}
142142
143143/* writes always occurs to the RAM banks, even if the ROMs are selected. */
144static WRITE8_HANDLER( ram_bank1_w )
144static WRITE8_HANDLER( ram_bank_w )
145145{
146146   UINT8 *cpu = memory_region(space->machine, "maincpu");
147147
148148   cpu[offset] = data;
149149}
150150
151static WRITE8_HANDLER( ram_bank2_w )
152{
153   UINT8 *cpu = memory_region(space->machine, "maincpu");
154
155   cpu[offset+0x4000] = data;
156}
157
158151static ADDRESS_MAP_START(paso7_mem, ADDRESS_SPACE_PROGRAM, 8)
159152   ADDRESS_MAP_UNMAP_HIGH
160   AM_RANGE( 0x0000, 0x3fff ) AM_ROMBANK("bank1") AM_WRITE( ram_bank1_w )
161   AM_RANGE( 0x4000, 0x7fff ) AM_ROMBANK("bank2") AM_WRITE( ram_bank2_w )
153   AM_RANGE( 0x0000, 0x7fff ) AM_WRITE( ram_bank_w )
154   AM_RANGE( 0x0000, 0x3fff ) AM_ROMBANK("bank1")
155   AM_RANGE( 0x4000, 0x7fff ) AM_ROMBANK("bank2")
162156   AM_RANGE( 0x8000, 0xbfff ) AM_READWRITE(vram_r, vram_w ) AM_BASE(&p7_vram)
163157   AM_RANGE( 0xc000, 0xffff ) AM_RAMBANK("bank4")
164158ADDRESS_MAP_END
r8466r8467
281275   /* ---- --x- sound off */
282276}
283277
278/* TODO: investigate on these. */
279static READ8_DEVICE_HANDLER( unk_r )
280{
281   return 0xff;//mame_rand(device->machine);
282}
284283
285284static I8255A_INTERFACE( ppi8255_intf_0 )
286285{
287   DEVCB_NULL,                  /* Port A read */
286   DEVCB_HANDLER(unk_r),         /* Port A read */
288287   DEVCB_HANDLER(crtc_portb_r),   /* Port B read */
289288   DEVCB_NULL,                  /* Port C read */
290289   DEVCB_HANDLER(ppi8255_0a_w),      /* Port A write */
r8466r8467
306305{
307306   DEVCB_NULL,                  /* Port A read */
308307   DEVCB_NULL,                  /* Port B read */
309   DEVCB_NULL,                  /* Port C read */
308   DEVCB_HANDLER(unk_r),         /* Port C read */
310309   DEVCB_HANDLER(ppi8255_2a_w),   /* Port A write */
311310   DEVCB_NULL,                  /* Port B write */
312311   DEVCB_NULL                  /* Port C write */
r8466r8467
377376static DRIVER_INIT( paso7 )
378377{
379378   UINT8 *bios = memory_region(machine, "maincpu");
380   const address_space *space = cputag_get_address_space(machine, "maincpu", ADDRESS_SPACE_PROGRAM);
381379
382   memory_unmap_write(space, 0x0000, 0x7fff, 0, 0);
383380   memory_set_bankptr(machine, "bank1", bios + 0x10000);
384381   memory_set_bankptr(machine, "bank2", bios + 0x10000);
385382//   memory_set_bankptr(machine, "bank3", bios + 0x10000);

Previous 15994 Revisions Next


© 1998-2018 The MESS Team