PS4 [Research]PS2 emulator configuration on PS4

This game has got some crazy DMA related issues (it does freeze on the PS3 randomly too). PCSX2 patches were ugly and broken, they worked by a pure luck (somebody patched a kernel space reserved area). I would rather consider trying different eeObj.SchedulerDelayEvent values with various events, like vif1.dma, gif.dma, ipu0.dma, ipu1.dma, etc.

Prisoner of Azkaban may be affected too.
you mean this PCSX2 patches?

Code:
comment=Harry Potter and The Chamber of Secrets [SLUS 20576] (U)
//prafull's highly experimental patch
//fix initial hang
patch=1,EE,002032bc,word,03e00008
//load game quickly
patch=1,EE,001f704c,word,1000000f
//this probably corrupts the graphics but without this the game will hang ingame
patch=1,EE,001f70b4,word,1000000f
//these patches remove the intro movies (needed for reliability)
patch=1,EE,0045e7d0,word,03e00008
patch=1,EE,0045e7d4,word,00000000
 
You don't need that patch in Kasai v1, when using --cdvd-sector-read-cycles=5000 in CLI. The EA/WB logo and FMV run without any issues. When you enter the main menu every entry (even Options) will crash the emu though.

Also works with Parappa 2 v1(to title screen, then crash after selecting new game or options). No settings applied.

This 30/60hz switching seems to big issue for a lot of (EA) games. Perhaps we can implement something like this (from Jak* emus):
Code:
-- Force MPEG movies to 30Hz to prevent stutters
local halfspeed = 0
local fixupMPEGsync1 = function()
    -- always capture this flag
    halfspeed = eeObj.ReadMem32(eeObj.GetGpr(gpr.gp) + 0x9c)
    local falseval = eeObj.GetGpr(gpr.s7)
  
    -- check if we're running a FMV
    if eeObj.GetGpr(gpr.v1) ~= falseval then
        -- pretend we're not and set 30hz to force and extra syncv()
        eeObj.SetGpr(gpr.v1, falseval) -- 3020801 = false
        eeObj.WriteMem32(eeObj.GetGpr(gpr.gp) + 0x9c, falseval + 4) -- 3020805 = true
    end
end

local fixupMPEGsync2 = function()
    -- restore half-speed flag
    eeObj.WriteMem32(eeObj.GetGpr(gpr.gp) + 0x9c, halfspeed)
end


eeOverlay.AddPostHook("drawable.main", 0x16c, 0x9c6302fc, fixupMPEGsync1)
eeOverlay.AddPostHook("drawable.main", 0x184, 0x8ef90173, fixupMPEGsync2)

That would be great. How would I go about finding the correct addresses for each game?
 
That would be great. How would I go about finding the correct addresses for each game?
Trial and error like everything we do here... :hopelessness:
But seriously I think the only chance is to look up these addresses from Jak1-3,X in hex and see if they share a common pattern.
 
Not sure if this is the right place to ask this, but does the multiplayer functionality work on emulated ps2 games?
I'd like to play some split screen shooters and fighting games but I'd rather check first before I actually buy a second controller.
 
Not sure if this is the right place to ask this, but does the multiplayer functionality work on emulated ps2 games?
I'd like to play some split screen shooters and fighting games but I'd rather check first before I actually buy a second controller.
Depends games of course!
For sure command
Code:
--mtap1=always
--mtap2=always
work for example in Digimon World 4
VIDEO
 
Fix for DreamWorks Madagascar (SLUS-21015)

CLI
Code:
--gs-uprender=2x2
--gs-upscale=EdgeSmooth

--host-display-mode=16:9
--cdvd-sector-read-cycles=2000

--vu1-no-clamping=0

#emu used=psychonauts v1
LUA
Code:
-- DreamWorks Madagascar (U)(SLUS-21015)
-- Widescreen Hack by Arapapa
-- ported to PS4
-- emu used=psychonauts v1

apiRequest(0.1)

local gpr       = require("ee-gpr-alias")

local emuObj      = getEmuObject()
local eeObj       = getEEObject()

--Widescreen hack 16:9
eeInsnReplace(0x0014a0e0,0x3c013f00,0x3c013f21) -- 0x3c013f00

eeInsnReplace(0x002881c8,0x46010043,0x08045ca0) -- 0x46010043 div.s $f1, $f0, $f1

