mirror of
https://github.com/mamedev/mame.git
synced 2024-11-16 07:48:32 +01:00
leonardo/renaissa: correct ACK output
This commit is contained in:
parent
e893c175ea
commit
bb7e5844ef
5 changed files with 29 additions and 14 deletions
|
@ -9,7 +9,7 @@ be inserted into the Odyssey 2/G7000.
|
|||
|
||||
Hardware notes:
|
||||
- Z80 @ 3.547MHz
|
||||
- 2*8KB ROM, 16KB RAM(2*TMS4416, 2 unpopulated sockets)
|
||||
- 2*8KB ROM, 16KB RAM(2*TMS4416, 2 unpopulated locations)
|
||||
- optional data recorder
|
||||
|
||||
The RAM can be expanded to 32KB by simply adding two more TMS4416. To enable it,
|
||||
|
|
|
@ -26,7 +26,6 @@ higher speed versions, they overclocked the CPU. And if the CPU couldn't
|
|||
handle the overclock well enough, they went for a slightly lower speed XTAL.
|
||||
|
||||
TODO:
|
||||
- does not work if cpu speed is 4MHz
|
||||
- cpu clock divider after writing to 0x2000/0x2200
|
||||
|
||||
***************************************************************************/
|
||||
|
@ -284,7 +283,7 @@ void saitekosa_maestro_device::control_w(u8 data)
|
|||
|
||||
u8 saitekosa_maestro_device::ack_r()
|
||||
{
|
||||
// d6: ?
|
||||
// d6: _Vcc
|
||||
// d7: ACK-P
|
||||
return m_expansion->ack_state() ? 0x80 : 0x00;
|
||||
}
|
||||
|
|
|
@ -17,9 +17,6 @@ Hardware notes:
|
|||
The CPU is a 4MHz part, higher speed modules overclock it. The PCB is not
|
||||
compatible for upgrading to newer Maestro versions.
|
||||
|
||||
TODO:
|
||||
- does not work if cpu speed is 4MHz
|
||||
|
||||
***************************************************************************/
|
||||
|
||||
#include "emu.h"
|
||||
|
|
|
@ -46,10 +46,9 @@ The H8 Brute Force module doesn't work with the 1st program version of Leonardo,
|
|||
this is mentioned in the repair manual and it says it requires an EPROM upgrade.
|
||||
The Sparc module doesn't appear to work with it either. Moreover, the Sparc module
|
||||
manual mentions that for it to work properly on Leonardo, the chesscomputer needs
|
||||
to be upgraded with an EMI PCB (power supply related).
|
||||
to be upgraded with an EMI PCB (power supply related, meaningless for emulation).
|
||||
|
||||
TODO:
|
||||
- OSA module comms is not completely understood
|
||||
- OSA PC link, uses MCU serial interface
|
||||
- add nvram (MCU port $14?)
|
||||
- add power-off, not useful with missing nvram support
|
||||
|
@ -122,12 +121,16 @@ private:
|
|||
u8 p5_r();
|
||||
void p6_w(u8 data);
|
||||
|
||||
int m_ack_state = 0;
|
||||
int m_rts_state = 0;
|
||||
u8 m_inp_mux = 0;
|
||||
u8 m_led_data[2] = { };
|
||||
};
|
||||
|
||||
void leo_state::machine_start()
|
||||
{
|
||||
save_item(NAME(m_ack_state));
|
||||
save_item(NAME(m_rts_state));
|
||||
save_item(NAME(m_inp_mux));
|
||||
save_item(NAME(m_led_data));
|
||||
}
|
||||
|
@ -183,7 +186,10 @@ void leo_state::unk_w(u8 data)
|
|||
|
||||
void leo_state::exp_rts_w(int state)
|
||||
{
|
||||
// NAND with ACK-P (not used by chesscomputer?)
|
||||
// recursive NAND with ACK-P
|
||||
if (state && m_ack_state)
|
||||
m_expansion->ack_w(m_ack_state);
|
||||
m_rts_state = state;
|
||||
}
|
||||
|
||||
|
||||
|
@ -225,8 +231,11 @@ void leo_state::p5_w(u8 data)
|
|||
// d3: NAND with STB-P
|
||||
m_stb->in_w<1>(BIT(data, 3));
|
||||
|
||||
// d5: expansion ACK-P
|
||||
m_expansion->ack_w(BIT(data, 5));
|
||||
// d5: expansion ACK-P (recursive NAND with RTS-P)
|
||||
int ack_state = BIT(data, 5);
|
||||
if (m_rts_state || !ack_state)
|
||||
m_expansion->ack_w(ack_state);
|
||||
m_ack_state = ack_state;
|
||||
|
||||
// d6,d7: chessboard led row data
|
||||
m_led_data[0] = (m_led_data[0] & 3) | (~data >> 4 & 0xc);
|
||||
|
|
|
@ -108,6 +108,8 @@ private:
|
|||
u8 p6_r();
|
||||
void p6_w(u8 data);
|
||||
|
||||
int m_ack_state = 0;
|
||||
int m_rts_state = 0;
|
||||
u8 m_inp_mux = 0;
|
||||
u8 m_led_data[2] = { };
|
||||
};
|
||||
|
@ -116,6 +118,8 @@ void ren_state::machine_start()
|
|||
{
|
||||
m_out_lcd.resolve();
|
||||
|
||||
save_item(NAME(m_ack_state));
|
||||
save_item(NAME(m_rts_state));
|
||||
save_item(NAME(m_inp_mux));
|
||||
save_item(NAME(m_led_data));
|
||||
}
|
||||
|
@ -200,7 +204,10 @@ u8 ren_state::control_r()
|
|||
|
||||
void ren_state::exp_rts_w(int state)
|
||||
{
|
||||
// NAND with ACK-P (not used by chesscomputer?)
|
||||
// recursive NAND with ACK-P
|
||||
if (state && m_ack_state)
|
||||
m_expansion->ack_w(m_ack_state);
|
||||
m_rts_state = state;
|
||||
}
|
||||
|
||||
|
||||
|
@ -243,8 +250,11 @@ void ren_state::p5_w(u8 data)
|
|||
// d3: NAND with STB-P
|
||||
m_stb->in_w<1>(BIT(data, 3));
|
||||
|
||||
// d5: expansion ACK-P
|
||||
m_expansion->ack_w(BIT(data, 5));
|
||||
// d5: expansion ACK-P (recursive NAND with RTS-P)
|
||||
int ack_state = BIT(data, 5);
|
||||
if (m_rts_state || !ack_state)
|
||||
m_expansion->ack_w(ack_state);
|
||||
m_ack_state = ack_state;
|
||||
|
||||
// d0: power-off on falling edge
|
||||
m_expansion->pw_w(data & 1);
|
||||
|
|
Loading…
Reference in a new issue