From 2cb7842e56574103e6b724b932426d181b823b76 Mon Sep 17 00:00:00 2001 From: AJR Date: Tue, 2 Jul 2019 23:40:49 -0400 Subject: zorba: Fix regression; document a few more things (nw) --- src/mame/drivers/zorba.cpp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/mame/drivers/zorba.cpp b/src/mame/drivers/zorba.cpp index e0a3b1a3d33..af3973f5bd0 100644 --- a/src/mame/drivers/zorba.cpp +++ b/src/mame/drivers/zorba.cpp @@ -166,20 +166,20 @@ void zorba_state::zorba(machine_config &config) m_dma->in_iorq_callback().set(FUNC(zorba_state::io_read_byte)); m_dma->out_iorq_callback().set(FUNC(zorba_state::io_write_byte)); - I8251(config, m_uart0, 0); // U32 COM port J2 + I8251(config, m_uart0, 24_MHz_XTAL / 12); // U32 COM port J2 m_uart0->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd)); // TODO: this line has a LED attached m_uart0->dtr_handler().set("rs232", FUNC(rs232_port_device::write_dtr)); m_uart0->rts_handler().set("rs232", FUNC(rs232_port_device::write_rts)); m_uart0->rxrdy_handler().set(FUNC(zorba_state::tx_rx_rdy_w<1>)); m_uart0->txrdy_handler().set(FUNC(zorba_state::tx_rx_rdy_w<0>)); - I8251(config, m_uart1, 0); // U31 printer port J3 + I8251(config, m_uart1, 24_MHz_XTAL / 12); // U31 printer port J3 m_uart1->txd_handler().set("serprn", FUNC(rs232_port_device::write_txd)); m_uart1->rts_handler().set("serprn", FUNC(rs232_port_device::write_rts)); m_uart1->rxrdy_handler().set(FUNC(zorba_state::tx_rx_rdy_w<3>)); m_uart1->txrdy_handler().set(FUNC(zorba_state::tx_rx_rdy_w<2>)); - I8251(config, m_uart2, 0); // U30 serial keyboard J6 + I8251(config, m_uart2, 24_MHz_XTAL / 12); // U30 serial keyboard J6 m_uart2->txd_handler().set("keyboard", FUNC(zorba_keyboard_device::txd_w)); m_uart2->rxrdy_handler().set(FUNC(zorba_state::tx_rx_rdy_w<5>)); m_uart2->txrdy_handler().set(FUNC(zorba_state::tx_rx_rdy_w<4>)); @@ -214,8 +214,9 @@ void zorba_state::zorba(machine_config &config) pit.out_handler<2>().append(m_uart2, FUNC(i8251_device::write_rxc)); // CRTC - I8275(config, m_crtc, 14.318'181_MHz_XTAL / 7); + I8275(config, m_crtc, 14.318'181_MHz_XTAL / 8); // TODO: character clock divider is 9 during HRTC m_crtc->set_character_width(8); + m_crtc->set_refresh_hack(true); m_crtc->set_display_callback(FUNC(zorba_state::zorba_update_chr), this); m_crtc->drq_wr_callback().set(m_dma, FUNC(z80dma_device::rdy_w)); m_crtc->irq_wr_callback().set("irq0", FUNC(input_merger_device::in_w<1>)); @@ -500,15 +501,16 @@ I8275_DRAW_CHARACTER_MEMBER( zorba_state::zorba_update_chr ) uint8_t gfx = m_p_chargen[(linecount & 15) + (charcode << 4) + ((gpa & 1) << 11)]; + if (rvv) + gfx ^= 0xff; + + // VSP actually overrides reverse video here if (vsp) gfx = 0; if (lten) gfx = 0xff; - if (rvv) - gfx ^= 0xff; - for(i=0;i<8;i++) bitmap.pix32(y, x + 7 - i) = palette[BIT(gfx, i) ? (hlgt ? 2 : 1) : 0]; } -- cgit v1.2.3