Previous Thread
Next Thread
Print Thread
#120253 12/29/21 09:47 PM
Joined: Oct 2020
Posts: 17
Likes: 3
MrBogi Offline OP
Member
OP Offline
Member
Joined: Oct 2020
Posts: 17
Likes: 3
So, I've been trying to come up with some way that "I" can contribute to MAME. I'm a decent coder but currently suck at anything complex in C/C++.

So I was poking around and noticed that some arcade games have the neat dip switch block in the dip switch settings and some do not. I traced this to the fact that the ones that did not have it don't have the "PORT_DIPLOCATION" lines in the source code.

So my question is... is it worth my time to start looking through the drivers and adding the "PORT_DIPLOCATION" where I can find the manuals that show the correct settings?

If the answer is Yes... then is there a standard repository for the arcade manuals that an average joe schmuck like me can access to verify the settings? smile

If the answer is No... then I'll keep thinking about what else I can do smile

Joined: Jul 2001
Posts: 101
Likes: 1
R
Senior Member
Offline
Senior Member
R
Joined: Jul 2001
Posts: 101
Likes: 1
https://www.crazykong.com/manuals/

Good selection of manuals.

1 member likes this: MrBogi
Joined: Apr 2006
Posts: 731
Senior Member
Offline
Senior Member
Joined: Apr 2006
Posts: 731
Originally Posted by Reznor007
https://www.crazykong.com/manuals/

Good selection of manuals.

Keep in mind if you were go down that route, you need to not only get manual defaults, but be able to test each one to verify their function. Manuals have been known to be incorrect, different versions may have different defaults and or function with their DIPs or even a protection check or missing emulation might account for even more differences. All that takes research and time so one can never assume.




Joined: Oct 2020
Posts: 17
Likes: 3
MrBogi Offline OP
Member
OP Offline
Member
Joined: Oct 2020
Posts: 17
Likes: 3
I guess I was looking to basically turn this:

PORT_START("DSW1")
PORT_DIPNAME( 0x03, 0x03, "Difficulty?" )
PORT_DIPSETTING( 0x03, "Easy?" )
PORT_DIPSETTING( 0x02, "Medium?" )
PORT_DIPSETTING( 0x01, "Hard?" )
PORT_DIPSETTING( 0x00, "Hardest?" )
PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) )
PORT_DIPSETTING( 0x04, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x08, 0x00, DEF_STR( Cabinet ) )
PORT_DIPSETTING( 0x00, DEF_STR( Upright ) )
PORT_DIPSETTING( 0x08, DEF_STR( Cocktail ) )
PORT_DIPNAME( 0x10, 0x10, "High Score" )
PORT_DIPSETTING( 0x00, "0" )
PORT_DIPSETTING( 0x10, "10000" )
PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) )
PORT_DIPSETTING( 0x20, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0xc0, 0xc0, DEF_STR( Lives ) )
PORT_DIPSETTING( 0x00, "1" )
PORT_DIPSETTING( 0xc0, "3" )
PORT_DIPSETTING( 0x80, "5" )
PORT_DIPSETTING( 0x40, "7" )

into something like this (may not be correct, just an example):

PORT_START("DSW1")
PORT_DIPNAME( 0x03, 0x03, "Difficulty?" ) PORT_DIPLOCATION("SW1:8,7")
PORT_DIPSETTING( 0x03, "Easy?" )
PORT_DIPSETTING( 0x02, "Medium?" )
PORT_DIPSETTING( 0x01, "Hard?" )
PORT_DIPSETTING( 0x00, "Hardest?" )
PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:6")
PORT_DIPSETTING( 0x04, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0x08, 0x00, DEF_STR( Cabinet ) ) PORT_DIPLOCATION("SW1:5")
PORT_DIPSETTING( 0x00, DEF_STR( Upright ) )
PORT_DIPSETTING( 0x08, DEF_STR( Cocktail ) )
PORT_DIPNAME( 0x10, 0x10, "High Score" ) PORT_DIPLOCATION("SW1:4")
PORT_DIPSETTING( 0x00, "0" )
PORT_DIPSETTING( 0x10, "10000" )
PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) PORT_DIPLOCATION("SW1:3")
PORT_DIPSETTING( 0x20, DEF_STR( Off ) )
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
PORT_DIPNAME( 0xc0, 0xc0, DEF_STR( Lives ) ) PORT_DIPLOCATION("SW1:2,1")
PORT_DIPSETTING( 0x00, "1" )
PORT_DIPSETTING( 0xc0, "3" )
PORT_DIPSETTING( 0x80, "5" )
PORT_DIPSETTING( 0x40, "7" )

so I wasn't planning on changing any "defaults" was just hoping to add the locations so the switch block would show up...

Joined: Feb 2004
Posts: 2,305
Likes: 26
Very Senior Member
Online Content
Very Senior Member
Joined: Feb 2004
Posts: 2,305
Likes: 26
Well, you can do it if you want, just make sure you have good references and don’t make assumptions based on bit order.

Joined: Oct 2020
Posts: 17
Likes: 3
MrBogi Offline OP
Member
OP Offline
Member
Joined: Oct 2020
Posts: 17
Likes: 3
Yeah, that goes to my question in SB the other day and why I was hoping for manuals smile

I found two games in the same driver (downhill & 500gp in namcos23.cpp) that actually had a service mode that reflected the switch order on screen. I guess I would call that a good reference. I haven't checked the other games in that driver yet.

But I do understand the need for accuracy and won't submit anything that I wasn't at least reasonably sure on. I can include my reasoning in the pull requests if you want.

For something like that would you prefer one PR per driver file or one PR for a batch of driver files?

Joined: Feb 2004
Posts: 2,305
Likes: 26
Very Senior Member
Online Content
Very Senior Member
Joined: Feb 2004
Posts: 2,305
Likes: 26
Small-ish batches is best – if there’s too much unrelated stuff at a time it’s harder to review. Doesn’t need to be one file at a time though, you can batch a few up. Keep polarity in mind as well as positions. And yeah, games that show DIP switch state on the screen are a good place to start.

Some of my early-ish contributions were DIP switch locations. I actually added the support for polarity flags in DIP switch locations. I think Nintendo games were the first ones with active-high DIP switches.

1 member likes this: MrBogi

Link Copied to Clipboard
Who's Online Now
2 members (Golden Child, AJR), 19 guests, and 1 robot.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics9,018
Posts118,430
Members5,010
Most Online890
Jan 17th, 2020
Forum Host
These forums are hosted by www.retrogamesformac.com
Forum hosted by www.retrogamesformac.com