eeInsnReplace(0x00117280,0x00000000,0x46010043) -- 0x00000000 nop
eeInsnReplace(0x00117284,0x00000000,0x3c013f40) -- 0x00000000 nop
eeInsnReplace(0x00117288,0x00000000,0x4481f000) -- 0x00000000 nop
eeInsnReplace(0x0011728c,0x00000000,0x461e1082) -- 0x00000000 nop
eeInsnReplace(0x00117290,0x00000000,0x080a2073) -- 0x00000000 nop

--Unlock All Levels by MadCatz
eeInsnReplace(0x20BB39AC,0x00000000,0x0000000B)

local patch = function()


emuObj.ThrottleMax()
end

emuObj.AddVsyncHook(patch)
 
Moorhuhn Collection Compilation Gameplay PSX/PS2toPS4 Test

FiX for Moorhuhn X (SLES54468)
Code:
--force-frame-blend=1

in txt.

FiX for Moorhuhn Fun Kart 2008 (SLES55122)
Code:
-- Moorhuhn Fun Kart 2008
-- emu used=ADK

apiRequest(1.0)   

local gpr = require("ee-gpr-alias")

local eeObj = getEEObject()
local emuObj = getEmuObject()

local patcher = function()

--Widescreen hack
--X-Fov
eeObj.WriteMem32(0x001997d0,0x08030000) -- 46001082

eeObj.WriteMem32(0x000c0000,0x46001082) -- 00000000
eeObj.WriteMem32(0x000c0004,0x3c013f40) -- 00000000
eeObj.WriteMem32(0x000c0008,0x4481f000) -- 00000000
eeObj.WriteMem32(0x000c000c,0x461e1082) -- 00000000
eeObj.WriteMem32(0x000c0010,0x080665f5) -- 00000000

emuObj.ThrottleMax()
end

emuObj.AddVsyncHook(patcher)

in lua.

Shaking screen issue for Moorhuhn X game - FiXed! Widescreen patch added for Moorhuhn Fun Kart 2008! Speed up loading screens for both ps2 games!
 
Fix for Harry Potter and the Sorcerer's Stone (NTSC-U)

CLI
Code:
--gs-uprender=2x2
--gs-upscale=edgesmooth
--gs-kernel-cl="h2lpool"
--gs-kernel-cl-up="h2lpool2x2"

--cdvd-sector-read-cycles=4000
--ee-cycle-scalar=2.0

--vu1-mpg-cycles=1750

#emu used=rotk v1
LUA
Code:
-- Harry Potter and the Sorcerer's Stone (NTSC-U)
-- Widescreen hack by ElHecht
-- emu used=rotk v1

local gpr = require("ee-gpr-alias")

apiRequest(0.1)

local eeObj = getEEObject()
local emuObj = getEmuObject()

emuObj.SetDisplayAspectWide()

local patcher = function()
-- 16:9
eeObj.WriteMem32(0x0018da74,0x3c013f40) -- e494d5c4 hor fov gameplay
eeObj.WriteMem32(0x0018da78,0xac81d5c4) -- 0c0c17e4
eeObj.WriteMem32(0x0018da80,0x0c0c17e4) -- 00000000

eeObj.WriteMem32(0x2036D5C4,0x3F400000) -- troll greenhouse battle

eeObj.WriteMem32(0x002b4258,0x3c013f40) -- 3c013faa hor fov cut-scenes 1
eeObj.WriteMem32(0x002b425c,0x4481f000) -- 3421aaab
eeObj.WriteMem32(0x002b426c,0x0c0abc0d) -- 0c0abc0e
eeObj.WriteMem32(0x002b4270,0x460d6343) -- 460d6342

eeObj.WriteMem32(0x002b453c,0x3c013f40) -- 3c013faa hor fov cut-scenes 2
eeObj.WriteMem32(0x002b4540,0x4481f000) -- 3421aaab
eeObj.WriteMem32(0x002b4554,0x0c0abc0d) -- 0c0abc0e
eeObj.WriteMem32(0x002b4558,0x460d6343) -- 460d6342

eeObj.WriteMem32(0x002af034,0x461e6302) -- 00000000

--60 fps
--eeObj.WriteMem32(0x203A4FD8,0x00000001)

emuObj.ThrottleMax()
end

emuObj.AddVsyncHook(patcher)
 
Config for Mega Man X™ Collection®

CLI
Code:
--gs-uprender=2x2
--gs-upscale=point
--gs-kernel-cl-up="up2x2skipinterp"
--cdvd-sector-read-cycles=4400
--host-display-mode=16:9

