Ejemplo n.º 1
0
static READ8_DEVICE_HANDLER( r6532_portb_r )
{
	UINT8 newdata = riot6532_portb_in_get(device);
	if (has_tms5220)
	{
		running_device *tms = devtag_get_device(device->machine, "tms");
		newdata &= ~0x0c;
		if (tms5220_readyq_r(tms)) newdata |= 0x04;
		if (tms5220_intq_r(tms)) newdata |= 0x08;
	}
	return newdata;
}
Ejemplo n.º 2
0
/*
    TMS7041 PORT A
    A0 - X1 NDSR A8
    A1 - X1 MDTR A9
    A2 - R - TMS7020 port B bit 0 (REV2)
    A3 - TMS5220 IRQ
    A4 - R - TMS7020 port B bit 1 (REV4)
    A5 - X1 RXD A4 (version b) / WX301-14 (version a)
    A6 - X1 SCLK A9
    A7 - TMS5220 RDY
*/
static READ8_HANDLER(tms7041_porta_r)
{
	exelv_state *state = space->machine().driver_data<exelv_state>();
	device_t *tms5220c = space->machine().device( "tms5220c" );
	UINT8 data = 0x00;

	logerror("tms7041_porta_r\n");

	data |= ( state->m_tms7020_portb & 0x01 ) ? 0x04 : 0x00;
	data |= tms5220_intq_r( tms5220c ) ? 0x08 : 0x00;
	data |= ( state->m_tms7020_portb & 0x02 ) ? 0x10 : 0x00;
	data |= tms5220_readyq_r( tms5220c ) ? 0x80 : 0x00;

	return data;
}
Ejemplo n.º 3
0
static READ8_DEVICE_HANDLER( r6532_porta_r )
{
	/* Configured as follows:           */
	/* d7 (in)  Main Ready Flag         */
	/* d6 (in)  Sound Ready Flag        */
	/* d5 (out) Mute Speech             */
	/* d4 (in)  Not Sound Self Test     */
	/* d3 (out) Hold Main CPU in Reset? */
	/*          + enable delay circuit? */
	/* d2 (in)  TMS5220 Not Ready       */
	/* d1 (out) TMS5220 Not Read        */
	/* d0 (out) TMS5220 Not Write       */
	/* Note: bit 4 is always set to avoid sound self test */
	UINT8 olddata = riot6532_porta_in_get(device);

	return (olddata & 0xc0) | 0x10 | (tms5220_readyq_r(devtag_get_device(device->machine, "tms")) << 2);
}
Ejemplo n.º 4
0
static READ8_HANDLER( speech_ready_r )
{
	return (tms5220_readyq_r(space->machine->device("tms"))) << 7;
}
Ejemplo n.º 5
0
static READ8_HANDLER( speech_ready_r )
{
	return (tms5220_readyq_r(devtag_get_device(space->machine, "tms"))) << 7;
}