WHDLoad MantisBT - Turrican2
View Issue Details
0001196Turrican2[All Projects] Generalpublic2006-01-27 16:582009-07-09 23:26
ReporterCHRKUM 
Assigned ToWepl 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
MachineA1200
CPU68060 + PPC
CPUSpeed60
ChipSetAGA
GFXCardBlizzardVision PPC
ChipMem2 MB
FastMem128 MB
WorkbenchOS 3.9
KickROM40 - Kick 3.1
KickSoftNone
WHDLoad16.5
importedyes
Summary0001196: Turrican 2: Second Joypad Button don`t work, if i start the game from Floppy it
DescriptionInstall: Turrican 2 (Factor 5/Rainbow Arts) http://whdload.de/games/Turrican2.html
GameVersion: english,pal
SlaveVersion: Newest

Second Joypad Button don`t work, if i start the game from Floppy it works.
I try 3 Joypad`s. The second button is for the Wappon that goes from
the Middle to the left and to the right and destroy all (small) enemys on
the Screen. You have 3 of this on Game start.
The other Wappon that comes if i press both Buttons on the
same time don`t work too. This is this heavy one that is good for big
enemys. From this you have only one/Life.
Tagssupport 2nd fire button
related to 0002113closed Wepl When you press the second joystick/gamepad button, its like it the game think 
Attached Files? Turrican2.Slave (2,340) 2009-06-15 20:43
https://www.whdload.de/mantis/file_download.php?file_id=21&type=bug

Notes
(0000195)
Wepl   
2009-04-20 00:46   
is that problem still present with the latest slave/install version?
(0000226)
CHRKUM   
2009-04-20 22:19   
Yes, its still with the "newest" downloadable version from www.whdload.de
(0000248)
Wepl   
2009-04-21 00:02   
The only idea I have is that it's connected to some custom registers init.
Will try to check this.

(0000645)
Wepl   
2009-04-24 22:11   
I've tried 'Honey Bee' and 'tecnoplus' pads with disk and cdtv version of turrican2, second button is working in all of them.
What joypad are you trying?
Special QuitKey set?
(0000704)
CHRKUM   
2009-04-25 11:52   
My Version have Disk.1 1.069.768 Bytes and none Disk.2 seems that
version available free for download.

The Jopads are connected like a Mouse,
switches:
Pin 5 to GND
Pin 6 to GND
Pin 9 to GND

Not such CD32 Serial stuff.

One of them have only 2 Firebuttons.
I remember for the 2. and 3. Fire Button you must write
to the CC in front of every read out the follow:

POKEB &hDFF034, (PEEKB(&hDFF016) OR &b11110000)

That means readout 0xDFF016 or it with 1111000 and write it to 0xDFF034.
Without it you can`t get the state of it.

Maybe this help to find out where is the problem located.


just:

SLAVE=turrican2.slave
PRELOAD
;NTSC
ChipNoCache
(0000710)
Wepl   
2009-04-25 20:12   
There are only two disk versions supported, this has very unlikely to do anything with this issue.
I know the difference between a cd32 joypad and a two button joystick. The tecnoplus is not a cd32 joypad. What are the three joypads you have tried?
(0000768)
CHRKUM   
2009-04-26 11:00   
okay, was long long time ago don`t know why there is only disk one.
But there are no access fault while game and the game starts, not like
unsupported versions.

One Atari joypad, one of a Sega and a red Amiga Joystik - don`t know its name
its away already.
The connections are as i sayed and works from disk without any problems.
(0001169)
Wepl   
2009-06-02 23:39   
I close this. If anybody can reproduce it let me know or reopen it.
(0001197)
Wepl   
2009-06-13 11:27   
Date: Wed, 10 Jun 2009 13:00:33 +0200
From: Chr
To: Bert Jahn
Subject: Re: : Turrican 2: Second Joypad Button don`t work, if i start the game from Floppy it

Hallo Bert,

Am 09.06.09 schriebst Du:
> On Thu, 4 Jun 2009, Chr wrote:
>
>>>> of course you cant reproduce it if you use a Joystick. The most
>>>> Joystick has a Microswitch, if this switched you have 0 Ohm between
>>>> the Pin and GND. A Joypad has a similar system like a Remote Control
>>>> there are about 200 Ohm between Pin and GND. If i connect a Mouse to
>>>> Joyport and use the second Key it works, because its a Microswitch.
>>>> I send you an Example in Basic, its needet to "activate" Button 2
>>>> and 3. The Game(s) without whdload do it fine. I think its maybe a
>
> schick mir bitte mal das beispiel

