Disk Command is a set of new commands that you add
to BASIC or ASSEMBLER to assist in editing your programs.
The listing presented here will not give you the
new commands directly. You must insert a formatted disk with either
DOS 2 or DOS 2.5 (it might work with DOS 3 but I haven't tested it)
in drive 1 and then run the Basic program which will produce an
AUTORUN.SYS file. When you re-boot the computer (switch on and off
you will now, if you typed the DATA statements right(!), find a
message on your screen. The message will say 'type HELP'. If you
wish, typing HELP will display the HELP MENU.
HOW IT WORKS
The machine code program interrupts the Get-byte
routine of the Screen Editor and points it to the Disk Command
routine. This waits until RETURN is pressed and then checks the
table of new commands before resuming its normal routines.
The program protects itself from being overwritten
by your programming by moving up MEMLO (743,744) and storing itself
beneath it. It also interrupts DOSINI (12,13) so that when you press
SYSTEM RESET it re-runs. The machine code is less than 3K in length
and because the commands are table driven it shouldn't be very
difficult to add extra commands as necessary.
|
|
|
THE COMMANDS
COMMAND |
OBJECT |
FORMAT |
DIR
|
Disk Directory |
DIR |
RENAME
|
Rename File
|
RENAME D:oldfile,newfile (note the D: in first filename but
not in
second.) |
DELETE
|
Delete file
|
DELETE D:filename.ext |
LOCK
|
Lock file
|
LOCK D:filename.ext |
UNLOCK
|
Unlock file
|
UNLOCK D:filename.ext |
WRDOS
|
Write DOS.SYS
|
WRDOS (You must type Y to prompt if want to write DOS.SYS to
Drive D1:. N.B. DUP.SYS is not written) |
MEMO
|
Goto Memo Pad
|
MEMO (400/800 Users will remember the Note Pad obtain by
typing BYE. This is similar to that only screen will turn
green and you use the ESCAPE Key to EXIT) |
HEX
|
HEX to Decimal Conversion |
HEX hhhh (where hhhh is a 4 figure Hexadecimal number
between 0000 and FFFF)
|
DEC
|
Decimal to HEX Conversion
|
DEC Decnum (where
Decnum is any Decimal number between 0 and 65535)
|
#FORMAT
|
Format Disk
|
#FORMAT (You need to reply Y to the prompt FORMAT (Y/N) for
safety. The # was used so as not to get confused with the
BASIC FOR statement) |
KILL
|
Delete Routine
|
KILL (This command allows you to type DOS. If you type DOS
without typing KILL first the System will `appear' to LOCK
UP. Pressing system reset will correct this then typing DOS
again will take you to DOS. It is still better o type KILL
before typing DOS. |
HELP
|
Show list of Commands |
HELP
|
COL
|
Make Screen colour BLACK |
COL (Just a personal preference I prefer the screen
black !!)
|