nesdev.com
http://forums.nesdev.com/

VS Zapper info?
http://forums.nesdev.com/viewtopic.php?f=3&t=9917
Page 1 of 1

Author:  oRBIT2002 [ Wed Mar 13, 2013 8:45 am ]
Post subject:  VS Zapper info?

Someone told me in another thread that the Zapper that is connected to the VS Unisystem works in a different way than "usual" Zappers.
I can't find any documentation about this (except the info I got in that thread). Have I missed something? I've checked the wiki but nothing.. :/

Author:  Quietust [ Wed Mar 13, 2013 10:19 am ]
Post subject:  Re: VS Zapper info?

I'm not sure it was ever formally documented - the information I posted was from my own implementation (which works), and I either got that from another emulator or by reverse-engineering the code behind it.

Author:  oRBIT2002 [ Wed Mar 13, 2013 1:42 pm ]
Post subject:  Re: VS Zapper info?

So the $4016/$4017 registers on the VS-system (Zapper) is read 1-bit at a time (sort of how the MMC1-mapper works?). 7th read returns "sense" and 8th read returns "trigger" (all on bit 0 of course?).

I'm trying to write a "VS-Zapper-emulator" for my experimental "Duck Hunt (VS)"-hack but there's something I'm doing wrong.. Perhaps I've misunderstod the above information?

Does the Zapper leaves some kind of identification on these registers when connected?

Author:  lidnariq [ Wed Mar 13, 2013 2:15 pm ]
Post subject:  Re: VS Zapper info?

FCEU (yes, ancient) implements the Vs. System zapper as though it were a standard controller where
"start" is always pressed
"left" is whether the zapper is pointed at light
"right" is whether the trigger is pressed

For a de-VS-ifying patch to the ROM, I'd probably look for the place where the game has its joypad read function and replace that wholesale. (It appears to be at $84D5…$84F5)

edit: I am so good at 0-index vs 1-index.

Author:  Quietust [ Wed Mar 13, 2013 9:06 pm ]
Post subject:  Re: VS Zapper info?

lidnariq wrote:
FCEU (yes, ancient) implements the Vs. System zapper as though it were a standard controller where
"start" is always pressed
"left" is whether the zapper is pointed at light
"right" is whether the trigger is pressed


Actually, it's "up" (0x10) that's always pressed, not "start" (0x08).

Author:  tepples [ Thu Mar 14, 2013 7:19 am ]
Post subject:  Re: VS Zapper info?

Quietust wrote:
Actually, it's "up" (0x10) that's always pressed, not "start" (0x08).

There's a bit of confusion there. In some controller reading subroutines, A is $80 and Right is $01; in others, A is $01 and Right is $80. I edited the article not to impose any place value on the order of bits in the Vs. Zapper's report.

Author:  oRBIT2002 [ Thu Mar 14, 2013 1:43 pm ]
Post subject:  Re: VS Zapper info?

I finally got past the freezing part with my patch.. Still something wrong with the trigger however. Not everyday I code stuff based on "trial and error". :)

Author:  oRBIT2002 [ Thu Mar 14, 2013 11:35 pm ]
Post subject:  Re: VS Zapper info?

I suspect the SENSE-bit is inverted compared to the "normal" Zapper-bits. Can anyone confirm this?

Author:  lidnariq [ Fri Mar 15, 2013 12:53 am ]
Post subject:  Re: VS Zapper info?

FCEU 0.98.12 agrees with you.

Author:  zeroone [ Wed Jun 22, 2016 6:22 pm ]
Post subject:  Re: VS Zapper info?

@oRBIT2002 Is source code of MadNESs available?

Page 1 of 1 All times are UTC - 7 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/