Next Previous Contents

7.3 cbmformat

cbmformat is a fast low-level disk formatter for the 1541 and compatible devices (1570, 1571, third-party clones). A 1581 drive is not supported.

The drive routine was taken from the Star Commander ((C) Joe Forster/STA) and highly improved.

There is also another, very similar tool, cbmforng.

cbmformat invocation

Synopsis: cbmformat [OPTION]... DRIVE# NAME,ID

DRIVE# has to be the drive number of the disk drive, NAME is a name with up to 16 characters which will be the name of the disk after formatting, ID is the 2-letter disk ID.

Note: Unlike the N0 command of the drive, the ID must be given (thus, no so-called "short format" is possible).

Here's a complete list of known options:

-h, --help

Display help and exit.

-V, --version

Display version information and exit.

-@, --adapter=<plugin>[:<bus>]

Specify the plugin to use. If you have installed more than one plugin (XA1541, XU1541, XUM1541), you can specifiy which one to use for this command. This way, you can use all three variants at the same time.

This requires an argument of the form <plugin>[:<bus>], where <plugin> is the plugin's backend name (currently: xa1541, xu1541, xum1541), and <bus> is the bus identifier, if it is supported by the backend.

-n, --no-bump

Do not bump drive head at the beginning. Don't use this on eventually misaligned drives.

-x, --extended

Format a 40 track disk, the BAM format is compatible to SpeedDOS.

-c, --clear

clear (demagnetize) this disk. This is highly recommended if the disk is used for the first time, or if it was previously formatted for another system (i.e., MS-DOS). Note that this option takes much time.

-v, --verify

verify each track after it is written. As this needs an extra round of the drive for each track, the formatting time is almost doubled.

cf. cbmformat Notes for 1571 drives

-o, --original

Fill sectors with the original pattern (0x4b, 0x01, 0x01...) instead of zeroes. The original pattern is probably due to a bug in the drive ROM, apart from this, zeroing out unused sectors should give (slightly) better results for compressed disk images.

cf. cbmformat Notes for 1571 drives

-s, --status

Display drive status after formatting. Normally, cbmformat exits after executing the drive code. With this option turned on, cbmformat waits until the drive has finished formatting and prints the drive status after initializing the BAM on standard out.

-p, --progress

Display a hash mark ('#') for each formatted track. Slows formatting down a bit.

cbmformat Notes for 1571 drives

We encountered problems with decent revision/mechanics combinations of the 1571 disk drives when using cbmformat. We highly recommend to use --original and --verify with 1571 drives. From our experience, with --original, the problem does not occur; with --verify, the drive tests each track after it was formatted and ensures that the failure condition did not occur.

We did not encounter these problems with either of 1541 (1541-II, 1541C), 1570 or 1571CR (the drive which is part of the C128DCR) drives, only with original 1571 drives.

In the current state, cbmformat is not able to format double-sided disks on a 1571 drive.

cbmformat Examples

Format standard disk (35 tracks) in drive 8:


cbmformat 8 GAMES,42

Format standard disk (35 tracks) in drive 9, use (buggy) 1541 sector pattern (for example, because this is a 1571 drive), show drive status when done:


cbmformat -os 9 1571disk,71

SpeedDOS disk (40 tracks), show progress indicator, all sectors zeroed out, no head banging:


cbmformat -npx 8 "40 TRACKS,OK"


Next Previous Contents