Ninja tap

ページ 6/19
1 | 2 | 3 | 4 | 5 | | 7 | 8 | 9 | 10 | 11

By Danjovic

Champion (344)

Danjovic さんの画像

01-10-2022, 23:20

Well, it looks that openMSX replicates the behavior of the LS07 gates at pins 6,7. When these bits are LOW the reading of the pins is tied to zero,

// pin 6,7 input is ANDed with pin 6,7 output

And the code of the test program writes a Zero to pins 6,7

ld a,15
out (0a0h),a ; reg 15
ld a,80h                             
out (0a1h),a ; pins low   <-- LOOK HERE 
ld a,14
out (0a0h),a ; reg 14
in a,(0a2h)

The same for the check tap routine of DM system 2 driver

CHECK:	CALL	PORSEL   ; 
	INC	B          ; B = Max player number + 1
	AND	0C0H       ; A is state of port 15. 
	OUT	(0A1H),A	; 678=L  for both joystick ports (!)  <-- LOOK HERE
	EX	AF,AF'      ; save state of Reg15 with all output pins low
	
	LD	A,14        ; select register 14 
	OUT	(0A0H),A
	IN	A,(0A2H)    ; read state of joystick port
	AND	20H		    ; 7=H ?   return if bit is high (!) (shouldn't be forced high, its being driven low internally )
	RET	Z           ; if return here, A = state of pin 6, and B=B+1 from the function call
	

On a real MSX the Ninja TAP circuit is forcing a HIGH level on pin 7, that is the reason why the real hardware is behaving differently from the emulation.

That is the reason why the Ninja Tap circuit looks critical in respect to the use of a chip from the ACT series, that can source much more current than the LS gate inside the MSX can sink to maintain the level HIGH and be detected by the driver (and test program)

Mystery solved :)

By aoineko

Paragon (1145)

aoineko さんの画像

01-10-2022, 23:41

Manuel wrote:

On which real hardware was the Ninjatap and s_ntap.rom tested successfully?

On Jipe's original Ninja Tap.
I don't know other people that own one.

By Manuel

Ascended (19691)

Manuel さんの画像

01-10-2022, 23:55

I mean, on which machines?

By aoineko

Paragon (1145)

aoineko さんの画像

02-10-2022, 00:14

MSX turbo R at least.
I'll ask Jipe for more detail.

By sd_snatcher

Prophet (3677)

sd_snatcher さんの画像

02-10-2022, 00:38

Danjovic wrote:

I see two problems in the original circuit:

1) The diode D1 is inverted. @Jipe, can you please double-check if it was inverted on the circuit, or maybe a mistake when reverse engineering it?

2) The resistor R1 should not be present. The MSX General Purpose ports already have pull-up resistors on all input pins, and placing another resistor in parallel will cause the resistance to be too strong. Many MSX models have 4K7 pull-up resistors, so this will result in a 824 Ohms resulting resistance. Way too strong.

The Shinobi-Tap version fixed the diode direction, but the R1 resistor also should not be present, even if its value is now 4K7 instead of 1K.

By gdx

Enlighted (6449)

gdx さんの画像

02-10-2022, 00:45

sd_snatcher wrote:

The MSX General Purpose ports already have pull-up resistors on all input pins, and placing another resistor in parallel will cause the resistance to be too strong.

It is the opposite, it reduces the resistance.

By sd_snatcher

Prophet (3677)

sd_snatcher さんの画像

02-10-2022, 01:03

gdx wrote:
sd_snatcher wrote:

The MSX General Purpose ports already have pull-up resistors on all input pins, and placing another resistor in parallel will cause the resistance to be too strong.

It is the opposite, it reduces the resistance.

Correct. It was poorly phrased. What I meant was: the pull-up effect on the line will become too strong.

By Danjovic

Champion (344)

Danjovic さんの画像

02-10-2022, 04:47

1k//4k7 => ~5mA. Don't worry, there is a large margin left up to IOl max (40mA for 'ls07).

By Jipe

Paragon (1625)

Jipe さんの画像

03-10-2022, 12:57

I tested the ninja tap in the following MSX with MSX engine
Sony HB-F9P (S1985) ok port 1 and 2
Panasonic FS-A1F (S1985) ok port 1 and 2
Philips NMS 8280 (S3527) mod MSX2+ 4Mo ok port 1 and 2
VG 8235/00 (S3527) mod MSX2+ 1MB ok port 1 and 2
Yamaha CX5MII (S3527) mod MSX2 4Mo does not work port 1 and 2
on the CX5MII the ninja tap cannot work because there is a transistor on the input of trigger B

By Danjovic

Champion (344)

Danjovic さんの画像

03-10-2022, 18:25

Thanks Jipe.
The input circuit of the CX5MII is very peculiar as the transistors are acting like a switch in series with the input pins of Triggers on the msx engine (which are off during reset).
Nevertheless they add an extra voltage drop on the way of the ACT00 to win the bus contention and, as you mentioned, that explains the Ninja Tap did not worked in such machine

ページ 6/19
1 | 2 | 3 | 4 | 5 | | 7 | 8 | 9 | 10 | 11