CPCWiki forum

General Category => Programming => Topic started by: HAL6128 on 21:31, 04 October 15

Title: Determine disc format??
Post by: HAL6128 on 21:31, 04 October 15
How can I determine a format of a floppy (DATA vs. SYSTEM format)?
My intention is to read a sector from disc. I have sector reading routine, but to do this I need some kind of sector ID (&Cx or &4x) which is set manually.

Is there a routine which provide me this sector (head) ID before reading the datas of the sector?? I have read about doing this with the port &FB7F (command &X0m001010 and drive set). But how?
Title: Re: Determine disc format??
Post by: TFM on 21:49, 04 October 15
The best way is to read the sector ID. For Data format this is &Cx and for IBM or Vortex it's &0X (only Vortex can have &09 or a sector ID from head 1 instead of 0). System format has Sektor IDs &4x.


To read a sector ID is very simple. Email me for a OS function from FutureOS. I'm at work now, have no source here.
Powered by SMFPacks Menu Editor Mod