novagmcs48: clear mux data after updating leds (nw)

This commit is contained in:
hap 2017-04-25 19:38:38 +02:00
parent 70e38e83ed
commit e8bae53e6e
2 changed files with 7 additions and 8 deletions

View File

@ -1059,15 +1059,15 @@ WRITE8_MEMBER(fidelz80_state::vbrc_ioexp_port_w)
WRITE8_MEMBER(fidelz80_state::vbrc_mcu_p1_w) WRITE8_MEMBER(fidelz80_state::vbrc_mcu_p1_w)
{ {
// d0-d7: select digits, input mux // P10-P17: select digits, input mux
m_inp_mux = m_led_select = data; m_inp_mux = m_led_select = data;
vbrc_prepare_display(); vbrc_prepare_display();
} }
READ8_MEMBER(fidelz80_state::vbrc_mcu_p2_r) READ8_MEMBER(fidelz80_state::vbrc_mcu_p2_r)
{ {
// d0-d3: I8243 P2 // P20-P23: I8243 P2
// d4-d7: multiplexed inputs (active low) // P24-P27: multiplexed inputs (active low)
return (m_i8243->i8243_p2_r(space, offset) & 0x0f) | (read_inputs(8) << 4 ^ 0xf0); return (m_i8243->i8243_p2_r(space, offset) & 0x0f) | (read_inputs(8) << 4 ^ 0xf0);
} }

View File

@ -11,8 +11,8 @@
such as Arena(in editmode). such as Arena(in editmode).
TODO: TODO:
- is presto led handling correct? led data needs to be auto cleared - is presto led handling correct? mux data needs to be auto cleared
similar to novag6502 sforte/sexpert similar to diablo/sexpert
****************************************************************************** ******************************************************************************
@ -65,7 +65,6 @@ WRITE8_MEMBER(novagmcs48_state::presto_mux_w)
{ {
// D0-D7: input mux low, led data // D0-D7: input mux low, led data
m_inp_mux = (m_inp_mux & ~0xff) | (~data & 0xff); m_inp_mux = (m_inp_mux & ~0xff) | (~data & 0xff);
m_led_data = ~data & 0xff;
} }
WRITE8_MEMBER(novagmcs48_state::presto_control_w) WRITE8_MEMBER(novagmcs48_state::presto_control_w)
@ -78,8 +77,8 @@ WRITE8_MEMBER(novagmcs48_state::presto_control_w)
// P24-P26: led select // P24-P26: led select
m_led_select = ~data >> 4 & 7; m_led_select = ~data >> 4 & 7;
display_matrix(8, 3, m_led_data, m_led_select); display_matrix(8, 3, m_inp_mux, m_led_select);
m_led_data = 0; // ? m_inp_mux &= ~0xff; // ?
} }
READ8_MEMBER(novagmcs48_state::presto_input_r) READ8_MEMBER(novagmcs48_state::presto_input_r)