Git Product home page Git Product logo

Comments (6)

israpps avatar israpps commented on August 16, 2024

Found one issue after reading some parts of libcglue.

the issue is calling ps2time()
Wich inside has a call to CDVD RPC sceCdReadClock

Namco arcades don't have CDVDFSV listed on rom0:IOPBTCONF 1

Therefore, the most sane solution would be to override it like I did, but then call a custom implementation of it taking place after loading the IOPRP image and manually loading CDVDFSV:

id = SifLoadStartModule("rom0:CDVDFSV", 0, NULL, &ret);
if (id < 0 || ret == 1) we_have_a_problem();

Another option would be to include a custom IOPBTCONF with the following contents into the already needed IOPRP Image: (yet overriding the libcglue init is still needed)

!include IOPBTCONF
CDVDFSV

Arcade IOPBTCONF

@800
SYSMEM
LOADCORE
BOARDINF
EXCEPMAN
INTRMANP
INTRMANI
SSBUSC
DMACMAN
TIMEMANP
TIMEMANI
SYSCLIB
HEAPLIB
EECONF
THREADMAN
VBLANK
IOMAN
MODLOAD
ROMDRV
STDIO
SIFMAN
#DECI2
#DECI2DRP
#DECI2DRS
#DECI2FILE
#DECI2HSYN
#DECI2KPRT
IGREETING
SIFCMD
REBOOT
LOADFILE
#APPLOAD
#DECI2LOAD
ACDEV
SIFINIT
FILEIO
CDVDMAN
SECRMAN
#SSND
#LED
EESYNC

Footnotes

from ps2sdk.

israpps avatar israpps commented on August 16, 2024

Another option would be to change how we deal with RPC bindings on PS2SDK.

On KELFBinder, I made SECRSIF RPC Bind function return an error after any RPC bind failed 500 times.

Many apps Could benefit of such feature. of course, probably the app will not be able to function completely without that RPC. but at least it gives you a chance to call a function where you change the BG color to indicate and error, and if the lack of that RPC is severe, maybe call SleepThread() too

from ps2sdk.

fjtrujy avatar fjtrujy commented on August 16, 2024

Hello @israpps !
Nice investigation.
I think that solution for you is actually easier than this...

On the file ee/libcglue/src/rtc.c we have that function void _libcglue_rtc_update() which is weak. This function is the only one that uses ps2time, so for your [System 2x6] machines you just need to do void _libcglue_rtc_update() {} overriding weak symbols and should be enough.

This function in theory is just used to get the current date and time, (https://man7.org/linux/man-pages/man2/gettimeofday.2.html ), so unless you want to print the current date.... this shouldn't be a problem for you 😃

If you see in the ps2sdk samples we have one which actually overrides this too, take a look at ee/libcglue/samples/mem_test/main.c.

Cheers

from ps2sdk.

fjtrujy avatar fjtrujy commented on August 16, 2024

@israpps any update?

from ps2sdk.

israpps avatar israpps commented on August 16, 2024

@israpps any update?

Haven't taken a look at it yet.

from ps2sdk.

uyjulian avatar uyjulian commented on August 16, 2024

cdvdfsv is not loaded by default on those systems, but fileio devctls to get time to cdrom: should work since those systems have a newer cdvdman.

I'll eventually implement it once I make some improvements to ioman/iomanX/fileio differing version handling.

from ps2sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.