Main > Main Forum
MAME Driver Patch for Hardware Gear Shift Support
(1/8) > >>
Dmod:
I created a simple driver patch to incorporate use of a Happ 2-position (High/Low) Speed Shifter for games like pole position, outrun, and spy hunter, whose drivers, by default, use a single keypress to toggle the gear shift position.

The patch is attached below.  I'm releasing it here in case it may be of benefit to others.  It was created using the current drivers in Mame v0127 but it is likely useful for other versions as well.

HOW TO USE IT

This file can be used to modify the driver files in the main MAME distribution prior to compilation.  A simple way to use the patch is to apply it using HeadKaze's excellent Mame Compiler front end which can be found by searching the archives.  The Happ 2-position speed shifter uses only one switch.  The state of the switch controls the gear selection.  The modified drivers expect that "High Gear" is selected when the switch is closed (or for keyboards, when the button is pressed).  Otherwise "Low Gear" is selected.  For games which use "Forward" and "Reverse" gears, the "High Gear" position is mapped to "Reverse".  For each ROM file, you will need to configure your ingame options to map the "Gear Shift" input to your shift controller.

WHAT IT DOES

The patch modifies a number of driver files which use the "PORT_TOGGLE" macro for a single button gear shift controller.  The modified driver files and associated roms are listed below.  The PORT_TOGGLE macro is removed and PORT_NAME is modified to indicate "Gear Shift/Hi" or "Gear Shift/Reverse" to indicate the expected state of the shifter when the button is pressed or the switch is closed.  When the button is not pressed, the gear shifter will operate in the opposite state.  On some drivers, the port behavior is modified from ACTIVE_HIGH to ACTIVE_LOW (or vice-versa) so that the behavior of the gearshift button is consistent across all the modified drivers.

MODIFIED DRIVERS AND ROMS

changela.c       changela
chqflag.c        chqflag
gaelco2.c        wrally2
gaelco3d.c       speedup
grchamp.c    grchamp
mcr3.c           powerdrv, spyhunt, turbotag
mw8080bw.c       280zzzap, lagunar
namcos2.c        finallap, finallap3
overdriv.c       overdriv
polepos.c        polepos, topracra, polepos2
seagorun.c       outrun, toutrun
sega32.c         radr, slipstrm
segaybd.c        pdrift
turbo.c          turbo
tx1.c            buggybjr, tx1
undrfire.c       cbombers
wecleman.c       hotchase, wecleman
wrally.c         wrally
Jakester:
Does anyone have this patch file?  I was trying to download it and it says the file can't be read...or something like that. it sounds like the source file was removed on the web server.

Thanks!
Jakester:
nevermind I found it on another computer I have.  If anyone wants it posted let me know.
Dmod:
Hope it works for you.  If you have any problems with it, let me know. 
cmoses:
I am not familar with this function.  Does it show on the screen what position the stick is in?  Any pictures?
Navigation
Message Index
Next page

Go to full version