Home Pagee

Home Page

BASIC Handbook

Basic2 Commands
Disk Drives
PEEK's and POKE's
RAM Memory Map
ROM Memory Map
Screen Display
Sprite
ASCII and CHR$ Codes

eMail
email5-commodorecheetah.co.uk

Note: You will need to replace the '-' with the @ symbol.
This is to minimize spam.

My BASIC Quick Reference Guide

Partition Information
for CMD Compatible Devices

Command: PRINT#lf, "G-P" [+CHR$(n)]

To get the current partition information then leave '+CHR$(n)' out or enter 255 at n.
To get the system partition information then enter 0 at n (CMD FD only).
Enter partition number in n to get its information.

Information returned will come through the Error channel as:

BYTE
CONTENTS
DESCRIPTION
0
Partition Type

0 - not created
1 - Native Mode
2 - 1541 Emulation Mode
3 - 1571 Emulation Mode
4 - 1581 Emulation Mode
5 - 1581 CP/M Emulation Mode
6 - Print Buffer
7 - Foreign Made (Direct Access)
255 - System

1

Disk info:

(Only for CMD FD drives, partition 0)

Bit 7 = Disk in drive (1 = yes)
Bit 6 = Formatted disk (1 = yes)
Bit 5 = Valid format (1= CMD/CBM)
Bit 4 = True 1581 disk (1 = yes
Bit 3-0 = Format Type:

Bit 3
Bit 2
Bit 1
Bit 0
Format
0
0
0
0
Unknown
0
0
0
1
800K
0
0
1
0
1.60Mb
0
1
0
0
3.20Mb
0
1
0
1
720K IBM
0
1
1
0
1.44Mb IBM
0
1
1
1
2.88Mb IBM

CMD HD and CMD RAMLink:-
CHR$(0)

2
Partition number
3 - 18
Partition name
19
Starting system address of partition (high byte)
20
Starting system address of partition (middle byte)
21
Starting system address of partition (low byte)
22 - 26
CHR$(0) Reserved
27
Size of partition (high byte)
28
Size of partition (middle byte)
29
Size of partition (low byte)
30
CHR$(13)

Important: To avoid problems with reading information from Partition 13, the G-P command should always sent with a trailing carriage return (CHR$(13)). The BASIC PRINT# statement will do this for you automatically as long as you do not follow it with a trailing semicolon (;).


Commodore Cheetah made by Allen Monks, started in the year 2000.