partial support for sega driving simulator
This commit is contained in:
parent
5644e834fa
commit
f186046c98
|
@ -14,7 +14,7 @@ bool cfgLoadBool(const std::string& section, const std::string& key, bool def);
|
|||
void cfgSetVirtual(const std::string& section, const std::string& key, const std::string& value);
|
||||
bool cfgIsVirtual(const std::string& section, const std::string& key);
|
||||
|
||||
bool ParseCommandLine(int argc, char *argv[]);
|
||||
void ParseCommandLine(int argc, char *argv[]);
|
||||
|
||||
void cfgSetAutoSave(bool autoSave);
|
||||
bool cfgHasSection(const std::string& section);
|
||||
|
|
|
@ -86,7 +86,7 @@ static int showhelp()
|
|||
return 0;
|
||||
}
|
||||
|
||||
bool ParseCommandLine(int argc,char* argv[])
|
||||
void ParseCommandLine(int argc,char* argv[])
|
||||
{
|
||||
settings.content.path.clear();
|
||||
int cl=argc-2;
|
||||
|
@ -140,5 +140,4 @@ bool ParseCommandLine(int argc,char* argv[])
|
|||
arg++;
|
||||
cl--;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -236,7 +236,7 @@ bool loadFiles()
|
|||
|
||||
void saveFiles()
|
||||
{
|
||||
if (settings.naomi.slave)
|
||||
if (settings.naomi.slave || settings.naomi.drivingSimSlave)
|
||||
return;
|
||||
if (settings.platform.isConsole())
|
||||
sys_nvmem->Save(getRomPrefix(), "nvmem.bin", "nvmem");
|
||||
|
|
|
@ -853,7 +853,7 @@ private:
|
|||
|
||||
maple_naomi_jamma::maple_naomi_jamma()
|
||||
{
|
||||
if (!settings.naomi.slave)
|
||||
if (settings.naomi.drivingSimSlave == 0 && !settings.naomi.slave)
|
||||
{
|
||||
switch (settings.input.JammaSetup)
|
||||
{
|
||||
|
@ -1278,7 +1278,12 @@ void maple_naomi_jamma::handle_86_subcommand()
|
|||
|
||||
w8(0x00);
|
||||
w8(0xff); // in(4)
|
||||
w8(0xff); // in(5) bit0: 1=VGA, 0=NTSCi
|
||||
u8 v = 0xf9;
|
||||
if (settings.naomi.drivingSimSlave == 1)
|
||||
v |= 2;
|
||||
else if (settings.naomi.drivingSimSlave == 2)
|
||||
v |= 4;
|
||||
w8(v); // in(5) bit0: 1=VGA, 0=NTSCi
|
||||
w8(0xff); // in(6)
|
||||
|
||||
w32(0x00);
|
||||
|
|
|
@ -7083,6 +7083,31 @@ const Game Games[] =
|
|||
},
|
||||
nullptr,
|
||||
&clubkart_inputs,
|
||||
},
|
||||
{
|
||||
"sgdrvsim",
|
||||
nullptr,
|
||||
"Sega Driving Simulator",
|
||||
0x20000000,
|
||||
0x5508,
|
||||
"naomi2",
|
||||
M4,
|
||||
ROT0,
|
||||
{
|
||||
{ "ic8.bin", 0x00000000, 0x4000000, 0x3ef5e62f },
|
||||
{ "ic9.bin", 0x04000000, 0x4000000, 0x4edf67df },
|
||||
{ "ic10.bin", 0x08000000, 0x4000000, 0xa3b0f436 },
|
||||
{ "ic11.bin", 0x0c000000, 0x4000000, 0x200ad72c },
|
||||
{ "ic12.bin", 0x10000000, 0x4000000, 0x90d192a4 },
|
||||
{ "ic13.bin", 0x14000000, 0x4000000, 0xeed33acc },
|
||||
{ "ic14.bin", 0x18000000, 0x4000000, 0x349267e9 },
|
||||
{ "ic15.bin", 0x1c000000, 0x4000000, 0xacc0c039 },
|
||||
|
||||
{ "317-0502-jpn.ic3", 0, 0x800, 0x528ad9e7, Key },
|
||||
},
|
||||
nullptr,
|
||||
&drvsim_inputs,
|
||||
sgdrvsim_eeprom_dump,
|
||||
},
|
||||
//
|
||||
// Naomi 2 GD-ROM
|
||||
|
|
|
@ -654,4 +654,16 @@ static u8 kingrt66_eeprom_dump[] {
|
|||
0x00, 0x00,
|
||||
};
|
||||
|
||||
// network: alone
|
||||
static u8 sgdrvsim_eeprom_dump[] {
|
||||
0x47, 0xDA, 0x10, 0x42, 0x41, 0x41, 0x30, 0x09, 0x00, 0x1A, 0x01, 0x01, 0x01, 0x00, 0x11, 0x11, 0x11, 0x11,
|
||||
0x47, 0xDA, 0x10, 0x42, 0x41, 0x41, 0x30, 0x09, 0x00, 0x1A, 0x01, 0x01, 0x01, 0x00, 0x11, 0x11, 0x11, 0x11,
|
||||
0xB2, 0x69, 0x20, 0x20, 0xB2, 0x69, 0x20, 0x20, 0x44, 0x72, 0x76, 0x53, 0x69, 0x6D, 0x6D, 0x00, 0x05, 0x00,
|
||||
0x00, 0x00, 0x00, 0x1E, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF,
|
||||
0x00, 0x00, 0xFF, 0xFF, 0x44, 0x72, 0x76, 0x53, 0x69, 0x6D, 0x6D, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x1E,
|
||||
0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0xFF, 0xFF,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00,
|
||||
};
|
||||
|
||||
#endif /* CORE_HW_NAOMI_NAOMI_ROMS_EEPROM_H_ */
|
||||
|
|
|
@ -659,3 +659,41 @@ static InputDescriptors soulsurfer_inputs = {
|
|||
{ "PITCH", Full, 1, true },
|
||||
},
|
||||
};
|
||||
|
||||
static InputDescriptors drvsim_inputs = {
|
||||
{
|
||||
{ NAOMI_BTN0_KEY, "Turn R" },
|
||||
{ NAOMI_BTN1_KEY, "Turn L" },
|
||||
{ NAOMI_BTN2_KEY, "Shift 2" },
|
||||
{ NAOMI_BTN3_KEY, "Shift 3" },
|
||||
{ NAOMI_BTN4_KEY, "O/D Switch" },
|
||||
{ NAOMI_BTN5_KEY, "S-Brake" },
|
||||
{ NAOMI_BTN6_KEY, "IG-ON", 0, NAOMI_DOWN_KEY },
|
||||
{ NAOMI_BTN7_KEY, "IG-START", 0, NAOMI_LEFT_KEY },
|
||||
{ NAOMI_BTN8_KEY, "Shift 0", 0, NAOMI_BTN0_KEY },
|
||||
{ NAOMI_UP_KEY, "Horn" },
|
||||
{ NAOMI_DOWN_KEY, "Light 0" },
|
||||
{ NAOMI_LEFT_KEY, "Light 1" },
|
||||
{ NAOMI_RIGHT_KEY, "Light 2" },
|
||||
NAO_START_DESC
|
||||
NAO_BASE_BTN_DESC
|
||||
// P2 inputs:
|
||||
// BTN0 Shift 0
|
||||
// BTN1 Shift 1
|
||||
// BTN2 BELT
|
||||
// UP Washer
|
||||
// DOWN IG-ON
|
||||
// LEFT IG_START
|
||||
// RIGHT HAZARD
|
||||
// START WIPER-LO
|
||||
// Unknown:
|
||||
// STOP
|
||||
// WIPER-HI
|
||||
},
|
||||
{
|
||||
{ "Master", Full, 0 },
|
||||
{ "Accelerator", Half, 4 },
|
||||
{ "Brake", Half, 5 },
|
||||
{ "Clutch", Full, 1 },
|
||||
},
|
||||
};
|
||||
|
|
|
@ -391,7 +391,8 @@ bool NaomiNetworkSupported()
|
|||
"SPIKERS BATTLE JAPAN VERSION", "VIRTUAL-ON ORATORIO TANGRAM", "WAVE RUNNER GP", "WORLD KICKS",
|
||||
"F355 CHALLENGE JAPAN",
|
||||
// Naomi 2
|
||||
"CLUB KART IN JAPAN", "INITIAL D", "INITIAL D Ver.2", "INITIAL D Ver.3", "THE KING OF ROUTE66"
|
||||
"CLUB KART IN JAPAN", "INITIAL D", "INITIAL D Ver.2", "INITIAL D Ver.3", "THE KING OF ROUTE66",
|
||||
"SAMPLE GAME MAX LONG NAME-" // Driving Simulator
|
||||
};
|
||||
if (!config::NetworkEnable)
|
||||
return false;
|
||||
|
|
|
@ -27,15 +27,13 @@ int flycast_init(int argc, char* argv[])
|
|||
ERROR_LOG(VMEM, "Failed to alloc mem");
|
||||
return -1;
|
||||
}
|
||||
if (ParseCommandLine(argc, argv))
|
||||
{
|
||||
return 69;
|
||||
}
|
||||
ParseCommandLine(argc, argv);
|
||||
if (cfgLoadInt("naomi", "BoardId", 0) != 0)
|
||||
{
|
||||
settings.naomi.multiboard = true;
|
||||
settings.naomi.slave = true;
|
||||
}
|
||||
settings.naomi.drivingSimSlave = cfgLoadInt("naomi", "DrivingSimSlave", 0);
|
||||
|
||||
config::Settings::instance().reset();
|
||||
LogManager::Shutdown();
|
||||
|
|
|
@ -306,6 +306,7 @@ struct settings_t
|
|||
{
|
||||
bool multiboard;
|
||||
bool slave;
|
||||
int drivingSimSlave;
|
||||
} naomi;
|
||||
|
||||
bool disableRenderer;
|
||||
|
|
Loading…
Reference in New Issue