Does the enabling of the /WAIT signal slowdown the V9958?

Page 2/3
1 | | 3

Par msxegor

Master (183)

Portrait de msxegor

27-12-2010, 09:38

When i turbo-modified my old yamaha, i used wait inserted _AFTER_ VDP access. 9938 (and 9958 i guess) is fast enough to accept data from 10-11 mhz Z80, but internal VRAM data pipeline seems to be slow, the worst case BTW is VRAM reading. I guess if you want minimum overhead wait insertion should be like this: end of VDP access starts delay clock, but wait is not asserted until Z80 fetches in or out opcode.

Par sd_snatcher

Prophet (3134)

Portrait de sd_snatcher

28-12-2010, 00:30

but z80 sets /iorq + /wr or /rd + adress on the falling edge of t1 cycle cycle.
and samples wait line at the falling edge of t2 .

so there is one cycle of cpu clk : from falling t1 to falling t2 to do adress decode + 130ns of wait delay.

typically you may put 30ns for logic of decode 30 ns for wires delay and 130ns=190ns , so te wait signal cant be used above 5.xx Mhz

I configured the S1985 to generate a forced waitstate (*1) and each VDP I/O, so that should be enough for the CPU to receive the V9958's /WAIT at the right time. But unfortunately that didn't solved the problem.

*1: S1985 datasheet, pg-9: Pull X7 low on RESET to enable a waitstate after each VDP I/O.

Par sd_snatcher

Prophet (3134)

Portrait de sd_snatcher

28-12-2010, 00:33

@msxegor

I enabled the S1985 waitstate for VDP I/O (see my previous msg), but it didn't solved the problem. Curiously enough, the V9958's /WAIT signal seems not to be needed with a Z80@5.37MHz: The VDP seems to be able to couple with the speed just fine without that.

Par Leo

Paragon (1236)

Portrait de Leo

28-12-2010, 12:21

i wonder if the wait signal was meant to be used only with the command high speed move cpu to vram through the data register r#44
there is one thing i wonder alsoin your boot up sequence , i believe that :
1 the msx boot without the bit that enable /WAIT,you have not modified roms ?
2 but then you set it manually
3 so the vdp init has to be redone again
or do you boot turbo off ?

the other option is to replace the z80 by a z180 with dma .... z180 has 3 T cycles while z80 has 4 , you gain 25%more nad it has software programable wait states 0-3 ws generator

Par msxegor

Master (183)

Portrait de msxegor

28-12-2010, 13:12

@msxegor

I enabled the S1985 waitstate for VDP I/O (see my previous msg), but it didn't solved the problem. Curiously enough, the V9958's /WAIT signal seems not to be needed with a Z80@5.37MHz: The VDP seems to be able to couple with the speed just fine without that.

This one (i believe) is useful only for the case of external VDP clock (with genlock). At least Yamaha YIS-805 uses this option only with video intarface connected. And it's simply not enough at speeds over 6 mhz.

Par sd_snatcher

Prophet (3134)

Portrait de sd_snatcher

28-12-2010, 21:54


1 the msx boot without the bit that enable /WAIT,you have not modified roms ?
2 but then you set it manually

I patched the ROMs, including the BIOS and the MSX bootlogo code.

3 so the vdp init has to be redone again
or do you boot turbo off ?

I boot with the turbo enabled.

the other option is to replace the z80 by a z180 with dma .... z180 has 3 T cycles while z80 has 4 , you gain 25%more nad it has software programable wait states 0-3 ws generator

Probably the same deal will happen here: VRAM corruption, because the Z180 is faster than the Z80.

Par msxegor

Master (183)

Portrait de msxegor

29-12-2010, 11:34


Probably the same deal will happen here: VRAM corruption, because the Z180 is faster than the Z80.

Exactly! I'm experimenting with Z180 "accelerator" and some (minor) screen corruption is visible. But Z180 can insert up to 3 additional wait states when accessing IO ports - so up to about 6 mhz is ok with thîse waits enabled. The problem with Z180 is that it does not support Z80 "unofficial" instructions like loading IX/IY halves. I don't know how much MSX soft uses them but there is at least one good program that does.

Par Leo

Paragon (1236)

Portrait de Leo

29-12-2010, 12:42

about that z180 accel do you use plcc68 to dil adapter ?
about ixh ixl , r800 does not implemented them neither.

Z280 implemented them plus R800 ones and has a feture to work internally double or quadruble the bus freq 3.5MHz external and 7MHz internal
the only problem with Z280 is that you need an extra 373 latch externally to deal with multiplexed Address data on bit 0-7.

how far can you push in MHz the z180 with 3 wait states

Par msxegor

Master (183)

Portrait de msxegor

29-12-2010, 14:08

Unfortunately, i have only 6 mhz z180 right now (and there is BIG problem obtaining modern Z8S180 - no seller has them in stock here in Russia) - so, 6,144 mhz yet, screen ok with 3 waits.
The accel is more than adapter - it has built-in fast SRAM for the case i get faster CPU and a small PLD to decode it.
BTW z280 in MSX will be great. I own one chip, so maybe will try it out Smile

Par Leo

Paragon (1236)

Portrait de Leo

30-12-2010, 09:02

i have obtained z8s180 33Mhz from singapore at around 4-5 usdollars the same for z280 .
the parts are quite recent 1995 for the z280 and 2007 for z8s180.
if you want i can send you a couple of each for free ?
one thing interesting inthe z8s180 is the CSI/O interface , clocked serial interface ,it fits exactly
the SPI or SD card interface! so high speed dma SD interface is then possible with this part.

Page 2/3
1 | | 3