Disk image file format

This document describes the standard disk image format. It has the file extension ".DSK".

Disc Information block

The "Disc Information block" is always at offset 0 in the disk image file. If track data exists, then this will immediatly follow the Disc Information Block and will start at offset &100 in the disc image file.

The "Disc Information block" has the following structure:

offset description bytes
00-21 "MV - CPCEMU Disk-File\r\nDisk-Info\r\n" 34
22-2f name of creator 14
30 number of tracks 1
31 number of sides 1
32-33 size of a track (little endian; low byte followed by high byte) 2
34-ff not used (0) 204

Notes:

Track Information Block

Each Track Block comprises a Track Information Block and sector data. The sector data is always at an offset of &100 bytes from the start of the track block. The data for the next track in the disc image immediatly follows the data for the current track.

The first Track Block is located at offset &100 in the disk image file. The track block starts with the Track Information Block and has this form.

offset description bytes
00 - 0c "Track-Info\r\n" 13
0d - 0f unused 3
10 track number 1
11 side number 1
12 - 13 unused 2
14 sector size 1
15 number of sectors 1
16 GAP#3 length 1
17 filler byte 1
18 - xx Sector Information List xx

Notes:

Sector info

offset description bytes
00 track (equivalent to C parameter in NEC765 commands) 1
01 side (equivalent to H parameter in NEC765 commands) 1
02 sector ID (equivalent to R parameter in NEC765 commands) 1
03 sector size (equivalent to N parameter in NEC765 commands) 1
04 FDC status register 1 (equivalent to NEC765 ST1 status register) 1
05 FDC status register 2 (equivalent to NEC765 ST2 status register) 1
06 - 07 notused (0) 2

Notes:

General format

Single sided DSK images

Double sided DSK images