X16 largest file size

Chat about anything CX16 related that doesn't fit elsewhere
Post Reply
xanthrou
Posts: 165
Joined: Mon Jan 25, 2021 11:57 am

X16 largest file size

Post by xanthrou »


What is the largest possible file size on X16 that theoretically could be achieved?

Ender
Posts: 220
Joined: Sat May 09, 2020 9:32 pm

X16 largest file size

Post by Ender »


I'm not sure what you mean exactly? Like, the maximum size that could be loaded into lower memory all at once without overwriting anything essential?  Probably from $400 to $9F00, so around 38.75KB.  If you write an algorithm to, for example, read one byte at a time and copy them into RAM as you do, it would be that 38.75KB plus the 2MB of maximum RAM, so 2.03875MB.  Of course, it would be dangerous to assume you have all 256 RAM banks available, as some, or most, users wouldn't actually have that much installed in their machine.

kelli217
Posts: 541
Joined: Sun Jul 05, 2020 11:27 pm

X16 largest file size

Post by kelli217 »


I can set an upper bound for you: 4GB. That's inherent to FAT32 as a filesystem. Whether or not the ROM can even begin to support files of that size, I couldn't venture a guess. I did read some of the docs, and the size of the filesystem itself can go up to 2TB. That's the limit for FAT32 anyway, so the file size limit is probably the same, too.

xanthrou
Posts: 165
Joined: Mon Jan 25, 2021 11:57 am

X16 largest file size

Post by xanthrou »



5 minutes ago, kelli217 said:




I can set an upper bound for you: 4GB. That's inherent to FAT32 as a filesystem. Whether or not the ROM can even begin to support files of that size, I couldn't venture a guess. I did read some of the docs, and the size of the filesystem itself can go up to 2TB. That's the limit for FAT32 anyway, so the file size limit is probably the same, too.



X16 uses FAT32?

kelli217
Posts: 541
Joined: Sun Jul 05, 2020 11:27 pm

X16 largest file size

Post by kelli217 »



17 minutes ago, xanthrou said:




X16 uses FAT32?



It does for the SD card, yes. 

TomXP411
Posts: 1804
Joined: Tue May 19, 2020 8:49 pm

X16 largest file size

Post by TomXP411 »


Yes, the X16 uses FAT32, and the file seek command takes 4 bytes. So it’s possible to create and make use of a 4GB file. 

 

You obviously can’t load 4GB into RAM, but that’s part of why the Seek command was introduced - to allow you to dynamically loads portions of the file you actually need, as you need them. 

Post Reply