Implementing DMC pop reducer on a real NES/Famicom

This is an archive of a topic from NESdev BBS, taken in mid-October 2019 before a server upgrade.
View original topic
Implementing DMC pop reducer on a real NES/Famicom
by on (#25359)
Is this actually possible to do because the Turtles 2 arcade game's popping gets really annoying.

by on (#25360)
DMC pop reducer just means take out the write to $4011 in the music engine. Game Genie should be able to do this.

by on (#25382)
Of course, the codes will be game specific right? And what do mean wright $4011? Use a hex editor to set adress to $0000?

by on (#25390)
You'd probably overwrite the opcode, changing the STA $4011 to a BIT $4011. First do it in a hex editor, then convert it to a Game Genie code.

by on (#25396)
tepples wrote:
You'd probably overwrite the opcode, changing the STA $4011 to a BIT $4011. First do it in a hex editor, then convert it to a Game Genie code.


what program do I use to overwrite the opcode, changing the STA $4011 to a BIT $4011? And how do I use a hex editor like Hex Workshop to convert it to a GG code?

by on (#25402)
NotTheCommonDose wrote:
tepples wrote:
You'd probably overwrite the opcode, changing the STA $4011 to a BIT $4011. First do it in a hex editor, then convert it to a Game Genie code.

what program do I use to overwrite the opcode, changing the STA $4011 to a BIT $4011?

To my knowledge, there is no program that will automatically scan a ROM and make codes for you. You will need to trace through the assembly language code of the game using an NES debugger that runs as part of an emulator on the PC. For example, on FCE Ultra, you'd set a write breakpoint on $4011, and then find the instruction that does this write. You have to know 6502 assembly language for this to work.

Quote:
And how do I use a hex editor like Hex Workshop to convert it to a GG code?

You figure out the address of the 6502 instruction, then you use a Game Genie encoder to replace the store with a BIT instruction, whose opcode is $2C.

by on (#25403)
Would replacing the STA with a TOP opcode be safer, in terms of keeping the flags intact?

by on (#25404)
Mednafen wrote:
Would replacing the STA with a TOP opcode be safer, in terms of keeping the flags intact?


Flags? I barely know what an "opcode" is. Operation code?

by on (#25405)
Mednafen wrote:
Would replacing the STA with a TOP opcode be safer, in terms of keeping the flags intact?

Wouldn't replacing STA $4011 with STA $4018 or NOPing it (loose two CCs) be even better?

NotTheCommonDose wrote:
Flags? I barely know what an "opcode" is. Operation code?

Replace all store operations (STA, STX, STY) with something. (Hopefully they the code doesn't do indexed or RMW operations on registers or use pointers to the register.)

in a hex editor change all:
8D1140 => 8D1840
8E1140 => 8E1840
8C1140 => 8C1840

by on (#25406)
kyuusaku wrote:
Mednafen wrote:
Would replacing the STA with a TOP opcode be safer, in terms of keeping the flags intact?

Wouldn't replacing STA $4011 with STA $4018 or NOPing it (loose two CCs) be even better?

NotTheCommonDose wrote:
Flags? I barely know what an "opcode" is. Operation code?

Replace all store operations (STA, STX, STY) with something. (Hopefully they the code doesn't do indexed or RMW operations on registers or use pointers to the register.)

in a hex editor change all:
8D1140 => 8D1840
8E1140 => 8E1840
8C1140 => 8C1840


I don't the other mumbo jumbo but it worked! Hex editing is all I can do at this point do to lack of all assembly knowledge. Did you people go to compter school or something?

by on (#25407)
NotTheCommonDose wrote:
Did you people go to compter school or something?

Personally, yes, but they didn't teach me much! Sometimes I wonder how people here know what they know, this is easily the smartest place I've found on the internet.

by on (#25408)
It probably doesnt matter now, but here are some game genie codes.

I couldnt get the game genie to block writes to 4011 directly (I think it automatically adds 0x8000 to the address), so I used it to alter the data value queried from those addresses.

I added a breakpoint in FCEU whenever 4011 was written and was able to view its value and where it was being queried from.

The addresses were C941,C945,C949,C94D,C951

So in an emulator, adding ALL these game genie codes seemed to get rid of the pops:
AAGGOP
AAGGSP
AAGKOP
AAGKSP
AAIGOP

I dont think you can enter more than 2 codes on a real NES though.

Al

by on (#25409)
albailey wrote:
It probably doesnt matter now, but here are some game genie codes.

I couldnt get the game genie to block writes to 4011 directly (I think it automatically adds 0x8000 to the address), so I used it to alter the data value queried from those addresses.

I added a breakpoint in FCEU whenever 4011 was written and was able to view its value and where it was being queried from.

The addresses were C941,C945,C949,C94D,C951

So in an emulator, adding ALL these game genie codes seemed to get rid of the pops:
AAGGOP
AAGGSP
AAGKOP
AAGKSP
AAIGOP

I dont think you can enter more than 2 codes on a real NES though.

Al


Thanks! This is for what game? You can't enter more than 3 codes on a real NES/Famicom.

by on (#25410)
kyuusaku wrote:
NotTheCommonDose wrote:
Did you people go to compter school or something?

Personally, yes, but they didn't teach me much! Sometimes I wonder how people here know what they know, this is easily the smartest place I've found on the internet.


Where did you actually start knowing NES Stuff besides CP School? I want to
be able to do this stuff as well.

by on (#25411)
Start reading the documents on the main site, that's what I did.

by on (#25413)
Its for Turtles 2.

NotTheCommonDose wrote:
albailey wrote:
It probably doesnt matter now, but here are some game genie codes.

I couldnt get the game genie to block writes to 4011 directly (I think it automatically adds 0x8000 to the address), so I used it to alter the data value queried from those addresses.

I added a breakpoint in FCEU whenever 4011 was written and was able to view its value and where it was being queried from.

The addresses were C941,C945,C949,C94D,C951

So in an emulator, adding ALL these game genie codes seemed to get rid of the pops:
AAGGOP
AAGGSP
AAGKOP
AAGKSP
AAIGOP

I dont think you can enter more than 2 codes on a real NES though.

Al


Thanks! This is for what game? You can't enter more than 3 codes on a real NES/Famicom.

by on (#25418)
You can enter 6 codes if you use 2 Game Genies, but some games are unstable or don't work at all.