cd dir list with fileXioDopen

Discuss the development of software, tools, libraries and anything else that helps make ps2dev happen.

Moderators: cheriff, Herben

Post Reply
bbraun
Posts: 5
Joined: Sat Jan 01, 2005 1:11 am

cd dir list with fileXioDopen

Post by bbraun »

Iʻve just started playing with PS2 development with the ps2sdk this weekend, and have had success while experimenting with libpad. Iʻve decided to move on to file manipulation, now that I feel reasonably comfortable with controller interaction, and have run into some trouble.
I wanted to do basic directory listings and file manipulation. However, I cannot seem to get fileXioDopen("cdrom0:\\"); to return. Here is the problematic code:

Code: Select all

   cdInit(CDVD_INIT_INIT);
   cdSetMediaMode(CDVD_MEDIA_MODE_CD);
   d = fileXioDopen("cdrom0:\\");
I do not seem to get past fileXioDopen(); The cdInit() and cdSetMediaMode() are in there as suggested by a previous post in a different forum.
Am I doing something wrong here?
Having just started out, I am also a little confused by the relationship between fileXio and fio. Reading some posts here, they seem to overlap in functionality, but not 100%. Some devices work in one, and others do not?
bbraun
Posts: 5
Joined: Sat Jan 01, 2005 1:11 am

Post by bbraun »

Ah, I just learned about loading the fileXio.irx file to get this functionality. Iʻm getting a little closer to it working now.
bbraun
Posts: 5
Joined: Sat Jan 01, 2005 1:11 am

Post by bbraun »

After talking to a few people on #ps2dev, it seems there is no filesystem driver for cdrom0 to use fioDopen() or fileXioDopen(). It was suggested I look at hiryuʻs libcdvd at http://ps2dev.org/kb.x?T=996 for doing cdrom directory lists.
Post Reply