#emu used=aofa
LUA
Code:
-- Mega Man X™ Collection®
-- emu used=aofa

local gpr = require("ee-gpr-alias")

apiRequest(0.1)

local eeObj = getEEObject()
local emuObj = getEmuObject()

local patcher = function()
--Force Videout to 480i instead of 240p by lee4
eeObj.WriteMem32(0x2014499C,0x24110001)
eeObj.WriteMem32(0x201449A0,0x24120002)
eeObj.WriteMem32(0x201449AC,0x24130000)
--Unlock Mega Man Battle & Chase by Code Master
local unlock1 = eeObj.ReadMem16(0x662E84)
if unlock1 == 0x0001 then
eeObj.WriteMem32(0x00669980,0x00000001)
end
--All Gallery by Code Master
local unlock2 = eeObj.ReadMem16(0x662E84)
if unlock2 == 0x0001 then
eeObj.WriteMem32(0x206699C4,0xFFFFFFFF)
end

-- Widescreen Selector
local pad_bits    = emuObj.GetPad()

local L1  = pad_bits &  0x0400
local L3  = pad_bits &  0x0002
local R1  = pad_bits &  0x0800
local R3  = pad_bits &  0x0004

if (L1 ~= 0 and R3 ~= 0) then --Normal Screen
--4:3
emuObj.SetDisplayAspectNormal()
end

if (L3 ~= 0 and R1 ~= 0) then --Widescreen Screen
--16:9
emuObj.SetDisplayAspectWide()
end

end

emuObj.AddVsyncHook(patcher)
 
Enhancement for Assault Suits Valken PAL

CLI
Code:
--gs-uprender=2x2
--gs-upscale=edgesmooth
--cdvd-sector-read-cycles=4000
--host-display-mode=16:9
--host-vsync=1
--gs-progressive=1

#emu used=kof98um
LUA
Code:
-- Assault Suits Valken (Europe) SLES_532.33;1) Game CRC = 0x1E177BBC
-- Enable native progressive mode by Felixthecat1970
-- emu used=kof98um

local gpr = require("ee-gpr-alias")

apiRequest(2.0)

local eeObj = getEEObject()
local emuObj = getEmuObject()

local patcher = function()
--480p + skip pal-ntsc selector + corrections
eeObj.WriteMem32(0x2011D908,0x00000000) --patch this file to SLES_532.33 when promted
eeObj.WriteMem32(0x2020FB0C,0x24050004)
eeObj.WriteMem32(0x2020FB10,0x240701C0)
eeObj.WriteMem32(0x2020BA40,0x6466013E)
eeObj.WriteMem32(0x2020BA44,0x24A30033)


emuObj.ThrottleMax()
end

emuObj.AddVsyncHook(patcher)

Tested. Works great!
 
Last edited:
Fix for Beat Down - Fists of Vengeance (SLUS-21150)

CLI
Code:
--gs-uprender=2x2
--gs-upscale=edgesmooth
--gs-progressive=1
--gs-force-bilinear=1

--host-vsync=1
--host-display-mode=16:9

--cdvd-sector-read-cycles=4000
--vu1-no-clamping=0 #fixes disappearing shadows 

#emu used=parappa v1
LUA
Code:
-- Beat Down - Fists of Vengeance (U) (SLUS-21150)
-- Widescreen Hack (16:9) by ElHecht
-- emu used=parappa v1

local gpr = require("ee-gpr-alias")

apiRequest(0.1)

local eeObj = getEEObject()
local emuObj = getEmuObject()

local patcher = function()
--X-Fov
eeObj.WriteMem32(0x002661f0,0x080f8050) -- c6010068
eeObj.WriteMem32(0x003e0140,0x3c013f40) -- 00000000
eeObj.WriteMem32(0x003e0144,0x4481f000) -- 00000000
eeObj.WriteMem32(0x003e0148,0xc6010068) -- 00000000
eeObj.WriteMem32(0x003e014c,0xc602006c) -- 00000000
eeObj.WriteMem32(0x003e0150,0x461e0843) -- 00000000
eeObj.WriteMem32(0x003e0154,0xe6010068) -- 00000000
eeObj.WriteMem32(0x003e0158,0x0809987e) -- 00000000

--emuObj.ThrottleMax()
end

emuObj.AddVsyncHook(patcher)

Parappa v1 was only emu that got past boot crash for me. I did not try all of them.
 

Similar threads

Back
Top