FSRW 2.6 root directory
William50
Posts: 22
in Propeller 1
What is the maximum amount of files that can be stored and/or addressed in the root directory using FSRW 2.6?
Comments
I'm working on a project that uses several sounds; for example:
100_mainmenu.wav
Internally, I have a dat table like this:
By prefixing the sound file name with a number I can keep the first six characters unique, and allow the program to switch to a different group of files by changing the first character of the names in my table; this is very useful in multi-lingual apps. In the example above, group 1 is English, and file 00 is the main menu audio. As you can see, the table entry uses the first six characters of the file name, with "~1" after. If you read the directory with FSRW you will see the files listed in this manner (8.3 format). Note that I only use 3-character extensions on my files.
In my case it's easy to get to the nth file name in the list because all entries use 13 bytes (8 + 1 + 3 + 1 [terminating zerol]); when my strings are variable length I use this method to find the address of the nth item in a list (as above).
That's pretty slick!
Correct me if I'm wrong, but doing that does limit the number of file entries available. Each 11 characters added to a long file name uses up one of the available file entry slots. While FSRW does support FAT32 in terms of the size of files and media, I don't think it allows any entries past the 512 that fit in the fixed size root directory.