POKEB &hDFF034, (PEEKB(&hDFF016) OR &b11000000) REM Fire2+3 aktieren
delay 1 REM warten
c%=PEEKW(&hDFF016) REM auslesen

Das delay 1 sollte man im spiel natürlich nicht verwenden, da reicht ein kürzerer
Zeitraum.

>>>> Speed related problem(relocation of the code to fastmem for
>>>> example). You need a Delay between the activation/loading than there
>
> normalerweise gibt es da keine aktivierung, die eingänge werden von
> spielen die Kein joypad unterstützen immer digital abgefragt, da wird
> auch keine messung o.ä. angestossen sondern einfach nur ausgelesen was
> paula meldet.

Dann würde es ohne WHD nicht funktionieren, tut es jedoch.
Lässt man das aktivieren weg kommen keine werte mehr auf dem DFF016 register an(120R), bei 0 Ohm
schon.

>>>> is enougt Voltage to recognize joypads. If you don`t have this Delay
>>>> you may recognize 0 Ohm but not 200 Ohm. If i hold down the the 2 or
>>>> 3. Button for some seconds the special wappons fire but its useless
>>>> after some seconds. I tryed too Turrican 1 it has the same Problem.
>
> da hängt ein kondensator an der leitung dran wie man in den specs
> nachlesen kann der natürlich umgeladen werden muss, für die analog
> messung sind allerdings 470k widerstand vorgesehen
>
>>> das ist alles schön und gut. meine joypads gehen aber. du hast mir
>>> nicht gesagt was du für joypads getestet hast.
>>> ich weiss nicht was ich da noch tun soll?
>>
>> Dann haben deine joypads entweder nicht die gleiche art von
>> "schaltern" wie in einer Fernbedienung oder ähnliche aber spezielle
>> mit einem geringeren Widerstand. Die Sega haben 120 Ohm der Atari
>> sogar 600 Ohm. Wenn du weniger hast kannst du einen entsprechenden
>> Reihenwiderstand einfügen für die Reproduktion. Es braucht aber
>> einen schnellen Prozessor 68060 mit mindestens 50 MHZ. Da es um ein
>> Delay geht welches warscheinlich aus NOPs etc. besteht. Sonst würde
>
> soweit ich weiss gibt es da kein delay, die programme lesen einfach
> aus was in potinp drin steht
>
>> es ja auch im Fastram etc. sauber ablaufen. In diversen
>> Hardwaredokumentationen ist das vorgehen zum auslesen des 2. und 3.
>> Feuerknopfs beschrieben. Es muss nur entsprechend "Systemkonform"
>
> kannst du mir diese Hardwaredokumentationen mal zu kommen lassen?

Weiss nichtmehr welche es nun war aber hier ist z.b. was:

If you set the output enable for any pin to a 1, the Amiga disconnects the
potentiometer control circuitry from the port, and configures the pin for
output. The state of the data bit controls the logic level on the output
pin. This register must be written to at the POTGO address, and read
from the POTGOR address. There are large capacitors on these lines, and
it can take up to 300 microseconds for the line to change state.

To use the entire register as an input, sensing the current state of the
pot pins, write all 0s to POTGO. Thereafter you can read the current
state by using read-only address POTGOR. Note that bits set as inputs
will be connected to the proportional counters (See the description of the
START bit in POTGO).

http://gega.homelinux.net/AmigaDevDocs/hard_8.html

>> gemacht werden dann funktioniert das auch. Leider kenne ich die
>> Modellnummern der Joypads nicht, deswegen hab ich ein Bild
>> angehangen. Das Pinout und die Elektrischen werte habe ich schon
>> geschildert, also weiss ich nicht wie das helfen soll.
(0001198)
Wepl   
2009-06-13 12:02   
(Last edited: 2009-06-13 15:27)
I don't see anything about resistors on the button line here http://pinouts.ru/connector/9_pin_D-SUB_male_connector.shtml do you have any resource regarding this?

you write a byte to potgo which is word register! this will write a random (mirror) value to the low byte of potgo!

the correct basic example would be probably doing this at start of each vbi:
c%=PEEKW(&hDFF016) REM auslesen
POKEW &hDFF034, hc001 REM rücksetzen der werte

please test the attached updated slave.
I changed the game to write $c001 instead of $c000 to potgo after each read from potinp

(0001216)
CHRKUM   
2009-06-14 21:32   
there is no resistor in the button line. the button is a resistor inself.
have you never opened a Remote control for a TV?
There are the Board with Zn contacts then there are such rubber keys, they
have about 200 Ohm. Its simply no Metal.

Word, i know but this should not touch the other byte part. i recheck that.
But why do you write direct values to DFF034, that activates for example
the Menu.

It takes still about 3 seconds of pressing, but there is a difference.
After the first wappon fire the others follow immediate while holding the
button.
i think it should set in front of every read and a low delay between ;)
(0001222)
Wepl   
2009-06-15 20:51   
the custom chip bus is 16 bit wide and will always read/write words, it's impossible to write a byte...
why do you want read potgo before writing it? readable are only the dat bits anyway! for system conform coding you have to use potgo.ressource!
what Menu?

I have changed the routine to toggle between input and output mode, please test attached slave.
(0001225)
CHRKUM   
2009-06-15 21:43   
okay thanks for the info.
I read the actual state OR it with the state i need, write it and then read it out.
this works since years, i use a amiga as an security system.

With your basic example the Workbench menu is activated because of
POKEW &hDFF034, hc001.

Thanks, it works now like original. can you do the same for Turrican 1?
(0001227)
Wepl   
2009-06-16 00:01   
(Last edited: 2009-06-16 00:05)
I will remember it for Turrican 1, but I'm reworking this for some years now, a release date is not yet in sight...

the updated install has been released.

(0001306)
Wepl   
2009-07-09 23:26   
hi CHRKUM, can you please try if the modified slave attached to #2113 still works for you?

Issue History
2009-04-10 00:50administratorNew Issue
2009-04-10 00:50administratorStatusnew => assigned
2009-04-10 00:50administratorAssigned To => Kyzer
2009-04-10 00:50administratorMachine => A1200
2009-04-10 00:50administratorCPU => 68060 + PPC
2009-04-10 00:50administratorCPUSpeed => 60
2009-04-10 00:50administratorChipSet => AGA
2009-04-10 00:50administratorGFXCard => BlizzardVision PPC
2009-04-10 00:50administratorChipMem => 2 MB
2009-04-10 00:50administratorFastMem => 128 MB
2009-04-10 00:50administratorWorkbench => OS 3.9
2009-04-10 00:50administratorKickROM => 40 - Kick 3.1
2009-04-10 00:50administratorKickSoft => None
2009-04-10 00:50administratorWHDLoad => 16.5
2009-04-10 00:50administratorimported => yes
2009-04-20 00:23WeplAssigned ToKyzer => Wepl
2009-04-20 00:46WeplNote Added: 0000195
2009-04-20 00:46WeplStatusassigned => feedback
2009-04-20 22:19CHRKUMNote Added: 0000226
2009-04-20 23:53WeplTag Attached: support 2nd fire button
2009-04-21 00:02WeplNote Added: 0000248
2009-04-21 00:02WeplNote Edited: 0000248
2009-04-24 22:11WeplNote Added: 0000645
2009-04-25 11:52CHRKUMNote Added: 0000704
2009-04-25 20:12WeplNote Added: 0000710
2009-04-26 11:00CHRKUMNote Added: 0000768
2009-06-02 23:39WeplNote Added: 0001169
2009-06-02 23:39WeplStatusfeedback => closed
2009-06-02 23:39WeplResolutionopen => unable to reproduce
2009-06-13 11:27WeplNote Added: 0001197
2009-06-13 11:27WeplStatusclosed => feedback
2009-06-13 11:27WeplResolutionunable to reproduce => reopened
2009-06-13 12:02WeplNote Added: 0001198
2009-06-13 12:20WeplNote Edited: 0001198
2009-06-13 12:22WeplNote Edited: 0001198
2009-06-13 12:32WeplNote Edited: 0001198
2009-06-13 12:45WeplNote Edited: 0001198
2009-06-13 15:25WeplFile Added: Turrican2.Slave
2009-06-13 15:27WeplNote Edited: 0001198
2009-06-14 21:32CHRKUMNote Added: 0001216
2009-06-15 20:43WeplFile Deleted: Turrican2.Slave
2009-06-15 20:43WeplFile Added: Turrican2.Slave
2009-06-15 20:51WeplNote Added: 0001222
2009-06-15 21:43CHRKUMNote Added: 0001225
2009-06-16 00:01WeplNote Added: 0001227
2009-06-16 00:05WeplNote Edited: 0001227
2009-06-16 00:05WeplStatusfeedback => closed
2009-06-16 00:05WeplResolutionreopened => fixed
2009-07-06 22:08WeplRelationship addedrelated to 0002113
2009-07-09 23:26WeplNote Added: 0001306