mirror of
https://github.com/holub/mame
synced 2025-06-26 06:14:12 +03:00
Fixed CDP1869 character memory access, and Cidelsa sprite flashing.
This commit is contained in:
parent
ef6d13be04
commit
d41a31dd12
@ -582,42 +582,50 @@ READ8_DEVICE_HANDLER( cdp1869_charram_r )
|
||||
{
|
||||
cdp1869_t *cdp1869 = get_safe_token(device);
|
||||
|
||||
UINT8 cma = offset & 0x0f;
|
||||
UINT16 pma;
|
||||
|
||||
if (cdp1869->cmem)
|
||||
{
|
||||
UINT16 pma = cdp1869_get_pma(device);
|
||||
UINT8 cma = offset & 0x0f;
|
||||
|
||||
if (cdp1869_get_lines(device) == 8)
|
||||
{
|
||||
cma &= 0x07;
|
||||
}
|
||||
|
||||
return cdp1869->intf->char_ram_r(device, pma, cma);
|
||||
pma = cdp1869_get_pma(device);
|
||||
}
|
||||
else
|
||||
{
|
||||
return 0xff;
|
||||
pma = offset;
|
||||
}
|
||||
|
||||
if (cdp1869->dblpage)
|
||||
{
|
||||
cma &= 0x07;
|
||||
}
|
||||
|
||||
return cdp1869->intf->char_ram_r(device, pma, cma);
|
||||
}
|
||||
|
||||
WRITE8_DEVICE_HANDLER( cdp1869_charram_w )
|
||||
{
|
||||
cdp1869_t *cdp1869 = get_safe_token(device);
|
||||
|
||||
UINT8 cma = offset & 0x0f;
|
||||
UINT16 pma;
|
||||
|
||||
if (cdp1869->cmem)
|
||||
{
|
||||
UINT16 pma = cdp1869_get_pma(device);
|
||||
UINT8 cma = offset & 0x0f;
|
||||
pma = cdp1869_get_pma(device);
|
||||
}
|
||||
else
|
||||
{
|
||||
pma = offset;
|
||||
}
|
||||
|
||||
if (cdp1869_get_lines(device) == 8)
|
||||
{
|
||||
cma &= 0x07;
|
||||
}
|
||||
if (cdp1869->dblpage)
|
||||
{
|
||||
cma &= 0x07;
|
||||
}
|
||||
|
||||
if (cdp1869->intf->char_ram_w)
|
||||
{
|
||||
cdp1869->intf->char_ram_w(device, pma, cma, data);
|
||||
}
|
||||
if (cdp1869->intf->char_ram_w)
|
||||
{
|
||||
cdp1869->intf->char_ram_w(device, pma, cma, data);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -394,7 +394,7 @@ static INPUT_PORTS_START( destryer )
|
||||
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) // LF
|
||||
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON1 ) // FR
|
||||
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED )
|
||||
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SPECIAL ) PORT_CUSTOM(cdp1869_pcb_r, 0)
|
||||
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(cdp1869_pcb_r, 0)
|
||||
|
||||
PORT_START_TAG("IN1")
|
||||
PORT_DIPNAME( 0x03, 0x02, DEF_STR( Difficulty ) )
|
||||
@ -434,7 +434,7 @@ static INPUT_PORTS_START( altair )
|
||||
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) // LF
|
||||
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON1 ) // FR
|
||||
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED )
|
||||
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SPECIAL ) PORT_CUSTOM(cdp1869_pcb_r, 0)
|
||||
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(cdp1869_pcb_r, 0)
|
||||
|
||||
PORT_START_TAG("IN1")
|
||||
PORT_DIPNAME( 0x03, 0x02, DEF_STR( Difficulty ) )
|
||||
@ -484,7 +484,7 @@ static INPUT_PORTS_START( draco )
|
||||
PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN )
|
||||
PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN )
|
||||
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN )
|
||||
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SPECIAL ) PORT_CUSTOM(cdp1869_pcb_r, 0)
|
||||
PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(cdp1869_pcb_r, 0)
|
||||
|
||||
PORT_START_TAG("IN1")
|
||||
PORT_DIPNAME( 0x03, 0x02, DEF_STR( Difficulty ) )
|
||||
|
Loading…
Reference in New Issue
Block a user