romdisk?

If you have any questions on programming, this is the place to ask them, whether you're a newbie or an experienced programmer. Discussion on programming in general is also welcome. We will help you with programming homework, but we will not do your work for you! Any porting requests must be made in Developmental Ideas.
Post Reply
arcticblue
DC Developer
DC Developer
Posts: 60
https://www.artistsworkshop.eu/meble-kuchenne-na-wymiar-warszawa-gdzie-zamowic/
Joined: Wed Oct 17, 2001 7:44 pm
Has thanked: 0
Been thanked: 0

romdisk?

Post by arcticblue »

I just moved from libdream (I wasn't there long) to KOS and I'm lost. First of all, what is a romdisk? Also, what about serial_disable() and bfont_draw_str()? What are the equivalents in KOS?
Sanchez
DCEmu Ex-Admin
DCEmu Ex-Admin
Posts: 1098
Joined: Wed Oct 17, 2001 7:44 pm
Has thanked: 0
Been thanked: 0

Post by Sanchez »

The romdisk is for storing information, files, etc that your program would need without requiring the use of the CD, VMU, or BBA to load the info from. It's especially useful if you need a base directory of files to run your program, but you need to swap CDs, etc.

One thing to note is the romdisk is linked into your executable, increasing the size of the elf file accordingly. In other words, it's not a good place to store large numbers of files, etc.... One piece it's often needed for is to store the stream.drv file for any SPU access (thanks Atani!)

As for serial_disable, there's an option for kos_init that will do it, although the better thing to do is use a -DDEBUG option to your makefile so it will only compile in the printf's when you need them. As for bfont_draw_str, it's the same command....
User avatar
toastman
Iron Fist of Justice
Iron Fist of Justice
Posts: 4933
Joined: Sat Nov 10, 2001 3:08 am
Location: New Orleans
Has thanked: 0
Been thanked: 0
Contact:

i had find out the hard way

Post by toastman »

i had to find out the hard way about sound.drv :D
thanks example code :lol:
Sanchez
DCEmu Ex-Admin
DCEmu Ex-Admin
Posts: 1098
Joined: Wed Oct 17, 2001 7:44 pm
Has thanked: 0
Been thanked: 0

Post by Sanchez »

Heh.. no kidding... I couldn't figure out why the example ogg program worked and mine didn't when it was the exact same code for the ogg loading....

Thanks to Atani, I had one of those "bang your head on the desk" moments of clarity...
arcticblue
DC Developer
DC Developer
Posts: 60
Joined: Wed Oct 17, 2001 7:44 pm
Has thanked: 0
Been thanked: 0

Post by arcticblue »

hey, thanks a lot. I didn't expect to get a reply this quick(especially in the programming forum).
atf487
DCEmu's Ranter
DCEmu's Ranter
Posts: 2529
Joined: Sun Feb 17, 2002 2:54 pm
Has thanked: 0
Been thanked: 0

Post by atf487 »

I always thought it was "ramdisk". Guess i was wrong.
Sanchez
DCEmu Ex-Admin
DCEmu Ex-Admin
Posts: 1098
Joined: Wed Oct 17, 2001 7:44 pm
Has thanked: 0
Been thanked: 0

Post by Sanchez »

I always thought it was "ramdisk". Guess i was wrong.
There's a very subtle difference here between a romdisk and a ramdisk. Both are virtual, and both occupy a portion of memory. The difference is, that like rom vs ram, a romdisk is read-only while a ramdisk actually allows you to write data to memory as though it were a disk.
atf487
DCEmu's Ranter
DCEmu's Ranter
Posts: 2529
Joined: Sun Feb 17, 2002 2:54 pm
Has thanked: 0
Been thanked: 0

Post by atf487 »

Thanks for the info, sanchez.
Sanchez
DCEmu Ex-Admin
DCEmu Ex-Admin
Posts: 1098
Joined: Wed Oct 17, 2001 7:44 pm
Has thanked: 0
Been thanked: 0

Post by Sanchez »

No prob.... on rare occasions, I actually know something...
Post Reply