Ade Vickers wrote: ... >>Sinclair used 512 byte blocks/sectors on the mdvs. ^_^ > > Of course.... I'd forgotten that. It's been too long since I used a QL in > anger -- even though I have one set up right here in the office :-/ > > So... My estimate of 3.5million MDVs is, in fact, wrong; it should be nearly > 7million MDVs.
Mdvs had a [theoretical] max capacity of 128K, though in practice, it was slightly less: I used to get around 220 sectors on a formatted cartridge giving about 110K. ... > Of course, formatting will remove a lot of that; if one assumes 50%, my > original figure comes out conveniently accurate, for some inexplicable > reason :) On a MDV, 2 sectors were taken at the start: sector 0 is the sector map and another sector was the start of file 0 - the directory for the mdv. The data for each sector had a header which contained the filenumber and block number within that file - the sector map contains a copy of these bytes for all 255 possible data sectors, along with a note of the most recently allocated sector.[1] Other than those 2 sectors, all formatted sectors are available for use for files. Each file has a 64 byte header containing things like name, file type, etc, and this takes the first 64 bytes of the first sector allocated to the file. The directory file (file 0) holds a duplicate copy of these 64 byte headers, the offset within its sector(s) the file number*64. Thus File 0 (the directory) has its header starting at the first byte of first sector of File 0 (this is the only file to have a single copy of this data); File 1 has its header copy starting at offset 64, etc. File 8 has its header starting at offset 512 which is the start of a second sector which is added to the directory file when needed. [1] According to Adrian Dickens: QL Advanced User Guide (with my sumarizing) Bit of a stupid question: Why does each file contain its header in its first 64 bytes (meaning that a file can only hold up to 448 bytes before a second sector is needed for bytes 449-960, etc): why not just use the one in the directory? _______________________________________________ QL-Users Mailing List http://www.q-v-d.demon.co.uk/smsqe.htm
