CPCWiki forum

General Category => Programming => Topic started by: zhulien on 18:54, 29 April 23

Title: AMSDOS file headers
Post by: zhulien on 18:54, 29 April 23
Hi

Is this page correct?

https://www.cpcwiki.eu/index.php/AMSDOS_Header

Why would a filename be in an actual file header? 
Title: Re: AMSDOS file headers
Post by: HAL6128 on 19:10, 29 April 23
It is correct (see Firmware:  s968se09.PDF (cpcwiki.eu) (https://www.cpcwiki.eu/imgs/b/bc/S968se09.pdf)).

I couldn't answer the "why". :) (developer intention?)
Title: Re: AMSDOS file headers
Post by: pelrun on 03:59, 30 April 23
It doesn't matter for a disk file, but note the fields that are tape only - this is also the TAPE file header (https://www.cpcwiki.eu/imgs/5/5d/S968se08.pdf), and that absolutely needs the filename in it.
Title: Re: AMSDOS file headers
Post by: zhulien on 12:28, 30 April 23
ah thanks, at least CPC has the same header layout for both tape and disc - I was reading about the MSX headers and was confused a bit why they would make 2 different headers (for tape and disc) - actually they have more than 2 for disc even.

I guess cos tape doesn't have the concept of an allocation table or directory.
Title: Re: AMSDOS file headers
Post by: HAL6128 on 16:56, 30 April 23
Actually the tape header can have a 16 characters name whereas disc has 8.3.
Title: Re: AMSDOS file headers
Post by: GUNHED on 18:21, 30 April 23
The Amsdos file header was expanded (in a 100% compatible way) for FutureOS. Now it contains an icon or short file description. Also 24 bit for file length, supporting files up to 16 MB. And data for loading the file into expansion RAM etc (see FutureOS manual).

Title: Re: AMSDOS file headers
Post by: pelrun on 12:09, 01 May 23
Quote from: HAL6128 on 16:56, 30 April 23Actually the tape header can have a 16 characters name whereas disc has 8.3.

Sure, however even in the disc header there is still *room* for a 16 character name, and it doesn't matter because it's the directory that holds the actual filename.
Title: Re: AMSDOS file headers
Post by: HAL6128 on 14:15, 01 May 23
Yes, you are right; @zhulien asked regarding the header layout (tape/disc) and they are different.
Powered by SMFPacks Menu Editor Mod